[Libreoffice-commits] core.git: Branch 'aoo/trunk' - canvas/source

2018-03-07 Thread Yuri Dario
 canvas/source/cairo/cairo_os2_cairo.cxx  |6 +-
 canvas/source/cairo/cairo_textlayout.cxx |9 +++--
 2 files changed, 12 insertions(+), 3 deletions(-)

New commits:
commit 8b8df380310b2ba0c92ddff97361b0c4989d659f
Author: Yuri Dario 
Date:   Wed Mar 7 14:46:14 2018 +

#i127723# Fix StarSymbol to OpenSymbol mapping when using cairo on OS/2.

diff --git a/canvas/source/cairo/cairo_os2_cairo.cxx 
b/canvas/source/cairo/cairo_os2_cairo.cxx
index 788b51e3897f..e9b4912be7a6 100644
--- a/canvas/source/cairo/cairo_os2_cairo.cxx
+++ b/canvas/source/cairo/cairo_os2_cairo.cxx
@@ -327,7 +327,11 @@ namespace cairo
 fontAttrs.usCodePage = 850;
 fontAttrs.fsType = FATTR_TYPE_MBCS;
 fontAttrs.fsFontUse = FATTR_FONTUSE_NOMIX;
-strcpy( fontAttrs.szFacename, font);
+// map StarSymbol to OpenSymbol
+if (strcmp( font, "StarSymbol") == 0)
+strcpy( fontAttrs.szFacename, "OpenSymbol");
+else
+strcpy( fontAttrs.szFacename, font);
 rc = Ft2CreateLogFont( hps, NULL, 1L, );
 rc = Ft2SetCharSet( hps, 1L);
 
diff --git a/canvas/source/cairo/cairo_textlayout.cxx 
b/canvas/source/cairo/cairo_textlayout.cxx
index 4fb559ec8a0a..b8eff6393c16 100644
--- a/canvas/source/cairo/cairo_textlayout.cxx
+++ b/canvas/source/cairo/cairo_textlayout.cxx
@@ -546,8 +546,13 @@ namespace cairocanvas
 CAIRO_FONT_SLANT_NORMAL : 
CAIRO_FONT_SLANT_ITALIC);
 cairo_font_weight_t weight = (rOutDev.GetFont().GetWeight() == 
WEIGHT_NORMAL ?
   CAIRO_FONT_WEIGHT_NORMAL : 
CAIRO_FONT_WEIGHT_BOLD);
-cairo_select_font_face( pSCairo.get(), aFontName,
-slant, weight);
+// map StarSymbol to OpenSymbol
+if (aFontName.equals("StarSymbol"))
+cairo_select_font_face( pSCairo.get(), "OpenSymbol",
+slant, weight);
+else
+cairo_select_font_face( pSCairo.get(), aFontName,
+slant, weight);
 #endif
 
 if (font_face)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'aoo/trunk' - canvas/source

2014-02-05 Thread Herbert Dürr
 canvas/source/cairo/cairo_textlayout.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 05e9a04ef0191aeb59e09d2bf8306f88baf399e3
Author: Herbert Dürr h...@apache.org
Date:   Wed Feb 5 07:19:11 2014 +

#i123068# remove implicit conversion from aUTF8String to its char pointer

diff --git a/canvas/source/cairo/cairo_textlayout.cxx 
b/canvas/source/cairo/cairo_textlayout.cxx
index aaa6973..35f498d 100644
--- a/canvas/source/cairo/cairo_textlayout.cxx
+++ b/canvas/source/cairo/cairo_textlayout.cxx
@@ -333,7 +333,7 @@ namespace cairocanvas
before we were depending on unmodified current point which I 
believed was preserved by save/restore */
 cairo_move_to( pCairo, 0, 0 );
 useFont( pCairo );
-cairo_show_text( pCairo, aUTF8String );
+cairo_show_text( pCairo, aUTF8String.getStr() );
 cairo_restore( pCairo );
 
 return true;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'aoo/trunk' - canvas/source

2014-01-30 Thread Armin Le Grand
 canvas/source/vcl/canvascustomsprite.cxx |9 -
 canvas/source/vcl/spritehelper.cxx   |8 +++-
 2 files changed, 15 insertions(+), 2 deletions(-)

New commits:
commit 342ebf4c79972ba3e1159831fce04cdef80f585b
Author: Armin Le Grand a...@apache.org
Date:   Thu Jan 30 17:27:11 2014 +

i12355 Allow 1bit masks for all OSes except Linux (see i122485)

diff --git a/canvas/source/vcl/canvascustomsprite.cxx 
b/canvas/source/vcl/canvascustomsprite.cxx
index 1287ed7..39ae9d6 100644
--- a/canvas/source/vcl/canvascustomsprite.cxx
+++ b/canvas/source/vcl/canvascustomsprite.cxx
@@ -81,7 +81,14 @@ namespace vclcanvas
 pBackBuffer-setSize( aSize );
 
 // create mask backbuffer, with one bit color depth #122485# use full 
depth to avoid problem with 1bit depth, get AAed masks
-BackBufferSharedPtr pBackBufferMask( new BackBuffer( 
rOutDevProvider-getOutDev() ) ); // , true ) ); // #122485#
+BackBufferSharedPtr pBackBufferMask(
+#if defined LINUX || defined FREEBSD || defined NETBSD
+// #122485# no 1bit buffers on Linuxes, 1bit Vdev seems to work no 
longer
+new BackBuffer( rOutDevProvider-getOutDev() ) );
+#else
+// 1bit mask buffer for all others
+new BackBuffer( rOutDevProvider-getOutDev(), true ) );
+#endif
 pBackBufferMask-setSize( aSize );
 
 // TODO(F1): Implement alpha vdev (could prolly enable
diff --git a/canvas/source/vcl/spritehelper.cxx 
b/canvas/source/vcl/spritehelper.cxx
index 2440ad3..b793090 100755
--- a/canvas/source/vcl/spritehelper.cxx
+++ b/canvas/source/vcl/spritehelper.cxx
@@ -159,7 +159,13 @@ namespace vclcanvas
 
 // bitmasks are much faster than alphamasks on some 
platforms
 // so convert to bitmask if useful
-#ifndef QUARTZ
+#if defined LINUX || defined FREEBSD || defined NETBSD || defined QUARTZ
+// #122485# allow more than 1bit masks for Linux and Mac,
+// but reduce to mono now
+aMask.MakeMono(255);
+#else
+// #122485# assert when mask uses more than 1bit and reduce
+// to mono
 if( aMask.GetBitCount() != 1 )
 {
 OSL_ENSURE(false,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits