When I generate multiple-mapped glyphs in FontLab Studio 5, the order of the Unicode assignments can't be controlled *. For example I have an A that I want mapped to 0041 0391 0410 (A, Alpha, Cyrillic A) but FontLab generates a glyph mapped to 0410 0041 0391. This has no effect on the function of the font but when I sort the index by Unicode it results in a messy index table. FontLab only "sees" the first Unicode value when it chooses the index sorting order. I tried sorting the index by Unicode in FontLab IV and got the same result.
I think I need to fix the order of the multiple mapping for each glyph so I can get FontLab to sort the index neatly. Also, I'd like the order of the multimaps to be sequential for the sake of tidiness. Otherwise, to anyone looking an Adobe glyph panel, Windows Character Map or the glyphs list on MyFonts, it looks like the A is missing from the alphabet and there's a general scrambled appearance.
Is there a tool that can order the Unicode multimaps sequentially? Ideally it would change my A from 0410 0041 0391 to 0041 0391 0410 so sorting the index table by Unicode won't result in chaos.
* Changing the order in the name table when generating has no effect. FontLab does whatever it wants with the order and it's seemingly random. And I need to process a few hundred fonts this way so I'd like to automate the process.
0
Comments
Just to clarify, having a custom encoding (.enc file) just changes the view order in FontLab, when that encoding is invoked. If you want that glyph order baked into the font (changing the Glyph IDs), go to the menu and choose Glyph > Sort Glyphs > By Encoding.
@Thomas Phinney: Do you know from where you can open .enc files in the Fontlab VI interface? I can’t seem to find it. :-(
The default location of the FontLab VI encodings folder is:
You can change the location in Preferences > General in FontLab VI.
For more info on this and other custom data files for FontLab VI, see https://help.fontlab.com/fontlab-vi/Custom-data-files-and-locations/
(Cribbed from my own writing at:https://github.com/tphinney/science-gothic/blob/master/lib/encoding/ReadMe%20encoding.md)
Thanks for the folder location, but the folder is empty and I can’t seem able to open older .enc files which were in the Fontlab Studio 5 application support folder.
Also, if you want to export an .enc file in Fontlab VI how can you do?
They do not need to be “opened” to work. Just to be in a location FontLab VI knows about.
If you do want to change the contents, they are just text files. You can use any plain text editor to open and edit them, such as NotePad on Windows, BBEdit or TextWrangler on Mac.
But if you want to use an older .enc file, either:
- just copy it to the new Fontlab VI location as discussed above:
- macOS: "Macintosh HD/Users/Your_Name/Library/Application Support/FontLab/FontLab VI/Encoding/"
- Windows: "C:\Users\Your_Name\AppData\Roaming\Fontlab\FontLab VI\Encoding"
- Or go to Preferences > General and change the location of the "User data folder" to wherever you like ... which could be the old FontLab Studio 5 location if you like.
I see Jameson Spires shared a script above. I *think* his "FLS 5?" comment means it is an FLS 5 script, though.I expect it could still be scripted in VI, to export the current view order, and/or the current GID order, as an encoding. Somebody like @Vassil Kateliev could probably do so.
- Switch to index mode an arrange the glyphs however you like them
- Glyph/Glyph Names/Save Encoding
- Switch to Names mode
- Click the dropdown beside the names mode button and go all the way to the bottom. You'll see the name of your font there
- Glyphs/Sort Glyphs/By Encoding
- Switch to index mode to confirm that sorting worked correctly
If you want to change the name of the encoding, locate and edit the .enc file in Notepad etc. ...you'll see the name on the first line. Save then restart FontLab.If By Encoding is grayed out, you're probably in the wrong mode. This only works in Names mode.
After the export, you will only need to change the encoding ID (21000888) and the encoding file name.