From 979f50e101d52133773df5dca3f615e7b4abcaa0 Mon Sep 17 00:00:00 2001 From: Adi Oanca Date: Sat, 3 Apr 2004 15:01:10 +0000 Subject: [PATCH] added a PrintToStream method git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7146 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/servers/app/server/LayerData.cpp | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/src/servers/app/server/LayerData.cpp b/src/servers/app/server/LayerData.cpp index 52eb5eddc6..f647090062 100644 --- a/src/servers/app/server/LayerData.cpp +++ b/src/servers/app/server/LayerData.cpp @@ -27,6 +27,7 @@ //------------------------------------------------------------------------------ #include "LayerData.h" #include +#include DrawData::DrawData(void) { @@ -136,6 +137,7 @@ LayerData &LayerData::operator=(const LayerData &from) patt=from.patt; draw_mode=from.draw_mode; + penlocation=from.penlocation; lineCap=from.lineCap; lineJoin=from.lineJoin; @@ -169,3 +171,27 @@ LayerData &LayerData::operator=(const LayerData &from) return *this; } + +void LayerData::PrintToStream() const{ + printf("\t Pen Location and Size: (%f, %f) - %f\n", penlocation.x, penlocation.y, pensize); + printf("\t HighColor: "); highcolor.PrintToStream(); + printf("\t LowColor: "); lowcolor.PrintToStream(); + printf("\t ViewColor "); viewcolor.PrintToStream(); + printf("\t Pattern: %llu\n", patt.GetInt64()); + printf("\t DrawMode: %lu\n", (uint32)draw_mode); + printf("\t LineCap: %d\t LineJoin: %d\t MiterLimit: %f\n", (int16)lineCap, (int16)lineJoin, miterLimit); + printf("\t AlphaSrcMode: %ld\t AlphaFncMode: %ld\n", (int32)alphaSrcMode, (int32)alphaFncMode); + printf("\t Scale: %f\n", scale); + if (clippReg) + clippReg->PrintToStream(); + + printf("\t ===== Font Data =====\n"); + printf("\t FontStyle: CURRENTLY NOT SET\n"); + printf("\t FontSize: %f\n", font.Size()); + printf("\t FontShear: %f\n", font.Shear()); + printf("\t FontRotation: %f\n", font.Rotation()); + printf("\t FontSpacing: %ld\n", font.Spacing()); + printf("\t FontEncoding: %ld\n", font.Encoding()); + printf("\t FontFace: %ld\n", font.Face()); + printf("\t FontFlags: %lu\n", font.Flags()); +}