- Final Branch:
gsoc-2022-chariri-final
(commit history, tree)
- 2023/2/9: The updated version of
ftinspect
has been released with FreeType 2.13.0! Thanks for all you guys!!
- GSoC project: https://summerofcode.withgoogle.com/programs/2022/projects/UTT0MqfN
- Repository: freetype-demos
- Language and Technologies: C++, FreeType, Qt
- Mentee: Charlie Jiang (@cqjjjzr)
- Mentors: Werner Lemberg (@wl), Toshiya Suzuki (@mpsuzuki) (Alexei Podtelezhnikov @apodtele also provided great help)
- Discussion: Most in Issue #15 of the
freetype-demos
repo.
- Dev branch:
gsoc-2022-chariri-3
(commit history, tree) - Wrapping-up branch (rebase to latest master, organize commits and clean-up):
gsoc-2022-chariri-final
(commit history, tree)
ftinspect
is a tool for inspecting how fonts are rendered with FreeType. In this project, the tool is integrated with functionalities from other FreeType demo tools including ftgrid
, ftview
, ftstring
, ftdiff
, ftmulti
and ftdump
. The tool was converted from a bare skeleton with limited function from ftgrid
to a comprehensive font and engine inspector, which allows adjusting for a wide range of rendering parameters and viewing the font in multiple views including checking the bitmap in a grid view, displaying strings rendered by FreeType, comparing different rendering parameters side-by-side, etc.
Major tasks completed:
-
Improved "Singular Grid View" (from
ftgrid
): Inspecting the bitmaps and (if available) outlines in an enlarged grid view. This was the only function in the originalftinspect
tool. The project introduces GUI improvement to this view. Auxiliary lines showing several font metrics are added. -
New "Continuous View" (from
ftstring
andftview
): Displaying strings or all glyphs in a continuous manner. Fancy rendering (emboldened and slanting), stroked and waterfall modes are supported. -
New "Comparator View" (from
ftdiff
): Compare different sets of parameters side-by-side. -
New "Font Info" (from
ftdump
): Showing information for the font file including metadata, basic metrics, charmaps, SFNT tables, etc. Two functions absent from theftdump
tool are implemented: showing mapping between SFNT tables and subfaces for TrueType Collections font files; showing composite glyphs tree; -
More parameters implemented: Only hinting and several anti-aliasing settings were supported in the original
ftinspect
tool. This project adds implementation for gamma correction, back/foreground color, embedded bitmaps, color layers, LCD anti-aliasing, and MM/GX axes (fromftmulti
). -
Major UI/UX improvement: A much more intuitive GUI is introduced. Remarkable points include:
- Scroll operations in grid and continuous view can zoom the view, adjust the size. Drag operation in the continuous view can move the string (if in string mode), or adjust the glyph index (if showing all glyphs).
- The user can click on the glyphs in the continuous view to get detailed information about them, like glyph index and metrics. Right-clicking will bring the user to the singular grid view showing the clicked glyph.
- Dropping files on the window will open them.
- The original design to navigate between fonts, faces and VF named instances is 6 buttons ("Previous" and "Next" for each). The project rewrites the selector to 3 checkboxes at the bottom of the window, making the navigation markedly more intuitive.
- Tooltips are added for most GUI widgets as documentation.
-
Finer representation for data: Better translation of original values from the FreeType library is provided. For example, charmap encoding are represent as names instead of simply tags. The same applies for platforms and languages, etc.
Here is a list of possible additions that haven't been implemented:
- SVG glyphs rendering
- Full command-line support
- Automation and automated testing support
- Testing and Benchmark for fonts (
ftlint
andftbench
)
I'd like to express my deepest gratitude to all FreeType mentors and community members who provided enormous help. It was the guidance, suggestions, feedbacks and reviews from Werner, Suzuki, Alexei and other community member that make my GSoC experience possible, remarkable and smooth.
It's delightful that my skills were greatly extended during the project, and my understanding for font rendering is significantly deepened.
Cheers,
Charlie Jiang