Jump to content
Sign in to follow this  
KenNichols

How do I make a better looking button?

Recommended Posts

KenNichols

GUICtrlCreateButton("Button", 10, 10, 70, 20)

When using the standard Windows XP theme these types of buttons look ok. But if you use the Windows Classic theme they basically blend into the background.

Is there a way to embed the pictures when using GUICtrlCreatePic("", 72, 80, 92, 28)?

Or is there a better way to create buttons?


[topic="21048"]New to AutoIt? Check out AutoIt 1-2-3![/topic] Need to make a GUI? You NEED KODA FormDesigner!

Share this post


Link to post
Share on other sites
CodyBarrett

$BS_ICON

and... i personally use Labels when it comes to buttons they are much more customizable

Share this post


Link to post
Share on other sites
KenNichols

$BS_ICON

and... i personally use Labels when it comes to buttons they are much more customizable

Thanks for the reply. It's not exactly what I need, but good to know.

Can you give me an example of how you use Labels?


[topic="21048"]New to AutoIt? Check out AutoIt 1-2-3![/topic] Need to make a GUI? You NEED KODA FormDesigner!

Share this post


Link to post
Share on other sites
CodyBarrett

$label = Guictrlcreatelabel ('LABEL', 10, 10, 100, 20, $SS_CENTER)
Guictrlsetbkcolor (-1, 0x2E2E2E)
Guictrlsetcolor (-1, 0xFFFFFF)
Guictrlsetfont (-1, 10, 400, 'Fixedsys')

a label control is the same control as a button except that buttons have a nice Push in animation, labels on the other hand are MUCH more customizable

Share this post


Link to post
Share on other sites
KenNichols

Thanks ButtonHover is pretty close to what I wanted. Is there a way to embed the button pics into the app?


[topic="21048"]New to AutoIt? Check out AutoIt 1-2-3![/topic] Need to make a GUI? You NEED KODA FormDesigner!

Share this post


Link to post
Share on other sites
Valuater

Yes FileInstall()

$My_pic = @TempDir & "\Over.jpg"
FileInstall("C:\Program Files\AutoIt3\Examples\Over.jpg", $My_pic)

8)


NEWHeader1.png

Share this post


Link to post
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
Sign in to follow this  

×