Default fonts


    Sponsored Links


  • 1. Quest: CAsyncSocket derived sockets...
    Is it possible to get see if a Server Socket obj has been already accepted or if it is not in use and is ready to be accepted?
  • 2. the printer jobID be unique?
    Will you help me ? The JobID of diffrent printer definitely is not same all time?
  • 3. The edit control eats the ESCAPE key
    Dear All, I have a property sheet and in one of the page there is a edit control. I find that if the focus window falls into the edit control, the ESCAPE key can not close the window. I made several tests and get the following conclusion: If the edit control is multiple line, it will always eat the ESCAPE key. If the edit control is single line, it won't eat the ESCAPE key. My question is that: is there any elegant or convient way to let the multi-line edit control NOT eat the ESCAPE key. Thanks in advance. Regards, Johnny Xia.
  • 4. Fix header position on ScrollView
    I am trying to implement an outlook like calendar view with Date header. I tried to use header control in scrollview but the header is move away when i scroll. How can I stick the header at fix position in the scrollview, just like the header in list control? Thx a lot
  • 5. PropertySheet in wizard mode with system menu
    Hi, how can I add a system menu to the property pages / property sheet? Using the corresponding setting for the dialog template doesn't work. Regards, Harald

Default fonts

Postby asellon » Sat, 16 May 2009 00:44:17 GMT

I have looked around for the answer but not very successfully.  If I want to 
find the font information that is in the "Advanced Appearance" dialog under 
the Display Properties dialog found when you rightclick the desktop, where 
do I need to be looking?

What I am after is init-ing a font dialog box with the default font off 
windows.  MS Shell Dlg is not the default I want.

I should be finding tahoma somewhere... so how to get this?



Re: Default fonts

Postby Seetharam » Sat, 16 May 2009 03:40:25 GMT

Have you tried
SystemParametersInfo() with SPI_GETNONCLIENTMETRICS ?

The NONCLIENTMETRICS  struct has all these various font information
( from MSDN )

lfCaptionFont - A pointer to a LOGFONT structure that contains
information about the caption font.
iSmCaptionWidth - The width of small caption buttons, in pixels.
lfSmCaptionFont -A pointer to a LOGFONT structure that contains
information about the small caption font.
lfMenuFont - A pointer to a LOGFONT structure that contains
information about the font used in menu bars.
lfStatusFont - A pointer to a LOGFONT structure that contains
information about the font used in status bars and tooltips.
lfMessageFont - A pointer to a LOGFONT structure that contains
information about the font used in message boxes.


Re: Default fonts

Postby asellon » Sat, 16 May 2009 04:52:21 GMT

yes.  this is what I was looking for..  I recently found it, but thank you 
for responding.


Similar Threads:

1.set default font when adding a new textbox to a windows form

Hi - Is there any way to set default Properties - so that when I add a
new textbox to a form  - that that control  wil start out using Arial
10 (for instance)?

2.Getting system default font

Hi all,
I am having trouble finding out how to get the default system font (i.e. the
one set up in the appearance tab of display settings) so that i can use it
when drawing on a device context.
Does anyone know how to do this?

Cheers for any help you can give me,


3.Changing MFC application's default font


It seems like my MFC application automatically inherit the system font
when it come up. I need to set it to use Tahoma all the time so that
double byte chars can be shown no mater what the system font is.
Anybody have done this before?



4.changing default font size


How can i change the default font size in C++? when i use the TextOut function in MFC, the font size and colour is already a default. How can i change that?


5.default font in a MFC program (main menu)

I wonder if it is possible to change the default font used when
showing the main menu. i.e. not interested in changing the view font.


6. Change Default Font CRichEditView

7. Default font in dialog property pages

8. change default font in CRichedit doc/view

Return to VC


Who is online

Users browsing this forum: No registered users and 57 guest