Matches partial titles from the start. (只匹配标题的前面部分)
In this mode the a window titled Untitled - Notepad would be matched by "Untitled - Notepad", "Untitled", "Un", etc.
Matches any substring in the title. ( 标题的任意子串皆可)
In this mode a window titled Untitled - Notepad would be matched by "Untitled - Notepad", "Untitled", "Notepad", "pad", etc.
Exact title match.
In this mode a window titled Untitled - Notepad would on
In this mode special sequences(特殊的字符串) are used in the title parameter so that window classnames(类别名) and handles(句柄) can be used. The text parameter remains the same.
The special sequences must contain no whitespace (这些特殊的字符串不能含有空白符(whitespace，一般指空格、制表符、回车等))
"classname=" matches a window based on its classname.
$size = wingetpos("classname=notepad")
matches the currently active window (same as "" in the default WinTitleMatchMode).
uses the last successful window match so you don't have to keep specifying the title and text again and again. e.g.
WinWaitActive("Untitled - Notepad")
WinClose("last") ; Closes the previously matched notepad window
Note: If "classname=", "active", "last" or "" are not used as the title then the window matching takes place as in Mode 1 making this a good mode for general use.
A window handle is a special value that windows assigns to a window each time it is created.
The advantage of using window handles is that if you have multiple copies of an application open - which have the same title/text - you can uniquely identify them when using handles. When you use a window handle for the title parameter then the text parameter is completely ignored.
It is imp
Note: Window handles will work no matter what WinTitleMatchMode is currently in use.
$handle = WinGetHandle("Untitled - Notepad", "")