The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: raleeper on May 19, 2007, 09:14:57 AM

Title: Character Set
Post by: raleeper on May 19, 2007, 09:14:57 AM
I'm trying to use CreateFontIndirect to get a font with a character set that includes 26h = & and if possible, 19h = [down arrow].

The font returned by GetStockObject OEM_FIXED_FONT has that character set and is the one I'd like to use, but it's tiny.

Is there a way to use that character set, but with size and perhaps other attributes settable by CreateFontIndirect?


Petzold says FixedSys is the "typeface name" of OEM_FIXED_FONT.  "A program can use the typeface name to refer to the font in a CreateFont or CreateFontIndirect function call" - Petzold, Programming Windows, 5th ed., p. 244-5.

But plugging FixedSys into the LOGFONT structure for CreateFontIndirect doesn't work.

face   DB   "FixedSys",0   ;1C  TCHAR lfFaceName[LF_FACESIZE]
same old character set w/ 26h = underscore_next

face   DB   FixedSys   ;1C  TCHAR lfFaceName[LF_FACESIZE]
lfw.asm(114) : error A2006: undefined symbol : FixedSys
Title: Re: Character Set
Post by: MichaelW on May 20, 2007, 05:17:21 AM
Lucida Console includes the down arrow character, is fixed pitch, and available in a range of sizes.
Title: Re: Character Set
Post by: raleeper on May 20, 2007, 11:26:21 AM
Quote from: MichaelW on May 20, 2007, 05:17:21 AM
Lucida Console includes the down arrow character, is fixed pitch, and available in a range of sizes.


Thanks Michael.

I don't have it working yet - tho the typeface looks good - but I've decided to stop asking questions til I know more.

So it's back to the tutorials & Petzold.