Commit Graph

3789 Commits

Author SHA1 Message Date
Simon Elsbrock fe6e1f496a toggle fullscreen on 'scratchpad show'
If the focused application is in fullscreen mode and 'scratchpad show'
is executed, toggle the fullscreen mode before showing the scratchpad
application. Otherwise, the scratchpad app would not be visible anyways
but focus would be stolen.

fixes #613
2012-09-16 17:59:35 +02:00
Michael Stapelberg 794783defb Merge branch 'master' into next 2012-09-14 13:18:04 +02:00
Michael Stapelberg 0929f68a10 Merge branch 'fix-scratchpad-focus' 2012-09-14 13:18:00 +02:00
Michael Stapelberg 15499bf8e7 Bugfix: Don’t focus the wrong workspace when moving to scratchpad (+test) (Thanks loblik)
The problem was that scratchpad_move() didn’t check whether the source
workspace was focused. Therefore, 'move scratchpad' only worked reliably
interactively , but not when used with criteria.
2012-09-14 13:17:32 +02:00
Michael Stapelberg 22922a9e70 update release notes to reflect the current i3-nagbar situation 2012-09-11 13:19:05 +02:00
Michael Stapelberg 8abd1c48f7 Only launch i3-nagbar for parse errors 2012-09-11 13:17:36 +02:00
Michael Stapelberg 40b12c0a4d Remove support for resize increment size hints for tiling windows
As discussed on the mailing list and the bugtracker.

fixes #540
2012-09-11 13:11:47 +02:00
Michael Stapelberg 0db93d9072 sighandler: use non-existing backtrace filenames ($TMPDIR/i3-backtrace.%pid.%idx.txt) 2012-09-11 13:07:20 +02:00
Michael Stapelberg e713283605 sasprintf() already handles errors, we don’t need to do that twice 2012-09-11 13:02:59 +02:00
Michael Stapelberg 9d8a4ebc61 sighandler: provide gdb with pipe stdin/stdout fds (necessary for gdb < 7.5) 2012-09-11 12:57:53 +02:00
Bas Pape 38869004fe Replace exit with backtrace in crash dialog
When the user hits 'b', attach gdb and dump a backtrace to the tmpdir
2012-09-11 12:46:03 +02:00
Michael Stapelberg cfa74c5468 include the testcases in the dist tarball (required for building docs) 2012-09-10 16:49:43 +02:00
Michael Stapelberg daf2b57222 docs/testsuite: add pointers to additional docs 2012-09-10 14:13:43 +02:00
Michael Stapelberg 338199913b add boilerplate to all testcases with documentation references 2012-09-10 14:09:01 +02:00
Michael Stapelberg d745b47269 fix typo 2012-09-10 14:08:52 +02:00
Michael Stapelberg a4a3c59cf5 debian: add lib-i3test.html and lib-i3test-test.html to docs 2012-09-10 13:31:34 +02:00
Michael Stapelberg 71607ccdd3 tests: document each and every i3test function 2012-09-10 13:30:47 +02:00
Michael Stapelberg 0626c637aa tests: move does_i3_live to i3test::Test 2012-09-10 13:29:50 +02:00
Michael Stapelberg 6bfbec9da3 tests: make cmp_float a real test instruction 2012-09-10 13:24:11 +02:00
Michael Stapelberg 5bea7cb7df docs: generate HTML from testsuite POD documentation 2012-09-10 12:03:14 +02:00
Michael Stapelberg b4afd20d21 use pwd -P instead of readlink -f (Thanks Marcus Crestani)
readlink -f does not work on Mac OS X
2012-09-09 15:39:49 +02:00
Michael Stapelberg 02ce246caf build fix: remove src/cmdparse.* in make clean
This was removed in commit 8853334bbe
2012-09-09 15:30:37 +02:00
Michael Stapelberg a1823e59ff don’t errnously detect --release bindings as duplicates 2012-09-06 18:11:16 +02:00
Michael Stapelberg 4186827386 docs/userguide: document the --release flag for key bindings 2012-09-06 17:31:30 +02:00
Michael Stapelberg b15dd83b26 docs/userguide: use --no-startup-id for executing shell scripts 2012-09-06 17:31:16 +02:00
Michael Stapelberg 548d74015c ignore modifiers for KeyRelease bindings
For the following binding:

    # Simulate ctrl+v upon pressing $mod+x
    bindsym --release $mod+x exec --no-startup-id xdotool key --clearmodifiers ctrl+v

you can now use either:
1. press $mod, press x, release x, release $mod
2. press $mod, press x, release $mod, release x

fixes #485
2012-09-06 17:24:30 +02:00
Michael Stapelberg c6c6d3a952 naive implementation of 'bindsym --release' (and bindcode)
The implementation is naive because the user has to generate exactly the
event he specified. That is, if you use this binding:

    bindsym --release $mod+x exec import /tmp/latest-screenshot.png

Then it will only be triggered if you hit $mod, hit x, release x,
release $mod. It will not be triggered if you hit $mod, hit x, release
$mod, release x. The reason is that the KeyRelease event in the latter
case will not have the modifier in its flags, so it doesn’t match the
configured binding.
2012-09-06 17:04:31 +02:00
Michael Stapelberg f44d4ce4b3 re-indent src/config.c 2012-09-06 15:55:38 +02:00
Michael Stapelberg ea842f9686 update release-notes 2012-09-06 09:48:10 +02:00
Michael Stapelberg 1e3e6997f4 rendering: ceil() instead of truncating for tabbed deco_rect width (Thanks szalik)
In tabbed mode, the available width (say 1280) is divided by the amount
of child containers (say 3). Before this commit, we just truncated the
result and would end up with 426 + 426 + 426 = 1278 pixels that we
render to. Now we render a bit too much, but that’ll at least not give
us graphics corruption on any side :).

fixes #791
2012-09-05 23:54:56 +02:00
Michael Stapelberg 34391ae885 fix format string warnings 2012-09-05 22:26:59 +02:00
Michael Stapelberg d644dbff64 bugfix: forgot to mark split containers as split = true (+test) (Thanks szalik)
When the workspace layout (formerly orientation) was forced to change
due to a move command, the split container we created was not marked as
split = true, which caused tree_flatten() to errnously kill the contents
of it and thus one window ended up unmanaged.

Also, the logic in tree_flatten() was inverted due to commit de94f6da.

fixes #790
2012-09-05 22:26:52 +02:00
Michael Stapelberg a598544b5a userguide: point out explicitly how to use startup-notifications 2012-09-05 21:10:26 +02:00
Michael Stapelberg 32d4dbf70f startup-notifications: keep sequence around for 30s after completion
This changes the fact that Firefox would not be launched on the correct
workspace because it marked the startup sequence as completed *before*
actually mapping all of its windows.

To test this, go to workspace 3 and run this command in a terminal:
    i3-msg 'exec iceweasel; workspace 4'
That will make i3 start iceweasel (and create a proper startup
notification context for it), then immediately switch to workspace 4
(before iceweasel could possibly start).

The iceweasel window(s) should appear on workspace 3.
2012-09-05 21:02:52 +02:00
Michael Stapelberg 8d2799c251 Merge branch 'master' into next 2012-09-05 17:09:43 +02:00
Michael Stapelberg 9436e6f26e Merge branch 'fix-nagbar-exit' 2012-09-05 17:09:40 +02:00
Michael Stapelberg f5a7492a11 Bugfix: Use _exit() instead of exit to avoid calling atexit functions (Thanks f8l)
Basically, this is the same fix as commit 914ca6cf :-/. Once again, we
called exit() instead of _exit(), but this time it lead to a kill(0,
SIGTERM), effectively killing all processes in the i3 process group,
including i3 itself. The cause for the kill(0) is that nagbar_pid is set
to 0 by fork(), signaling we’re in the child process. The cleanup
handler only checks for nagbar_pid being -1 as a special value, however.
2012-09-05 17:09:23 +02:00
Michael Stapelberg 4976fa3350 con_set_layout: always use the parent container, handle workspaces properly
Previously, in case 'layout stacked' (for example) had been called
interactively, con_set_layout would be called with focused->parent,
while with for_window, it’d be called on the actual matching container.

This difference in behavior was the cause for the inability to use
'for_window [class="XTerm"] layout tabbed', which now works \o/, but
more on that below.

The change also allows us to handle the case of the user selecting a
CT_WORKSPACE container properly, that is, by using the special case and
creating a new split container on the workspace which gets all the
contents, but a new layout.

Now, before you are enthusiastic about the change and try to use
for_window magic in your config file, keep in mind: The 'layout' command
acts on the parent split container. That is, when using a line such as
this one:

    for_window [class="XTerm"] layout tabbed

…and opening an XTerm when on a workspace with one single other window,
the whole workspace will be set tabbed (just as previously when you
opened an XTerm and sent 'layout tabbed' manually).

Therefore, to open XTerm in its own tabbed split container, you need to
split before:

    for_window [class="XTerm"] split v, layout tabbed

The comma here is important! It says that the second command should not
be treated as an entirely unrelated command, but it should also relate
the matching window (while it does work with a ';', that is prone to
race-conditions and should be avoided).

fixes #358
2012-09-05 00:22:38 +02:00
Michael Stapelberg 2a37089ad1 Merge branch 'master' into next 2012-09-04 22:49:16 +02:00
Michael Stapelberg ada6af4244 Merge branch 'fix-1px-flickering' 2012-09-04 22:49:12 +02:00
Michael Stapelberg 8176b55b7b Bugfix: fix flickering with 1pixel border tabbed layouts (Thanks julien)
When you have a tabbed container which has had more than one container
but currently has precisely one container, there was a bit of flickering
when switching workspaces occasionally. This commit fixes it by properly
setting the height of the deco_rect (and thus the X11 window) to not
make the old window contents show up for a minimum period of time.

fixes #777
2012-09-04 22:47:12 +02:00
Michael Stapelberg 232d6ccce9 tests: introduce is_num_children test
This makes it clearer what the tests are actually doing and kills quite
a bit of useless repetitions
2012-09-04 22:24:13 +02:00
Michael Stapelberg 65e5bcfdf4 Merge branch 'master' into next 2012-09-04 20:21:31 +02:00
Michael Stapelberg 562c53d66c Merge branch 'fix-fullscreen-confreq' 2012-09-04 20:21:22 +02:00
Michael Stapelberg 5b95e20a62 Bugfix: Don’t allow ConfigureRequests while in fullscreen (Thanks Piotr)
This fixes a compatibility issue with gnome-terminal and xfce’s
terminal, where fullscreening would lead to moving the window and not
displaying the contents properly.

fixes #788
2012-09-04 20:21:07 +02:00
Michael Stapelberg 73d5dcbbaf x: grab server and process pending events before managing existing windows
fixes #782
2012-09-04 18:02:37 +02:00
Michael Stapelberg 9976e7461e remove xcb-proto from DEPENDS, it’s only a build-time dep of libxcb (Thanks okraits) 2012-09-04 16:53:06 +02:00
Michael Stapelberg 4636eb840d fix compilation with older xcb-util with -DXCB_COMPAT (Thanks okraits) 2012-09-03 14:55:27 +02:00
Michael Stapelberg f18ab28f5c bugfix: memleak: use i3STRING_FREE() instead of FREE() 2012-09-03 00:42:17 +02:00
Michael Stapelberg 2d1ebc2b90 Bugfix: memleak: because we use i3string_from_utf8(), we need to free buffer()
Previously, buffer was directly used and thus not freed, but
i3string_from_utf8() makes a copy.
2012-09-03 00:42:14 +02:00