The suggested solution does not work with components.
Here is my alternative:
from fontTools.pens.cocoaPen import CocoaPen
def drawGlyph(g):
pen = CocoaPen(g.getParent())
g.draw(pen)
drawPath(pen.path)
The suggested solution does not work with components.
Here is my alternative:
from fontTools.pens.cocoaPen import CocoaPen
def drawGlyph(g):
pen = CocoaPen(g.getParent())
g.draw(pen)
drawPath(pen.path)
Writing down this issue which wonders about the possibility of semantically embedding a URL into running text (without actually showing that URL) made me think of how useful Markdown syntax in the context of a FormattedString could be.
Has anyone tried something like it?
I assume I could write something which regex-parses a given text for .md formatting, and then applies different formats depending on the match. Small bits of FormattedString could be chained into a big FormattedString – voilà, formatted text.
However, while this approach addresses the simple visual variants available within the world of Markdown, it does not solve the original ”how to invisibly embed a URL link within text” (which Markdown is good at).
I am testing OT features in DrawBot, and I’m noticing that the locl feature does not seem to be supported. For a given font with locl feature included, it is not listed in listOpenTypeFeatures(my_font), also language tagging does not seem to affect the text in that regard.
Would it be possible to access the locl feature somehow?