Jump to content

Set font of the GUI title.


electrico
 Share

Recommended Posts

I just wanna know if it is possible to set font of the GUI title, created with autoit?

Sorry if lame question, .. posting this thread as found no info in the forums.

I think that there must be DllCall use but any1 experienced could help me avoid time loose, - please.

Thx for prompt replyes and for any help provided.

Sincerely yours, elect.

Edited by electrico
Link to comment
Share on other sites

Ok, thanks for prompt reply.

As a work arround see your other post.

Code per that post was proveded by Melba23 I just added my 2c worth:

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <SendMessage.au3>
#include <StaticConstants.au3>

Global Const $SC_DRAGMOVE = 0xF012
Global $sTitlebarHeight = 15 ; Change this to the value you require
$frmBar = GUICreate("frmBar", 202, $sTitlebarHeight, -1, -1, $WS_POPUP, 0)
GUISetBkColor(0x8080FF)
$GuiLabel = GUICtrlCreateLabel("Use as Title Bar", -1, -1, 202, $sTitlebarHeight, $SS_CENTER, $WS_EX_CLIENTEDGE)
GUICtrlSetFont($GuiLabel, 6, 4, 2, "Comic Sans MS")
GUISetState(@SW_SHOW)
$frmMain = GUICreate("frmMain", 200, 200, 3, $sTitlebarHeight + 3, BitOR($WS_BORDER, $WS_POPUP), $WS_EX_MDICHILD, $frmBar)
GUISetState(@SW_SHOW)
While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
        Case $GUI_EVENT_PRIMARYDOWN
            _SendMessage($frmBar, $WM_SYSCOMMAND, $SC_DRAGMOVE, 0)
    EndSwitch
WEnd
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...