Jump to content

XP Themes and GUI appearance


CyberSlug
 Share

Recommended Posts

See Attached screenshot... Why do the second and third buttons look the way they do?

; Using a recent November unstable version of AutoIt on XP Pro sp2
Global $GUI_EVENT_CLOSE = -3, $BS_ICON = 0x40
GuiCreate("Example", 300, 100)

GuiCtrlCreateButton("One", 10, 10, 50, 50)
GuiCtrlCreateButton("Two", 100, 10, 50, 50, $BS_ICON)
GuiCtrlCreateButton("Three", 180, 10, 50, 50, $BS_ICON)
   GuiCtrlSetImage(-1, "shell32.dll")

GuiSetState()
While GuiGetMsg() <> $GUI_EVENT_CLOSE
WEnd
Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
Link to comment
Share on other sites

Simple (I think). The control is either owner drawn and isn't properly calling the theme API or a native Windows feature doesn't have automatic theme support when used this way. In either case, the answer is to have a look at the Visual Style related functions. They are declared in uxtheme.h (Platform SDK is required, I believe). In this situation, the correct functions must be called (Dynamically so as to be compatible with Pre-XP or whenver uxtheme.dll came about).

Link to comment
Share on other sites

I had a similar result using progress bars...In the default Windows XP theme, if you wanted the scrollbar to be smooth it would default to being a segmented one, but under Win2k and the classic theme, you'd get the smooth scrollbar..

Weird, but nonetheless acceptable I think!

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...