I would like to add partial window title matching to #IfWinActive. For example to match any notepad window, regardless wether the title is "Untitled - Notepad" or "MyFile - Notepad"
This should be very simple. My attemtps:
SetTitleMatchMode, Regex
SetTitleMatchMode, Slow
#IfWinActive *.Notepad
+n::b
#IfWinActive
second attempt matchmode 2 should match anywhere
SetTitleMatchMode, 2
#IfWinActive Notepad
+n::b
#IfWinActive
A test with using the full title Untitled - Notepad confirms that the code +n::b does substute Shift-n for Shift-b
NOTE: ahk_class is not an option as the class is different on every machine for the target programme TeXnicCenter
*.Notepad
isn't a valid regular expression. You mean.*Notepad
, i.e., 0 or more characters followed by "Notepad". – Brigand