Bug 116522 - Font Replacement Table handling of Graphite/OTF feature flags
Summary: Font Replacement Table handling of Graphite/OTF feature flags
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
(earliest affected) release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
Depends on:
Blocks: Font-Rendering
  Show dependency treegraph
Reported: 2018-03-20 18:32 UTC by Harry.dent
Modified: 2018-03-22 01:39 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Note You need to log in before you can comment on or make changes to this bug.
Description Harry.dent 2018-03-20 18:32:58 UTC
While searching for a workaround for https://bugs.documentfoundation.org/show_bug.cgi?id=116490, I found that it was possible to prevent ligatures being added between characters by appending `:-liga` to the name of the current font. 

I now wish to define replacements in the Font Replacement Table (Tools > Options > LibreOffice > Fonts) such that e.g. "SomeFont Sans" -> "SomeFont Sans:-liga". This does not work - the font still contains ligatures after its replacement is added to the table.

N.B. Replacing two normal fonts works e.g. "DejaVu Sans" -> "Verdana"

Steps to Reproduce:
1. Create a new document containing the word "final" in font "DejaVu Sans"
2. Select "final" and change the font to "DejaVu Sans:-liga"

3. Create a new document exactly like the first
4. Add "DejaVu Sans" -> "DejaVu Sans:-liga" to the Font Replacement Table (Tools > Options > LibreOffice > Fonts)

Actual Results:  
The "fi" in the first document contains a ligature, but not in the second document

Expected Results:
The "fi" in both documents should not contain a ligature

Reproducible: Always

User Profile Reset: No

Additional Info:
For testing, other combinations of letters than contain ligatures include ft, ff, tt, tf, ti, fj...

User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/64.0.3282.167 Chrome/64.0.3282.167 Safari/537.36
Comment 1 V Stuart Foote 2018-03-21 03:18:58 UTC
Well NAB as there is no support in the font replacement table to honor OpenType features with the established Graphite flag mechanism. 

So this would be an enhancement and likely requires rework of the font handling to support OTF features via Graphite flags applied to the Font Replacement Table dialog--if it is even possible.

So would it make sense to do it with the Graphite flags, or via some yet to be implemented GUI as for bug 58941