Commit Graph

235 Commits

Author SHA1 Message Date
Michael Stapelberg
622b51a1ea Fix switching containers by moving the mouse over their decorations when in the same container 2010-11-28 01:13:18 +01:00
Michael Stapelberg
6fe0e58a64 Bugfix: Also render decorations of nearby cons when getting an ExposeEvent (Thanks fernandotcl) 2010-11-28 00:52:24 +01:00
Michael Stapelberg
3f3fa08b15 more debug for ClientMessages 2010-11-27 16:44:32 +01:00
Michael Stapelberg
6431d3d187 fix indention 2010-11-27 16:44:20 +01:00
Michael Stapelberg
962fe075b9 Bugfix: Upon ExposEvents, redraw decoration also for the window itself
In the meantime, windows can have decorations (borders) on their own frame, too.
2010-11-26 18:37:34 +01:00
Michael Stapelberg
e744b48b30 Bugfix: When handling an EnterNotify for a child window, access the correct con->layout 2010-11-26 18:18:40 +01:00
Michael Stapelberg
db651679c5 Bugfix: Properly ignore UnmapNotify events (especially for floating windows)
This fixes the bug which caused floating windows to be visible even when
switching to a different workspace.

Instead of ignoring a specific sequence, we now set an ignore_unmap counter for
each container. (So, should containers be closed too early or stay open even if
they should be closed, we probably need to have a closer look at the counter.
At the moment, it is increased by one on reparenting and unmapping (for
workspace changes) and decremented by one on each UnmapNotify event).

This system is better because a sequence does not describe a single unmap or
reparent request but a request to X11 on the network layer -- which can contain
multiple requests.
2010-11-20 19:11:43 +01:00
Fernando Tarlá Cardoso Lemos
ea1e9b20be Get rid of the remaining hardcoded height. 2010-11-15 12:25:06 +01:00
Michael Stapelberg
055bd18142 Bugfix: after the first UnmapNotify, unignore the event 2010-11-14 20:15:12 +01:00
Michael Stapelberg
d760a1c7b2 Bugfix: don’t kill parent when currently in tree_close() for a child of this parent 2010-11-14 20:14:09 +01:00
Michael Stapelberg
432073dbe5 implement support for WM_TRANSIENT_FOR, expand testcase 2010-11-13 01:19:21 +01:00
Michael Stapelberg
ad9be5402a Implement support for WM_CLIENT_LEADER 2010-11-12 23:46:03 +01:00
Michael Stapelberg
8f7bd538d8 implement configure requests, adapt testcase
testcase does not pass 100% due to clients not being reparented correctly yet.
2010-11-12 21:41:10 +01:00
Michael Stapelberg
5c2758af26 Implement support for size hints (including test case) 2010-10-11 21:32:29 +02:00
Michael Stapelberg
61f9a79347 use decimal coordinates in debug message 2010-07-11 22:01:25 +02:00
Michael Stapelberg
32be3af109 Re-implement support for the urgency hint, extend t/13-urgent.t
The actual rendering will follow
2010-06-02 17:55:10 +02:00
Michael Stapelberg
14a312c152 more debug output 2010-06-02 17:04:26 +02:00
Michael Stapelberg
1c5adc6c35 Don’t ignore sequence in UnmapNotify, there might be multiple windows in one sequence
This would lead to i3 thinking that a new window was already managed if it
has the same X-ID as the old window. Instead, we need to fix the EnterNotify
problem in a different way.
2010-06-02 17:03:26 +02:00
Michael Stapelberg
2d52ecf071 Add parameter to reparent windows instead of killing them when closing a container
Necessary because when windows are unmapped, they are not necessary to
be killed (an application can unmap it temporarily).
2010-05-15 00:16:59 +02:00
Michael Stapelberg
def41582d1 re-render the three after calling parse_cmd 2010-05-14 23:41:17 +02:00
Michael Stapelberg
8c5d824fa8 Ignore UnmapNotify events generated by reparenting 2010-05-14 23:37:56 +02:00
Michael Stapelberg
7adf921bc3 use the new parser for handling keybindings 2010-05-11 23:04:47 +02:00
Michael Stapelberg
c4d87e2f81 handle destroynotify events 2010-04-17 17:27:53 +02:00
Michael Stapelberg
d973f30fc2 push X11 changes after a window is mapped 2010-04-17 16:43:34 +02:00
Michael Stapelberg
c56867792a handle client messages (fullscreen window state) 2010-04-17 13:54:45 +02:00
Michael Stapelberg
2534f21940 ignore sequence of unmapnotify events (generates enternotify events) 2010-04-16 20:56:49 +02:00
Michael Stapelberg
24725cd94a re-add fullscreen mode 2010-04-13 20:51:43 +02:00
Michael Stapelberg
8959c5005f cleanups 2010-04-13 19:33:40 +02:00
Michael Stapelberg
8e5a831e27 re-add focus follows mouse handling 2010-04-13 18:43:37 +02:00
Michael Stapelberg
dd7acf73e9 re-add support for legacy window titles (WM_NAME) 2010-04-13 17:46:54 +02:00
Michael Stapelberg
fd8735a6fd correctly update/display window title/class 2010-04-13 17:22:34 +02:00
Michael Stapelberg
c145f7e529 first step of the big refactoring ("tree" branch).
From here on, we can track changes. It made no sense to put the
development up to this point into git.
2010-04-13 13:17:39 +02:00
Michael Stapelberg
46e7cf5fe1 Handle destroy notify events like unmap notify events
This helps for windows which are immediately destroyed instead of
unmapped, like when starting i3status | ./foobar | dzen2 -dock
and foobar does not exist (i3status and dzen2 will get a SIGPIPE).
2010-03-24 16:52:16 +01:00
Michael Stapelberg
56139f3656 Bugfix: only restore focus if the workspace is focused, not if it is visible 2010-03-23 14:43:35 +01:00
Michael Stapelberg
aec40126b4 ipc: implement output event 2010-03-19 22:40:43 +01:00
Michael Stapelberg
c738b2e454 Don’t use SYNC key bindings for Mode_switch but re-grab keys
Before this commit, i3 used key bindings in SYNC mode for bindings
like Mode_switch + <a> and replayed the key if the current state
did not include Mode_switch. This had some problems:

1) The WM needed to acknowledge much more key presses than you
   actually had bindings for, thus making the system a bit laggy
   sometimes.
2) Users of layouts who constantly type in the third level (like
   russian layouts) did not get their cyrillic symbols correctly
   (they were not replayed right), neither did the keybindings
   work in both modes.

So, the current implementation uses the following approach: XKB
provides an event which contains the current state (including
the current level). i3 signs up for this event and upon receival,
it re-maps the bindings using Mode_switch (enables them when the
level goes to the third level and disables them as soon as the
level goes back to normal). This fixes both problems.
2010-03-14 22:40:58 +01:00
Michael Stapelberg
3db4890683 ipc: implement events, cleanup the code a bit 2010-03-12 21:05:05 +01:00
Michael Stapelberg
93a9f3c244 Bugfix: Don’t mess up x/y coordinates in configurerequests for floating windows
This was the cause for ticket #93, which actually has a false
conclusion for the reason of this bug.

This code needs to be refactored.
2010-03-11 23:34:29 +01:00
Michael Stapelberg
40475b250f Allow unsetting WM_CLIENT_LEADER (XCB_NONE is not an invalid value) 2010-03-05 17:42:50 +01:00
Michael Stapelberg
8d648b4e37 Update function names, variable names and documentation for the RandR changes 2010-03-05 16:18:41 +01:00
Michael Stapelberg
8b192ac7ed Bugfix: Correctly hide/show workspaces when enabling new outputs, correctly handle focus (Thanks Merovius) 2010-03-05 15:22:12 +01:00
Michael Stapelberg
e5f222e03e Save a resize_client() when handling the size hints 2010-03-03 01:23:38 +01:00
Michael Stapelberg
7839b7a4fe Bugfix: checked for wrong flag in size hints 2010-03-03 01:23:38 +01:00
Michael Stapelberg
818e02ef35 huge change: implement RandR instead of Xinerama
Thanks to Merovius for doing a proof of concept on this one and
being a driving force behind the idea.

Using RandR instead of Xinerama means that we are now able to use
the full potential of the modern way of configuring screens. That
means, i3 now has an idea of the outputs your graphic driver
provides, which allowed us to get rid of the ugly way of detecting
changes in the screen configuration which we used before. Now, your
workspaces should not be confused when changing output modes anymore.

Also, instead of having ugly heuristics to assign your workspaces
to (the screen at position X or the second screen in the list of
screens) you will be able to just specify an output name.

As this change basically touches everything, you should be prepared
for bugs. Please test and report them!
2010-03-02 12:47:21 +01:00
Michael Stapelberg
4fcbb7980e work around clients setting 0xFFFF as resize increments
I am not sure if behaviour is specified for this case, but as the
workaround is not really a big deal, why bother…
2010-02-20 20:32:43 +01:00
Michael Stapelberg
0b6b8e8380 Bugfix: Use both parts of WM_CLASS (it contains instance and class) (Thanks fallen)
Actually, WM_CLASS contains two null-terminated strings, so we cannot
use asprintf() to get its value but rather use strdup() to get both
of them. Both values are compared when a client is matched against
a wm_class/title combination (for assignments for example).
2010-02-12 12:12:25 +01:00
Michael Stapelberg
88b9700cdb Invert logic for the last commit
This makes it more clear that the option is meant to be a special
case (it *disables* part of the focus handling). Also, when
initializing the config data structure with zeros, it will get
initialized with the right value.

Furthermore, the config file parser now also accepts various values
which represent "true", not only numbers.
2010-01-29 21:58:50 +01:00
Kim Silkebækken (lokaltog)
7f10970fc7 Added focus_follows_mouse config option 2010-01-29 21:58:50 +01:00
Michael Stapelberg
848d9c1b01 Make containers containing exactly one window behave like default containers
Starting from this commit, a borderless window will always be
borderless if it is the only window in a container. For example,
you can have Firefox borderless in a tabbed container and as soon
as the download manager or a viewer gets opened, the container
will be rendered like a normal tabbed container.

This solves the user-interface dilemma of borderless/1-px-border
windows inside stacked/tabbed containers, at least for this special
case. Thanks to Merovius for this suggestion.
2009-12-22 23:40:06 +01:00
Michael Stapelberg
6ef0d1fa79 Touch each log message and classify it as DLOG (debug), ELOG (error) or LOG (verbose) 2009-12-19 22:40:23 +01:00