Opened 15 years ago
Closed 15 years ago
#41 closed task (fixed)
Port QFont, QFontEngine and QFontDatabase
Reported by: | Dmitry A. Kuminov | Owned by: | Dmitry A. Kuminov |
---|---|---|---|
Priority: | major | Milestone: | QtGui Beta |
Component: | QtGui | Version: | 4.5.1 Beta 1 |
Severity: | Keywords: | ||
Cc: |
Description
Provide the OS/2 version of the QFont, QFontEngine and QFontDatabase classes.
Change History (5)
comment:1 by , 15 years ago
Owner: | set to |
---|---|
Status: | new → accepted |
comment:2 by , 15 years ago
comment:3 by , 15 years ago
In r125, I added QFontEnginePMFT that uses QFontEngineFT to draw fonts with the FreeType library (included in Qt4 sources). This seems to work well, except that the standard OS/2 bitmap fonts (WarpSans, System Proportional etc) are not available through FreeType because they are PM resources rather than separate files and I'm also not sure that FreeType understands the format of the OS/2 bitmap fonts out-of-the-box.
Though it seems to be an (aestetic) issue, it won't get any workaround in the upcoming Beta. What about the GA, there are two possible solutions:
- Write a font driver for FreeType (similar to http://git.savannah.gnu.org/cgit/freetype/freetype2.git/tree/src/winfonts) that can read OS/2 bitmap fonts including those stored in the resource DLL.
- Write a separate QFontEngine derivant that uses GPI to draw OS/2 bitmap fonts.
1 is obviously the preferred solution but it may be a bit tricky (while 2 is more nasty and involves the oudated GPI font handling routines which will have a negative impact on antialiasing, matrix transformations etc).
The next step for the beta is to attach the fontconfig library for doing font matching (currently, C:\PSFONTS\HELV.PFB
is always selected for text drawing).
comment:4 by , 15 years ago
i also vote for 1, as i think it's less code and less pain for a further port.
comment:5 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | accepted → closed |
In r124, I enabled test font engines that draw boxes instead of real characters -- they seem to work well.