A little info about ligatures and e.g. Calibri

Caolán McNamara caolanm at redhat.com
Sun Feb 3 07:39:36 PST 2013


FWIW, as it came up as a question in the main track FOSDEM LibreOffice
talk, in vcl/generic/glyphs/gcach_layout.cxx see IcuLayoutEngine::layout
and...
if (rArgs.mnFlags & SAL_LAYOUT_ENABLE_LIGATURES)
    nLayoutFlags |= LayoutEngine::kTypoFlagLiga;
so ligatures are disabled by default unless SAL_LAYOUT_ENABLE_LIGATURES
is enabled, and SAL_LAYOUT_ENABLE_LIGATURES is only set if
TEXT_LAYOUT_ENABLE_LIGATURES is set on the outputdevice, and that
doesn't happen anywhere as of yet :-(

It would be no major problem to e.g. bubble up allowing those ligatures
to be set explicitly via the UI, or e.g. defaulted on via a new
compatibility flag for new docs, but the last time I played around with
it I ran into the snag that with our current Linux rendering stack via
cairo we get the unfortunate visual effect that ligatures appear bold in
Calibri, etc.

Here's a screenshot of gedit which renders for me today like we would do
if we enabled ligatures in above code.
https://bugzilla.redhat.com/attachment.cgi?id=613610 
from https://bugzilla.redhat.com/show_bug.cgi?id=857860

C.



More information about the LibreOffice mailing list