Commit Graph

2850 Commits

Author SHA1 Message Date
Fernando Tarlá Cardoso Lemos
af335f0403 Don't call free on statically allocated strings.
Fixes segfault when the option -f is used. Also, don't leak prompt
strings. We either keep FREE to prevent leaking, or choose to leak
and avoid strdup. Another option would be using a flag to indicate
whether or not the strings are heap allocated, but it's overkill.
2011-11-07 19:57:25 +00:00
Fernando Tarlá Cardoso Lemos
d5613905c8 Plug minor leaks in string conversion routines. 2011-11-07 19:57:11 +00:00
Michael Stapelberg
ddf261432a i3bar: change default color for active workspace buttons to make them visible
Previously, you could not figure out which workspace is displayed on a screen
which is not focused.
2011-11-07 19:52:21 +00:00
Michael Stapelberg
a977b2d96e i3bar: fix -h output (Thanks IsoLnCHiP) 2011-10-31 20:44:55 +00:00
Michael Stapelberg
2b6504d310 Bugfix: RandR: Correctly keep focus on the focused workspace when an output disappears (Thanks AlexanderB, xeen) 2011-10-31 12:11:34 +00:00
Michael Stapelberg
51e0d1b741 docs/userguide: clarify proportional resizing with floating modifier (Thanks Donald) 2011-10-29 22:58:32 +01:00
Michael Stapelberg
50d14718f4 fix t/120-multiple-cmds: open a window before moving 2011-10-27 23:30:29 +01:00
Michael Stapelberg
8e3cef33d9 Error out early if there is nothing to move
Fixes: #532
2011-10-27 23:27:33 +01:00
Michael Stapelberg
09a07b9169 docs/userguide: update the workspace assignment section 2011-10-27 22:45:34 +01:00
Michael Stapelberg
5227b29b0f Make named workspace assignments work again
Please note that you need a quoted string for the workspace name.
Example:
    workspace "1: www" output HDMI2

Fixes: #456
2011-10-27 22:43:53 +01:00
Michael Stapelberg
a4cb4a64d4 Bugfix: warp pointer during the EnterNotify-disabled phase
Following bug:
1) Assign workspace 9 to output HDMI2
2) On HDMI2, be on workspace 1
3) Focus a different output, say LVDS1
4) Execute i3 'workspace 9'
5) Something happens, but you end up back on ws 1

(this is due to an EnterNotify being generated when warping)
2011-10-27 22:29:47 +01:00
Michael Stapelberg
4330c723ae Merge branch 'move-floating' into next 2011-10-27 21:52:59 +01:00
Michael Stapelberg
18c2ef33d3 docs/userguide: Document the move syntax 2011-10-27 21:52:39 +01:00
Michael Stapelberg
df980bffa4 Make 'move' handle floating windows properly
This means you can now specify an amount of pixels for the move command. The
default is 10. Note that this of course only works for floating windows.

Example:
  move left 20 px
2011-10-27 21:46:15 +01:00
Michael Stapelberg
edfa9febae extend t/124-move.t to test move for floating containers 2011-10-27 21:46:01 +01:00
Michael Stapelberg
ca0c2a46e4 t/124-move.t: re-activate test for useless move commands 2011-10-27 21:22:41 +01:00
Michael Stapelberg
e25991f538 Bugfix: Don’t invoke resizing when clicking on the decoration in a > 1 child split con (Thanks julien)
Fixes: #534
2011-10-27 20:36:55 +01:00
Michael Stapelberg
af1871e414 Bugfix: Only fallback on the font if it’s actually set (Thanks phnom) 2011-10-26 21:21:55 +01:00
Michael Stapelberg
ee804a0635 Also call workspace_show() when moving cursor to an empty output (Thanks mw) 2011-10-25 23:41:52 +01:00
Michael Stapelberg
38447c4b47 Bugfix: Correctly use workspace_show() when focus changes to a different output via EnterNotify or FocusIn (Thanks pnutzh4x0r)
This makes i3bar show the correct workspace when you move your mouse from one
output to another.
2011-10-25 23:04:10 +01:00
Michael Stapelberg
e710477a07 Bugfix: properly handle comments in colors {} blocks of bar config (+test) (Thanks fernandotcl) 2011-10-25 22:31:57 +01:00
Michael Stapelberg
704c9967b2 Merge branch 'exec_nosn' into next 2011-10-25 22:23:35 +01:00
Michael Stapelberg
af6f8ca7c2 complete-run: clear the DESKTOP_STARTUP_ID environment variable before starting i3 2011-10-25 22:21:59 +01:00
Michael Stapelberg
91d589b176 tests: extend t/175-startup-notification to test the --no-startup-id flag 2011-10-25 22:21:37 +01:00
Michael Stapelberg
73d4737e42 docs/userguide: document the --no-startup-id flag for exec directives in the config 2011-10-25 22:21:09 +01:00
Michael Stapelberg
15f36cdc91 docs/userguide: document the --no-startup-id flag 2011-10-25 22:18:40 +01:00
Michael Stapelberg
bbfbd28dfa Add a --no-startup-id flag for exec (command), exec (config), exec_always (config) 2011-10-25 22:18:17 +01:00
Michael Stapelberg
726f2a1e5a normalize file headers across **/*.{h,c} 2011-10-25 21:19:38 +01:00
Michael Stapelberg
8660ae4e12 bar config: fall back to the i3 font (Thanks pl) 2011-10-25 20:50:57 +01:00
Michael Stapelberg
35bd2d27c0 i3bar: put tray icons in the save-set (prevents them from crashing when i3bar exits/crashes) 2011-10-24 20:11:32 +01:00
Fernando Tarlá Cardoso Lemos
d490bae8a2 Close empty workspaces if they're not visible.
Previously, we'd only close an empty workspace when we moved away
from it. Now we also close it when the last client exits, as long
as that workspace is not visible anymore.
2011-10-24 00:12:14 +01:00
Michael Stapelberg
f4469eee0b get rid of xcb.c in all i3-* tools
open_input_window was slightly different for each of them, so it made no sense
to generalize it (then we would end up with a thin and useless wrapper).
2011-10-23 23:20:57 +01:00
Michael Stapelberg
a58018cf66 Add libi3/load_font, use it everywhere
…except for i3bar, which needs slightly more information about the font
2011-10-23 22:37:11 +01:00
Michael Stapelberg
6d01d37b03 remove unused cached_fonts TAILQ 2011-10-23 22:03:20 +01:00
Michael Stapelberg
8da6049ca9 Actually make load_font only fallback if 'fallback' is true 2011-10-23 22:02:11 +01:00
Michael Stapelberg
29f9f8c090 Fix tests: s/i3bar/bar {/ and hash prefix for color codes in GET_BAR_CONFIG 2011-10-23 21:51:43 +01:00
Michael Stapelberg
3e7f941b83 Fix comment in run_assignments (Thanks xeen) 2011-10-23 21:45:12 +01:00
Michael Stapelberg
91134f75c0 Move get_mod_mask to libi3, use it in i3 and i3-config-wizard
Also, the API changed a bit. There are two functions now, both assume you
already got the keysyms (which is the case for i3 and i3-config-wizard),
one gets the modifier mapping for you (aio_get_mod_mask_for) while the other
assumes you also got that. No roundtrips are required for the latter.
2011-10-23 21:26:15 +01:00
Michael Stapelberg
a512b99a51 Introduce --get_socketpath and --force_xinerama as synonyms for --get-socketpath and --force-xinerama 2011-10-23 19:41:40 +01:00
Michael Stapelberg
c2d04116d4 i3-input: Remove unused get_mod_mask from xcb.c 2011-10-23 19:37:28 +01:00
Michael Stapelberg
05d097bb36 i3-input: fix handling of Mode_switch (makes special characters work again)
This seems to have only worked before in certain settings, where the modifiers
were configured in a way that it matched by chance…
2011-10-23 19:34:48 +01:00
Michael Stapelberg
7c04e23ab7 i3-input: Bugfix: font must be dynamically allocated, we FREE it later 2011-10-23 19:34:21 +01:00
Michael Stapelberg
7d487b0314 remove unused get_mod_mask from i3-config-wizard/xcb.{c,h} 2011-10-23 18:33:21 +01:00
Michael Stapelberg
6dc6ba11fc Eliminate xcb_change_gc_single everywhere with C99 2011-10-23 18:06:25 +01:00
Michael Stapelberg
9eda7fb6fb move strndup to libi3 2011-10-23 18:02:01 +01:00
Michael Stapelberg
78fea8e1fb i3-nagbar: eliminate xcb_change_gc_single with C99 2011-10-23 17:55:58 +01:00
Michael Stapelberg
ada4857ad2 Fix colors in i3bar (Thanks julien)
i3bar previously used get_colorpixel on strings without the leading # (ff0000
instead of #ff0000). Since it uses libi3’s get_colorpixel now we needed to
update a few places.
2011-10-23 17:48:44 +01:00
Michael Stapelberg
91ae73b1f6 i3-config-wizard: eliminate xcb_change_gc_single with C99 2011-10-23 17:45:40 +01:00
Michael Stapelberg
cb9bbcfccf Move get_colorpixel to libi3, use it everywhere else 2011-10-23 17:38:21 +01:00
Michael Stapelberg
0086bcb2b4 i3-input: eliminate xcb_change_gc_single usage with C99 2011-10-23 17:26:06 +01:00