Commit graph

37 commits

Author SHA1 Message Date
sghctoma
073dcb3a86 Change _XOPEN_SOURCE defines to _POSIX_C_SOURCE 2018-09-03 09:08:49 +02:00
sghctoma
cc16948c85 Fix feature macros for FreeBSD
On FreeBSD, snprintf and vsnprintf are visible only if
_XOPEN_SOURCE >= 600.
2018-08-30 09:34:26 +02:00
Ryan Dwyer
255dc8bbb0 swaybar: Read urgent colors from IPC 2018-07-17 08:29:43 +10:00
emersion
63b4bf5000
Update for swaywm/wlroots#1126 2018-07-09 22:54:30 +01:00
emersion
aa36899d8a
Fix a bunch of swaybar memory leaks 2018-04-24 22:28:55 +01:00
db
39e3319394 fix swaybar ipc handling
Swap return with break in IPC_EVENT_WORKSPACE case to free resp.

Change default return value to true. This causes IPC_EVENT_MODE changes to be
rendered instantly.
2018-04-10 22:01:22 +02:00
Drew DeVault
efac07db5f Fix workspaces not updated on swaybar 2018-04-06 09:43:52 -04:00
Drew DeVault
f242362e7e Handle output removal on swaybar 2018-04-05 16:04:30 -04:00
Drew DeVault
333dbcbe72 Render i3bar blocks 2018-04-02 11:09:23 -04:00
Drew DeVault
ae14dfc7ae Implement scroll wheel workspace switching 2018-03-30 22:44:08 -04:00
Drew DeVault
2a90d26ebe Fix issues with swaybar on DRM 2018-03-30 00:30:38 -04:00
Drew DeVault
b72825441b Fixed laggy focused output boolean 2018-03-29 22:11:08 -04:00
Drew DeVault
1e8faeec02 Pixel-perfect rendering 2018-03-29 22:11:08 -04:00
Drew DeVault
37b61eff2d Add binding mode indicator 2018-03-29 22:11:08 -04:00
Drew DeVault
86ba0fc15d Re-render bar on IPC updates 2018-03-29 22:11:08 -04:00
Drew DeVault
3399ad9840 Round up workspaces on each output 2018-03-29 22:11:08 -04:00
Drew DeVault
e5e8094dc3 Only utilize the configured outputs 2018-03-29 22:11:08 -04:00
Drew DeVault
5c9ad035db Wire up basic IPC support 2018-03-29 22:11:08 -04:00
Drew DeVault
cab1352801 Start port of swaybar to layer shell
This starts up the event loop and wayland display and shims out the
basic top level rendering concepts. Also includes some changes to
incorporate pango into the 1.x codebase properly.
2018-03-29 22:11:08 -04:00
Calvin Lee
843ad38b3c Implement Tray Icons
This commit implements the StatusNotifierItem protocol, and enables
swaybar to show tray icons. It also uses `xembedsniproxy` in order to
communicate with xembed applications.
The tray is completely optional, and can be disabled on compile time
with the `enable-tray` option. Or on runtime with the bar config option
`tray_output none`.

Overview of changes:
In swaybar very little is changed outside the tray subfolder except
that all events are now polled in `event_loop.c`, this creates no
functional difference.

Six bar configuration options were added, these are detailed in
sway-bar(5)

The tray subfolder is where all protocol implementation takes place and
is organised as follows:

tray/sni_watcher.c:
	This file contains the StatusNotifierWatcher. It keeps track of
	items and hosts and reports when they come or go.
tray/tray.c
	This file contains the StatusNotifierHost. It keeps track of
	sway's version of the items and represents the tray itself.
tray/sni.c
	This file contains the StatusNotifierItem struct and all
	communication with individual items.
tray/icon.c
	This file implements the icon theme protocol. It allows for
	finding icons by name, rather than by pixmap.
tray/dbus.c
	This file allows for asynchronous DBus communication.

See #986 #343
2017-06-07 17:49:16 -07:00
Drew DeVault
9aed9d9359 UnGNUify the codebase 2017-03-10 23:41:24 -05:00
Drew DeVault
9ad1e6b40f Handle malloc failure in ipc_recv_response 2016-12-15 19:01:40 -05:00
D.B
ad4d21d60b add bar colours for focused_(workspace|statusline|separator)
If these aren't defined in config, color settings without 'focused_'
prefix are used as a fallback.
2016-11-02 18:58:33 +01:00
Ryan Dwyer
e4cb4d1b5c Fix swaybar when running on named outputs.
When using a bar on a named output, load_swaybars() requires the
output to be active (ie. in the root container), but this is not the case if
the bar is added to the last output. To fix this, load_swaybars() is now
called after the output has been added to the root container.

After fixing that, swaybar would segfault due to using the wrong index
variable when loading outputs and config.
2016-09-17 17:25:45 +10:00
D.B
c239f228c2 swaybar sends workspace name in quotes
fixes #894
2016-09-12 06:58:53 +02:00
Drew DeVault
416417a54c Reorganize includes 2016-09-01 08:18:37 -04:00
Drew DeVault
3bb880bf20 Implement configurable wrapping on bar ws scroll 2016-07-17 11:26:38 -04:00
David Eklov
8a232c8cfd Send command to sway to change workspace when workspace button is clicked 2016-07-14 17:18:01 -05:00
David Eklov
a0c8799c80 Compute what workspace button is clicked
This commit does not do anything with this information other than logging it.
2016-07-14 17:18:01 -05:00
Mykyta Holubakha
0f1cfdec61 Renamed to pango_markup 2016-04-24 20:35:21 +03:00
Mykyta Holubakha
2e6c43e62b Added plaintext_markup to swaybar IPC 2016-04-24 20:14:02 +03:00
Mikkel Oscar Lyderik
e4c1176b72 Differentiate between all or no outputs 2016-02-27 22:12:35 +01:00
Mikkel Oscar Lyderik
6d57f03028 Make single bar handle multiple outputs 2016-02-27 22:12:35 +01:00
Mikkel Oscar Lyderik
ed227f5664 swaybar: move headers to include/bar 2016-01-24 15:55:58 +01:00
Mikkel Oscar Lyderik
aa6ad09183 swaybar: rename state to bar 2016-01-24 14:22:19 +01:00
Mikkel Oscar Lyderik
6140f9c42c swaybar: Move swaybar_teardown to free_state 2016-01-24 14:22:19 +01:00
Mikkel Oscar Lyderik
fcc47cb3bd swaybar: move ipc stuff to ipc.{h,c} 2016-01-24 14:22:19 +01:00