1=pod
2
3=head1 NAME
4
5 icesh - control window properties and the IceWM window manager
6
7=head1 SYNOPSIS
8
9=over
10
11=item B<icesh> I<OPTIONS|ACTIONS>+
12
13=back
14
15=head1 DESCRIPTION
16
17B<icesh> provides two types of commands:
18
19=over
20
21=item 1. Commands to directly interact with icewm:
22
23These are listed in the section "MANAGER ACTIONS" below.
24They are easy to use, because they don't require to select one
25or more windows. For example, C<icesh restart> will restart
26icewm and C<icesh clients> lists the applications which
27are managed by icewm.
28
29=item 2. Commands which operate on a selection of windows:
30
31See the section C<WINDOW ACTIONS> below. For example, C<icesh close>
32is a request to close a window, but which window? Now icesh
33will turn the mouse pointer into a crosshair. Click on a window
34and a close request will be sent to that application.
35
36The power of icesh lies in its ability to programmatically
37select one or more windows and operate on that selection.
38This can be used in scripts and in L<icewm-keys(5)>
39to define your own window management hotkeys.  For example, to
40immediately close all xterm windows do C<icesh -c xterm close>.
41
42There are a dozen C<SELECT OPTIONS> to select windows.  They start
43with a '-' or a '+'.  The '-' starts a new selection, while the '+'
44adds more windows to an existing selection.
45
46This selection of windows can be reduced by C<FILTER OPTIONS>.
47These remove unwanted windows from the current selection.
48Multiple filter options can be given. For example,
49C<icesh -c xterm -W this close> will close only those xterms
50which are shown on the current workspace. The xterms on other
51workspaces are filtered out by the C<-W this> filter option.
52
53=back
54
55There is no limit to the number of commands, selections, filters
56and actions which you can give to a single icesh command.
57They are processed and evaluated one by one from left to right.
58This makes icesh a small declarative programming language.
59Have a look at some examples near the end of this document.
60
61=head1 OPTIONS
62
63B<icesh> recognizes the following options:
64
65=head2 SELECT OPTIONS
66
67Select options specify the window or windows to which subsequent
68actions apply. If none is given, but an action does require a window,
69then a selection crosshair is shown to select the desired window
70interactively. The manager actions do not require window options.
71
72The following options I<select> one or more client windows.
73If needed, they can be repeated for successive actions.
74
75=over
76
77=item B<-a>, B<-all>
78
79Selects all client windows of the window manager.
80
81=item B<-f>, B<-focus>, B<+f>, B<+focus>
82
83Selects the application window which is currently focused.
84The option with minus sign replaces the existing selection with
85the focused window. With a plus sign the focused window is added to
86an existing selection.
87
88=item B<+g>, B<+group>
89
90Extend the current selection with client windows which
91belong to the same application window group.
92
93=item B<-r>, B<-root>, B<+r>, B<+root>
94
95Selects the root window.
96The option with minus sign replaces the existing selection with
97the root window. With a plus sign the root window is added to
98an existing selection.
99
100=item B<-s>, B<-shown>
101
102Selects all client windows which are on the current workspace.
103
104=item B<-t>, B<-top>
105
106Selects all toplevel windows from the display unconditionally.
107This includes windows which have never been mapped and windows
108with the override redirect bit set to evade management.
109
110=item B<-w>, B<-window>, B<+w>, B<+window> I<WINDOW_ID>
111
112Specifies the identifier of the window, I<WINDOW_ID>, for which the
113action applies.  Special identifiers are B<root> for the root window
114and B<focus> for the currently focused window.
115The option with minus sign replaces the existing selection.
116With a plus sign the window is added to an existing selection.
117
118=item B<-x>, B<-xembed>
119
120Selects all windows which are embedded using the I<XEMBED> protocol.
121
122=item B<+c>, B<+class> I<CLASS>
123
124Extend the current selection with client windows that have a
125I<WM_CLASS> property equal to I<CLASS>. This is the resource
126instance and class name.  If I<CLASS> contains a period, only
127windows with exactly the same I<WM_CLASS> property are matched.
128If there is no period, windows of the same class and windows
129of the same instance are selected.
130
131=item B<+C>, B<+Class>
132
133Extend the current selection with client windows that
134have a I<WM_CLASS> property I<similar> to the already
135selected set of windows.
136
137=item B<-D>, B<-Dockapps>
138
139Selects all Dockapp applications which are managed by icewm.
140
141=item B<+P>, B<+Pid>
142
143Extend the current selection with client windows that have
144the same process identifier as one of the selected windows.
145
146=item B<-T>
147
148Selects the IceWM taskbar.
149
150=back
151
152=head2 FILTER OPTIONS
153
154The following options I<filter> the currently selected set of windows.
155If no previous I<select> option was given then a B<-all> option is
156implicitly assumed to filter all client windows.
157
158=over
159
160=item B<-c>, B<-class> I<CLASS>
161
162Filters the set of windows on their I<WM_CLASS> property.  This is
163the resource instance and class name. If I<CLASS> contains a period,
164only windows with exactly the same I<WM_CLASS> property are matched.
165If there is no period, windows of the same class and windows of the
166same instance (aka. I<-name>) are selected.
167
168=item B<-l>, B<-last>
169
170Filter clients and keep only the most recent client.
171
172=item B<-m>, B<-machine> I<HOST>
173
174Filters clients by host name. Clients with a WM_CLIENT_MACHINE property
175equal to I<HOST> are selected.
176
177=item B<-n>, B<-name> I<NAME>
178
179Filters clients by _NET_WM_NAME or WM_NAME.
180I<NAME> matches any part of the property value.
181To match at the beginning use a C<^> prefix.
182To match at the end use a C<$> suffix.
183
184=item B<-p>, B<-pid> I<PID>
185
186Filters clients by process ID. Clients with a _NET_WM_PID property equal
187to I<PID> are selected.
188
189=item B<-u>, B<-unmapped>
190
191Filter clients and keep those which are currently not viewable.
192These are hidden, minimized, rolled-up, or on another workspace.
193
194=item B<-v>, B<-viewable>
195
196Filter clients and keep only those which are currently viewable.
197These clients are mapped on the current workspace.
198
199=item B<-G>, B<-Gravity> I<GRAVITY>
200
201Filters clients by the window gravity field of the WM_NORMAL_HINTS
202property.  Clients with a gravity equal to I<GRAVITY> are selected.
203If I<GRAVITY> starts with an exclamation mark then the filtering is
204inverted.
205
206=item B<-L>, B<-Layer> I<LAYER>
207
208Filters clients by I<GNOME window layer>, which can either be a layer
209name or a layer number. See EXPRESSIONS below. If I<LAYER> starts with
210an exclamation mark then the filtering is inverted.
211
212=item B<-N>, B<-Netstate> I<STATE>
213
214Filters clients by I<EWMH window state>. Clients which have at
215least an EWMH window state of I<STATE> are selected.  This state
216refers to details like B<MINIZED> or B<MAXIMIZED>. See EXPRESSIONS
217below. If I<STATE> starts with an exclamation mark then the filtering
218is inverted.  A question mark C<?> filters clients with any bit set
219in I<STATE>.
220
221=item B<-P>, B<-Property> I<PROP[=value]>
222
223Filters clients by property. Clients which have a property I<PROP>
224are selected. If the optional I<value> is given, the match succeeds
225only if I<PROP> is a string, window, cardinal, or atom, with a value
226equal to I<value>.  The filtering is inverted if I<PROP> starts with
227an exclamation mark.
228
229=item B<-R>, B<-Role> I<ROLE>
230
231Filters clients by WM_WINDOW_ROLE. Clients which have a WM_WINDOW_ROLE
232property value equal to I<ROLE> are selected.  The filtering is inverted
233if I<ROLE> starts with an exclamation mark.
234
235=item B<-W>, B<-Workspace> I<WORKSPACE>
236
237Filter clients by workspace. Workspace I<WORKSPACE> is either a
238workspace name, or a workspace number counting from zero, or the word
239C<this> for the current workspace, or the word C<All> for all workspaces.
240If I<WORKSPACE> starts with an exclamation mark then the filtering is
241inverted.
242
243=item B<-X>, B<-Xinerama> I<MONITOR>
244
245Limit clients by I<RandR>/I<Xinerama> monitor. Only operate on
246clients which are displayed on I<MONITOR>, where I<MONITOR> can
247be C<All> for all monitors, C<this> for the monitor where the
248active window is displayed, or a monitor number starting from zero.
249See the output of C<randr> or C<xinerama> below.
250
251=back
252
253=head2 GENERAL OPTIONS
254
255The following options are identical for every IceWM command.
256
257=over
258
259=item B<-d>, B<-display> I<DISPLAY>
260
261Specifies the X11 DISPLAY.  If unspecified, defaults to B<$DISPLAY>.
262
263=item B<-h>, B<--help>
264
265Print a brief usage statement to F<stdout> and exit.
266
267=item B<-V>, B<--version>
268
269Print the program version to F<stdout> and exit.
270
271=item B<-C>, B<--copying>
272
273Print copying permissions to F<stdout> for the program and exit.
274
275=item B<-q>, B<--quiet>
276
277Don't complain if no matching windows could be found.
278
279=back
280
281=head1 ACTIONS
282
283B<icesh> expects one or more action arguments.  There are two kinds of
284actions: I<window actions> and I<manager actions>. The first operates on
285the selected windows. The second directly interacts with the B<icewm>
286window manager.
287
288=head2 WINDOW ACTIONS
289
290The following actions affect the selected window or windows.
291
292=over
293
294=item B<activate>
295
296Activate the window, aka. I<to focus>.
297
298=item B<close>
299
300Send a close request to the client that created the window.
301
302=item B<kill>
303
304Force an immediate close down of the client that created the window.
305
306=item B<id>
307
308Print window identifiers for the selected windows.
309
310=item B<pid>
311
312Print process identifiers for the selected windows.
313
314=item B<list>
315
316Show window details, like geometry and names.
317
318=item B<lower>
319
320Lower the window.
321
322=item B<raise>
323
324Raise the window.
325
326=item B<above>
327
328Stack the window above others.
329
330=item B<below>
331
332Stack the window below others.
333
334=item B<rollup>
335
336Rollup the specified window.
337
338=item B<fullscreen>
339
340Set the window to fullscreen.
341
342=item B<maximize>
343
344Maximize the window.
345
346=item B<horizontal>
347
348Maximize the window only horizontally.
349
350=item B<vertical>
351
352Maximize the window only vertically.
353
354=item B<minimize>
355
356Minimize the window.
357
358=item B<restore>
359
360Restore the window to normal.
361
362=item B<hide>
363
364Hide the window.
365
366=item B<unhide>
367
368Reveal the window.
369
370=item B<skip>
371
372Don't show the window on the taskbar.
373
374=item B<unskip>
375
376Do show the window on the taskbar.
377
378=item B<sticky>
379
380Show the window on all workspaces.
381
382=item B<unsticky>
383
384Show the window on just one workspace.
385
386=item B<urgent>
387
388Set the urgent flag to flash the task button.
389
390=item B<resize> I<WIDTH> I<HEIGHT>
391
392Resize window to I<WIDTH> by I<HEIGHT> window units.  For text based
393applications like terminals, a window unit is the size of a single
394character cell.
395
396=item B<sizeto> I<WIDTH> I<HEIGHT>
397
398Resize window to I<WIDTH> by I<HEIGHT> pixels. If I<WIDTH> or I<HEIGHT>
399ends with a percent sign C<%>, then they refer to a percentage of the
400desktop work area. For instance, C<sizeto 50% 100%> resizes to half
401the desktop width and whatever height is available above or below the
402taskbar.
403
404=item B<sizeby> I<WIDTH> I<HEIGHT>
405
406Resize window by I<WIDTH> by I<HEIGHT> pixels. If I<WIDTH> or I<HEIGHT>
407ends with a percent sign C<%>, then they refer to a percentage of the
408current window size. For instance, C<sizeby 50% 200> increases the width
409by 50% and increases the height by 200 pixels.
410
411=item B<move> I<X> I<Y>
412
413Move the selected window or windows to the screen position I<X> I<Y>.
414To specify I<X> or I<Y> values relative to the right side or bottom side
415precede the value with an extra minus sign, like in C<move -+10 --20>.
416
417=item B<moveby> I<X> I<Y>
418
419Displace window by I<X> I<Y> pixels.
420
421=item B<center>
422
423Position the window in the center of the desktop work area.
424
425=item B<left>
426
427Position the window against the left side of the desktop work area.
428
429=item B<right>
430
431Position the window against the right side of the desktop work area.
432
433=item B<top>
434
435Position the window against the top side of the desktop work area.
436
437=item B<bottom>
438
439Position the window against the bottom side of the desktop work area.
440
441=item B<setIconTitle> I<TITLE>
442
443Set the icon title to I<TITLE>.
444
445=item B<getIconTitle>
446
447Print the icon title.
448
449=item B<setWindowTitle> I<TITLE>
450
451Set the window title to I<TITLE>.
452
453=item B<getWindowTitle>
454
455Print the window title.
456
457=item B<setGeometry> I<GEOMETRY>
458
459Set the window geometry to I<GEOMETRY>.  This geometry should be
460specified in a format that can be parsed by L<XParseGeometry(3)>.
461Negative offsets are with respect to the bottom or right side of
462the screen.  Use C<+-> for a truly negative position.
463
464=item B<getGeometry>
465
466Print the window geometry.
467
468=item B<netState> I<[STATE]>
469
470If I<STATE> is omitted then it shows the I<EWMH window state>.
471If I<STATE> starts with a C<+> then flags in I<STATE> are appended to
472the existing I<EWMH window state>.  If I<STATE> starts with a C<->
473then flags in I<STATE> are removed from the existing I<EWMH window
474state>.  If I<STATE> starts with a C<^> then flags in I<STATE> are
475toggled with respect to the existing I<EWMH window state>.
476If I<STATE> starts with a C<=> then the I<EWMH window state>
477is set to I<STATE>. See EXPRESSIONS below. A list of I<EWMH flags>
478can be found in the output of C<icesh symbols>.
479
480=item B<setLayer> I<LAYER>
481
482Move the specified window to another I<window layer>.
483See EXPRESSIONS below for a list of I<LAYER> symbols.
484
485=item B<getLayer>
486
487Print the I<window layer> for the specified window.
488
489=item B<setWorkspace> I<WORKSPACE>
490
491Move the specified window to another workspace.  Select the root
492window to change the current workspace. If I<WORKSPACE> is C<All>
493then the specified window becomes visible on all workspaces.
494Specify C<this> for the current workspace.
495
496=item B<getWorkspace>
497
498Print the workspace for the specified window.
499
500=item B<opacity> [I<OPACITY>]
501
502Print the window opacity if I<OPACITY> is not given,
503otherwise set the window opacity to I<OPACITY>.
504
505=item B<setTrayOption> I<TRAYOPTION>
506
507Set the I<IceWM tray option> for the specified window to I<TRAYOPTION>.
508See I<IceWM tray options>, below, for I<TRAYOPTION> symbols.
509
510=item B<getTrayOption>
511
512Print the I<IceWM tray option> for the specified window.
513
514=item B<setNormalGravity> I<GRAVITY>
515
516Set the window gravity field in the WM_NORMAL_HINTS property for the
517specified window to I<GRAVITY>.  See below for I<GRAVITY> symbols.
518
519=item B<getNormalGravity>
520
521Print the window gravity from the WM_NORMAL_HINTS property for the
522specified window.
523
524=item B<setWindowGravity> I<GRAVITY>
525
526Set the window gravity for the specified window to I<GRAVITY>.
527See below for I<GRAVITY> symbols.
528
529=item B<getWindowGravity>
530
531Print the window gravity for the specified window.
532
533=item B<setBitGravity> I<GRAVITY>
534
535Set the bit gravity> for the specified window to I<GRAVITY>.
536See below for I<GRAVITY> symbols.
537
538=item B<getBitGravity>
539
540Print the bit gravity for the specified window.
541
542=item B<motif> [B<funcs> I<FUNCTIONS> | B<decor> I<DECORATIONS> | B<remove>]
543
544Query, set or modify the C<_MOTIF_WM_HINTS> property for the specified
545window.  Without arguments B<motif> will show the current value, but
546only if the window has such a property. The property can be removed or
547reset with the B<remove> argument. With B<funcs> and B<decor> individual
548fields of this property can be enabled or disabled. If I<FUNCTIONS> or
549I<DECORATIONS> starts with a minus or plus sign then the existing value
550is modified, otherwise it is set to the new value. Note that if C<All>
551is set, other set fields are disabled and cleared fields are enabled.
552
553=item B<borderless>
554
555Hide the frame borders and title.
556
557=item B<bordered>
558
559Show the frame borders and title.
560
561=item B<denormal>
562
563Remove the WM_NORMAL_HINTS property, if it exists.  This lifts
564font-size restrictions on resizing, especially for terminals.
565
566=item B<prop> I<PROPERTY>
567
568Print the value of property I<PROPERTY>, if it is present.
569
570=item B<properties>
571
572Print all properties and their values.
573
574=item B<frame>
575
576Print the identifier of the window frame.
577
578=item B<click> I<window-x> I<window-y> I<button>
579
580Send a button press and release event at position (I<window-x>,
581I<window-y>). A negative position is relative to the bottom right
582corner. The mouse pointer is warped to the position before sending
583the events. The button number should be between 1 and 5 inclusive.
584
585=item B<monitors> I<top> I<bottom> I<left> I<right>
586
587This sets the monitors to use for fullscreen.
588Top, bottom, left, and right are indices of the I<icesh xinerama> command.
589
590=item B<spy>
591
592Observe the selected windows and report any changes. This includes
593focus, visibility, position, size and all window properties.
594To monitor all of the protocol request messages that client applications
595may send to icewm, also spy on the root window.
596
597=back
598
599=head2 MANAGER ACTIONS
600
601The following actions control the IceWM window manager and therefore
602do not require a window I<select> or I<filter> option:
603
604=over
605
606=item B<listWorkspaces>
607
608List the names of all workspaces.
609
610=item B<current>
611
612Show the number and name of the current workspace.
613
614=item B<goto> I<WORKSPACE>
615
616Change the current workspace to I<WORKSPACE>.
617
618=item B<workspaces> [I<COUNT>]
619
620Print the number of workspaces if I<COUNT> is not given,
621otherwise set the number of workspaces to I<COUNT>.
622
623=item B<setWorkspaceName> I<INDEX> I<NAME>
624
625Change the name of the workspace I<INDEX> to I<NAME>, where I<INDEX> is
626a workspace number starting from zero.
627
628=item B<setWorkspaceNames> I<NAME> [I<NAME>]*
629
630Change the workspace names to the list of I<NAME>s.
631
632=item B<addWorkspace> I<NAME>
633
634Create a new workspace with name I<NAME>.
635
636=item B<desktop> [I<SHOWING>]
637
638If I<SHOWING> is C<1> then set C<showing the desktop> mode.
639If I<SHOWING> is C<0> then turn off C<showing the desktop>.
640Print the current mode if I<SHOWING> is not given.
641
642=item B<randr>
643
644Summarize the I<RandR> configuration.
645
646=item B<xinerama>
647
648Summarize the I<Xinerama> configuration.
649
650=item B<check>
651
652Print information about the current window manager, like name,
653version, class, locale, command, host name and pid.
654
655=item B<clients>
656
657List all managed client windows, their titles and geometries.
658
659=item B<shown>
660
661List all mapped client windows for the current desktop,
662their titles and geometries.
663
664=item B<windows>
665
666List all toplevel windows, their titles and geometries.
667
668=item B<systray>
669
670List applications which are managed by the IceWM system tray.
671
672=item B<xembed>
673
674List application windows which are embedded using the I<XEMBED> protocol.
675This is another way to discover system tray applications.
676
677=item B<logout>
678
679Let icewm execute the C<LogoutCommand>.
680
681=item B<reboot>
682
683Let icewm execute the C<RebootCommand>.
684
685=item B<shutdown>
686
687Let icewm execute the C<ShutdownCommand>.
688
689=item B<cancel>
690
691Let icewm cancel the logout/reboot/shutdown.
692
693=item B<about>
694
695Let icewm show the about window.
696
697=item B<windowlist>
698
699Let icewm show the window list window.
700
701=item B<restart>
702
703Let icewm restart itself.
704
705=item B<suspend>
706
707Let icewm execute the C<SuspendCommand>.
708
709=item B<winoptions>
710
711Let icewm reload the C<winoptions>.
712
713=item B<keys>
714
715Let icewm reload the C<keys> file.
716
717=item B<guievents>
718
719Monitor the B<ICEWM_GUI_EVENT> property and report all changes.
720
721=item B<delay> [I<time>]
722
723Stop execution for I<time> or 0.1 seconds.
724
725=item B<runonce> I<program> [I<arguments...>]
726
727This action is meant to be used together with the B<-class> option.
728Only if no window is matched by I<WM_CLASS> then
729I<program> [I<arguments...>] is executed.
730
731=item B<sync>
732
733Synchronize with the IceWM window manager. That is, wait for icewm to
734process all previous actions.
735
736=item B<symbols>
737
738List all named symbols.
739
740=back
741
742=head2 CONDITIONALS
743
744Icesh supports C<if-then-else> expressions. The full syntax is:
745
746    if selection
747    then
748        actions
749    elif selection
750    then
751        actions
752    else
753        actions
754    end
755
756Where C<selection> is a sequence of selection and filtering options,
757which evaluates to B<true> when it is non-empty. That is, if one or more
758windows fulfilled the condition. If it is empty, then its C<actions>
759clause is ignored and the subsequent C<elif> or C<else> clause is tried
760or taken. Each clause is optional.
761
762Whenever a selection condition evaluates to B<false>, the window selection
763that existed before the C<if> clause is immediately restored.  This also
764happens after an C<end> clause.
765
766=head2 EXPRESSIONS
767
768Some of the window actions require one or two I<EXPRESSION> arguments.
769
770=over
771
772=item B<EXPRESSION> ::= I<SYMBOL> | I<EXPRESSION> { C<+> | C<|> }
773I<SYMBOL>
774
775=back
776
777Each I<SYMBOL> may be from one of the following applicable domains:
778
779=over
780
781=item I<Window layer>
782
783Named symbols of the domain I<Window layer> (numeric range: 0-15):
784
785    Desktop                (0)
786    Below                  (2)
787    Normal                 (4)
788    OnTop                  (6)
789    Dock                   (8)
790    AboveDock             (10)
791    Menu                  (12)
792
793These symbols are used with the I<LAYER> argument to the C<setLayer>
794action.
795
796=item I<IceWM tray option>
797
798Named symbols of the domain I<IceWM tray option> (numeric range: 0-2):
799
800    Ignore                 (0)
801    Minimized              (1)
802    Exclusive              (2)
803
804These symbols are used with the I<TRAYOPTION> argument to the
805C<setTrayOption> action.
806
807=item I<Gravity symbols>
808
809Named symbols for window and bit gravity (numeric range: 0-10):
810
811    ForgetGravity         (0)
812    NorthWestGravity      (1)
813    NorthGravity          (2)
814    NorthEastGravity      (3)
815    WestGravity           (4)
816    CenterGravity         (5)
817    EastGravity           (6)
818    SouthWestGravity      (7)
819    SouthGravity          (8)
820    SouthEastGravity      (9)
821    StaticGravity         (10)
822
823=item I<Motif functions>
824
825    All                  (1)
826    Resize               (2)
827    Move                 (4)
828    Minimize             (8)
829    Maximize             (16)
830    Close                (32)
831
832=item I<Motif decorations>
833
834    All                  (1)
835    Border               (2)
836    Resize               (4)
837    Title                (8)
838    Menu                 (16)
839    Minimize             (32)
840    Maximize             (64)
841
842=item I<EWMH window state symbols>
843
844Named symbols of the domain I<EWMH state> (numeric range:
8450-8191):
846
847    ABOVE                 (1)
848    BELOW                 (2)
849    DEMANDS_ATTENTION     (4)
850    FOCUSED               (8)
851    FULLSCREEN            (16)
852    HIDDEN                (32)
853    MAXIMIZED_HORZ        (64)
854    MAXIMIZED_VERT        (128)
855    MODAL                 (256)
856    SHADED                (512)
857    SKIP_PAGER            (1024)
858    SKIP_TASKBAR          (2048)
859    STICKY                (4096)
860
861=back
862
863=head1 EXAMPLES
864
865List all workspace names:
866
867    icesh listWorkspaces
868
869Example output:
870
871    workspace #0: `main'
872    workspace #1: `web'
873    workspace #2: `doc'
874    workspace #3: `dev'
875
876Close terminal work and activate terminal fun.
877
878    icesh -c work.XTerm close -a -c fun.XTerm activate
879
880Print opacity for all xterms.
881
882    icesh -c XTerm opacity
883
884Change opacity for all xterms.
885
886    icesh -c XTerm opacity 84
887
888Move all windows on workspace "Top" to the current workspace.
889
890    icesh -W "Top" setWorkspace "this"
891
892Restore all hidden clients, minimize all clients on the current
893workspace and activate Firefox.
894
895    icesh -N HIDDEN restore -a -W "this" minimize -a -c Firefox activate
896
897Resize the focused window to occupy the right half of the desktop area.
898
899    icesh -f sizeto 49% 100% sync top sync right sync raise activate
900
901Toggle the frame border of the focused window.
902
903    if icesh -f motif | grep -q 'decor:$'; then \
904        icesh -f motif decor All; else icesh -f motif decor ""; fi
905
906Here is a different solution using conditionals.
907
908    icesh -f if -P _NET_FRAME_EXTENTS=0 then bordered else borderless
909
910Here is a conditional to either toggle the visibility of a roxterm,
911which has a WM_ROLE value of C<special>, or start it with B<runonce>.
912
913    icesh sync if -c roxterm.Roxterm -R special then \
914        if -v then hide \
915        elif -u then setWorkspace this sync activate end \
916        else runonce roxterm --role=special
917
918=head1 ENVIRONMENT
919
920=over
921
922=item B<DISPLAY>
923
924The default display.
925
926=back
927
928=head1 EXIT STATUS
929
930=over
931
932=item B<0>
933
934The last action completed successfully.
935
936=item B<1>
937
938The last action completed unsuccessfully, or no window met the condition.
939
940=item B<2>
941
942A conditional has invalid syntax.
943
944=item B<3>
945
946The display could not be opened.
947
948=item B<4>
949
950The X server reports an error while processing a request.
951
952=back
953
954=head1 COMPLIANCE
955
956B<icesh> is largely compliant with the EWMH and ICCCM specifications.
957Some commands, like manager actions, are specific to IceWM.
958
959=head1 SEE ALSO
960
961L<icewm(1)>, L<wmctrl(1)>, L<xdotool(1)>, L<xprop(1)>,
962L<xwininfo(1)>, L<XParseGeometry(3)>.
963
964=head1 BUGS
965
966Please report bugs at L<https://github.com/bbidulock/icewm/issues>.
967
968=head1 AUTHOR
969
970Brian Bidulock L<mailto:bidulock@openss7.org>.
971
972See B<--copying> for full copyright notice and copying permissions.
973
974=head1 LICENSE
975
976B<IceWM> is licensed under the GNU Library General Public License.
977See the F<COPYING> file in the distribution or use the B<--copying> flag
978to display copying permissions.
979
980=cut
981
982# vim: set sw=4 tw=72 nocin spell spelllang=en_ca:
983