Search found 40 matches
- Today, 10:43
- Forum: Scripts and Functions (v2)
- Topic: [2024/06/06] ColorButton.ahk | Customize Gui Button Background/ Text/ Border Colors.
- Replies: 14
- Views: 1984
Re: [2024/05/06] ColorButton.ahk | An extended method that lets you customize gui button background colors.
here's the solution that worked for me after testing for a few hours, ctrl-f `first` for changes case CDDS_PREPAINT : { isPressed := GetKeyState("LButton", "P") isHot := (lpnmCD.uItemState & CDIS_HOT) corner := (roundedCorner ?? (IS_WIN11 ? 9 : 0)) drawFocused := (showFocusedBorder && !IsSet(first)...
- 08 May 2024, 15:07
- Forum: Scripts and Functions (v2)
- Topic: [2024/06/06] ColorButton.ahk | Customize Gui Button Background/ Text/ Border Colors.
- Replies: 14
- Views: 1984
Re: ColorButton.ahk | An extended method that lets you customize gui button background colors.
hey big fan of your stuff. I do a lot of gui work, https://github.com/samfisherirl/Easy-Auto-GUI-for-AHK-v2 and https://github.com/samfisherirl/Useful-AHK-v2-Libraries-and-Classes?tab=readme-ov-file#gui-libraries I worked with GuiResizer for all of my commercial application guis due to various reso...
- 05 May 2024, 19:51
- Forum: Scripts and Functions (v2)
- Topic: [2024/06/06] ColorButton.ahk | Customize Gui Button Background/ Text/ Border Colors.
- Replies: 14
- Views: 1984
Re: ColorButton.ahk | An extended method that lets you customize gui button background colors.
BTW: class NMCUSTOMDRAWINFO { static Call(ptr) { return { hdr: { hwndFrom: NumGet(ptr, 0 ,"uptr"), idFrom : NumGet(ptr, 8 ,"uptr"), code : NumGet(ptr, 16 ,"int") }, dwDrawStage: NumGet(ptr, 24, "uint"), hdc : NumGet(ptr, 32, "uptr"), rc : RECT( NumGet(ptr, 40, "uint"), NumGet(ptr, 44, "uint"), NumG...
- 03 May 2024, 13:58
- Forum: Scripts and Functions (v2)
- Topic: [2024/06/06] ColorButton.ahk | Customize Gui Button Background/ Text/ Border Colors.
- Replies: 14
- Views: 1984
Re: ColorButton.ahk | An extended method that lets you customize gui button background colors.
Moin, running the code embedded in your v2.0 script with v2.0.13 on Win 10 myGui := Gui() myGui.SetFont("cWhite s24", "Segoe UI") myGui.BackColor := 0x2c2c2c btn := myGui.AddButton(, "SUPREME") btn.SetBackColor(0xaa2031) btn2 := myGui.AddButton(, "SUPREME") btn2.SetBackColor(0xffd155) myGui.Show("w...
- 01 May 2024, 13:37
- Forum: Scripts and Functions (v2)
- Topic: [2024/06/06] ColorButton.ahk | Customize Gui Button Background/ Text/ Border Colors.
- Replies: 14
- Views: 1984
[2024/06/06] ColorButton.ahk | Customize Gui Button Background/ Text/ Border Colors.
This is an extended method for changing a button's background, text and border color. Updates: 2024/06/06 New Features: Customise the button text colour . Customise the button border colour . Customise the button border display timing (always show, show on focus, never show). Once the button backgr...
- 18 Apr 2024, 15:39
- Forum: Scripts and Functions (v2)
- Topic: Apply Dark Theme to Your MsgBox
- Replies: 1
- Views: 658
Apply Dark Theme to Your MsgBox
The original built-in MsgBox is too bright to you? Try this! image.png Get Code For v2.1-alpha.9 users: Click here For v2.0 users: Click here Dark_MsgBox.ahk Example for v2.1-alpha.9 #requires AutoHotkey v2.1-alpha.9 #include <Dark_MsgBox> MsgBox "HELLO", "QQQQ" Example for v2.0 #requires AutoHotkey...
- 10 Apr 2024, 14:50
- Forum: Scripts and Functions (v2)
- Topic: Dark Theme ListView
- Replies: 0
- Views: 541
Dark Theme ListView
This script applies a dark theme to the ListView control. This script is compatible with AutoHotkey v2.1-alpha.9 or later . Features Applies a dark theme to the ListView control. Compatible with AutoHotkey v2.1-alpha.9 or later. Learn more about the ahk v2.1-alpha: Click here image.png Usage Downloa...
- 30 Mar 2024, 13:35
- Forum: Scripts and Functions (v2)
- Topic: System Theme Aware ToolTip (Dark/ Light Mode)
- Replies: 6
- Views: 566
Re: System Theme Aware ToolTip
I compared how ToolTipEx and ToolTipX performed and found out that the former causes delays when called repeatedly, while the latter immediately updates the tooltip text, although the timeout is affected (it is not reset and gets reduced). Can you look into this? Here's a script in which I am using...
- 26 Mar 2024, 01:52
- Forum: Scripts and Functions (v2)
- Topic: System Theme Aware ToolTip (Dark/ Light Mode)
- Replies: 6
- Views: 566
Re: System Theme Aware ToolTip
Nice script as always @NPerovic! I am using ToolTipX script as a library. I found it here: https://www.autohotkey.com/boards/viewtopic.php?p=515335#p515335 . Can you incorporate the system-aware feature in that as well? Much appreciated. Edit: Btw, I followed you on Github. :) Thanks:) It's great t...
- 25 Mar 2024, 17:00
- Forum: Scripts and Functions (v2)
- Topic: System Theme Aware ToolTip (Dark/ Light Mode)
- Replies: 6
- Views: 566
System Theme Aware ToolTip (Dark/ Light Mode)
This will make your ToolTip style conform to the current system theme (dark/ light mode and rounded corners on Win 11). How It Looks Like (On Windows 11/ Dark Mode) image.png How To Use Just simply include this class in your script, and you're good to go! No need to create an instance. If you saved...
- 16 Mar 2024, 14:37
- Forum: Scripts and Functions (v2)
- Topic: MsgBoxCopyText
- Replies: 6
- Views: 670
Re: MsgBoxCopyText
An easy way to do the same thing:
Code: Select all
#Requires AutoHotkey v2
MsgBoxCopyText(Enable := true) {
HotIfWinActive("ahk_class #32770")
Hotkey("^c", (*) => A_Clipboard := ControlGetText("Static1"), Enable ? "On" : "Off")
}
- 07 Mar 2024, 09:16
- Forum: Scripts and Functions (v1)
- Topic: AutohoKey tool chinese
- Replies: 3
- Views: 394
Re: AutohoKey tool chinese
@dengpeiyou — If this is the same script that is now in the Chinese forum, it is v1 code and should not be posted here in the v2 section. You apparently also posted the same script in the v1 section. Is this the same script? I have not downloaded it to verify. I downloaded it, and it's 100% v1 for ...
- 18 Jan 2024, 21:26
- Forum: Ask for Help (v2)
- Topic: Creating a "Super" key for Emacs Gui on Windows11 WSLg
- Replies: 4
- Views: 627
Re: Creating a "Super" key for Emacs Gui on Windows11 WSLg
Once the InputHook starts, it should not stop before LWin is released. While holding down LWin , any other key press will trigger the callback function for the OnKeyDown and OnKeyUp events. (You can replace OnKeyDown and OnKeyUp with OnChar if you only want to trigger letters and numbers) #Requires...
- 12 Dec 2023, 07:13
- Forum: Ask for Help (v2)
- Topic: Conflict with PowerToys - Caps and Control Switch?
- Replies: 7
- Views: 521
Re: Conflict with PowerToys - Caps and Control Switch?
InstallKeybdHook() #InputLevel 1 CapsLock::LCtrl .... I tried that and it worked great for about 10 minutes. Then it got stuck on CAPS LOCK and neither key (Caps or Ctrl) would get it out. Exiting the script did it of course. How about this one? #Requires AutoHotkey v2 InstallKeybdHook() #HotIf InS...
- 06 Dec 2023, 03:21
- Forum: Ask for Help (v2)
- Topic: Conflict with PowerToys - Caps and Control Switch?
- Replies: 7
- Views: 521
Re: Conflict with PowerToys - Caps and Control Switch?
Ahk can do everything that PowerToys Keyboard Manager can. I'm not sure if I understand what you're trying to do, but this script does: CapsLock > LControl LControl > CapsLock CapsLock + any keys = LControl + any keys Showing MsgBox only when CapsLock being pressed and released along . (Tested on wi...
- 06 Dec 2023, 02:15
- Forum: Ask for Help (v2)
- Topic: Long / Short press a key ??
- Replies: 10
- Views: 767
Re: Long / Short press a key ??
AHK will not allow you to make up your own syntax. ChatGPT is not good with AHK, especially v2. See the :arrow: KeyWait options. #Requires AutoHotkey v2.0 ~RShift:: { KeyWait 'RShift' If A_TimeSinceThisHotkey < 200 Send 'b' } It does what I want, Thx. But there is something very strange with just C...
- 22 Nov 2023, 00:56
- Forum: Ask for Help (v2)
- Topic: How to use/call the GetMonitorInfo Win32 function
- Replies: 5
- Views: 418
Re: How to use/call the GetMonitorInfo Win32 function
Use Buffer to store data temporarily. Make sure you use the correct parameters for WinMove . CenterActiveWindow() { Numput("UInt", 40, buf := Buffer(40, 0)) hMonitor := DllCall("MonitorFromWindow", "Int", WinExist("A"), "UInt", 2) DllCall("GetMonitorInfoW", "Ptr", hMonitor, "Ptr", buf) L := NumGet(b...
- 21 Nov 2023, 14:59
- Forum: Ask for Help (v2)
- Topic: [Windows 11] Win+Tab mapping to Alt+tab with having Tab switch through windows instead of arrow keys
- Replies: 11
- Views: 1095
Re: [Windows 11] Win+Tab mapping to Alt+tab with having Tab switch through windows instead of arrow keys
Hi, What I want is exactly Alt + Tab functionality to work in Task View but work with Alt+Tab keys instead of Win+Tab, so what I wanted is (I thought my OP requirements will be enough, but it seems not sufficient enough to replicate Alt+Tab functionality): 1. Alt + Tab should open Task View instead...
- 18 Nov 2023, 02:37
- Forum: Ask for Help (v2)
- Topic: [Windows 11] Win+Tab mapping to Alt+tab with having Tab switch through windows instead of arrow keys
- Replies: 11
- Views: 1095
Re: [Windows 11] Win+Tab mapping to Alt+tab with having Tab switch through windows instead of arrow keys
Try this
Code: Select all
#Requires AutoHotkey v2
#HotIf WinActive("ahk_class XamlExplorerHostIslandWindow")
Tab::Right
+Tab::Left
#HotIf
<!Tab::#Tab
- 14 Nov 2023, 20:20
- Forum: Tips and Tricks
- Topic: Multiple distinct RegExMatch matches for v2
- Replies: 1
- Views: 816
Re: Multiple distinct RegExMatch matches for v2
What is HasVal() for? You can still get the same result without it, isn't it? #Requires AutoHotkey v2 ~^n::{ test := "", mtgaMatches := [] Haystack := 'blabla bla bla this:"xx" bla bla bla bla this:"xx" bla this:"yy" bla bla bla this:"zz"' while p := RegExMatch(Haystack, 'this:"([^"]+)"', &m, (p ?? ...