Commit Graph

113 Commits

Author SHA1 Message Date
Michael Stapelberg
44c4c9d5a6 Bugfix: Go to the target workspace before changing focus on goto command (Thanks yurifury) 2009-10-07 20:41:21 +02:00
Michael Stapelberg
2b70e05ee9 Refactor workspaces to be stored in a TAILQ instead of an array
This fixes many problems we were having with a dynamically growing
array because of the realloc (pointers inside the area which was
allocated were no longer valid as soon as the realloc moved the
memory to another address).

Again, this is a rather big change, so expect problems and enable
core-dumps.
2009-09-29 19:45:41 +02:00
Michael Stapelberg
bfd704c523 Fix syntax for resize command 2009-09-29 00:54:27 +02:00
Michael Stapelberg
8f67eba044 Implement modes. Modes allow you to use different keybindings and switch between them.
For example, you can create a mode which will let you resize windows
with some easy to use keys. So, instead of binding a combination
of your homerow and modifiers to resize, like this:

	bind Mod4+44 resize right +10
	bind Mod4+45 resize right -10
	...

You can instead define a new mode:

	mode "resize" {
		bind 44 resize right +10
		bind 45 resize right -10
		...
		bind 36 mode default
	}

	bindsym Mod4+r mode resize

So, if you press Mod4+r now, your keybindings will be set to the ones
defined in your resize mode above. You can then use your homerow
(without any other modifier) to resize the current column/row and
press enter to go back to the default mode when you are done.

Note that using this option requires you to enable the new lexer/parser
by passing the -l flag to i3 when starting.
2009-09-27 18:45:39 +02:00
Michael Stapelberg
f38809288a Make number of workspaces dynamic (no longer limited by 10)
Warning: This is not yet thoroughly tested, so be prepared to
encounter some segfaults. Please enable logging and coredumps,
so we can fix bugs quickly.
2009-09-27 14:00:54 +02:00
Michael Stapelberg
a55d0b77fe Implement resize command
Syntax: resize <left|right|up|down> [+|-]<pixels>
2009-09-26 17:18:50 +02:00
Michael Stapelberg
f4ec7fdfe9 Implement stack-limit for further defining how stack windows should look
Using this command, you can limit the amount of columns or rows for
a stacking container. This allows for better usage of screen estate
when using stacking containers with many clients.

Examples:
  i3-msg "stack-limit cols 2"
You will now have a stack window which has two columns of windows.
2009-09-22 18:07:59 +02:00
Michael Stapelberg
3ada8f326c Implement vim-like marks
Commands are 'mark' and 'goto'. Both can be used either directly,
like 'mark a' and 'goto a', or interactively (just 'mark'). For
interactive mode, i3-input must be installed and in your PATH.
2009-09-20 16:54:29 +02:00
Michael Stapelberg
739f4f35aa Compilation fix for the last commit 2009-09-12 18:34:03 +02:00
Michael Stapelberg
3b59f5829f Bugfix: Correctly initialize workspaces for floating clients, too 2009-09-12 18:18:41 +02:00
Michael Stapelberg
4d01a02dba Bugfix: Correctly initialize workspace when moving clients (Thanks tsdh) 2009-09-12 18:15:32 +02:00
Michael Stapelberg
bf043cd2bd Some little style adjustments for badboy’s patch 2009-09-10 18:48:16 +02:00
Jan-Erik Rediger
40bc7c93d0 Implement command to toggle border style
Use 'bt' to toggle from normal to 1-px, borderless and back.
2009-09-10 18:44:27 +02:00
Michael Stapelberg
d9d4d9fff1 Implement tabbing
Use command "T" to switch to tabbing
2009-08-22 09:07:23 +02:00
Michael Stapelberg
44d9111d65 More log cleanups 2009-08-11 15:23:58 +02:00
Michael Stapelberg
556f180290 Bugfix: Fix screen wrapping, cleanup some log messages
Before this fix, you could go upwards and select the screen which
was at the rightmost because it also was the one topmost (if all
screen’s top position is equal).
2009-08-11 15:02:30 +02:00
Michael Stapelberg
b9636ceeec Set WM_STATE_WITHDRAWN when unmapping, unmap windows when destroying (Thanks xeen)
Seems like java apps need it. Also, you probably want to use XToolkit,
when you have to work with java apps:

export AWT_TOOLKIT=XToolkit
2009-08-11 12:16:10 +02:00
Michael Stapelberg
47a798ac4a Implement assignments of workspaces to screens, big cleanup of workspace code
Please test this! Plug in screens, unplug them, use your video projector,
change resolutions, etc.

To use the assignments, use the following syntax:
workspace <number> [screen <screen>] [name]

Where screen can be one of:
<number> (It is not provided that these numbers stay constant, so use with care)
<x>x<y> (Coordinates where the screen starts, so 1280 will be fine to match the
	 screen right of the main screen if your main screen is 1280 pixels
	 width. However, 1281 will not match)
<x>
x<y>

Some examples follow:

 workspace 1 screen 0
 workspace 1 screen 1
 workspace 1 screen 1280x0
 workspace 2 screen 1280
 workspace 3 screen x0
 workspace 3 screen 1 www
 workspace 4 screen 0 mail
2009-08-08 19:51:51 +02:00
Michael Stapelberg
35d811db82 Bugfix: Change to default mode if there was no client selected
Another bug fixed by having testcases :-)
2009-08-06 00:16:58 +02:00
Michael Stapelberg
22e4f03553 Implement ws (with screen) to focus the next screen (wsl for example) 2009-08-05 19:24:21 +02:00
Michael Stapelberg
9222bea3b2 Implement borderless / 1-px-bordered windows
Use bn (normal), bp (1-px), bb (borderless) as commands to change the
border style of the currently focused window. Feel free to use i3-msg
to do this.
2009-08-05 18:33:44 +02:00
Michael Stapelberg
7cfe520755 Bugfix: Don’t hide assigned clients to inactive but visible workspaces (Thanks xeen) 2009-08-02 22:31:52 +02:00
Michael Stapelberg
ce501c9de9 Some fixes/reformatting for bapt’s patch 2009-07-23 20:36:48 +02:00
bapt
40750e227d Implements a reload command 2009-07-23 18:46:21 +02:00
Michael Stapelberg
9db8535b4c Some little fixes (mostly formatting) for bapt’s patch 2009-07-22 00:16:16 +02:00
Bapt
3e262913e8 Implements next-previous workspace 2009-07-21 23:50:08 +02:00
Michael Stapelberg
ab48d714cf Bugfix: Don’t lose focus when putting windows into floating 2009-06-26 04:34:36 +02:00
Michael Stapelberg
8f87c212be Bugfix: When moving, first check boundaries, then check for col-/rowspan (Thanks Mirko) 2009-06-26 04:21:30 +02:00
Michael Stapelberg
8659419ef6 Bugfix: Correctly handle moving fullscreen client onto another screen (Thanks dirkson) 2009-06-25 13:46:47 +02:00
Michael Stapelberg
aa2f20ce26 Bugfix: Correctly handle floating windows when unmapping, fix focus bug when moving 2009-06-25 13:31:58 +02:00
Michael Stapelberg
777eedf0f4 Bugfix: Fix selecting col-/rowspanned containers 2009-06-24 21:10:12 +02:00
Michael Stapelberg
07bebdf841 Correctly re-assign floating clients to the destination workspace when moving 2009-06-24 17:12:12 +02:00
Michael Stapelberg
7ed967c96f Ensure that the focus is set correctly when moving floating clients 2009-06-24 00:35:05 +02:00
Michael Stapelberg
125faef1f4 Correctly move floating clients to other workspaces on visible screens 2009-06-24 00:34:03 +02:00
Michael Stapelberg
0aed552bae Bugfix: Remove/add floating clients to workspace->floating_clients when moving to other workspaces 2009-06-23 23:17:06 +02:00
Michael Stapelberg
cba36914a8 Implement selecting the next tiling/floating window (using "focus")
Also update documentation (manpage, userguide).
To make the code easier to read/write when checking if a client is
floating, introduce client_is_floating().
2009-06-21 16:14:15 +02:00
Michael Stapelberg
93ff4159c1 Bugfix: Obey colspan/rowspan when checking if containers can be snapped to the right/bottom (Thanks Mirko)
This fixes ticket #54.
2009-06-19 22:39:03 +02:00
Michael Stapelberg
89c0caaec4 Implement a command for hiding all floating windows (and showing them again) 2009-06-19 13:59:29 +02:00
Michael Stapelberg
5c48444b4e Implement the possibility to set a workspace open clients automatically in floating mode
Use "wwt" (with workspace: toggle floating) in your configuration file
2009-06-19 13:20:10 +02:00
Michael Stapelberg
4135aaad7c Implement moving of floating clients 2009-06-19 12:57:21 +02:00
Michael Stapelberg
a6d7f5451d Also set DIALOG, UTILITY and SPLASH windows floating automatically 2009-06-19 12:05:55 +02:00
Michael Stapelberg
00c6bdeb0b Implement changing focus via keyboard between floating clients, fix several floating bugs 2009-06-14 01:04:59 +02:00
Michael Stapelberg
d70ea03356 Remove some dead code, add default paths to switch() to make static analyzers happy
Check was done with scan-build from the LLVM suite. The remaining reports are false
positives and have been reported to llvm:

http://llvm.org/bugs/show_bug.cgi?id=4358
http://llvm.org/bugs/show_bug.cgi?id=4359
2009-06-10 19:59:36 +02:00
Michael Stapelberg
2f334c3f59 Bugfix: Don’t set focus when unmapping clients if the workspace is not active (Thanks Mirko)
This fixes ticket #53 because current workspace was set to the
workspace which was deleted.
2009-06-07 19:09:39 +02:00
Michael Stapelberg
0cb5d7448d Implement clients going automatically into floating 2009-05-31 00:31:18 +02:00
Michael Stapelberg
fccbdea925 Bugfix: Correctly set focus when switching to a workspace with floating clients
This fixes ticket #45
2009-05-30 11:41:49 +02:00
Michael Stapelberg
b1eb93326f Bugfix: Correctly cleanup stack_windows when setting clients to floating
This fixes ticket #44
2009-05-30 11:35:32 +02:00
Michael Stapelberg
94ee39d1ce Bugfix: Forgot to update client’s workspace pointer (Thanks Mirko) 2009-05-27 12:27:29 +02:00
Michael Stapelberg
bcd68d9ca1 Bugfix: Fix crash when focusing/moving on an empty workspace (Thanks Mirko) 2009-05-27 12:15:23 +02:00
Michael Stapelberg
9c3b37f2d1 Bugfix: Cleanup the table after putting clients into floating mode 2009-05-26 17:16:51 +02:00