Commit graph

250 commits

Author SHA1 Message Date
Bastien Dejean
ea49ed35d7 Compute colors on the fly
When drawing window borders, we must consider the color map of the
window to compute the correct color *pixel*.
2013-09-04 21:57:26 +02:00
Bastien Dejean
e2f085815a Add index selector for desktops and monitors 2013-09-02 21:03:59 +02:00
Bastien Dejean
6cbd905520 Rotate the given edge, not the brother subtree 2013-08-28 12:56:04 +02:00
Bastien Dejean
111680a48b Add a --rotate option to the window command 2013-08-27 23:48:50 +02:00
Bastien Dejean
2cee7ad3a9 Fail when there's no edge in all cases 2013-08-10 19:37:49 +02:00
Bastien Dejean
8b48ff50a3 Add an option to rule -a: --focus 2013-08-06 11:26:51 +02:00
Bastien Dejean
e5c2c2524b Don't increment rule counter when failing 2013-07-30 09:23:18 +02:00
Bastien Dejean
7f4c33eec9 Check the number of arguments for all the messages 2013-07-30 09:12:39 +02:00
Bastien Dejean
9b7baf86a8 A random pointer is not a desktop 2013-07-27 14:48:28 +02:00
Bastien Dejean
e562c62b07 Only remove empty desktops 2013-07-24 14:30:02 +02:00
Bastien Dejean
07f9f2d6d5 Reject invalid ratios 2013-07-24 14:12:35 +02:00
Bastien Dejean
de1aa71a37 Fix potential leak and null pointer dereference 2013-07-20 21:22:26 +02:00
Bastien Dejean
e28581baf3 Show monitor padding information via query -T 2013-07-15 20:40:29 +02:00
Steven Allen
04919868b9 Eat padding arguments. 2013-07-14 16:45:13 -04:00
Bastien Dejean
74deafbf77 Remove the *_padding settings
Setting and getting the monitor padding is now handled by the `-p`
option of the monitor command.
2013-07-14 21:29:30 +02:00
Steven Allen
4783c03bd1 Don't assume command arguments. 2013-07-14 12:24:43 -04:00
Bastien Dejean
209784dfd0 Merge pull request #36 from Stebalien/fix-monitor-selection
Call `monitor_from_desc` in `monitor -f <mon>`
2013-07-13 13:31:27 -07:00
Bastien Dejean
64cde67dc2 Remove setting: focus_by_distance
The removal is motivated by the following example:

+-------+-------+
|       |       |
|       |   b   |
|       |       |
|       |_______|
|   a   |       |
|   *   |   c   |
|       |       |
|       |_______|
|       |       |
|       |   d   |
|       |       |
+-------+-------+

Bellow is a summary of the number of steps required to reach *b*, *c* and *d* with *a* as a starting point with the associated mean and variance:

focus_by_distance         steps           mean         variance
---------------------------------------------------------------
  false                   1, 2, 3           2            2/3
  true                    2, 1, 2          5/3           2/9
2013-07-13 22:23:13 +02:00
Steven Allen
a782c1e927 Call monitor_from_desc in monitor -f <mon> 2013-07-13 16:17:59 -04:00
Bastien Dejean
1f83706ab5 Don't transplant when swapping
The new syntax provides a separate transplantation option.
2013-07-13 09:40:19 +02: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
Bastien Dejean
8fd8521322 Rewrite message handling
The new message syntax:
- Provides 10 commands instead of 60.
- Allows multiple actions to be applied in one call.

The client now returns an non zero exit code when a message fails.

The `is_adjacent` function now handles vacant nodes.
2013-07-12 21:52:02 +02:00
Bastien Dejean
7cb638e1d4 Follow nodes transfered via shift 2013-07-05 12:30:39 +02:00
Bastien Dejean
d7e364d183 Don't try to send/drop a NULL node 2013-07-04 12:20:40 +02:00
Bastien Dejean
16e73b6342 New setting: auto_cancel 2013-07-04 12:14:47 +02:00
Bastien Dejean
714fb8d504 Remove message: ungrab_pointer
The above message was only needed for ending the `move` pointer action
on a floating window. It rendered the `move` pointer action finicky
because the floating rectangle of the floating windows was not updated
in real time.
2013-07-04 11:04:28 +02:00
Bastien Dejean
addd537eb8 Prevent node transplantation for circulate 2013-07-02 21:33:33 +02:00
Bastien Dejean
e8b5ca6de8 Merge pull request #31 from Stebalien/arrange-after-kill
Arrange after killing a window
2013-06-30 04:56:19 -07:00
Steven Allen
772da4dc5d Arrange after killing a window
When a window is killed, the unmap event is never fired leaving a hole
in the layout. This commit closes that hole by manually calling arrange
after killing.
2013-06-29 21:01:23 -04:00
Steven Allen
2547a70701 Check to make sure the fence ratio is specified
Fixes a missing check for NULL.
2013-06-29 20:20:16 -04:00
Bastien Dejean
bc9e991541 Consolidate monitor_focus_fallback handling 2013-06-28 19:41:14 +02:00
Bastien Dejean
5af488498c New setting: monitor_focus_fallback 2013-06-28 15:44:34 +02:00
Bastien Dejean
898187238f New message: focus_monitor 2013-06-28 15:16:56 +02:00
Bastien Dejean
216c2b7f68 Transplant within swap_nodes 2013-06-28 11:56:30 +02:00
Bastien Dejean
dee3902b33 When shifting into manual mode nodes: transplant 2013-06-27 19:41:01 +02:00
Bastien Dejean
4e4d312ba5 New option for cancel: --all 2013-06-27 19:25:55 +02:00
Bastien Dejean
a6e90f472a Make split mode and direction local 2013-06-27 17:26:52 +02:00
Bastien Dejean
d2b3ebc459 Honor history_aware_focus for shift 2013-06-25 12:41:59 +02:00
Bastien Dejean
d5d8805ad2 New setting: history_aware_focus 2013-06-24 16:25:50 +02:00
Bastien Dejean
32ecbcfbc3 New message: fence_ratio 2013-06-22 12:13:35 +02:00
Bastien Dejean
7eee047b14 Arrange when swapping 2013-06-08 22:52:24 +02:00
Bastien Dejean
12403a5081 Handle fullscreen state in apply_layout 2013-06-08 18:31:55 +02:00
Bastien Dejean
ad44ed1565 Arrange after toggle_floating 2013-06-08 13:11:22 +02:00
Bastien Dejean
1516b9dc0e Update all desktops in set_setting
But also:
- Call `manage` explicitly in `process_message`.
- Don't arrange after `ratio`: just redraw the window border.
2013-06-08 12:28:38 +02:00
Bastien Dejean
b939bd7480 Consider only pointer_follows_monitor exceptions
We'd prefer not to have to clutter `messages.c` with redundant code and
hence we handle the two exceptions instead.
2013-06-08 11:53:48 +02:00
Bastien Dejean
9c6af342b3 Honor pointer_follows_monitor with alternate_monitor 2013-06-08 11:34:36 +02:00
Bastien Dejean
d3e5566b07 Pointer follows monitor only via use* messages 2013-06-07 11:58:31 +02:00
Bastien Dejean
9cac7cd459 Consolidate transfer_desktop 2013-06-07 11:17:41 +02:00
Bastien Dejean
f19cf121d7 Call arrange in transfer_node
Fix a few regressions, and add numerous minor cosmetic improvements.
2013-06-06 23:51:30 +02:00
Bastien Dejean
311fbc06d5 New setting: pointer_follows_monitor 2013-06-05 21:21:12 +02:00