Ticket #1 (new enhancement)
Use Innotek FT2LIB in FM2
| Reported by: | gyoung | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | |
| Component: | fm/2 base | Version: | |
| Keywords: | Cc: |
Description
Globally activate the font engine on font engine enabled systems. http://www.edm2.com/index.php/Ft2lib
What I recommend is to use DosLoadModule? and DosQueryProcAddr? to conditionally load and enable the library. This also needs a settings page entry before it can go into production along with code to disable the library when the setting is toggled off.
The enable/disable code should to be wrapped in utility function rather than being done in-line.
The enable code needs to go into InitFM3DLL() in init.c and should be similar to
If lib wanted
EnableFT2Lib()
EnableFT2Lib() will look something like
Try to load library If not loaded
complain
Else
Try to get address
If fail
complain
Else
enable remember enabled
The disable function, DisableFt?2Lib(), will look something like
If enabled
Try to load library If not loaded
complain
Else
Try to get address If fail
complain
Else
disable remember disabled unload library unload library (since loaded by enable too)
For an example of how to use DosLoadModule? etc., see the code near line 1819 of misc.c.
![(please configure the [header_logo] section in trac.ini)](/fm2/chrome/site/your_project_logo.png)