English
Source / code snippets

List detect Font system Systemfonts

 
Andreas Miethe, URL=www.paules-pc-forum.de/forum/XProfan/125241-systemfonts-detect.html#mail763422 , Zeitpunkt=30.01.2010
I habs recently time used, Perhaps can it Yes yet someone use.
CompileMarkSeparation
 $H Windows.ph
DEF Checkmin(1) @If(@!(1) < 0, Int(@!(1)*-1), Int(@!(1)))
Struct LOGFONT =
lfHeight&,
lfWidth&,
lfEscapement&,
lfOrientation&,
lfWeight&,
lfItalic#(1),
lfUnderline#(1),
lfStrikeOut#(1),
lfCharSet#(1),
lfOutPrecision#(1),
lfClipPrecision#(1),
lfQuality#(1),
lfPitchAndFamily#(1),
lfFaceName$(31)
Struct NONCLIENTMETRICS =
cbSize&,
iBorderWidth&,
iScrollWidth&,
iScrollHeight&,
iCaptionWidth&,
iCaptionHeight&,
lfCaptionFont!LOGFONT,
iSmCaptionWidth&,
iSmCaptionHeight&,
lfSmCaptionFont!LOGFONT,
iMenuWidth&,
iMenuHeight&,
lfMenuFont!LOGFONT,
lfStatusFont!LOGFONT,
lfMessageFont!LOGFONT
cls
Var NCM# = New(NONCLIENTMETRICS)
NCM#.cbSize& = SizeOf(NCM#)
~SystemParametersInfo(~SPI_GETNONCLIENTMETRICS,SizeOf(NCM#),NCM#,0)
Print "Systemfonts"
Print
Print "TITELLEISTE         : " ,NCM#.lfCaptionFont!lfFacename$, Checkmin(- ~MulDiv(NCM#.lfCaptionFont!lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
Print "SCHMALE TITELLEISTE : " ,NCM#.lfSmCaptionFont!lfFacename$, Checkmin(- ~MulDiv(NCM#.lfSmCaptionFont!lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
Print "MENÜ                : " ,NCM#.lfMenuFont!lfFacename$, Checkmin(- ~MulDiv(NCM#.lfMenuFont!lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
Print "STATUSBAR           : " ,NCM#.lfStatusFont!lfFacename$, Checkmin(- ~MulDiv(NCM#.lfStatusFont!lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
Print "MESSAGEBOX          : " ,NCM#.lfMessageFont!lfFacename$, Checkmin(- ~MulDiv(NCM#.lfMessageFont!lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
Dispose NCM#
Var GUI# = New(LOGFONT)
~GetObject(~GetStockObject(~DEFAULT_GUI_FONT), SizeOf(GUI#),GUI#)
Print "DEFAULT_GUI_FONT    : " ,GUI#.lfFacename$, Checkmin(- ~MulDiv(GUI#.lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
~GetObject(~GetStockObject(~ANSI_FIXED_FONT), SizeOf(GUI#),GUI#)
Print "ANSI_FIXED_FONT     : " ,GUI#.lfFacename$, Checkmin(- ~MulDiv(GUI#.lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
~GetObject(~GetStockObject(~ANSI_VAR_FONT), SizeOf(GUI#),GUI#)
Print "ANSI_VAR_FONT       : " ,GUI#.lfFacename$, Checkmin(- ~MulDiv(GUI#.lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
~GetObject(~GetStockObject(~DEVICE_DEFAULT_FONT), SizeOf(GUI#),GUI#)
Print "DEVICE_DEFAULT_FONT : " ,GUI#.lfFacename$, Checkmin(- ~MulDiv(GUI#.lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
~GetObject(~GetStockObject(~OEM_FIXED_FONT), SizeOf(GUI#),GUI#)
Print "OEM_FIXED_FONT      : " ,GUI#.lfFacename$, Checkmin(- ~MulDiv(GUI#.lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
~GetObject(~GetStockObject(~SYSTEM_FONT), SizeOf(GUI#),GUI#)
Print "SYSTEM_FONT         : " ,GUI#.lfFacename$, Checkmin(- ~MulDiv(GUI#.lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
~GetObject(~GetStockObject(~SYSTEM_FIXED_FONT), SizeOf(GUI#),GUI#)
Print "SYSTEM_FIXED_FONT   : " ,GUI#.lfFacename$, Checkmin(- ~MulDiv(GUI#.lfHeight&,72,~GetDeviceCaps(%hDc,~LOGPIXELSY)))
Dispose GUI#
waitinput
 href='./../../Function-References/XProfan/end/'>end
 
01/30/10  
 



Zum Quelltext


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

3.624 Views

Untitledvor 0 min.
rquindt05/01/18
Nico Madysa06/28/16
Julian Schmidt06/30/11

Themeninformationen

this Topic has 1 subscriber:

iF (1x)


Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie