Commit graph

51 commits

Author SHA1 Message Date
Bastien Dejean
4907ddc382 Handle NULL node ref. in node_matches 2014-07-18 18:59:16 +02:00
Bastien Dejean
da38f30c32 Don't return NULL nodes in node_from_desc 2014-03-13 21:57:59 +01:00
Bastien Dejean
da84c486ab Replace deprecated index function
http://pubs.opengroup.org/onlinepubs/009695399/functions/index.html
2014-03-13 21:30:34 +01:00
Bastien Dejean
f98162fc38 Extend directional focusing to nearby monitors
Fixes #121
2014-02-26 20:59:08 +01:00
Bastien Dejean
42a0fdd253 Refactor error reporting
Fixes #123
2014-02-17 11:55:34 +01:00
Bastien Dejean
2c50a15455 Add desktop selector: MONITOR_SEL:^<n> 2014-02-09 10:23:01 +01:00
Bastien Dejean
eabbdd1b4f Reintroduce the *automatic* window modifier 2014-02-03 10:30:41 +01:00
Bastien Dejean
7542b5e6ff Handle NULL nodes in node_matches 2014-02-02 14:36:23 +01:00
Bastien Dejean
7cbcc64e7d Fix *restore* regression introduced by c231e8c
The lines of the output of `query -T` are now indented using tabs.

Hence, `restore_tree`'s *level* variable is now equal to the number of tabs.
2014-01-19 14:58:32 +01:00
Bastien Dejean
b9dcab1900 Remove trailing spaces in headers 2014-01-19 14:41:37 +01:00
Bastien Dejean
c231e8cf41 Indentation: convert spaces to tabs
http://lea.verou.me/2012/01/why-tabs-are-clearly-superior/
2014-01-18 16:30:00 +01:00
Bastien Dejean
edcb1f9aec Show window instance names in the output of query -T 2014-01-04 11:07:20 +01:00
Bastien Dejean
41c91cefa0 Add new desktop selector: focused:MONITOR_SEL 2013-12-31 18:39:47 +01:00
Bastien Dejean
0073eff5dc Simply treat transient windows as floating windows
http://tronche.com/gui/x/icccm/sec-4.html#WM_TRANSIENT_FOR
2013-12-29 19:53:42 +01:00
Bastien Dejean
b972f0abbd Provide padding settings for monitors
If a padding space is requested for a status bar, it concerns the
underlying monitor.
2013-12-28 10:30:49 +01:00
Bastien Dejean
48e0043f84 Implement the pseudo-tiled window state 2013-12-27 14:23:25 +01:00
Bastien Dejean
e0b6cd3cd4 *Frames* are unnecessary
The padding settings are sufficient for this.
2013-12-27 10:43:37 +01:00
Bastien Dejean
471fd2c7fc Turn {top,right,bottom,left}_padding into desktop settings 2013-12-25 10:06:02 +01:00
Bastien Dejean
d5672d09cd Don't crop splitting ratio in query -T 2013-12-16 11:55:44 +01:00
Bastien Dejean
de94ecb267 Add a floating state to desktops
Modifying the floating state of a desktop doesn't change the floating
state of the existing windows.
2013-11-03 23:01:31 +01:00
Bastien Dejean
6829eede5c Don't try to access the focused desktop of NULL 2013-10-29 14:23:58 +01:00
Bastien Dejean
08e1c85ce0 Remove tags
Tags should generalize desktops.

To accomplish this, the main node attributes: (type, ratio) would have
to become a dictionary: ((tf1, (type1, ratio1)), (tf2, (type2, ratio2),
...). (`tf<n>` being a tag field.).
2013-10-19 10:56:34 +02:00
Bastien Dejean
7334277454 Implement private windows 2013-10-12 21:16:51 +02:00
Bastien Dejean
6bc128554e Implement frames 2013-10-10 18:24:21 +02:00
Bastien Dejean
98c2b6c1e5 Fix clang warnings 2013-10-08 23:14:06 +02:00
Bastien Dejean
15695c066b Add copyright header 2013-10-08 21:05:56 +02:00
Bastien Dejean
759b87bb66 Add the older/newer selectors to all the objects
But also:
- Add a new modifier: `local`.
- Remove useless modifiers.
2013-10-08 17:47:00 +02:00
Bastien Dejean
ecb1b72263 Add history navigation selectors 2013-10-08 13:59:17 +02:00
Bastien Dejean
0b1727a28d Fix name collision with standard headers type 2013-10-07 10:22:07 +02:00
Bastien Dejean
ce844550dd New selector for nodes and desktops: last_local 2013-10-06 17:12:32 +02:00
Bastien Dejean
a75979be62 Implement tags 2013-10-05 22:32:40 +02:00
Bastien Dejean
ce25529e5c Implement sticky windows 2013-10-01 18:04:18 +02:00
Bastien Dejean
f2a578de2b Make the window border width a desktop setting 2013-10-01 14:15:50 +02:00
Bastien Dejean
bfded1effc History is global and stacking is independent
The last desktop and monitor are now deduced from the history.

The stacking order is now independent from the history of the focused
nodes: this prevents hacks on both sides.

All windows are now considered in the stacking algorithm: it prevents
tiled windows from one monitor to appear above the floating windows of
another monitor.

Transfered windows are stacked below the windows of the same kind.
2013-10-01 10:48:03 +02:00
Bastien Dejean
e60e87b12d Cosmetic improvements 2013-09-23 10:40:53 +02:00
Bastien Dejean
3dda8e7f6f Move a few functions from tree to desktop/monitor 2013-09-20 11:57:09 +02:00
Bastien Dejean
85f67b2164 Remove a few useless header inclusion via deheader 2013-09-19 15:38:22 +02:00
Bastien Dejean
d168e919e3 Split types.c into {monitor,desktop,history}.c 2013-09-19 15:02:49 +02:00
Bastien Dejean
488dd339cb Restore split direction 2013-09-14 12:17:22 +02:00
Bastien Dejean
758f5e6392 *window_gap* is now a desktop setting
The *config* command was generalized to handle desktop and monitor
settings.
2013-09-11 21:19:59 +02:00
Bastien Dejean
f38f863d30 Handle the primary monitor 2013-09-09 15:25:26 +02:00
Bastien Dejean
e2f085815a Add index selector for desktops and monitors 2013-09-02 21:03:59 +02:00
Bastien Dejean
daa358b3c4 Restore the split mode of nodes 2013-08-29 11:22:02 +02:00
Bastien Dejean
3941e01076 Optimize the last selector 2013-07-19 10:45:55 +02:00
Bastien Dejean
7606b0bb72 Add new selector modifiers: urgent and nonurgent 2013-07-19 10:13:22 +02:00
Bastien Dejean
e28581baf3 Show monitor padding information via query -T 2013-07-15 20:40:29 +02:00
Steven Allen
a61f4a32ab Add mode modifier
Allows selecting windows based on their mode (manual/automatic).  This
is useful for duplicating the old shift-can-be-transplant behavior.

    # Usage: squish DIR
    squish() {
        dir=$1
        bspc window -w ${dir}.manual || bspc window -s ${dir}
    }
2013-07-14 15:48:08 -04:00
Steven Allen
87fc178945 Don't segfault.
1. Pass the correct desktop when checking if the focused desktop matches.
2. Don't assume that a last desktop exists.
2. Don't assume that a last monitor exists.
2013-07-13 18:21:16 -04:00
Steven Allen
df89d390ec Apply modifiers to all objects
Window:
 * cycle                - no change
 * direction            - only consider matching nodes
 * last                 - walk history
 * focused              - match or NULL
 * biggest              - find biggest matching

Desktop:
 * cycle                - no change
 * focused              - match or NULL
 * last                 - match or NULL

Monitor:
 * cycle                - no change
 * direction            - only consider matching nodes
 * last                 - match or NULL
 * focused              - match or NULL
2013-07-13 16:40:37 -04:00
Bastien Dejean
7073f88479 Remove setting: monitor_focus_fallback
“There's only one way to do it.”

And a window selection shall always return a node.
2013-07-13 09:32:38 +02:00