Article View: comp.os.os2.programmer
Article #95can't access resource font
From: David E Nichols
Date: Sat, 31 Oct 1992 18:43
Date: Sat, 31 Oct 1992 18:43
23 lines
1680 bytes
1680 bytes
Hello. I wonder if anyone could help me. I have a font declared in my resource script like so: "FONT ID_DIGITALFNT PRELOAD MOVEABLE DISCARDABLE lcd.fnt" I would like to use this font to write text on my client window but I don't know how to access it. When I call GpiQueryFonts with QF_PRIVATE, I get the response that there are no private fonts available. The small amount of documentation I have says that I don't need to call GpiLoadFonts when the resource definition for the font includes PRELOAD, but when I do, I always get an error (call= GpiLoadFonts(hab, "lcd.fnt", this returns FALSE which means an error has occurred). Therefore I can't get a local identifier for the font to use with GpiSetCharSet. And how would you load the font from the resources in your EXE file if you did not use the keyword "PRELOAD"? I can't seem to find the answer to this either. So basically what I really need is a way to get a local identifier for a font contained in my resource script (which therefore should be in my EXE file) so I can call GpiSetCharSet so I can use it to draw text. I guess if there is another way to use it using WinSetPresParams that would work too. By the way, I am using gcc/2. Thank you very much, David Nichols davidn@cs.tamu.edu
Technical Details
Message-ID:
<1992Oct31.184358.4532@tamsun.tamu.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!usc!wupost!cs.utexas.edu!tamsun.tamu.edu!davidnShow Full Headers
Complete Article Headers
Newsgroups: comp.os.os2.programmer Path: arc1-ca.pugleaf.net!sparky!uunet!usc!wupost!cs.utexas.edu!tamsun.tamu.edu!davidn From: davidn@cs.tamu.edu (David E Nichols) Subject: can't access resource font Message-ID: <1992Oct31.184358.4532@tamsun.tamu.edu> Sender: news@tamsun.tamu.edu (Read News) Organization: Computer Science Department, Texas A&M University Date: Sat, 31 Oct 1992 18:43:58 GMT Lines: 33