diff options
author | Jan Holesovsky <kendy@suse.cz> | 2011-11-22 21:56:33 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2011-11-22 21:57:46 +0100 |
commit | 6b74943cc6fb7983035b12f6cda8cb8e0c0a016b (patch) | |
tree | 3f3240f1cef5a67af41c1c2763396ee6163e54f8 /canvas | |
parent | 2be37f241ffc3dbbe80c6ab4a9a6021acefeb692 (diff) |
Using #if etc. inside OSL_TRACE is not a good idea, breaks Windows.
Diffstat (limited to 'canvas')
-rw-r--r-- | canvas/source/cairo/cairo_textlayout.cxx | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/canvas/source/cairo/cairo_textlayout.cxx b/canvas/source/cairo/cairo_textlayout.cxx index 68143b5766b1..3aac7a9cbda6 100644 --- a/canvas/source/cairo/cairo_textlayout.cxx +++ b/canvas/source/cairo/cairo_textlayout.cxx @@ -578,6 +578,11 @@ namespace cairocanvas cairo_set_font_matrix(pSCairo.get(), &m); + #if (defined CAIRO_HAS_WIN32_SURFACE) && (OSL_DEBUG_LEVEL > 1) + #define TEMP_TRACE_FONT ::rtl::OUStringToOString( reinterpret_cast<const sal_Unicode*> (logfont.lfFaceName), RTL_TEXTENCODING_UTF8 ).getStr() + #else + #define TEMP_TRACE_FONT ::rtl::OUStringToOString( aFont.GetName(), RTL_TEXTENCODING_UTF8 ).getStr() + #endif OSL_TRACE("\r\n:cairocanvas::TextLayout::draw(S,O,p,v,r): Size:(%d,%d), W:%d->%d, Pos (%d,%d), G(%d,%d,%d) %s%s%s%s || Name:%s - %s", aFont.GetWidth(), aFont.GetHeight(), @@ -590,14 +595,11 @@ namespace cairocanvas rSysFontData.bAntialias ? "AA " : "", rSysFontData.bFakeBold ? "FB " : "", rSysFontData.bFakeItalic ? "FI " : "", - #if (defined CAIRO_HAS_WIN32_SURFACE) && (OSL_DEBUG_LEVEL > 1) - ::rtl::OUStringToOString( reinterpret_cast<const sal_Unicode*> (logfont.lfFaceName), RTL_TEXTENCODING_UTF8 ).getStr(), - #else - ::rtl::OUStringToOString( aFont.GetName(), RTL_TEXTENCODING_UTF8 ).getStr(), - #endif + TEMP_TRACE_FONT, ::rtl::OUStringToOString( maText.Text.copy( maText.StartPosition, maText.Length ), RTL_TEXTENCODING_UTF8 ).getStr() ); + #undef TEMP_TRACE_FONT cairo_show_glyphs(pSCairo.get(), &cairo_glyphs[0], cairo_glyphs.size()); |