D.B
ce98569fbc
Handle output disabling during runtime
...
Output now gets disabled if disable command is invoked via bindsym or
IPC.
2016-08-10 18:52:49 +02:00
minus
b246799548
fixed uninitialized bar.wrap_scroll
2016-08-02 22:02:39 +02:00
Drew DeVault
11e7ca044c
Update hidpi support to latest wlc API
2016-07-28 14:36:49 -04:00
Drew DeVault
6ea02f3064
Initial pass on HiDPI support
2016-07-28 14:36:49 -04:00
minus
50b09937b2
clean up apply_input_config
2016-07-18 20:12:49 +02:00
Drew DeVault
6d971af5c3
Turn swaybg into a shell surface
2016-07-17 11:55:05 -04:00
Zandr Martin
9ecb43ea3b
couple small fixes
2016-06-11 15:29:04 -05:00
Zandr Martin
2298143d09
cleanup + add timeouts for pid_workspace list
2016-06-11 12:43:34 -05:00
Zandr Martin
66caee645c
Merge branch 'master' into assign-command
2016-06-11 09:33:24 -05:00
thuck
3710cd6963
Fix segfault when using include with *
...
This should fix the issue #681
2016-06-06 22:20:27 +02:00
Zandr Martin
0f1859ed25
messy, unfinished version
2016-06-06 06:58:53 -05:00
Denis Doria
b692a6d31a
Initial implementation for floating_maximum_size
2016-06-02 17:35:02 +02:00
Denis Doria
009eaccd42
Clean up not used variables
2016-06-01 14:44:02 +02:00
Denis Doria
0ad7857f90
Included option floating_minimum_size
...
Values cannot be negative or 0; if so uses the default 75x50.
Uses the same syntax as i3: floating_minimum_size <width> x <height>, although the x can be anything.
2016-06-01 13:37:50 +02:00
Denis Doria
f1d5b89d3e
Initial work for floating view with sane values
2016-05-31 14:59:33 +02:00
Mykyta Holubakha
e73dde3b10
Support floating_scroll sideways
2016-05-14 23:42:02 +03:00
Mykyta Holubakha
0c495eecde
Remove FSB_GAPS_INNER and FSB_GAPS_OUTER
2016-05-08 17:17:35 +03:00
Mykyta Holubakha
0423c41a0f
Implemented configurable floating scroll behavior
2016-05-07 20:49:51 +03:00
Daniel Lockyer
b41097c085
sway/config.c: fix double free issue as we need to store path in list
2016-05-05 23:50:12 +01:00
Jasen Borisov
de007c9b58
Add input cmd for setting pointer accel profile.
2016-05-01 11:02:44 +01:00
Daniel Lockyer
682efbb7dd
sway/config.c: Initialise struct value
2016-04-30 01:12:41 +01:00
Daniel Lockyer
e1fa51a152
sway/config.c: Move the wordfree call before the if statement so it is always called
2016-04-29 18:36:29 +01:00
Daniel Lockyer
06986e58b8
sway/config.c: Change to the useful free_cmd_results helper method
2016-04-29 18:31:21 +01:00
Daniel Lockyer
01c2b5f2d6
sway/config.c: move free call to after sway_log
2016-04-29 18:27:49 +01:00
Daniel Lockyer
b8722ecd5f
sway/config.c: Leading on from cdf017c
, we need to free path
2016-04-29 18:09:56 +01:00
Daniel Lockyer
e077ebdc72
sway/config.c: res->input is a malloc'ed section which wasn't freed
2016-04-29 18:08:28 +01:00
Daniel Lockyer
cdf017ceea
sway/config.c: wordexp has a corresponding wordfree which was never used
...
I had to change the assignment to path to be wrapped by strdup as we
pass the data out of the method.
2016-04-29 18:07:38 +01:00
Daniel Lockyer
c225bcacee
sway/config.c: config_home is the result of a malloc but was never freed
2016-04-29 18:06:21 +01:00
Mykyta Holubakha
0f1cfdec61
Renamed to pango_markup
2016-04-24 20:35:21 +03:00
Mykyta Holubakha
53b53dd8c2
Added plaintext markup configuration
2016-04-24 19:57:35 +03:00
Mikkel Oscar Lyderik
7be476c115
Add cmds new_window and new_float
...
Makes it possible to set default layout style for new windows and new
floating windows.
Close #556
2016-03-31 12:42:20 +02:00
Drew DeVault
a12850444d
New feature: adjust gaps with floating_mod+scroll
...
I made this configurable but I didn't make the command for it. That's
left as an exercise to an eager contributor.
mod_scroll_behavior [gaps inner|gaps outer]
Would merge implementions of more behaviors for mod+scroll, if anyone
has some neato ideas.
2016-03-30 08:34:32 -04:00
Mikkel Oscar Lyderik
5a13cb0ed1
Implement borders
...
The borders are implemented as a surface/buffer attached to each view
which is sent to and rendered by wlc in the view_pre_render callback.
All the drawing logic is handled in sway/border.c and all the logic for
calculating the geometry of the border/view is handled in
`update_geometry` in sway/layout.c (same place as gaps are calculated).
2016-03-30 00:47:58 +02:00
Mikkel Oscar Lyderik
3b05f92f76
Add border <none|normal|toggle|pixel> config
2016-03-30 00:47:58 +02:00
Mikkel Oscar Lyderik
86ea79ea6d
Implement parsing of hide_edge_borders
2016-03-30 00:47:58 +02:00
Mikkel Oscar Lyderik
da567317ab
Make pango: prefix optional for font config
2016-03-30 00:47:58 +02:00
Mikkel Oscar Lyderik
e2774aee3c
Add default border colors
2016-03-30 00:47:58 +02:00
Mikkel Oscar Lyderik
cdc73fd95e
Don't try to read config if not a file.
2016-03-26 17:54:50 +01:00
Mikkel Oscar Lyderik
44ea92ea60
Add config path to error msg
2016-03-26 16:50:47 +01:00
Mikkel Oscar Lyderik
71a5350b68
Implement include command
...
The include command (`include <path>`) makes it possible to include sub
config files from the main config file (or from within other sub config
files).
The include command uses the following rules for including config files:
* the `path` can be either a full path or a path that is relative to the
parent config. Shell expansion is supported, so it's possible to do
`include ~/.config/sway.d/*`.
* The same config file can only be included once (to prevent include
cycles). If a config is included multiple times it will just be
ignored after it has been included once.
* Including a sub config file is the same as inserting the content of
that file into the parent config, thus rules about overwriting
bindsyms etc. works the same as for a single config.
Implement #542
2016-03-26 16:37:50 +01:00
Mikkel Oscar Lyderik
938ff29b7b
Gracefully exit when config is not found
...
This makes sure that sway will gracefully exit if the config is not
found or sway is unable to read it.
2016-03-24 22:20:25 +01:00
Mikkel Oscar Lyderik
2935e24cf5
Implement 'smart_gaps' feature from i3-gaps
2016-03-20 12:29:47 +01:00
Mikkel Oscar Lyderik
67bbcceba1
Free config before exiting sway.
...
Apart from freeing the sway_config struct, this also terminates the
swaybars spawned by sway, since they are linked by PID to the bar config
structs.
2016-02-27 22:13:15 +01:00
Mikkel Oscar Lyderik
e15a8a0376
Improve how swaybars are spawned
2016-02-27 22:12:35 +01:00
Mikkel Oscar Lyderik
bad4e22f3b
Make sway spawn only one bar per bar config
2016-02-27 22:12:35 +01:00
crondog
0ee5547406
font: Allow adding font to the config. In prep for border titles
...
v2: Give default font and make bar use it if no bar font
2016-01-27 20:53:31 +11:00
Yacine Hmito
c487cf71a5
Fix issue #455
...
CMAKE_INSTALL_FULL_SYSCONFIG is not actually passed to
the C preprocessor. I remember it working, so I must have
messed up somewhere last time I touched this.
This is fixed by manually passing its value to the C preprocessor
through the SYSCONFDIR definition
2016-01-21 21:08:18 +01:00
Drew DeVault
d969a1dec0
Fix memory leak in config.c
...
Thanks @jollywho
2016-01-21 11:18:13 -05:00
Cole Mickens
28081b7689
libinput
2016-01-19 06:51:36 -08:00
Mikkel Oscar Lyderik
f8b260d4a1
Add support for bincode command
...
If a bindsym and bincode maps to the same combination, the last one will
overwrite any previous mappings.
2016-01-09 18:07:47 +01:00
Mikkel Oscar Lyderik
32cd3f70eb
Add function for duplication a sway_binding
2016-01-08 03:03:55 +01:00
Mikkel Oscar Lyderik
843e2ad2c1
Only send modifier event once for active modifiers
...
This makes sure that a modifier event is only sent for active bar
modifiers, and that it is only sent once for each of those modifiers.
An active bar modifier is a modifier defined for a bar with `mode hide`
and `hidden_state hide`.
2016-01-05 23:18:59 +01:00
Mikkel Oscar Lyderik
7727c9efbc
Detect bar modifier pressed/released
2016-01-05 00:49:44 +01:00
Yacine Hmito
f02cf75ff3
Use SYSCONFDIR as recommended
...
- swaylock config path not hardcoded anymore
- the unusual and weird FALLBACK_CONFIG_DIR is no more
2015-12-23 12:22:48 +01:00
Drew DeVault
91c102a897
Merge pull request #393 from robotanarchy/musl-libc-compatibility
...
musl libc compatibility
2015-12-21 20:42:08 -05:00
robotanarchy
c3e9ee5e43
replace non-standard qsort_r with qsort
...
I've tried to make as few changes, as possible.
Usually the reason for using qsort_r is, that you can pass an extra userdata pointer to the
compare function. However, in sway list_sort wrapped qsort_r and always called a wrapper
function for comparing, the wrapper function then had the real compare function as argument.
The only thing, that the wrapper function does, is dereferencing the 'left' and 'right' function
arguments before passing them to the real compare function.
I have renamed list_sort to list_qsort to avoid confusion (so nobody tries to use list_qsort like
list_sort) and removed the wrapper functionality. Now the dereferencing must be done in the
compare function, that gets passed.
Some compare functions were used in both list_sort and list_seq_find. To make the difference
clear, I've added a '_qsort' suffix to the compare functions, that are intended to be used with
the new list_qsort. (In other words: list_qsort is not compatible anymore with list_seq_find).
- Changed and renamed function (it isn't used anywhere but in commands.c, and only for sorting):
compare_set -> compare_set_qsort
- New wrapper functions:
sway_binding_cmp_qsort (for sway_binding_cmp)
sway_mouse_binding_cmp_qsort (for sway_mouse_binding_cmp)
2015-12-22 00:38:18 +01:00
Drew DeVault
fc71c6303c
Fix default swaybar font
2015-12-21 05:07:19 -05:00
Drew DeVault
33fb648938
Merge pull request #372 from sce/fix_swaybar_output_name_test
...
config: load_swaybars: Fix name comparison.
2015-12-20 09:23:34 -05:00
S. Christoffer Eliesen
6ace37d0b1
config: load_swaybars: Fix name comparison.
2015-12-20 12:53:56 +01:00
S. Christoffer Eliesen
2779559b15
config: free_bar: Check if outputs is NULL.
...
bar_config.outputs is NULL if no output is explicitly defined in config
(ie. use for for all outputs).
2015-12-20 10:14:36 +01:00
Mikkel Oscar Lyderik
207678e809
Add support for running swaybar_command
2015-12-19 01:03:39 +01:00
Drew DeVault
b9f14cee41
Merge pull request #359 from mikkeloscar/i3bar-command
...
Add bar option: swaybar_command <command>
2015-12-18 18:19:59 -05:00
Mikkel Oscar Lyderik
9d7f1afdfb
Add bar option: swaybar_command <command>
2015-12-19 00:13:51 +01:00
Mikkel Oscar Lyderik
90ff36cab8
Terminate children when freeing output container
2015-12-18 18:27:54 +01:00
Mikkel Oscar Lyderik
ede27eabc5
Reload swaybar/swaybg on config reload.
...
This works by tracking the pids of the child processes in the related
output container and terminating the processes and spawning new ones on
a config reload.
Should solve: #347
2015-12-18 18:27:44 +01:00
Drew DeVault
03787871d0
Fix bar invocation for multihead setup
2015-12-16 19:36:31 -05:00
Drew DeVault
1a365f19c9
Use system swaybar instead of local swaybar
2015-12-16 19:30:38 -05:00
Drew DeVault
60c204a09b
Invoke swaybar when an output matches a bar config
2015-12-16 19:29:47 -05:00
Drew DeVault
01798a5ae2
Merge pull request #338 from mikkeloscar/bar-separator-symbol
...
Implement bar option: separator_symbol
2015-12-16 07:47:00 -05:00
Mikkel Oscar Lyderik
053fb09d1e
Use free_flat_list for simple char* list.
...
No need to reimplement free_flat_list functionality.
2015-12-16 13:06:54 +01:00
Mikkel Oscar Lyderik
2fd7dd64ec
Implement bar option: separator_symbol
2015-12-16 13:01:11 +01:00
Mikkel Oscar Lyderik
47f4aea9e7
Correctly free bindings list
2015-12-15 22:16:54 +01:00
Mikkel Oscar Lyderik
f59f5d27aa
Implement bar option: output <output>
2015-12-15 22:01:53 +01:00
Mikkel Oscar Lyderik
05e7334106
Fix active_workspace_border color definition
2015-12-15 15:08:41 +01:00
Mikkel Oscar Lyderik
6834a33290
Add bar height option (Airblader/i3)
2015-12-15 15:02:13 +01:00
Mikkel Oscar Lyderik
de1f625c27
Add rgba support for bar colors
2015-12-15 13:45:04 +01:00
Mikkel Oscar Lyderik
8c1d56812b
Implement bar option: colors {}
2015-12-15 13:12:55 +01:00
Drew DeVault
242da783f4
Merge pull request #324 from mikkeloscar/free-bar-bindings
...
Free bar->bindings
2015-12-14 19:58:41 -05:00
Mikkel Oscar Lyderik
95de999922
Free bar->bindings
2015-12-15 01:53:34 +01:00
Mikkel Oscar Lyderik
0513322c03
Move default bar config to bar creation.
...
Get rid of `config->bar` and define the default bar config options when
a bar is initialized.
2015-12-15 01:05:00 +01:00
Yacine Hmito
87126a9fc2
Added bar_cmd_bindsym
...
Defined a sway_mouse_binding for clicks on the swaybar
2015-12-15 00:15:32 +01:00
Mikkel Oscar Lyderik
0aeee6963d
Make mouse key used for drag/resize configurable
...
This makes it possible to define what mouse button key (left|right) to
use for dragging/resizing.
2015-12-14 22:31:34 +01:00
Mikkel Oscar Lyderik
211bc71599
Use tabs instead of spaces
2015-12-14 16:38:49 +01:00
Drew DeVault
4d17aa9919
Revert "Make mouse key used for drag/resize configurable"
...
This reverts commit 22916e9ebc
.
2015-12-14 08:57:00 -05:00
Mikkel Oscar Lyderik
0a8ec26383
Implement bar option: tray_padding <px> [px]
2015-12-14 12:56:59 +01:00
Mikkel Oscar Lyderik
74152043f4
Implement 'bar { }' block parsing
2015-12-14 12:56:45 +01:00
Drew DeVault
19fd979af4
Merge pull request #300 from mikkeloscar/configure-mouse-btn
...
[RFC] Make mouse key used for drag/resize configurable
2015-12-12 12:28:56 -05:00
Drew DeVault
bffbe11e53
Fix config.c strlen error
2015-12-11 14:22:28 -05:00
Mikkel Oscar Lyderik
22916e9ebc
Make mouse key used for drag/resize configurable
...
This makes it possible to define what mouse button key (left|right) to
use for dragging/resizing.
2015-12-11 18:04:27 +01:00
Yacine Hmito
f3f77f9ff1
FALLBACK_CONFIG_DIR did not work. Fixed.
...
- Flag was ignored. Now it's taken into account.
- Missing trailing slashes in path now behaves properly.
2015-12-01 19:41:44 +01:00
Yacine Hmito
09feef89ee
Can customize config fallback directory
...
CMake takes a `FALLBACK_CONFIG_DIR` flag which is the directory where the
standard configuration file `config` is copied at installation.
If loading from typical configuration directories fails, sway loads
FALLBACK_CONFIG_DIR/config (/etc/sway/config by default).
2015-12-01 01:07:48 +01:00
Drew DeVault
44d0f731c3
Add framework for switching command sets
...
This will allow the bar {} block to have a different command set (and
also bar { colors { } }.
2015-11-29 17:20:27 -05:00
Drew DeVault
4f89735fc4
Add bar config struct and defaults
2015-11-29 17:05:04 -05:00
Christoph Gysin
b1bd3ae6f3
cmd_output: Merge instead of replace output config
2015-11-29 23:17:56 +02:00
Drew DeVault
5a369b3132
Only strip comments at the start of a line
...
This is necessary because i3 config files use CSS notation for colors
(i.e. #rrggbb).
2015-11-29 14:02:58 -05:00
Christoph Gysin
ffdfaaa985
apply_output_config: use list_seq_find() to find config
2015-11-29 15:31:58 +02:00
Christoph Gysin
7d82cd9c0a
cmd_output: Use list_seq_find() to find matching config
2015-11-29 15:29:06 +02:00
Drew DeVault
1661edee28
Allow output config for output named *
...
Which will match any output.
2015-11-28 10:18:37 -05:00
Drew DeVault
2f192cceca
Improve config file loading
...
This also makes it so that your i3 config is used before
/etc/sway/config.
2015-11-28 10:00:53 -05:00
Christoph Gysin
e362f871d9
Call swaybg without invoking a shell
...
This makes escaping the arguments obsolete.
Also avoid dynamic memory allocation for the output id. It only supported ids up
to 99. Now we support up to 999, and take 4 bytes off the stack instead.
2015-11-25 23:19:11 +02:00