nanogui: fonts


Previous by date: 3 Mar 2001 19:47:42 -0000 Re: repaint problem, Greg Haerr
Next by date: 3 Mar 2001 19:47:42 -0000 Re: NanoX/uWin on eCos, Greg Haerr
Previous in thread: 3 Mar 2001 19:47:42 -0000 fonts, Amit Kulkarni
Next in thread: 3 Mar 2001 19:47:42 -0000 Fonts, Leah Burstein

Subject: Re: fonts
From: "Greg Haerr" ####@####.####
Date: 3 Mar 2001 19:47:42 -0000
Message-Id: <08c601c0a419$d3418cc0$15320cd0@gregh>

: how can i have GrCreateFont return a "copy" of the built in font?

Use GrCreateFont, details below.  GrCreateFont will use count
increment one of the built-in or external fonts, and then
GrSetGCFont can be used to associate the font with a gc.


: The built in font seems to be rather thick and i want the default fonts to 
: look thin. GrSetFontSize for the default font does not seem to work.
: But if i say something weird like GrCreateFont("",8,NULL) it seems to work 
: and somehow get a nice thinner font..(besides a warning printed by the 
: nano-X server)

If you look in include/mwtypes.h, you'll see the standard 4 fonts
that are built in to Microwindows.  You will want to execute
    GrCreateFont(MWFONT_GUI_VAR, 0, NULL);
which indicates a thin, Helvetica-style 11x13 ANSI font.
The default is MWFONT_SYSTEM_VAR, which is too thick.
I've been thinking for some time that the default font probably
should be changed to MWFONT_GUI_VAR.


: Also i do not want to load a freetype font for this purpose. The free type 
: support although present is of little practical use since it really crawls. 
: The built in fonts are much faster and better.

I'm working on some big speed improvements to freetype rendering
speed.  Someone had completed this at Century but their system
crashed and he had no backup ;-!

Regards,

Greg



Previous by date: 3 Mar 2001 19:47:42 -0000 Re: repaint problem, Greg Haerr
Next by date: 3 Mar 2001 19:47:42 -0000 Re: NanoX/uWin on eCos, Greg Haerr
Previous in thread: 3 Mar 2001 19:47:42 -0000 fonts, Amit Kulkarni
Next in thread: 3 Mar 2001 19:47:42 -0000 Fonts, Leah Burstein


Powered by ezmlm-browse 0.20.