Search found 388 matches

by RaptorX
06 May 2024, 11:05
Forum: Bug Reports
Topic: SetTitleMatchMode Regex + i) option failing Topic is solved
Replies: 13
Views: 800

Re: SetTitleMatchMode Regex + i) option failing Topic is solved

Apparently it has been documented like this (with slight syntax changes) since 2016: For WinTitle , each component is separate, e.g. in "i)^untitled ahk_class i)^notepad$ ahk_pid " mypid , i)^untitled and i)^notepad$ are separate regex patterns and mypid is always compared numerically (it is not a ...
by RaptorX
05 May 2024, 17:40
Forum: Wish List
Topic: Notify if not UTF-8? -- [Update: Not possible, me thinks]
Replies: 15
Views: 1185

Re: Notify if not UTF-8? -- [Update: Not possible, me thinks]

UTF-8 without the signature is preferred by some crowds. Non-UTF-8 text starting with "" is not a possibility that we need to consider. Anyone writing that as ANSI at the start of a script is likely trying to prove a point, knowing full well that it will be interpreted as UTF-8. Not only that, b...
by RaptorX
25 Apr 2024, 18:44
Forum: Ask for Help (v2)
Topic: Error: Hotkeys/hotstrings are not allowed inside functions or classes. Topic is solved
Replies: 16
Views: 675

Re: Error: Hotkeys/hotstrings are not allowed inside functions or classes. Topic is solved

Thanks for your reply Mike, Incidentally, the roku/hisense tv remote was solely at fault for their crappy implementation of an ir remote. I bought another ir remote made by direct-tv (black a white, and shapely, I guess it's called a genie or something) and seems to work flawlessly. Here is the las...
by RaptorX
24 Apr 2024, 10:37
Forum: Wish List
Topic: A_Downloads might be a nice thing to have at some point.
Replies: 15
Views: 1261

Re: A_Downloads might be a nice thing to have at some point.

I think we have a nice set of built-in variables that are flexible enough to do a lot of interesting things, but I keep thinking we are missing the A_Downloads variable that would point to the default location the downloads folder at in a similar fashion to A_MyDocuments ! Unless there is a technic...
by RaptorX
22 Apr 2024, 19:19
Forum: Ask for Help (v2)
Topic: Error: Hotkeys/hotstrings are not allowed inside functions or classes. Topic is solved
Replies: 16
Views: 675

Re: Error: Hotkeys/hotstrings are not allowed inside functions or classes. Topic is solved

That is not the bug. The hotkeys would be stacked by removing the second brace. Multiple hotkeys can be stacked vertically to have them perform the same action. For example: ^Numpad0:: ^Numpad1:: { MsgBox "Pressing either Ctrl+Numpad0 or Ctrl+Numpad1 will display this." } Source: Hotkeys - Definiti...
by RaptorX
22 Apr 2024, 19:00
Forum: Ask for Help (v2)
Topic: Error handling - ahk-v2
Replies: 1
Views: 108

Re: Error handling - ahk-v2

It is very rare that the operating system throws errors with certain functions but I could envision PixelGetColor throwing an error if you pass invalid parameters or the operating system cannot access the "Screen information" so to speak. Keep in mind that I am oversimplifying here. Most of the time...
by RaptorX
22 Apr 2024, 18:45
Forum: Ask for Help (v2)
Topic: Error: Hotkeys/hotstrings are not allowed inside functions or classes. Topic is solved
Replies: 16
Views: 675

Re: Error: Hotkeys/hotstrings are not allowed inside functions or classes. Topic is solved

Basically you just need to remove the brackets from the #HotIf directive.

The directive itself acts as the container for the code:

Code: Select all

#HotIf WinActive("ahk_exe HD-Player.exe")

f1::msgbox 'single line'
f2::
{
	msgbox 'multiline'
}

; more hotkeys

#HotIf
by RaptorX
20 Apr 2024, 06:25
Forum: Wish List
Topic: A_Downloads might be a nice thing to have at some point.
Replies: 15
Views: 1261

Re: A_Downloads might be a nice thing to have at some point.

yeah! those are great! i have used the one @autoexec posted before...

but hear me out: how about just A_Downloads?? :D

That way you don't have to find those in the forums every time you need it? just type A_Downloads and you are good to go. xD
by RaptorX
19 Apr 2024, 19:57
Forum: Wish List
Topic: Notify if not UTF-8? -- [Update: Not possible, me thinks]
Replies: 15
Views: 1185

Re: Notify if not UTF-8?

I agree with the above.

This is one of those problems that are really tricky to debug some times.
Having a warning at runtime might curve the head-scratching a bit in certain cases.
by RaptorX
19 Apr 2024, 17:08
Forum: Wish List
Topic: A_Downloads might be a nice thing to have at some point.
Replies: 15
Views: 1261

A_Downloads might be a nice thing to have at some point.

I think we have a nice set of built-in variables that are flexible enough to do a lot of interesting things, but I keep thinking we are missing the A_Downloads variable that would point to the default location the downloads folder at in a similar fashion to A_MyDocuments ! Unless there is a technica...
by RaptorX
11 Apr 2024, 22:34
Forum: Bug Reports
Topic: SetTitleMatchMode Regex + i) option failing Topic is solved
Replies: 13
Views: 800

Re: SetTitleMatchMode Regex + i) option failing Topic is solved

Personally I think your perspective is a bit strange. WinTitle is clearly not a regex string, but a WinTitle string containing one or more criteria. Yes, now that it has been clarified I think the same. I think is a problem of the documentation not being clear enough on that point rather than a syn...
by RaptorX
07 Apr 2024, 20:10
Forum: Bug Reports
Topic: SetTitleMatchMode Regex + i) option failing Topic is solved
Replies: 13
Views: 800

Re: SetTitleMatchMode Regex + i) option failing Topic is solved

see my confusion? Yes. I suppose for clarity I will use the standard regex (?i) , rather than the AHK option formatting. Because it does indeed look even more strange with the AHK formatting. Looks like this works for multiple criteria... and is a little easier to read for me. "(?i)tEsTiNg ahk_clas...
by RaptorX
07 Apr 2024, 12:20
Forum: Bug Reports
Topic: SetTitleMatchMode Regex + i) option failing Topic is solved
Replies: 13
Views: 800

Re: SetTitleMatchMode Regex + i) option failing Topic is solved

Why doesnt v1 have this issue? My tests did show this same behavior in v1. But maybe I tested it wrong? Nope you are right, I was the one who didnt perform the test correctly because of the point justme mentioned above. As soon as I changed the casing it stopped matching even with the "i)" option. ...
by RaptorX
07 Apr 2024, 10:00
Forum: Bug Reports
Topic: SetTitleMatchMode Regex + i) option failing Topic is solved
Replies: 13
Views: 800

Re: SetTitleMatchMode Regex + i) option failing Topic is solved

I think im understanding now.

Why doesnt v1 have this issue?
by RaptorX
06 Apr 2024, 17:40
Forum: Bug Reports
Topic: SetTitleMatchMode Regex + i) option failing Topic is solved
Replies: 13
Views: 800

Re: SetTitleMatchMode Regex + i) option failing Topic is solved

Both v1 and v2 display no match for me when I place the option at the beginning of string. But the following works for me in both versions... "ahk_class (?i)AutoHotkey.*" v1.1.37.01 v2.0.11 Yes, your suggestion works, interestingly these also work: Msgbox WinExist("ahk_class i)AutoHotkey.*") and Ms...
by RaptorX
06 Apr 2024, 15:05
Forum: Bug Reports
Topic: SetTitleMatchMode Regex + i) option failing Topic is solved
Replies: 13
Views: 800

SetTitleMatchMode Regex + i) option failing Topic is solved

Hello, If you try this you will get the expected result if you have an AHK GUI out there. SetTitleMatchMode 'Regex' F1::Msgbox WinExist("ahk_class AutoHotkey.*") But as soon as you use the case insensitive option it returns 0x0 SetTitleMatchMode 'Regex' F1::Msgbox WinExist("i)ahk_class AutoHotkey.*"...
by RaptorX
29 Mar 2024, 16:17
Forum: Tutorials (v2)
Topic: A_OSVersion for Win10/11
Replies: 6
Views: 1179

Re: A_OSVersion for Win10/11

For anyone who stumbles across this post, here is a simple function to determine if you're running Windows 10 or Windows 11. GetWinOSVersion() { i := A_OSVersion If (i < 10.0.20000) ; You're running Windows 10 Return 10 Else If (i >= 10.0.20000) ; You're running Windows 11 Return 11 } I think you w...
by RaptorX
26 Mar 2024, 08:16
Forum: Ask for Help (v2)
Topic: always popup submenus on right side of window Topic is solved
Replies: 1
Views: 99

Re: always popup submenus on right side of window Topic is solved

I do not think it is possible under certain conditions. For example: if you put your mouse close to the right edge of the monitor and open the menu. It doesnt matter what setting your computer has, the menu cant be displayed on the right side because it would overflow outside of the visible area of ...
by RaptorX
26 Mar 2024, 08:07
Forum: Visual Studio Code
Topic: VSCode doesn't like particular ahk file(?) Topic is solved
Replies: 2
Views: 329

Re: VSCode doesn't like particular ahk file(?) Topic is solved

What i am not really understading here is: the script launches itself? Why dont you use the Reload command? But back to the original question, if you are trying to run it from VSCode, open the debugging window. I have noticed that the v2 Extension many times catches the errors and display them in th...

Go to advanced search