[Libreoffice-commits] core.git: 2 commits - include/vcl ios/experimental vcl/source
Tor Lillqvist
tml at collabora.com
Tue Jun 3 14:02:47 PDT 2014
include/vcl/metaact.hxx | 3
ios/experimental/TiledLibreOffice/TiledLibreOffice.xcodeproj/project.pbxproj | 38 ++++
vcl/source/gdi/metaact.cxx | 81 +++++++++-
3 files changed, 120 insertions(+), 2 deletions(-)
New commits:
commit e909cf1b226d94791b523234779c22a38439e869
Author: Tor Lillqvist <tml at collabora.com>
Date: Tue Jun 3 18:55:27 2014 +0300
Add more source files for debugging convenience
Change-Id: I305870bd067d015d975b7a887bece91819810ec4
diff --git a/ios/experimental/TiledLibreOffice/TiledLibreOffice.xcodeproj/project.pbxproj b/ios/experimental/TiledLibreOffice/TiledLibreOffice.xcodeproj/project.pbxproj
index 3872449..ca5108f 100644
--- a/ios/experimental/TiledLibreOffice/TiledLibreOffice.xcodeproj/project.pbxproj
+++ b/ios/experimental/TiledLibreOffice/TiledLibreOffice.xcodeproj/project.pbxproj
@@ -741,6 +741,16 @@
BECAB371186054DE00F814F9 /* lo.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = lo.mm; sourceTree = "<group>"; };
BED2593E18F6B87900C94C72 /* ImageIO.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ImageIO.framework; path = System/Library/Frameworks/ImageIO.framework; sourceTree = SDKROOT; };
BED2594018F6B89000C94C72 /* MobileCoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MobileCoreServices.framework; path = System/Library/Frameworks/MobileCoreServices.framework; sourceTree = SDKROOT; };
+ BED53168193738D800830918 /* bitmapaction.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = bitmapaction.cxx; path = ../../../cppcanvas/source/mtfrenderer/bitmapaction.cxx; sourceTree = "<group>"; };
+ BED53169193738D800830918 /* cachedprimitivebase.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = cachedprimitivebase.cxx; path = ../../../cppcanvas/source/mtfrenderer/cachedprimitivebase.cxx; sourceTree = "<group>"; };
+ BED5316A193738D800830918 /* emfplus.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = emfplus.cxx; path = ../../../cppcanvas/source/mtfrenderer/emfplus.cxx; sourceTree = "<group>"; };
+ BED5316B193738D800830918 /* implrenderer.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = implrenderer.cxx; path = ../../../cppcanvas/source/mtfrenderer/implrenderer.cxx; sourceTree = "<group>"; };
+ BED5316C193738D800830918 /* lineaction.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = lineaction.cxx; path = ../../../cppcanvas/source/mtfrenderer/lineaction.cxx; sourceTree = "<group>"; };
+ BED5316D193738D800830918 /* mtftools.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = mtftools.cxx; path = ../../../cppcanvas/source/mtfrenderer/mtftools.cxx; sourceTree = "<group>"; };
+ BED5316E193738D800830918 /* pointaction.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = pointaction.cxx; path = ../../../cppcanvas/source/mtfrenderer/pointaction.cxx; sourceTree = "<group>"; };
+ BED5316F193738D800830918 /* polypolyaction.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = polypolyaction.cxx; path = ../../../cppcanvas/source/mtfrenderer/polypolyaction.cxx; sourceTree = "<group>"; };
+ BED53170193738D800830918 /* textaction.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = textaction.cxx; path = ../../../cppcanvas/source/mtfrenderer/textaction.cxx; sourceTree = "<group>"; };
+ BED53171193738D800830918 /* transparencygroupaction.cxx */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; name = transparencygroupaction.cxx; path = ../../../cppcanvas/source/mtfrenderer/transparencygroupaction.cxx; sourceTree = "<group>"; };
BEDB0F08185B7537009A6F26 /* lo.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = lo.xcconfig; path = ../../../lo.xcconfig; sourceTree = "<group>"; };
BEEE02CE1860ABB700FBDE67 /* program */ = {isa = PBXFileReference; lastKnownFileType = folder; name = program; path = Resources/program; sourceTree = SOURCE_ROOT; };
BEEE02CF1860ABB700FBDE67 /* share */ = {isa = PBXFileReference; lastKnownFileType = folder; name = share; path = Resources/share; sourceTree = SOURCE_ROOT; };
@@ -802,10 +812,11 @@
BE0898E61860D3CD0021A679 /* LibreOffice source files */ = {
isa = PBXGroup;
children = (
- BE82C47118CA18D70050EB79 /* drawinglayer */,
BE9F45F81868393D00B8BE69 /* bridges */,
BE55B10518DAD85E00950228 /* cppu */,
BE35B58A188FFA43001B7439 /* cppuhelper */,
+ BED531661937389B00830918 /* cppcanvas */,
+ BE82C47118CA18D70050EB79 /* drawinglayer */,
BECA60D9191026BA00B24A7E /* framework */,
BE03BF9418FC199B00620DC7 /* i18npool */,
BE55B10818DB673300950228 /* oox */,
@@ -1807,6 +1818,31 @@
name = services;
sourceTree = "<group>";
};
+ BED531661937389B00830918 /* cppcanvas */ = {
+ isa = PBXGroup;
+ children = (
+ BED53167193738B000830918 /* mtfrenderer */,
+ );
+ name = cppcanvas;
+ sourceTree = "<group>";
+ };
+ BED53167193738B000830918 /* mtfrenderer */ = {
+ isa = PBXGroup;
+ children = (
+ BED53168193738D800830918 /* bitmapaction.cxx */,
+ BED53169193738D800830918 /* cachedprimitivebase.cxx */,
+ BED5316A193738D800830918 /* emfplus.cxx */,
+ BED5316B193738D800830918 /* implrenderer.cxx */,
+ BED5316C193738D800830918 /* lineaction.cxx */,
+ BED5316D193738D800830918 /* mtftools.cxx */,
+ BED5316E193738D800830918 /* pointaction.cxx */,
+ BED5316F193738D800830918 /* polypolyaction.cxx */,
+ BED53170193738D800830918 /* textaction.cxx */,
+ BED53171193738D800830918 /* transparencygroupaction.cxx */,
+ );
+ name = mtfrenderer;
+ sourceTree = "<group>";
+ };
BEEEF9681860A21F00FBDE67 /* Resources */ = {
isa = PBXGroup;
children = (
commit 5b886c730ed2b85624e32d516fc74bfe21666c06
Author: Tor Lillqvist <tml at collabora.com>
Date: Tue Jun 3 18:25:05 2014 +0300
Add (debugging) function to get the symbolic name of a MetaAction
Change-Id: I3c1e5c23e7be636cc93c97da0c2db00ebb1050e3
diff --git a/include/vcl/metaact.hxx b/include/vcl/metaact.hxx
index 29bf6cd..4709d24 100644
--- a/include/vcl/metaact.hxx
+++ b/include/vcl/metaact.hxx
@@ -88,7 +88,10 @@ public:
void Delete() { if ( 0 == --mnRefCount ) delete this; }
public:
+ OUString GetTypeName() { return TypeName( mnType ); }
+
static MetaAction* ReadMetaAction( SvStream& rIStm, ImplMetaReadData* pData );
+ static OUString TypeName( sal_uInt16 nType );
};
class VCL_DLLPUBLIC MetaPixelAction : public MetaAction
diff --git a/vcl/source/gdi/metaact.cxx b/vcl/source/gdi/metaact.cxx
index fee3d80..30fab31 100644
--- a/vcl/source/gdi/metaact.cxx
+++ b/vcl/source/gdi/metaact.cxx
@@ -33,6 +33,79 @@
namespace
{
+const char *
+meta_action_name(sal_uInt16 nMetaAction)
+{
+#ifndef SAL_LOG_INFO
+ (void) nMetaAction;
+ return "";
+#else
+ switch( nMetaAction )
+ {
+ case META_NULL_ACTION: return "NULL";
+ case META_PIXEL_ACTION: return "PIXEL";
+ case META_POINT_ACTION: return "POINT";
+ case META_LINE_ACTION: return "LINE";
+ case META_RECT_ACTION: return "RECT";
+ case META_ROUNDRECT_ACTION: return "ROUNDRECT";
+ case META_ELLIPSE_ACTION: return "ELLIPSE";
+ case META_ARC_ACTION: return "ARC";
+ case META_PIE_ACTION: return "PIE";
+ case META_CHORD_ACTION: return "CHORD";
+ case META_POLYLINE_ACTION: return "POLYLINE";
+ case META_POLYGON_ACTION: return "POLYGON";
+ case META_POLYPOLYGON_ACTION: return "POLYPOLYGON";
+ case META_TEXT_ACTION: return "TEXT";
+ case META_TEXTARRAY_ACTION: return "TEXTARRAY";
+ case META_STRETCHTEXT_ACTION: return "STRETCHTEXT";
+ case META_TEXTRECT_ACTION: return "TEXTRECT";
+ case META_BMP_ACTION: return "BMP";
+ case META_BMPSCALE_ACTION: return "BMPSCALE";
+ case META_BMPSCALEPART_ACTION: return "BMPSCALEPART";
+ case META_BMPEX_ACTION: return "BMPEX";
+ case META_BMPEXSCALE_ACTION: return "BMPEXSCALE";
+ case META_BMPEXSCALEPART_ACTION: return "BMPEXSCALEPART";
+ case META_MASK_ACTION: return "MASK";
+ case META_MASKSCALE_ACTION: return "MASKSCALE";
+ case META_MASKSCALEPART_ACTION: return "MASKSCALEPART";
+ case META_GRADIENT_ACTION: return "GRADIENT";
+ case META_HATCH_ACTION: return "HATCH";
+ case META_WALLPAPER_ACTION: return "WALLPAPER";
+ case META_CLIPREGION_ACTION: return "CLIPREGION";
+ case META_ISECTRECTCLIPREGION_ACTION: return "ISECTRECTCLIPREGION";
+ case META_ISECTREGIONCLIPREGION_ACTION: return "ISECTREGIONCLIPREGION";
+ case META_MOVECLIPREGION_ACTION: return "MOVECLIPREGION";
+ case META_LINECOLOR_ACTION: return "LINECOLOR";
+ case META_FILLCOLOR_ACTION: return "FILLCOLOR";
+ case META_TEXTCOLOR_ACTION: return "TEXTCOLOR";
+ case META_TEXTFILLCOLOR_ACTION: return "TEXTFILLCOLOR";
+ case META_TEXTALIGN_ACTION: return "TEXTALIGN";
+ case META_MAPMODE_ACTION: return "MAPMODE";
+ case META_FONT_ACTION: return "FONT";
+ case META_PUSH_ACTION: return "PUSH";
+ case META_POP_ACTION: return "POP";
+ case META_RASTEROP_ACTION: return "RASTEROP";
+ case META_TRANSPARENT_ACTION: return "TRANSPARENT";
+ case META_EPS_ACTION: return "EPS";
+ case META_REFPOINT_ACTION: return "REFPOINT";
+ case META_TEXTLINECOLOR_ACTION: return "TEXTLINECOLOR";
+ case META_TEXTLINE_ACTION: return "TEXTLINE";
+ case META_FLOATTRANSPARENT_ACTION: return "FLOATTRANSPARENT";
+ case META_GRADIENTEX_ACTION: return "GRADIENTEX";
+ case META_LAYOUTMODE_ACTION: return "LAYOUTMODE";
+ case META_TEXTLANGUAGE_ACTION: return "TEXTLANGUAGE";
+ case META_OVERLINECOLOR_ACTION: return "OVERLINECOLOR";
+ case META_COMMENT_ACTION: return "COMMENT";
+ default:
+ // Yes, return a pointer to a static buffer. This is a very
+ // local debugging output function, so no big deal.
+ static char buffer[6];
+ sprintf(buffer, "%u", nMetaAction);
+ return buffer;
+ }
+#endif
+}
+
inline void ImplScalePoint( Point& rPt, double fScaleX, double fScaleY )
{
rPt.X() = FRound( fScaleX * rPt.X() );
@@ -127,7 +200,7 @@ MetaAction* MetaAction::ReadMetaAction( SvStream& rIStm, ImplMetaReadData* pData
rIStm.ReadUInt16( nType );
- SAL_INFO("vcl.gdi", "ReadMetaAction " << nType);
+ SAL_INFO("vcl.gdi", "ReadMetaAction " << meta_action_name( nType ));
switch( nType )
{
@@ -199,6 +272,12 @@ MetaAction* MetaAction::ReadMetaAction( SvStream& rIStm, ImplMetaReadData* pData
return pAction;
}
+OUString MetaAction::TypeName( sal_uInt16 nType )
+{
+ const char *name = meta_action_name( nType );
+ return OUString( name, strlen( name ), RTL_TEXTENCODING_ASCII_US );
+}
+
MetaPixelAction::MetaPixelAction() :
MetaAction(META_PIXEL_ACTION)
{}
More information about the Libreoffice-commits
mailing list