turn on cairo rendering of vertical text
This commit is contained in:
parent
28f5e1b27c
commit
9892df24a5
BIN
qadevOOo/testdocs/vertical-testcase.odt
Normal file
BIN
qadevOOo/testdocs/vertical-testcase.odt
Normal file
Binary file not shown.
@ -870,7 +870,7 @@ public:
|
|||||||
{
|
{
|
||||||
FcPatternDestroy(mpPattern);
|
FcPatternDestroy(mpPattern);
|
||||||
}
|
}
|
||||||
virtual void *GetPattern(void * face, bool bEmbolden, bool bVerticalLayout) const
|
virtual void *GetPattern(void * face, bool bEmbolden, bool /*bVerticalLayout*/) const
|
||||||
{
|
{
|
||||||
FcValue value;
|
FcValue value;
|
||||||
value.type = FcTypeFTFace;
|
value.type = FcTypeFTFace;
|
||||||
@ -879,8 +879,10 @@ public:
|
|||||||
FcPatternAdd (mpPattern, FC_FT_FACE, value, FcTrue);
|
FcPatternAdd (mpPattern, FC_FT_FACE, value, FcTrue);
|
||||||
FcPatternDel(mpPattern, FC_EMBOLDEN);
|
FcPatternDel(mpPattern, FC_EMBOLDEN);
|
||||||
FcPatternAddBool(mpPattern, FC_EMBOLDEN, bEmbolden ? FcTrue : FcFalse);
|
FcPatternAddBool(mpPattern, FC_EMBOLDEN, bEmbolden ? FcTrue : FcFalse);
|
||||||
|
#if 0
|
||||||
FcPatternDel(mpPattern, FC_VERTICAL_LAYOUT);
|
FcPatternDel(mpPattern, FC_VERTICAL_LAYOUT);
|
||||||
FcPatternAddBool(mpPattern, FC_VERTICAL_LAYOUT, bVerticalLayout ? FcTrue : FcFalse);
|
FcPatternAddBool(mpPattern, FC_VERTICAL_LAYOUT, bVerticalLayout ? FcTrue : FcFalse);
|
||||||
|
#endif
|
||||||
return mpPattern;
|
return mpPattern;
|
||||||
}
|
}
|
||||||
FcPattern* mpPattern;
|
FcPattern* mpPattern;
|
||||||
|
@ -454,9 +454,9 @@ void X11SalGraphics::DrawCairoAAFontString( const ServerFontLayout& rLayout )
|
|||||||
&text_extents);
|
&text_extents);
|
||||||
|
|
||||||
xdiff = -text_extents.x_advance/nHeight;
|
xdiff = -text_extents.x_advance/nHeight;
|
||||||
//deliberate bug here for temp render-like-X11-impl,
|
//to restore an apparent bug in the original X11 impl, replace
|
||||||
//nWidth should be nHeight below
|
//nHeight with nWidth below
|
||||||
xdiff += font_extents.descent/nWidth;
|
xdiff += font_extents.descent/nHeight;
|
||||||
}
|
}
|
||||||
cairo_matrix_translate(&m, xdiff, ydiff);
|
cairo_matrix_translate(&m, xdiff, ydiff);
|
||||||
}
|
}
|
||||||
@ -834,9 +834,7 @@ void X11SalGraphics::DrawServerFontLayout( const ServerFontLayout& rLayout )
|
|||||||
{
|
{
|
||||||
// draw complex text
|
// draw complex text
|
||||||
ServerFont& rFont = rLayout.GetServerFont();
|
ServerFont& rFont = rLayout.GetServerFont();
|
||||||
const bool bVertical = rFont.GetFontSelData().mbVertical;
|
if( isCairoRenderable(rFont) )
|
||||||
|
|
||||||
if( !bVertical && isCairoRenderable(rFont) )
|
|
||||||
DrawCairoAAFontString( rLayout );
|
DrawCairoAAFontString( rLayout );
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user