Thanks for pointing me in the right direction, I will try this.
It would be great if you could share your working example with us, try to make a dropbox link or similar.
Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
See if this link will work. This should be to a folder on my Google Drive that contains a zip called main.zip for the ribbon.
AHK Ribbon Demo
AHK Ribbon Demo
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Thanks. I see your example is based on SimpleRibbon.xml example from Microsoft. I was able to compile it with Visual Studio (free edition) and rename it to dll. However when I try to load it with Main.ahk I get an error - Failed to load ribbon. Some other examples load well... I wonder what might be the issue...
Did you use any visual editor for ribbon xml?
Did you use any visual editor for ribbon xml?
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
I just used Visual Studio 2015. It prompted me to uplift the project or something, which I did. I have extremely little experience with compiling code and using Visual Studio. Does it work if you use the .dll that I provided?
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Yes, your dll works, I must have done something wrong... Do you still have your xml file?
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
I added the xml file to the G-Drive folder I shared above.
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Windows 10 Settings Concept
Todo:
Atm the Tab-Style-Buttons lose colors when other controls get the focus
Possible solution is catch the active tab-button and set the defaulted color as normal color for this button. After switch set back to normal.
Or disable the button if defaulted and color them. Enable if switch to another button.
Code:
Todo:
Atm the Tab-Style-Buttons lose colors when other controls get the focus
Possible solution is catch the active tab-button and set the defaulted color as normal color for this button. After switch set back to normal.
Or disable the button if defaulted and color them. Enable if switch to another button.
Code:
Code: Select all
; GLOBAL SETTINGS ===============================================================================================================
#NoEnv
#SingleInstance Force
SetBatchLines -1
global version := 0.03
global IBAnimation := True ; enable / disable (hover-fade) animation
global IBNames := ["Startpage", "Menu 1", "Menu 2", "Menu 3", "Menu 4"]
global IBClrStyles := [ [0, 0x80FFFFFF, , 0xD3000000, 0, , 0x80FFFFFF, 1] ; normal
, [0, 0x80E6E6E6, , 0xD3000000, 0, , 0x80E6E6E6, 1] ; hover
, [0, 0x80CCCCCC, , 0xD3000000, 0, , 0x80CCCCCC, 1] ; pressed
, [0, 0x80F3F3F3, , 0x000078D7, 0, , 0x80F3F3F3, 1] ] ; disabled (defaulted)
; GUI ===========================================================================================================================
Gui, Margin, 0, 0
Gui, Color, FFFFFF
Gui, Font, s12, Segoe UI
Gui, Add, Button, xm ym w150 h30 0x100 hWndhBTN01 gMN_SELECT vMN_TAB_1, % " " IBNames[1]
ImageButton.Create(hBTN01, IBClrStyles*)
Gui, Add, Button, xm y+0 w150 h30 0x100 hWndhBTN02 gMN_SELECT vMN_TAB_2, % " " IBNames[2]
ImageButton.Create(hBTN02, IBClrStyles*)
Gui, Add, Button, xm y+0 w150 h30 0x100 hWndhBTN03 gMN_SELECT vMN_TAB_3, % " " IBNames[3]
ImageButton.Create(hBTN03, IBClrStyles*)
Gui, Add, Button, xm y+0 w150 h30 0x100 hWndhBTN04 gMN_SELECT vMN_TAB_4, % " " IBNames[4]
ImageButton.Create(hBTN04, IBClrStyles*)
Gui, Add, Button, xm y+0 w150 h30 0x100 hWndhBTN05 gMN_SELECT vMN_TAB_5, % " " IBNames[5]
ImageButton.Create(hBTN05, IBClrStyles*)
Gui, Add, Tab2, xm ym w0 h0 -Wrap Choose1 AltSubmit vMyMenuTab, % "1|2|3|4|5"
Gui, Tab, 1
Gui, Font, s14 c474747, Segoe UI
Gui, Add, Text, xm+150 ym w250 h250, % " " IBNames[1]
Gui, Tab, 2
Gui, Font, s14 c474747, Segoe UI
Gui, Add, Text, xm+150 ym w250 30, % " " IBNames[2]
Gui, Add, Button, xm+150 y+5 w80 h30, % "Test"
Gui, Tab, 3
Gui, Font, s14 c474747, Segoe UI
Gui, Add, Text, xm+150 ym w250 h250, % " " IBNames[3]
Gui, Tab, 4
Gui, Font, s14 c474747, Segoe UI
Gui, Add, Text, xm+150 ym w250 h250, % " " IBNames[4]
Gui, Tab, 5
Gui, Font, s14 c474747, Segoe UI
Gui, Add, Text, xm+150 ym w250 h250, % " " IBNames[5]
SystemParametersInfo(IBAnimation)
Gui, Show, AutoSize, % "AHK-Concept: Win10 Settings"
return
; SCRIPT ========================================================================================================================
MN_SELECT:
GuiControl, Choose, MyMenuTab, % k := SubStr(A_GuiControl, 8)
loop % IBNames.MaxIndex() {
if (k = A_Index)
GuiControl, Disable, MN_TAB_%A_Index%
else
GuiControl, Enable, MN_TAB_%A_Index%
}
return
; FUNCTIONS =====================================================================================================================
CtlColorBtns() ; https://github.com/jNizM/AHK_Scripts/blob/master/src/gui/GUI_CtlColorBtns.ahk
{
static init := OnMessage(0x0135, "CtlColorBtns")
return DllCall("gdi32\CreateSolidBrush", "uint", 0xFFFFFF, "uptr")
}
SystemParametersInfo(toggle := 0) ; https://msdn.microsoft.com/en-us/library/ms724947(v=vs.85).aspx
{
static SPI_SETCLIENTAREAANIMATION := 0x1043
if !(DllCall("user32\SystemParametersInfo", "uint", SPI_SETCLIENTAREAANIMATION, "uint", 0, "int", toggle, "uint", 0))
throw Exception("SystemParametersInfo failed: " A_LastError, -1)
return true
}
; INCLUDES ======================================================================================================================
#Include Class_ImageButton.ahk ; https://github.com/AHK-just-me/Class_ImageButton
; EXIT ==========================================================================================================================
GuiClose:
GuiEscape:
ExitApp
; ===============================================================================================================================
[AHK] v2.0.5 | [WIN] 11 Pro (Version 22H2) | [GitHub] Profile
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Always been a fan of your settings gui concepts ._. Do you have code?
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Because related: https://autohotkey.com/boards/viewtopic ... 247#p53247Run1e wrote:Always been a fan of your settings gui concepts ._. Do you have code?
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
But a different style =)
Because related: https://autohotkey.com/boards/viewtopic ... 439#p21439
and
Btw I love your examples in this thread TheDewd.. but I wanted some new for my ComputerStats Concept so I created it with ImageButton.ahk from "just me"
Because related: https://autohotkey.com/boards/viewtopic ... 439#p21439
and
Btw I love your examples in this thread TheDewd.. but I wanted some new for my ComputerStats Concept so I created it with ImageButton.ahk from "just me"
[AHK] v2.0.5 | [WIN] 11 Pro (Version 22H2) | [GitHub] Profile
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Thanks for sharing the code! I like it very much! Awesome!jNizM wrote:But a different style =)
My code isn't very great I just shared the link since they are both "Windows 10" inspired.jNizM wrote:Btw I loved your work TheDewd.. but I wanted some new for my ComputerStats Concept so I created it with ImageButton.ahk from "just me"
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Edit code with a temporary solution to keep the defaulted color even if you click on other controls and lose focus (test button on Menu1)
[AHK] v2.0.5 | [WIN] 11 Pro (Version 22H2) | [GitHub] Profile
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Implemented jNizM's concept into Power Play. Might do some tweaking but pretty happy with how smooth the results ended up being.
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Ooooooh fancy! :3
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
I found that setting the "selected" button to disabled (and setting the disabled option array in .Create() to your "active" colors) to give it permanent coloring is better and also makes the animations smooth either way as you don't have to re-create the imagebuttons.jNizM wrote:Edit code with a temporary solution to keep the defaulted color even if you click on other controls and lose focus (test button on Menu1)
Here's what that looks like in Power Play:
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
do you have code @jnizm ? for computerstats ?
Smart Kombo 1.0 | One of the best Knight Online's key combo program...
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Interesting.. will test itRun1e wrote:I found that setting the "selected" button to disabled (and setting the disabled option array in .Create() to your "active" colors) to give it permanent coloring is better and also makes the animations smooth either way as you don't have to re-create the imagebuttons.
For the gui or with the info?Klark92 wrote:do you have code @jnizm ? for computerstats ?
[AHK] v2.0.5 | [WIN] 11 Pro (Version 22H2) | [GitHub] Profile
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Update code again. Should now work. And added Animation (on / off)
[AHK] v2.0.5 | [WIN] 11 Pro (Version 22H2) | [GitHub] Profile
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
I made another attempt at creating a custom gui inspired by Windows 10 (and jNizM).
Script & Images attached (zip archive).
Script & Images attached (zip archive).
- Attachments
-
- Windows10Gui.zip
- (10.66 KiB) Downloaded 800 times
Re: Examples of Non-Standard GUIs (ActiveX, GDI, etc.)
Nice! thanks for sharing
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Return to “Scripts and Functions (v1)”
Who is online
Users browsing this forum: No registered users and 133 guests