What is the font used by Microsoft in their menubars?
Garrett Hylltun
garrett at paraboliclogic.com
Sun Apr 2 05:33:48 EDT 2006
Garrett Hylltun wrote:
> Dr. Robert E. Ball wrote:
>> Does anyone know what font is used in Microsoft Windows menubars? Can
>> I use
>> that font for the menubars in Revolution standalones built for Windows?
>
> It can vary depending on what theme they use in 95-ME/NT-2k and what
> Visual Style they use in XP.
>
> By default in 95 through ME, I believe it was "MS Serif" or "MS Sans
> Serif". Default on XP I believe is "Tahoma"
>
> In ME and XP (Most likely 98/NT/2K also), you can get the Menu font from
> the registry under the following:
> HKEY_USERS\.DEFAULT\Control Panel\Desktop\WindowMetrics,MenuFont
>
> It's in binary format so you'll have to convert it to get the text name
> of the font being used for the menu. I'm not sure at the moment how to
> convert that in Rev.
>
> (Rev can read registry data can't it?)
Answered my own question by checking the docs. Here's the code you can
use to get the menu font:
queryRegistry("HKEY_USERS\.DEFAULT\Control
Panel\Desktop\WindowMetrics\MenuFont",varWinMenuFont)
I believe that's how you code it. varWinMenuFont will hold the data,
but you will still need to convert that to a string from binary. The
Rev docs say to use "binaryDecode" to convert that, so check the docs on
that to find out how to convert it to a string.
-Garrett
More information about the use-livecode
mailing list