Jump to content

Picture As GUI?


Recommended Posts

ummm... why not just make the gui a tool window style, and make it the size of the picture and make the picture the size of the whole GUI and then just put controls on top...

Functions Needed (main ones at least):

GUICreate

GUICtrlCreateButton (whatever controls u want)

GUICtrlCreatePic

post if u need help :lmao:

FootbaG
Link to comment
Share on other sites

Do a winset trans before guisetstate

Im in a rush and dont have the correct syntax with me but here a basic example fo what you need to do.

$trans = 150

$gui = Guicreate
winsettrans ($gui, $trans)

If you still cant get it working, ill post real code when I get home.

Nova

Edited by Nova
Link to comment
Share on other sites

I think he's looking to have the GUI have regions of transparency, like a mask, like what Winamp can do, which unfortunately, is not available.

If however, you want the whole GUI to be evenly partially transparent, then, like Nova pointed out, WinSetTrans() is the function to use.

Some actual working code (not to be offensive):

#include <GuiConstants.au3>
$gui = GuiCreate('Window')
WinSetTrans($gui, '', 128)
GuiSetState()
Do
     $m = GuiGetMsg()
Until $m = $GUI_EVENT_CLOSE
Link to comment
Share on other sites

Well, ya, lol. I have a picture i made, and i want everything around it to be transparent, lol im trying to figure it out through adobe if there is a way to make the outside AROUND the picture to be invisible, i can post the code and pic if u guys need?

Crome_BAD

Link to comment
Share on other sites

if you mean a background pic you have to make it before everything else and disable it like this

$background = GUICtrlCreatePic( "background.bmp", 0, 0, window's width,window's height)

GUICtrlSetState($background, 128)

[font="Times"] If anyone remembers me, I am back. Maybe to stay, maybe not.----------------------------------------------------------------------------------------------------------[/font][font="Times"]Things I am proud of: Pong! in AutoIt | SearchbarMy website: F.R.I.E.S.A little website that is trying to get started: http://thepiratelounge.net/ (not mine)[/font][font="Times"] ----------------------------------------------------------------------------------------------------------[/font][font="Arial"]The newbies need to stop stealing avatars!!! It is confusing!![/font]

Link to comment
Share on other sites

Or if you give it a style of 0 (zero) it will act the same as being disabled. Like in the script that I linked to.

GuiCtrlCreatePic('default.gif', 0, 0, 275, 116, 0)

Xenogis: you should really use the GUI constants for things like GuiCtrlSetState. It makes for more readable code.

GuiCtrlSetState($background, $GUI_DISABLE)

Not many people know what "128" by itself does. o:)

Also, I think he's looking more for something like this:

Posted Image

Note: That's a Winamp 5 skin. Definitely not AutoIt, just so I don't get any requests for my "special version of AutoIt that does transparent windows" :lmao:

Edited by Saunders
Link to comment
Share on other sites

Unfortunately my main experience in programming is in Visual Basic 6.0 (cruddy if I've ever seen it). I am working my way slowly into c++, so I may be able to come up with something in the future. If you have Windows 2000/XP only, this becomes much easier since there is an API call (something like SetLayeredWindowAttributes or something) that will do this for you (maybe even using DllCall).

Who else would I be?
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...