Forum Replies Created
-
AuthorPosts
-
I recommend reading the feature file syntax see http://www.adobe.com/devnet/opentype/afdko/topic_feature_file_syntax.html
Both are warnings your font will work, but both are also easy to fix. I think the FDK warning message is very helpful.
good luck!
that is easy to :)
from mojo.events import addObserver class RenameGroupsObserver(object): def __init__(self): addObserver(self, "checkGroupNames", "fontDidOpen") def checkGroupNames(self, info): print "checking group names for single quotes" font = info["font"] for groupName, items in font.groups.items(): newItems = [] for glyphName in items: if "'" in glyphName: glyphName = glyphName.replace("'", "") newItems.append(glyphName) if newItems != items: ## something changed font.groups[groupName] = newItems print "done checking group names" RenameGroupsObserver()save this script in a file and add it in the preferences as a start up script and you never ever have to worry about single quotes in groups.
see http://doc.robofont.com/documentation/workspace/preferences/extensions/Your font data will change and importing the UFO back in FL will change the groups behavior, off course
good luck
see http://doc.robofont.com/documentation/workspace/preferences/misc/
and set the “Maximum Tools In Toolbar” to a preferred value.
or easier, make a script that is removing all
'font = CurrentFont() for groupName, items in font.groups.items(): newItems = [] for glyphName in items: if "'" in glyphName: glyphName = glyphName.replace("'", "") newItems.append(glyphName) if newItems != items: ## something changed font.groups[groupName] = newItemsand connect this script with event observer on
fontDidOpenand it happens automatically.
see http://doc.robofont.com/api/mojo/mojo-events/(RoboFont will never do this atomically cause one of the main principles is that the users should always be aware of what is happening with his/her font data)
I bundled all documentation on a single html page.
http://doc.robofont.com/the-complete-robofont-guide/I tried several word press plugins but none of them are satisfying.
If I offer a pdf for download I would like that the download is in sync with the current documentation.do you remember which value you edited in the info sheet?
fixed
thanks
you could set a observer when a font opens / when a fonts will generate a binary and set the value as you wish, this means it kinda atomically.
good luck
I just fixed this so a selection in the Font Overview is always between the previous selected cell and the current selected cell.
Thanks
as Tal stated in the ufo2fdk source code
# fallback to None on these # as the user should be in # complete control
http://code.typesupply.com/browser/packages/ufo2fdk/trunk/Lib/ufo2fdk/fontInfoData.py#L292
To draw in a glyph use a pen like object
To add or insert points useappendSegmentorinsertSegmentglyph = CurrentGlyph() glyph.clear() ## grab the pen of that glyph pen = glyph.getPen() ## draw with the pen ## this draws a rect pen.moveTo((100, 100)) pen.lineTo((100, 200)) pen.lineTo((200, 200)) pen.lineTo((200, 100)) pen.closePath() ## grab the first contour contour = glyph[0] ## append a segment contour.appendSegment("line", [(150, 50)]) ## insert a segment contour.insertSegment(2, "line", [(50, 200)]) contour.insertSegment(3, "curve", [(100, 280), (200, 280), (250, 200)])That will not change much.
But in the next version you will be able to open a glyph window for a font that has no UI.
from mojo.UI import OpenGlyphWindow, OpenSpaceCenter path = u"path/to/a/font.ufo" f = OpenFont(path, showUI=False) # opens glyphs "a" in a glyph window OpenGlyphWindow(f["a"]) OpenSpaceCenter(f)
That is easy: subscribe to
newFontDidOpenand do something with the new font.from mojo.events import addObserver class SetInfo(object): def __init__(self): addObserver(self, "myCallback", "newFontDidOpen") def myCallback(self, info): font = info["font"] print font font.info.copyright = "This is my font" SetInfo()and maybe set this script as start up script in the preferences so each time you open RoboFont the observer will be installed.
good luck
font = OpenFont("path/to/your/font.ufo", showUI=False) -
AuthorPosts