1ICESH(1) User Commands ICESH(1)
2
3
4
6 icesh - control window properties and the IceWM window manager
7
9 icesh OPTIONS|ACTIONS+
10
12 icesh provides 90 commands to change or query a window's state, and to
13 interact with the icewm(1) window manager. Command arguments are called
14 actions. Window actions operate on a selection of windows. icesh has
15 several options to select and filter windows. Options and actions can
16 be interspersed. They are processed and evaluated one after another
17 from left to right. Therefore, an option can only affect a subsequent
18 action, but not a previous one. Because of this, an action can operate
19 on a different selection of windows than a previous action, if it is
20 preceded by a new select option. In combination with filter options,
21 this gives icesh its expressive power. Use it in icewm-keys(5) to
22 define your own window management hotkeys.
23
25 icesh recognizes the following options:
26
27 SELECT OPTIONS
28 Select options specify the window or windows to which subsequent
29 actions apply. If none is given, but an action does require a window,
30 then a selection crossbar is invoked to select the desired window
31 interactively. The manager actions do not require window options.
32
33 The following five options select one or more client windows. If
34 needed, they can be repeated for successive actions.
35
36 -w, -window, +w, +window WINDOW_ID
37 Specifies the identifier of the window, WINDOW_ID, for which the
38 action applies. Special identifiers are root for the root window
39 and focus for the currently focused window. The option with minus
40 sign replaces the existing selection. With a plus sign the window
41 is added to an existing selection.
42
43 -r, -root, +r, +root
44 Is equivalent to -window root and selects the root window. The
45 option with minus sign replaces the existing selection with the
46 root window. With a plus sign the root window is added to an
47 existing selection.
48
49 -f, -focus, +f, +focus
50 Is equivalent to -window focus and selects the focused window. The
51 option with minus sign replaces the existing selection with the
52 focused window. With a plus sign the focused window is added to an
53 existing selection.
54
55 -a, -all
56 Selects all clients of the window manager.
57
58 -s, -shown
59 Selects all currently visible clients of the window manager.
60
61 -t, -top
62 Selects all toplevel windows from the display unconditionally.
63
64 FILTER OPTIONS
65 The following options filter the currently selected set of windows. If
66 no previous select option was given then a -all option is implicitly
67 assumed to filter all client windows.
68
69 -c, -class WM_CLASS
70 Filters the set of windows on window manager class, WM_CLASS. If
71 WM_CLASS contains a period, only windows with exactly the same
72 WM_CLASS property are matched. If there is no period, windows of
73 the same class and windows of the same instance (aka. -name) are
74 selected.
75
76 -l, -last
77 Filter clients and keep only the most recent client.
78
79 -m, -machine HOST
80 Filters clients by host name. Clients with a WM_CLIENT_MACHINE
81 property equal to HOST are selected.
82
83 -n, -name NAME
84 Filters clients by _NET_WM_NAME or WM_NAME. NAME matches any part
85 of the property value. To match at the beginning use a "^" prefix.
86 To match at the end use a "$" suffix.
87
88 -p, -pid PID
89 Filters clients by process ID. Clients with a _NET_WM_PID property
90 equal to PID are selected.
91
92 -G, -Gravity GRAVITY
93 Filters clients by the window gravity field of the WM_NORMAL_HINTS
94 property. Clients with a gravity equal to GRAVITY are selected.
95 If GRAVITY starts with an exclamation mark then the filtering is
96 inverted.
97
98 -L, -Layer LAYER
99 Filters clients by GNOME window layer, which can either be a layer
100 name or a layer number. See EXPRESSIONS below. If LAYER starts with
101 an exclamation mark then the filtering is inverted.
102
103 -N, -Netstate STATE
104 Filters clients by EWMH window state. Clients which have at least
105 an EWMH window state of STATE are selected. This state refers to
106 details like minized or maximized. See EXPRESSIONS below. If STATE
107 starts with an exclamation mark then the filtering is inverted. A
108 question mark "?" filters clients with any bit set in STATE.
109
110 -P, -Property PROP[=value]
111 Filters clients by property. Clients which have a property PROP are
112 selected. If the optional value is given, the match succeeds only
113 if PROP is a string, window, cardinal, or atom, with a value equal
114 to value. The filtering is inverted if PROP starts with an
115 exclamation mark.
116
117 -R, -Role ROLE
118 Filters clients by WM_WINDOW_ROLE. Clients which have a
119 WM_WINDOW_ROLE property value equal to ROLE are selected. The
120 filtering is inverted if ROLE starts with an exclamation mark.
121
122 -S, -State STATE
123 Filters clients by GNOME window state. Clients which have at least
124 a state of STATE are selected. The window state refers to details
125 like minized or maximized. See EXPRESSIONS below. If STATE starts
126 with an exclamation mark then the filtering is inverted. A
127 question mark "?" filters clients with any bit set in STATE.
128
129 -W, -Workspace WORKSPACE
130 Filter clients by workspace. Workspace WORKSPACE is either a
131 workspace name or a workspace number counting from zero. If
132 WORKSPACE starts with an exclamation mark then the filtering is
133 inverted.
134
135 -X, -Xinerama MONITOR
136 Limit clients by RandR/Xinerama monitor. Only operate on clients
137 which are displayed on MONITOR, where MONITOR can be "All" for all
138 monitors, "this" for the monitor where the active window is
139 displayed, or a monitor number starting from zero. See the output
140 of "randr" or "xinerama" below.
141
142 GENERAL OPTIONS
143 The following options are identical for every IceWM command.
144
145 -d, -display DISPLAY
146 Specifies the X11 DISPLAY. If unspecified, defaults to $DISPLAY.
147
148 -h, --help
149 Print a brief usage statement to stdout and exit.
150
151 -V, --version
152 Print the program version to stdout and exit.
153
154 -C, --copying
155 Print copying permissions to stdout for the program and exit.
156
158 icesh expects one or more action arguments. There are two kinds of
159 actions: window actions and manager actions. The first operates on the
160 selected windows. The second directly interacts with the icewm window
161 manager.
162
163 WINDOW ACTIONS
164 The following actions affect the selected window or windows.
165
166 activate
167 Activate the window, aka. to focus.
168
169 close
170 Close the window.
171
172 kill
173 Terminate the window.
174
175 id Print window identifiers for the selected windows.
176
177 pid Print process identifiers for the selected windows.
178
179 list
180 Show window details, like geometry and names.
181
182 lower
183 Lower the window.
184
185 raise
186 Raise the window.
187
188 above
189 Stack the window above others.
190
191 below
192 Stack the window below others.
193
194 rollup
195 Rollup the specified window.
196
197 fullscreen
198 Set the window to fullscreen.
199
200 maximize
201 Maximize the window.
202
203 horizontal
204 Maximize the window only horizontally.
205
206 vertical
207 Maximize the window only vertically.
208
209 minimize
210 Minimize the window.
211
212 restore
213 Restore the window to normal.
214
215 hide
216 Make window hidden.
217
218 unhide
219 Undo window hidden.
220
221 skip
222 Don't show window on taskbar.
223
224 unskip
225 Do show window on taskbar.
226
227 resize WIDTH HEIGHT
228 Resize window to WIDTH by HEIGHT window units.
229
230 sizeto WIDTH HEIGHT
231 Resize window to WIDTH by HEIGHT pixels. If WIDTH or HEIGHT ends
232 with a percent sign "%", then they refer to a percentage of the
233 desktop work area. For instance, "sizeto 50% 100%" resizes to half
234 the desktop width and whatever height is available above or below
235 the taskbar.
236
237 sizeby WIDTH HEIGHT
238 Resize window by WIDTH by HEIGHT pixels. If WIDTH or HEIGHT ends
239 with a percent sign "%", then they refer to a percentage of the
240 current window size. For instance, "sizeto 50% 200" increases the
241 width by 50% and increases the height by 200 pixels.
242
243 move X Y
244 Move the selected window or windows to the screen position X Y. To
245 specify X or Y values relative to the right side or bottom side
246 precede the value with an extra minus sign, like in "move -+10
247 --20".
248
249 moveby X Y
250 Displace window by X Y pixels.
251
252 center
253 Position window in the center of the desktop work area.
254
255 left
256 Position window against the left side of the desktop work area.
257
258 right
259 Position window against the right side of the desktop work area.
260
261 top Position window against the top side of the desktop work area.
262
263 bottom
264 Position window against the bottom side of the desktop work area.
265
266 setIconTitle TITLE
267 Set the icon title to TITLE.
268
269 getIconTitle
270 Print the icon title.
271
272 setWindowTitle TITLE
273 Set the window title to TITLE.
274
275 getWindowTitle
276 Print the window title.
277
278 setGeometry GEOMETRY
279 Set the window geometry to GEOMETRY.
280
281 getGeometry
282 Print the window geometry.
283
284 netState [STATE]
285 If STATE is omitted then it shows the EWMH window state. If STATE
286 starts with a "+" then flags in STATE are appended to the existing
287 EWMH window state. If STATE starts with a "-" then flags in STATE
288 are removed from the existing EWMH window state. If STATE starts
289 with a "=" then the EWMH window state is set to STATE. See
290 EXPRESSIONS below. A list of EWMH flags can be found in the output
291 of "icesh symbols".
292
293 setState MASK STATE
294 Set the GNOME window state to STATE. Only bits selected by MASK
295 are affected. See below for STATE and MASK symbols.
296
297 toggleState STATE
298 Toggle the GNOME window state bits specified by the STATE
299 expression. See below for STATE symbols.
300
301 getState
302 Print the GNOME window state for the specified window.
303
304 setHints HINTS
305 Set the GNOME window hints to HINTS. See below for symbols.
306
307 getHints
308 Print the GNOME window hints for the specified window.
309
310 setLayer LAYER
311 Move the specified window to another GNOME window layer. See below
312 for LAYER symbols.
313
314 getLayer
315 Print the GNOME window layer for the specified window.
316
317 setWorkspace WORKSPACE
318 Move the specified window to another workspace. Select the root
319 window to change the current workspace. If WORKSPACE is "All" then
320 the specified window becomes visible on all workspaces. Specify
321 "this" for the current workspace.
322
323 getWorkspace
324 Print the workspace for the specified window.
325
326 opacity [OPACITY]
327 Print the window opacity if OPACITY is not given, otherwise set the
328 window opacity to OPACITY.
329
330 setTrayOption TRAYOPTION
331 Set the IceWM tray option for the specified window to TRAYOPTION.
332 See IceWM tray options, below, for TRAYOPTION symbols.
333
334 getTrayOption
335 Print the IceWM tray option for the specified window.
336
337 setNormalGravity GRAVITY
338 Set the window gravity field in the WM_NORMAL_HINTS property for
339 the specified window to GRAVITY. See below for GRAVITY symbols.
340
341 getNormalGravity
342 Print the window gravity from the WM_NORMAL_HINTS property for the
343 specified window.
344
345 setWindowGravity GRAVITY
346 Set the window gravity for the specified window to GRAVITY. See
347 below for GRAVITY symbols.
348
349 getWindowGravity
350 Print the window gravity for the specified window.
351
352 setBitGravity GRAVITY
353 Set the bit gravity> for the specified window to GRAVITY. See
354 below for GRAVITY symbols.
355
356 getBitGravity
357 Print the bit gravity for the specified window.
358
359 motif [funcs FUNCTIONS | decor DECORATIONS | remove]
360 Query, set or modify the "_MOTIF_WM_HINTS" property for the
361 specified window. Without arguments motif will show the current
362 value, but only if the window has such a property. The property can
363 be removed or reset with the remove argument. With funcs and decor
364 individual fields of this property can be enabled or disabled. If
365 FUNCTIONS or DECORATIONS starts with a minus or plus sign then the
366 existing value is modified, otherwise it is set to the new value.
367 Note that if "All" is set, then other set fields will be disabled
368 and cleared fields will be enabled.
369
370 prop PROPERTY
371 Print the value of property PROPERTY if it is present.
372
373 click window-x window-y button
374 Send a button press and release event at position (window-x,
375 window-y). A negative position is relative to the bottom right
376 corner. The mouse pointer is warped to the position before sending
377 the events. The button number should be between 1 and 5 inclusive.
378
379 spy Observe the selected windows and report any changes. This includes
380 focus, visibility, position, size and all window properties.
381
382 MANAGER ACTIONS
383 The following actions control the IceWM window manager and therefore do
384 not require a window select or filter option:
385
386 listWorkspaces
387 List the names of all workspaces.
388
389 goto WORKSPACE
390 Change the current workspace to WORKSPACE.
391
392 workspaces [COUNT]
393 Print the number of workspaces if COUNT is not given, otherwise set
394 the number of workspaces to COUNT.
395
396 setWorkspaceName INDEX NAME
397 Change the name of the workspace INDEX to NAME, where INDEX is a
398 workspace number starting from zero.
399
400 setWorkspaceNames NAME [NAME]*
401 Change the workspace names to the list of NAMEs.
402
403 addWorkspace NAME
404 Create a new workspace with name NAME.
405
406 desktop [SHOWING]
407 If SHOWING is 1 then set "showing the desktop" mode. If SHOWING is
408 0 then turn off "showing the desktop". Print the current mode if
409 SHOWING is not given.
410
411 randr
412 Summarize the RandR configuration.
413
414 xinerama
415 Summarize the Xinerama configuration.
416
417 check
418 Print information about the current window manager, like name,
419 version, class, locale, command, host name and pid.
420
421 clients
422 List all managed client windows, their titles and geometries.
423
424 shown
425 List all mapped client windows for the current desktop, their
426 titles and geometries.
427
428 windows
429 List all toplevel windows, their titles and geometries.
430
431 systray
432 List applications which are managed by the IceWM system tray.
433
434 xembed
435 List application windows which are embedded using the XEMBED
436 protocol. This is another way to discover system tray
437 applications.
438
439 logout
440 Let icewm execute the "LogoutCommand".
441
442 reboot
443 Let icewm execute the "RebootCommand".
444
445 shutdown
446 Let icewm execute the "ShutdownCommand".
447
448 cancel
449 Let icewm cancel the logout/reboot/shutdown.
450
451 about
452 Let icewm show the about window.
453
454 windowlist
455 Let icewm show the window list window.
456
457 restart
458 Let icewm restart itself.
459
460 suspend
461 Let icewm execute the "SuspendCommand".
462
463 winoptions
464 Let icewm reload the "winoptions".
465
466 keys
467 Let icewm reload the "keys" file.
468
469 guievents
470 Monitor the ICEWM_GUI_EVENT property and report all changes.
471
472 delay [time]
473 Stop execution for time or 0.1 seconds.
474
475 runonce program [arguments...]
476 This action is meant to be used together with the -class option.
477 Only if no window is matched by WM_CLASS then program
478 [arguments...] is executed.
479
480 sync
481 Synchronize with the IceWM window manager. That is, wait for icewm
482 to process all previous actions.
483
484 symbols
485 List all named symbols.
486
487 EXPRESSIONS
488 Some of the window actions require one or two EXPRESSION arguments.
489
490 EXPRESSION ::= SYMBOL | EXPRESSION { "+" | "|" } SYMBOL
491
492 Each SYMBOL may be from one of the following applicable domains:
493
494 GNOME window state
495 Named symbols of the domain GNOME window state (numeric range:
496 0-1023):
497
498 AllWorkspaces (1)
499 Sticky (1)
500 Minimized (2)
501 Maximized (12)
502 MaximizedVert (4)
503 MaximizedVertical (4)
504 MaximizedHoriz (8)
505 MaximizedHorizontal (8)
506 Hidden (16)
507 Rollup (32)
508 All (1023)
509
510 These symbols are used with the MASK and STATE arguments to the
511 "setState" and "toggleState" actions. Some additional states
512 include: Above, Below, Urgent and Fullscreen.
513
514 GNOME window hint
515 Named symbols of the domain GNOME window hint (numeric range:
516 0-63):
517
518 SkipFocus (1)
519 SkipWindowMenu (2)
520 SkipTaskBar (4)
521 FocusOnClick (16)
522 DoNotCover (32)
523 All (63)
524
525 These symbols are used with the HINTS argument to the "setHints"
526 action.
527
528 GNOME window layer
529 Named symbols of the domain GNOME window layer (numeric range:
530 0-15):
531
532 Desktop (0)
533 Below (2)
534 Normal (4)
535 OnTop (6)
536 Dock (8)
537 AboveDock (10)
538 Menu (12)
539
540 These symbols are used with the LAYER argument to the "setLayer"
541 action.
542
543 IceWM tray option
544 Named symbols of the domain IceWM tray option (numeric range: 0-2):
545
546 Ignore (0)
547 Minimized (1)
548 Exclusive (2)
549
550 These symbols are used with the TRAYOPTION argument to the
551 "setTrayOption" action.
552
553 Gravity symbols
554 Named symbols for window and bit gravity (numeric range: 0-10):
555
556 ForgetGravity (0)
557 NorthWestGravity (1)
558 NorthGravity (2)
559 NorthEastGravity (3)
560 WestGravity (4)
561 CenterGravity (5)
562 EastGravity (6)
563 SouthWestGravity (7)
564 SouthGravity (8)
565 SouthEastGravity (9)
566 StaticGravity (10)
567
568 Motif functions
569 All (1)
570 Resize (2)
571 Move (4)
572 Minimize (8)
573 Maximize (16)
574 Close (32)
575
576 Motif decorations
577 All (1)
578 Border (2)
579 Resize (4)
580 Title (8)
581 Menu (16)
582 Minimize (32)
583 Maximize (64)
584
585 EWMH window state symbols
586 Named symbols of the domain EWMH state (numeric range: 0-8191):
587
588 ABOVE (1)
589 BELOW (2)
590 DEMANDS_ATTENTION (4)
591 FOCUSED (8)
592 FULLSCREEN (16)
593 HIDDEN (32)
594 MAXIMIZED_HORZ (64)
595 MAXIMIZED_VERT (128)
596 MODAL (256)
597 SHADED (512)
598 SKIP_PAGER (1024)
599 SKIP_TASKBAR (2048)
600 STICKY (4096)
601
603 List all workspace names:
604
605 icesh listWorkspaces
606
607 Example output:
608
609 workspace #0: `main'
610 workspace #1: `web'
611 workspace #2: `doc'
612 workspace #3: `dev'
613
614 Close terminal work and activate terminal fun.
615
616 icesh -c work.XTerm close -a -c fun.XTerm activate
617
618 Print opacity for all xterms.
619
620 icesh -c XTerm opacity
621
622 Change opacity for all xterms.
623
624 icesh -c XTerm opacity 84
625
626 Move all windows on workspace "Top" to the current workspace.
627
628 icesh -W "Top" setWorkspace "this"
629
630 Restore all hidden clients, minimize all clients on the current
631 workspace and activate Firefox.
632
633 icesh -S hidden restore -a -W "this" minimize -a -c Firefox activate
634
635 Resize the focused window to occupy the right half of the desktop area.
636
637 icesh -f sizeto 49% 100% sync top sync right sync raise activate
638
640 The following environment variables are examined by icesh:
641
642 DISPLAY
643 The display to use if the -display option is unspecified.
644
646 While icesh is largely compliant with the GNOME WinWM/WMH
647 specification, it only minimally supports NetWM/EWMH. Some commands,
648 like tray options and manager actions, are specific to IceWM.
649
651 icewm(1), wmctrl(1), xdotool(1), xprop(1), xwininfo(1).
652
654 icesh had no known bugs at the time of release. Please report bugs for
655 current versions to the source code repository at
656 <https://github.com/bbidulock/icewm/issues>.
657
659 Brian Bidulock <mailto:bidulock@openss7.org>.
660
661 See --copying for full copyright notice and copying permissions.
662
664 IceWM is licensed under the GNU Library General Public License. See
665 the COPYING file in the distribution or use the --copying flag to
666 display copying permissions.
667
668
669
670icewm 1.6.5 2020-03-17 ICESH(1)