What Does Round to Int Do in FontForge?
The Round to Int command in FontForge is a utility used to convert fractional coordinate values of glyph outlines into whole integer values. This article covers what the command does, why non-integer coordinates occur during type design, and how executing this command helps ensure file validation, format compatibility, and clean rendering across different operating systems.
In digital typography, glyph outlines are drawn on a grid defined by an Em square (typically 1000 units for PostScript/CFF fonts or 2048 units for TrueType fonts). The Round to Int command scans the currently selected glyphs, contours, or points and rounds the X and Y coordinates of every on-curve node and off-curve control handle to the nearest whole integer. For example, a point positioned at (120.45, 310.82) is converted to (120, 311).
Fractional coordinates commonly appear during font development due to geometric transformations. Operations such as scaling, rotating, slanting, applying stroke effects, or importing vector artwork from applications like Adobe Illustrator frequently produce decimal values. While FontForge supports floating-point precision during the editing phase, standard output font formats traditionally do not.
The primary function of Round to Int is to prepare font data for
production standards. Formats like TrueType (.ttf) and
OpenType (.otf) natively store point coordinates as
integers. If a font contains fractional points upon export, the font
generator must either round them automatically or output validation
warnings. Running Round to Int manually gives the designer full control
over outline changes before export, preventing unintended curve shifts,
hinting conflicts, and rendering artifacts in legacy rasterizers.
To use the feature in FontForge, select the desired points, contours, or entire glyphs in the Font View or Glyph View, navigate to the Element menu, select Round, and click To Int. It is best practice to run this command after completing all major scaling and transformation work, but prior to applying final visual adjustments and manual hinting.