fontlab://font/current- Current font infofontlab://font/current/glyphs- List all glyphsfontlab://font/info- Font metadatafontlab://glyph/{name}- Individual glyph details
create_glyph- Create new glyph with name, unicode, widthmodify_glyph_width- Change glyph widthtransform_glyph- Scale, rotate, translate glyphsupdate_font_info- Update family name, style, version, copyrightexport_font- Export to OTF, TTF, WOFF, WOFF2, UFOdelete_glyph- Remove glyphs
Coverage: ~10% of FontLab API capabilities
- fontlab - High-level GUI-integrated operations
- fontgate - Low-level font engine (technical operations)
- typerig - Pythonic wrapper library by Vassil Kateliev
- FL - Legacy FontLab Studio 5 compatibility
- Python 3.11 (10-60% faster than previous versions)
- 340+ preference attributes via
flPreferences - Action set execution via Python
- HTML rendering in output panel
- Special protocols:
glyph:,class:,file: - Startup script hooks:
startupScript.py,initScript.py
High-level (fontlab):
flWorkspace- Application controlflPackage- Font containerflGlyph- Glyph operationsflLayer- Layer operationsflContour- Contour representationflNode- Node operationsflTransform- Geometric transformations
Low-level (fontgate):
fgFont- Font with kerning, features, axes, guidesfgGlyph- Glyph with anchors, components, contoursfgKerning- Kerning pairs and classesfgAnchor/fgAnchors- Anchor pointsfgComponent/fgComponents- Composite glyphsfgContour/fgContours- Bezier pathsfgAxis/fgAxes- Variable font axesfgBitmap- Embedded bitmapsfgCoding- Character encoding/mappingfgColor- Color support
- No kerning pair management
- No kerning classes
- No auto-kerning features
- No metrics classes
- No feature code access/modification
- No glyph classes management
- No GSUB/GPOS manipulation
- No path/contour manipulation
- No bezier curve editing
- No node operations
- No shape operations (union, intersect, etc.)
- No anchor creation/editing
- No mark positioning
- No composite glyph operations
- No component transformation
- No axes management
- No masters manipulation
- No interpolation
- No instance generation
- No guide creation/management
- No alignment zones
- No TrueType hinting
- No PostScript hints
- Basic metrics only (LSB, RSB missing)
- No tags, notes, marks
- No glyph renaming/duplication
- No glyph searching by unicode
- No layer management
- No multi-master layer operations
- Basic info only
- No font validation
- No glyph sorting/reordering
- No font comparison
- No batch operations
- No color layer management
- No SVG/COLR/CBDT support
- No bitmap glyph support
- Basic export only
- No import functionality
- No format conversion options
- No UFO read/write
- No viewport manipulation
- No UI interaction
- No preferences access
- No action set execution
Resources:
fontlab://font/kerning- Get all kerning pairsfontlab://font/kerning/classes- Get kerning classesfontlab://font/metrics-classes- Get metrics classes
Tools:
set_kerning_pair- Set kerning between two glyphsremove_kerning_pair- Remove kerning paircreate_kerning_class- Create kerning classauto_kern- Auto-generate kerningimport_kerning- Import kerning from fileexport_kerning- Export kerning dataset_metrics_class- Create/update metrics classset_glyph_sidebearings- Set left/right sidebearingsauto_metrics- Auto-calculate metrics
Resources:
fontlab://glyph/{name}/contours- Get contour datafontlab://glyph/{name}/paths- Get path data with nodes
Tools:
add_contour- Add contour to glyph from path dataremove_contour- Remove contour by indexmodify_contour- Modify nodes in contourreverse_contour- Reverse contour directionsimplify_contour- Simplify/optimize pathsunion_shapes- Boolean unionintersect_shapes- Boolean intersectionsubtract_shapes- Boolean subtractionoutline_stroke- Convert stroke to outlineadd_node- Add node to contourremove_node- Remove node from contourconvert_node_type- Change curve/corner typealign_nodes- Align selected nodesdistribute_nodes- Distribute nodes evenly
Resources:
fontlab://glyph/{name}/anchors- Get anchor positions
Tools:
add_anchor- Add anchor to glyphremove_anchor- Remove anchormove_anchor- Reposition anchorauto_anchor- Auto-position anchorsgenerate_mark_feature- Generate mark/mkmk features
Resources:
fontlab://glyph/{name}/components- Get component info
Tools:
add_component- Add component referenceremove_component- Remove componentdecompose_glyph- Break components to outlinestransform_component- Transform specific componentauto_build_composites- Build composite glyphs
Resources:
fontlab://font/features- Get all feature codefontlab://font/features/{tag}- Get specific featurefontlab://font/classes- Get glyph classes
Tools:
set_feature_code- Set OpenType feature codecompile_features- Compile and validate featurescreate_glyph_class- Create glyph classremove_glyph_class- Remove glyph classgenerate_feature- Auto-generate feature (kern, mark, liga, etc.)
Resources:
fontlab://font/axes- Get variation axesfontlab://font/masters- Get font mastersfontlab://font/instances- Get defined instances
Tools:
add_axis- Add variation axisremove_axis- Remove axisadd_master- Add font masterset_master_location- Position master in design spacegenerate_instance- Generate font instanceinterpolate_glyphs- Interpolate between masterscreate_variable_font- Export variable font
Resources:
fontlab://glyph/{name}/layers- Get layer info
Tools:
add_layer- Add layer to glyphremove_layer- Remove layercopy_layer- Copy layer contentsmerge_layers- Merge layers
Resources:
fontlab://font/guides- Get global guidesfontlab://font/zones- Get alignment zones
Tools:
add_guide- Add guideremove_guide- Remove guideadd_zone- Add alignment zoneadd_stem- Add stem hint
Resources:
fontlab://glyphs/search- Search glyphs (by unicode, name pattern, etc.)fontlab://glyph/{name}/metadata- Get tags, notes, marks
Tools:
rename_glyph- Rename glyphduplicate_glyph- Duplicate glyphcopy_glyph_to_font- Copy between fontsset_glyph_unicode- Set/change unicodeset_glyph_note- Set noteset_glyph_tags- Set tagsset_glyph_mark- Set color markfind_replace_glyph- Find and replace by patternsort_glyphs- Reorder glyphs
Resources:
fontlab://font/validation- Get validation errorsfontlab://font/statistics- Get font statistics
Tools:
validate_font- Run font validationfind_overlaps- Find overlapping pathsfind_open_paths- Find open contoursfind_wrong_directions- Check path directionsauto_fix_contours- Auto-fix common issuesanalyze_spacing- Analyze glyph spacing
Tools:
import_font- Import font fileimport_glyphs- Import specific glyphsimport_ufo- Import UFOexport_ufo- Export UFOexport_glif- Export glyphs as GLIFbatch_export- Export multiple formats
Resources:
fontlab://glyph/{name}/color-layers- Get color layers
Tools:
add_color_layer- Add color layerset_layer_color- Set layer colorimport_svg- Import SVG to glyphexport_svg- Export glyph as SVG
Resources:
fontlab://workspace/preferences- Get preferencesfontlab://workspace/viewport- Get viewport state
Tools:
update_viewport- Refresh viewset_preference- Change preferencerun_action_set- Execute action setexecute_macro- Run macro/scriptopen_font- Open font fileclose_font- Close fontsave_font- Save current font
Tools:
batch_transform- Transform multiple glyphsbatch_rename- Rename glyphs by patternbatch_unicode- Assign unicodes by patternbatch_create_glyphs- Create multiple glyphsbatch_delete_glyphs- Delete multiple glyphsapply_to_selection- Apply operation to selected glyphs
Tools:
auto_hint_ps- Auto-hint PostScriptauto_hint_tt- Auto-hint TrueTypeclear_hints- Remove all hints
Priority: Immediate - Covers most common use cases
-
Contours & Shapes (Category B)
- Path data access and manipulation
- Boolean operations
- Node operations
- ~15 tools
-
Kerning & Metrics (Category A)
- Kerning pair management
- Kerning classes
- Metrics classes
- ~9 tools
-
Components (Category D)
- Component operations
- Composite glyph building
- ~5 tools
-
Advanced Glyph Operations (Category I)
- Glyph search, rename, duplicate
- Metadata (tags, notes, marks)
- ~9 tools
Estimated: ~38 new tools + 8 resources
Priority: Next - Enables professional font production
-
OpenType Features (Category E)
- Feature code management
- Glyph classes
- Feature compilation
- ~6 tools
-
Variable Fonts (Category F)
- Axes and masters
- Interpolation
- Instance generation
- ~7 tools
-
Font Validation & Analysis (Category J)
- Validation
- Auto-fix tools
- ~6 tools
-
Import/Export (Category K)
- Enhanced import/export
- UFO support
- ~6 tools
Estimated: ~25 new tools + 10 resources
Priority: Optional - Niche but valuable
-
Anchors (Category C)
- Anchor management
- Mark feature generation
- ~5 tools
-
Layers (Category G)
- Layer operations
- ~4 tools
-
Guides & Zones (Category H)
- Guide management
- Alignment zones
- ~4 tools
-
Application Control (Category M)
- Workspace control
- Preferences
- Action sets
- ~7 tools
Estimated: ~20 new tools + 6 resources
Priority: Future - Automation and specialized workflows
-
Batch Operations (Category N)
- Bulk transformations
- Pattern-based operations
- ~6 tools
-
Color Fonts (Category L)
- Color layer support
- SVG import/export
- ~4 tools
-
Hinting (Category O)
- Auto-hinting
- ~3 tools
Estimated: ~13 new tools + 2 resources
These provide immediate value with moderate effort:
-
Glyph search/filtering - Very useful for LLMs
fontlab://glyphs/search?pattern=A*fontlab://glyphs/by-unicode/{codepoint}
-
Glyph rename/duplicate - Common operations
rename_glyph(old_name, new_name)duplicate_glyph(name, new_name)
-
LSB/RSB adjustment - Basic metrics control
set_sidebearings(name, lsb, rsb)
-
Glyph metadata (tags, notes) - Organization
set_glyph_note(name, note)set_glyph_tags(name, tags)
-
Basic kerning pairs - Essential typography
set_kerning_pair(left, right, value)fontlab://font/kerning
Features Identified:
- ~96 new tools across all phases
- ~26 new resources for data access
- Current: 6 tools + 4 resources
- Full coverage: 102 tools + 30 resources
Development Effort:
- Phase 1: 3-4 weeks (high impact)
- Phase 2: 2-3 weeks (professional features)
- Phase 3: 2-3 weeks (specialized)
- Phase 4: 1-2 weeks (automation)
Total: ~8-12 weeks for complete API coverage
- Caching Layer - Cache font info to reduce bridge calls
- Batch Mode - Bundle multiple operations into single script execution
- Event Hooks - Listen for font changes in FontLab
- Better Error Handling - Propagate FontLab errors with context
- Streaming Support - For large data (e.g., all contour paths)
- Async Improvements - Non-blocking operations where possible
- Type Validation - Validate parameters before sending to FontLab
- Result Formatting - Use FontLab 8's HTML output for rich responses
- Main API: https://fontlabcom.github.io/fontlab-python-docs/
- FontLab 8 scripting: https://help.fontlab.com/fontlab/8/whats-new/whats-new-12-scripts-extensions/
- Extend FontLab: https://extend.fontlab.com/
flWorkspace- Application controlflPackage- Font containerflGlyph- Glyph operationsflLayer- Layer operationsfgFont- Low-level font operationsfgKerning- Kerning managementfgContour- Path/contour operationsfgComponent- Component operationsfgAnchor- Anchor management
- ✅ Save this research document
- ⬜ Start with "Quick Wins" implementation
- ⬜ Test FontLab bridge with actual FontLab installation
- ⬜ Implement Phase 1 features iteratively
- ⬜ Add comprehensive error handling
- ⬜ Create test suite for FontLab integration
- ⬜ Document each new tool/resource as implemented