In the Window designer I can specify a font and size for the MENUBAR, and it even shows the desired font in the Window Preview. But alas when I generate and run the app I am left with the default font and size. How do I fix this?
Any suggestions will be gratefully received.
So you might try looking at the generated code for the window preview.
Apart from that…
This is what I use
INCLUDE('CWINT.int'),ONCE !<-- for alter menu font.
MenuStyle &IMenuStyle
FontProps &IFontProperties
FontName CSTRING('Segoe UI')
CODE
MenuStyle &= (SYSTEM{PROP:MenuStyle})
FontProps &= MenuStyle.MenuFont()
FontProps.FontName(FontName)
!FontProps.FontSize(11)
!WARNING: this alters POPUP() menus too
!see Libsrc\Win\MenuStyle.inc/clw
3 Likes
So you might try looking at the generated code for the window preview.
I meant the window designer, sorry. It shows what I want:
But what I get is different:

Apart from that…
This is what I use
Where do I put this code?
I understood you meant the window desginer
When you preview a window
it generates CLW code and compiles it.
note: this is NOT template generated code.
I put it before opening my first window
1 Like
As it turns out, the problem was much simpler. Changing the font property in the Window designer only changes the size, not the font. But if I specify the font property correctly in the underlying code, it works as intended:
See the code I have highlighted.
2 Likes