Jump to content

EzSkin_1-2-3 (exe) 1,000+ Skin & Button Choices


Valuater
 Share

Recommended Posts

  • 1 month later...
  • 4 months later...

Funny, after all the work I originally put into ControlHover.au3, then moved on and developed ButtonHover.au3, then developed Xskin with buttonHover() built-in, then finally developed such an easy program executable that could do it ALL... So EASY.... I even named it "EzSkin"

I really, really thought this would be bigger than all my other threads combined... I am really lost at how simple this is and how many choices it has, yet, no apparent public desire...

Well, the road that lead me here was a lot of fun anyways...

Valuater

8)

Edited by Valuater

NEWHeader1.png

Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...
  • 1 year later...

Be sure to use GUICtrlSetState($tab, $GUI_ONTOP)

Great Example by RazerM with EzSkin

#NoTrayIcon
#include <GUIConstants.au3>
;===============================================================================
;
; Program Name:     Unit Converter
; Description::     Converts Length, Area, Volume, Weight, and Temperature to different units
; Requirement(s):   None
; Author(s):        RazerM
;
;===============================================================================
;

Opt("GUIOnEventMode", 1)
;GUICreate("Imperial to Metric Converter", 440, 130)

#region ; Code generated by EzSkin_1-2-3, Created by Valuater
; For personal use only, All Rights Reserved
; Author of this code: Valuater
; Thank you big_daddy and Joscpe

#include <GUIConstants.au3>
#include <EzSkin.au3>

$EzGUI = EzSkinGUICreate ("Imperial to Metric Converter", 480, 190)
$EzIcon = EzSkinIcon ($EzGUI)
GUICtrlSetOnEvent($EzIcon[1], "Close")
GUICtrlSetOnEvent($EzIcon[2], "Mini")

#endregion

$tab = GUICtrlCreateTab(30, 40, 420, 110)
GUICtrlSetOnEvent(-1, "TabClicked")

GUICtrlCreateTabItem("Length")
GUICtrlCreateLabel("From:", 40, 65)
$LengthFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$LengthTo = GUICtrlCreateInput("", 290, 80, 150)
$LengthConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($LengthConvert, "ConvertLength")
$LengthFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Inches|Feet|Yards|Miles|Millimetres|Centimetres|Metres|Kilometres", "Inches")
$LengthToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Inches|Feet|Yards|Miles|Millimetres|Centimetres|Metres|Kilometres", "Millimetres")

GUICtrlCreateTabItem("Area")
GUICtrlCreateLabel("From:", 40, 65)
$AreaFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$AreaTo = GUICtrlCreateInput("", 290, 80, 150)
$AreaConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($AreaConvert, "ConvertArea")
$AreaFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Square Inches|Square Feet|Square Yards|Acres|Square Miles|Square Millimetres|Square Centimetres|Square Metres|Hectares|Square Kilometres", "Square Inches")
$AreaToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Square Inches|Square Feet|Square Yards|Acres|Square Miles|Square Millimetres|Square Centimetres|Square Metres|Hectares|Square Kilometres", "Square Millimetres")

GUICtrlCreateTabItem("Volume")
GUICtrlCreateLabel("From:", 40, 65)
$VolumeFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$VolumeTo = GUICtrlCreateInput("", 290, 80, 150)
$VolumeConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($VolumeConvert, "ConvertVolume")
$VolumeFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Cubic Inches|Cubic Feet|Fluid Ounces|Pints|Gallons|US Fluid Ounces|US Pints|US Gallons|Cubic Centimetres|Cubic Decimetres|Cubic Metres|Litres|Hectolitres", "Cubic Inches")
$VolumeToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Cubic Inches|Cubic Feet|Fluid Ounces|Pints|Gallons|US Fluid Ounces|US Pints|US Gallons|Cubic Centimetres|Cubic Decimetres|Cubic Metres|Litres|Hectolitres", "Cubic Centimetres")

GUICtrlCreateTabItem("Weight")
GUICtrlCreateLabel("From:", 40, 65)
$WeightFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$WeightTo = GUICtrlCreateInput("", 290, 80, 150)
$WeightConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($WeightConvert, "ConvertWeight")
$WeightFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Ounces|Pounds|Stone|Milligrams|Grams|Kilograms", "Ounces")
$WeightToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Ounces|Pounds|Stone|Milligrams|Grams|Kilograms", "Milligrams")

GUICtrlCreateTabItem("Temperature")
GUICtrlCreateLabel("From:", 40, 65)
$TempFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$TempTo = GUICtrlCreateInput("", 290, 80, 150)
$TempConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($TempConvert, "ConvertTemp")
$TempFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Celsius|Fahrenheit|Kelvin", "Celsius")
$TempToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Celsius|Fahrenheit|Kelvin", "Fahrenheit")

GUICtrlCreateTabItem(" EzSkin!!!  &&  Converter ")
$TempSkin = GUICtrlCreateLabel("> More EzSkin Designs are located here <", 60, 90, 375, 30)
GUICtrlSetColor(-1, 0xff)
GUICtrlSetFont(-1, 14, 500, 6)
GUICtrlSetOnEvent(-1, "Get_Skins")
GUICtrlCreateTabItem("")

GUICtrlSetState($LengthConvert, $GUI_DEFBUTTON)

GUISetState()
GUISetOnEvent($GUI_EVENT_CLOSE, "Close")

GUICtrlSetState($tab, $GUI_ONTOP)

While 1
    EzSkinOver ($EzGUI)
    Sleep(20)
WEnd

Func ConvertTemp()
    $vFrom = Execute(GUICtrlRead($TempFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[3][2] = [["Kelvin", ")*1"], ["Fahrenheit", "+459.67)*5/9"], ["Celsius", "+273.15)"]]
    Local $avToUnits[3][2] = [["Kelvin", ")*1"], ["Fahrenheit", "*9/5-459.67)"], ["Celsius", "-273.15)"]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($TempFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom = Execute("(" & $vFrom & $avUnits[$iUnit][1])
        EndIf
    Next
    For $iUnit = 0 To UBound($avToUnits) - 1
        If GUICtrlRead($TempToUnits) = $avToUnits[$iUnit][0] Then
            $vTo = Execute("(" & $vFrom & $avToUnits[$iUnit][1])
        EndIf
    Next
    GUICtrlSetData($TempTo, $vTo)
EndFunc   ;==>ConvertTemp

Func ConvertWeight()
    $vFrom = Execute(GUICtrlRead($WeightFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[6][2] = [["Ounces", 1], ["Pounds", 16], ["Stone", 224], ["Milligrams", 3.52739619 * 10 ^ - 5], ["Grams", 0.0352739619], ["Kilograms", 35.2739619]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($WeightFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($WeightToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($WeightTo, $vTo)
EndFunc   ;==>ConvertWeight

Func ConvertVolume()
    $vFrom = Execute(GUICtrlRead($VolumeFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[13][2] = [["Cubic Inches", 1], ["Cubic Feet", 1728], ["Fluid Ounces", 1.73387217], ["Pints", 34.6774434], ["Gallons", 277.419547], ["US Fluid Ounces", 1.80468751 ], ["US Pints", 28.8750001], ["US Gallons", 231.000001], ["Cubic Centimetres", 0.0610237441], ["Cubic Decimetres", 61.0237441], ["Cubic Metres", 61023.7441], ["Litres", 61.0237441], ["Hectolitres", 6102.37441]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($VolumeFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($VolumeToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($VolumeTo, $vTo)
EndFunc   ;==>ConvertVolume

Func ConvertArea()
    $vFrom = Execute(GUICtrlRead($AreaFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[10][2] = [["Square Inches", 1], ["Square Feet", 144], ["Square Yards", 1296], ["Acres", 6272640], ["Square Miles", 4014489600], ["Square Millimetres", 0.0015500031], ["Square Centimetres", 0.15500031], ["Square Metres", 1550.0031], ["Hectares", 15500031], ["Square Kilometres", 1.5500031 * 10 ^ 9]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($AreaFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($AreaToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($AreaTo, $vTo)
EndFunc   ;==>ConvertArea

Func ConvertLength()
    $vFrom = Execute(GUICtrlRead($LengthFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[8][2] = [["Inches", 1], ["Feet", 12], ["Yards", 36], ["Miles", 63360], ["Millimetres", 0.0393700787], ["Centimetres", 0.393700787], ["Metres", 39.3700787], ["Kilometres", 39370.0787]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($LengthFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($LengthToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($LengthTo, $vTo)
EndFunc   ;==>ConvertLength

Func TabClicked()
    Switch GUICtrlRead($tab)
        Case 0 ;Length Tab is visible
            GUICtrlSetState($LengthConvert, $GUI_DEFBUTTON)
        Case 1 ;Area Tab is visible
            GUICtrlSetState($AreaConvert, $GUI_DEFBUTTON)
        Case 2 ;Volume Tab is visible
            GUICtrlSetState($VolumeConvert, $GUI_DEFBUTTON)
        Case 3 ;Weight Tab is visible
            GUICtrlSetState($WeightConvert, $GUI_DEFBUTTON)
        Case 4 ;Temperature Tab is visible
            GUICtrlSetState($TempConvert, $GUI_DEFBUTTON)
    EndSwitch
EndFunc   ;==>TabClicked

Func Get_Skins()
    ShellExecute("http://www.autoitscript.com/forum/index.php?showtopic=41319")
EndFunc   ;==>Get_Skins

Func Close()
    Exit
EndFunc   ;==>Close

Func Mini()
    GUISetState(@SW_MINIMIZE)
EndFunc   ;==>Mini

8)

Regarding the above script example:

I'm now using AutoIT 3.3.8.1 and the above script would not work. It requires #include <ComboConstants.au3> to be added as things have been updated a bit since the script was first written. But when fixed, is a perfect example of using the tabs with the skin.

I've been exploring the various GUI examples and fiddled around a fair bit with TabSkin and a couple of other but this EZ_Skin is certainly a nice facility all around.

@Valuator

This is a most excellent utility and I really hope that you'll continue to support & develop it. If you are so inclined, I would suggest 1 minor change which is, when you create the script to place it in @ScriptDirEzSkin2 IE:"E:AutoIT_ScriptsEZ_SkinEzSkin2" instead of the desktop.

One other thought to go with it but I'm not sure it would even be practical to do but maybe have the EzSkin_1-2-3.exe program have a couple of options to generate Tabbed or Menu.

One Question which I have not found the answer to yet in the thread (I have to re read things a couple of times) is using BMP the only option or can JPG or PNG be used as well. Ideally I'd like to use teh smallest graphic format possible and incorporate them into the generated EXE so they don't have to be external or extracted to display.

Sorry if it's been asked before & I missed it but I'm pretty new to AutoIT and it's a bit of a learning curve to assimilate it.

Thanks a lot for all yoru efforts!

WhiteStar

~ WhiteStar Magic

Always tuned to http://www.superbluesradio.com/Ā  Tune in at http://87.117.217.41:8036/

Link to comment
Share on other sites

Hi Whitestar,

I haven't been around as much so I am behind on updates & etc... But I do try to help people when I can.

The result is EzSkin.exe....

Funny, after all the work I originally put into ControlHover.au3, then moved on and developed ButtonHover.au3, then developed Xskin with buttonHover() built-in, then finally developed such an easy program executable that could do it ALL... So EASY.... I even named it "EzSkin"

I really, really thought this would be bigger than all my other threads combined... I am really lost at how simple this is and how many choices it has, yet, no apparent public desire...

Well, the road that lead me here was a lot of fun anyways...

Valuater

8)

XSkin.au3 is where you can look to understand what is inside EzSkin.exe

Hope that helps

Valuater

8)

Edited by Valuater

NEWHeader1.png

Link to comment
Share on other sites

  • 9 months later...
  • 2 weeks later...

perhaps part of the problem is the need of manually creating the GUI-s.. since Koda is not much help if one wants to use EzSkin.. and with more difficult GUI-s it's quite time consuming task.

I am using EzSkin at the moment and it's a joy, after the GUI part is done... TY

Link to comment
Share on other sites

  • 4 weeks later...

Ok I am very new with autoit and xskin. I have tried to run a simple file found as an example that came with xskin. first thing autoit says there is an error opening #include xskin

I did put in the file path, replacing @ScriptDir

In hunting around, I added the include-once

#include-once

#Include <XSkin.au3>

; folder of skin

$Skin_Folder = @ScriptDir & "SkinsBlack-Yellow"

$XSkinGui = XSkinGUICreate( "My GUI", 400, 450, $Skin_Folder)

GUISetState()

While 1

Sleep(10)

WEnd

Thanks

9acresdave

Link to comment
Share on other sites

download the http://www.autoitscript.com/forum/index.php?app=downloads&showfile=45 unpack it somewhere.. run EzSkin_1-2-3.exe, pick the theme & button style you like the most and export them. Then modify the exported script (or simply create brand new script of your own) accordingly.

Files for the button style and theme are located in same exported folder with the demoscript and UDF-file, but inside the "EzSkin" subfolder. you can recognize it by seeing files like Standard1.bmp, Skin.dat, 0.bmp, 1.bmp and so forth, in it.

UDF you must keep is EzSkin.au3 (for #include 'EzSkin.au3' in your own script), demofile is what you can tear apart, modify or erase alltogether.

UDF also contains function descriptions you could use. Just skim it trough for better look.

Edited by shaqan
Link to comment
Share on other sites

Hey! Wayfarer that EzSkin_1-2-3.exe is a real nice program. I have made 5 skins and buttons from there. It just would be nice if I get a style of button I like, to be able to make it the color I like also. Or am I missing something! : Well I will go back and take another look.

Thanks for your response :bye:

Link to comment
Share on other sites

  • 2 weeks later...
  • 4 months later...
  • 1 month later...

Ā 

Hi.

I have a church project where I need to create a matrix (about 10 by 10) with questions/answers. Students pick a square (button) on the matrix being displayed on a large format television screen.

When I click on the chosen button, a question shows up, the student is given a chance to verbally answer. Finally, a second click reveals the answer.

There is a column heading for each column on top (categories), and a label for each row (point value) going down the left.

Think of the Jeopardy TV program.

I downloaded your EzSkin and was very impressed by it. I think I can make it work, but having a bit of a problem. I can't change the button labels, text, color, etc. from the initial value.

I can always revert to the regular button functions but this defeats the purpose of having much more attractive skin-based custom buttons.

Is there a way to use your EzSkinButton function while being able to change at least some of the states?

Thank you.

Ā 

Here is an ideas... I whipped up quickly ( needs more work )

#include <GUIConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
$gui = GUICreate("Jeapordy", 800, 600, -1, -1, $WS_POPUP, BitOR($WS_EX_TOPMOST, $WS_EX_TOOLWINDOW))
_GuiRoundCorners($gui, 0, 0, 100, 100)
GUICtrlCreatePic("JeopardyBoard.jpg", -1, 0, 800, 601)
GUICtrlSetState(-1, $GUI_DISABLE)
GUIRegisterMsg($WM_LBUTTONDOWN, "_WinMove")
;******************************** Create labels *****
GUICtrlCreateLabel("FOOD", 50, 50, 100, 30)
GUICtrlSetFont(-1, 22)
GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT)
;******************************** Create buttons *****
$Button1 = GUICtrlCreateLabel("$100", 55, 130, 100, 30)
GUICtrlSetFont( $Button1, 22)
GUICtrlSetBkColor($Button1, $GUI_BKCOLOR_TRANSPARENT)
GUISetState(@SW_SHOW, $gui)
; Create second GUI
$gui2 = GUICreate("Question", 400, 300)
$question = GUICtrlCreateLabel("", 10, 10, 380, 250)
$click = GUICtrlCreateButton("ANSWER", 150, 270, 120)
GUISetState(@SW_HIDE, $gui2)
While 1
 $Msg = GUIGetMsg()
 Select
  Case $Msg = $GUI_EVENT_CLOSE
   Exit
  Case $Msg = $Button1
   GUICtrlSetData($Button1, "")
   _Set_Question("the topic of food is all about cooking")
 EndSelect
WEnd
Func _Set_Question($text)
 GUISetState(@SW_HIDE, $gui)
 GUICtrlSetData($question, $text)
 GUISetState(@SW_SHOW, $gui2)
 GUISetState(@SW_SHOWNORMAL, $gui2)
While 2
 $Msg2 = GUIGetMsg()
 Select
  Case $Msg2 = $GUI_EVENT_CLOSE
   GUISetState(@SW_HIDE, $gui2)
   GUISetState(@SW_SHOW, $gui)
   ExitLoop
  Case $Msg2 = $Click
   GUICtrlSetData($question, "HERE IS YOUR ANSWER")
 EndSelect
WEnd
 
EndFunc   ;==>_Set_Question
Func _WinMove($HWnd, $Command, $wParam, $lParam)
 If BitAND(WinGetState($HWnd), 32) Then Return $GUI_RUNDEFMSG
 DllCall("user32.dll", "long", "SendMessage", "hwnd", $HWnd, "int", $WM_SYSCOMMAND, "int", 0xF009, "int", 0)
EndFunc   ;==>_WinMove
Func _GuiRoundCorners($h_win, $i_x1, $i_y1, $i_x3, $i_y3)
 Dim $pos, $ret, $ret2
 $pos = WinGetPos($h_win)
 $ret = DllCall("gdi32.dll", "long", "CreateRoundRectRgn", "long", $i_x1, "long", $i_y1, "long", $pos[2], "long", $pos[3], "long", $i_x3, "long", $i_y3)
 If $ret[0] Then
  $ret2 = DllCall("user32.dll", "long", "SetWindowRgn", "hwnd", $h_win, "long", $ret[0], "int", 1)
  If $ret2[0] Then
   Return 1
  Else
   Return 0
  EndIf
 Else
  Return 0
 EndIf
EndFunc   ;==>_GuiRoundCorners

Good Luck

8)

post-4920-0-21442500-1376615107_thumb.jp

Edited by Valuater

NEWHeader1.png

Link to comment
Share on other sites

  • 3 weeks later...
  • 9 months later...

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