Commit graph

572 commits

Author SHA1 Message Date
Daniel Eklöf
221a6809c0 wip: man pages 2019-04-21 11:49:33 +02:00
Daniel Eklöf
879d5cefb1 wayland: HiDPI: initial support for HiDPI displays
We do it differently from everybody else...

A traditional HiDPI implementation typically scales up
everything. I.e. if the user wants a 1px border, it's scaled up to
2px. The wayland server typically presents an output width/height that
has been scaled *down*.

This is all a bit backwards, but perhaps was the best choice to make
legacy applications at least work.

f00bar on the other hand, wants to give the user absolute
control. Thus, we don't scale up at all. If the user wants a 25px bar
height, that's what he gets.

This does mean however, that we need to scale *down* the surface size
since it's in logical pixels, not physical.

So we scale *down* the surface size (which then gets scaled back up by
the wayland server), and then render everything *on* that surface
without any scaling.
2019-04-15 11:08:38 +02:00
Daniel Eklöf
89d9f15f59 PKGBUILD: alternative PKGBIULD that configures f00bar for wayland only 2019-03-31 14:45:19 +02:00
Daniel Eklöf
a8370d08d5 PKGBUILD: f00bar is both X11 and Wayland compatible 2019-03-31 14:44:13 +02:00
Daniel Eklöf
902245da7a PKGBUILD: i3-wm is no longer a dependency 2019-03-31 14:23:47 +02:00
Daniel Eklöf
aac2a81c2b ci: i3wm-dev shouldn't be needed anymore; we use our own i3/ipc.h 2019-03-31 12:10:26 +02:00
Daniel Eklöf
7dc5694965 module/i3: use our own copy of i3/ipc.h
The main advantage is when targeting sway/wayland instead of i3/x11;
sway doesn't package ipc.h. There *is* an ipc.h in the sway sources,
but it doesn't define e.g the header format, and has different names
for the constants.
2019-03-31 12:08:44 +02:00
Daniel Eklöf
065c40a9e6 ci: looks like i3wm packages has been split up into i3wm and i3wm-dev 2019-03-31 12:00:10 +02:00
Daniel Eklöf
0aee7befd8 bar/wayland: better name for SHM backing memfd 2019-03-30 22:24:13 +01:00
Daniel Eklöf
fa586b9ac1 wayland: depend on xdg-output for output size/positioning information 2019-03-14 19:41:06 +01:00
Daniel Eklöf
2123956b14 particle: refactor command line tokenization 2019-03-07 21:31:30 +01:00
Daniel Eklöf
67e12e8d1e bump wlr-protocols 2019-03-06 20:17:03 +01:00
Daniel Eklöf
6030ef5298 bar/wayland: use cairo_format_stride_for_width() to calculate stride 2019-03-03 12:56:13 +01:00
Daniel Eklöf
cf680573c2 particle/string: improve font centering
* Use ascent+descent instead of 'height'
* Center around 'ascent', except when 'descent' is negative
2019-03-01 17:55:05 +01:00
Daniel Eklöf
611b5b551c particle/string: use *font* extents to calculate font baseline 2019-02-28 20:10:54 +01:00
Daniel Eklöf
ea38ab3b2f particle/module: pass a cairo context to all begin_expose() 2019-02-28 20:10:26 +01:00
Daniel Eklöf
35e9d0e25c bar: need to double border size (why?) 2019-02-28 20:09:50 +01:00
Daniel Eklöf
cd28099ad8 module/i3: don't try to strdup() a NULL pointer 2019-02-20 18:21:58 +01:00
Daniel Eklöf
fe709bd82b Revert "bar/wayland: drop wl_seat interface version requirement to 1"
This reverts commit a1bcf07599.
2019-02-18 21:43:44 +01:00
Daniel Eklöf
b4845a55fe module/i3: remove even more IPC related json error messages 2019-02-17 21:53:01 +01:00
Daniel Eklöf
11eff5b13b module/i3: one more malformed IPC error message removed 2019-02-17 21:51:48 +01:00
Daniel Eklöf
fd955fa3ac module/i3: use json_object_object_get_ex()
json_object_object_get() is deprecated.

At the same time, simplify code by removing error messages; it's
not *our* problem if someone is sending malformed IPC replies.
2019-02-17 21:50:01 +01:00
Daniel Eklöf
546a4b5009 module/i3: improve window event handling
* Only care about 'close', 'focus' and 'title' events
* Remove application/title on 'close'
* Ignore 'title' events if it's not for the currently active
  window (from the last 'focus' event)

This fixes an issue where we rendered a 'title' event just like a
focus event. Meaning that a non-focused window, perhaps even on a
different workspace, that changed its title, would cause us to refresh
with its title being used.
2019-02-17 20:05:44 +01:00
Daniel Eklöf
f959d96c17 module/i3-common: add LOG_ENABLE_DBG define, but leave it disabled 2019-02-17 20:05:30 +01:00
Daniel Eklöf
c2ea1c5a59 Merge branch 'surface-margins' 2019-02-17 19:48:37 +01:00
Daniel Eklöf
28d39f3aec bar/xcb: ignore non-zero border margins 2019-02-17 19:45:26 +01:00
Daniel Eklöf
0ab772f869 bar: move x,y coordinates to xcb backend 2019-02-17 19:40:20 +01:00
Daniel Eklöf
3d8cb7f17e bar/wayland: implement border margins 2019-02-17 15:47:44 +01:00
Daniel Eklöf
cb0c43a61b README: update bar configuration properties 2019-02-17 15:47:29 +01:00
Daniel Eklöf
9c611a716b config: make border.width and border.color optional 2019-02-17 15:47:13 +01:00
Daniel Eklöf
50d6afab6a bar: add margin properties to the border 2019-02-17 15:45:02 +01:00
Daniel Eklöf
12ef2569a4 bar/wayland: log *something* when a global is removed 2019-02-17 12:38:52 +01:00
Daniel Eklöf
a1bcf07599 bar/wayland: drop wl_seat interface version requirement to 1
This allows us to drop the empty 'name' handler.
2019-02-17 12:38:52 +01:00
Daniel Eklöf
620d89319b module/i3: reset current window info on a "floating" window event 2019-02-17 12:32:27 +01:00
Daniel Eklöf
272a1bd2ed cmake: link i3-common against json and xcb-stuff 2019-02-15 22:48:01 +01:00
Daniel Eklöf
db211de70c modules/i3-common: add support for sway's IPC_GET_INPUTS 2019-02-15 22:30:12 +01:00
Daniel Eklöf
e710152248 Merge branch 'i3-split' 2019-02-15 22:08:06 +01:00
Daniel Eklöf
06ae704ded module/i3-commonh: I3_IPC_REPLY_TYPE_SYNC is relatively new
And is for example not present in our CI.
2019-02-15 22:06:24 +01:00
Daniel Eklöf
e40b50bf5e module/i3-common: add missing include
Needed for e.g strncpy() and strcmp()
2019-02-15 22:06:03 +01:00
Daniel Eklöf
ae7f554b8c module/i3: only call bar->refresh() from burst_done() callback
IPC reply and event handlers no longer call bar->refresh()
directly. Instead, they set a 'dirty' bit. Then, in burst_done(), we
call bar->refresh() when the dirty bit has been set.
2019-02-15 22:01:58 +01:00
Daniel Eklöf
f9044ec883 module/i3: add a 'burst_done()' callback
This callback is called after all received packets have been
processed, before going into a blocking poll() again.
2019-02-15 22:01:07 +01:00
Daniel Eklöf
5e97c77c24 module/i3: remove unneeded includes 2019-02-15 20:58:43 +01:00
Daniel Eklöf
e36ba56caf module/i3-common: being disconnected is usually not an error 2019-02-15 20:57:31 +01:00
Daniel Eklöf
fce37e86e4 module/i3: break out I3 IPC receive loop 2019-02-15 18:58:21 +01:00
Daniel Eklöf
6df68f1c23 module/i3-common: const:ify 2019-02-13 22:00:42 +01:00
Daniel Eklöf
92319714c7 module/i3: break out send_pkg() 2019-02-13 22:00:13 +01:00
Daniel Eklöf
76dc4f82cd module/i3-common: always disconnect from XCB on error 2019-02-13 21:58:20 +01:00
Daniel Eklöf
37d15096f9 module/i3: break out get_socket_address() 2019-02-13 21:55:03 +01:00
Daniel Eklöf
6e44d8e04e module/i3: fix crash when there is no "current" workspace template 2019-02-13 21:46:30 +01:00
Daniel Eklöf
4d9ee6ff82 cmake: use find_program() to locate wayland-scanner binary 2019-02-13 21:45:31 +01:00