You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+17-3Lines changed: 17 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
# wmw-desktop
2
2
What's My Window (WMW) is a simple C++ utility for detecting active application from the OS, designed to display activity in code editors in the Internet.
3
3
4
-
WMW uses Windows API to get the foreground window and output its name and elapsed time using the following scheme:
4
+
WMW uses Windows API to get the foreground window and output its name and elapsed time using (by default) the following scheme:
5
5
```
6
6
MyAppName hh:mm:ss
7
7
```
@@ -20,18 +20,32 @@ WMW can be widely personalised to the user's needs by changing the values in `se
20
20
21
21
`unsigned int interval` - the interval between two window requests in miliseconds (default: `1000`)
22
22
23
+
`string format` - the format of the WMW output.
24
+
Available placeholders:
25
+
-`%name` - current application name
26
+
-`%time` - current application time
27
+
-`%pname` - current process name
28
+
-`%pid` - current process ID
29
+
-`%file` - current file name
30
+
-`%project` - current project name
31
+
32
+
Default: `%name %time`
33
+
23
34
`string windowStartup` - the text to display on application startup (used for future translation purposes)
24
35
25
36
`codeEditors` - a list of key/value pairs of the applications' process names and the corresponding window titles\
26
37
(Tip: process names can be obtained via the details tab of the Task Manager)
27
38
39
+
`titleFormats` - a list of key/value pairs of the process names and the corresponding user-defined window title formats, used to detect file and project names.\
40
+
(Tip: as formats may contain Unicode characters, detecting them by hand may be difficult. If you're experiencing problems with the title detection, use the debug funtion at lines 112-114 to read the title as integer values letter by letter)
41
+
28
42
**Remember**: the settings are stored in the WMW binary and you have to rebuild it to apply the changes!
29
43
30
44
# To Do
31
45
32
-
- Add file name/project name detection for the code editors - the window title usually contains them
46
+
-~~Add file name/project name detection for the code editors - the window title usually contains them~~
33
47
- Improve the example project by making it refresh automatically every second
34
-
- Add the ability to personalise the output structure in the config, e.g. adding the process name or the PID
48
+
-~~Add the ability to personalise the output structure in the config, e.g. adding the process name or the PID~~
35
49
36
50
Feel free to open a pull request if you develop a solution of one of these (new ideas are also welcome)!
0 commit comments