- Ported d-bus specific code from 'libdbus' to 'sd-bus'
- 'sd_bus' has been added to mesons dependencies. If systemd (>=221) is
not installed, we fall back to [basu](https://git.sr.ht/~emersion/basu)
v2.1
- Fixed a memory leak upon metadata change
This commit adds the ability to display status information for MPRIS
compatible music players.
I've adapted most of the naming conventions (and some code) from the
MPD module.
This patch adds an inheritable option, “font-shaping”, that controls
whether a particle that renders text should enable font-shaping or
not.
The option works similar to the ‘font’ option: one can set it at the
top-level, and it gets inherited down through all modules and to their
particles.
Or, you can set it on a module and it gets inherited to all its
particles, but not to other modules’ particles.
Finally, you can set it on individual particles, in which case it only
applies to them (or “child” particles).
When font-shaping is enabled (the default), the string particle shapes
full text runs using the fcft_rasterize_text_run_utf32() API. In fcft,
this results in HarfBuzz being used to shape the string.
When disabled, the string particle instead uses the simpler
fcft_rasterize_char_utf32() API, which rasterizes individual
characters.
This gives user greater control over the font rendering. One example
is bitmap fonts, which HarfBuzz often doesn’t get right.
Closes#159
New FreeBSD versions have memfd_create but other BSDs don't.
bar/wayland.c:774:15: error: implicit declaration of function 'memfd_create' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
pool_fd = memfd_create("yambar-wayland-shm-buffer-pool", MFD_CLOEXEC);
^
bar/wayland.c:774:62: error: use of undeclared identifier 'MFD_CLOEXEC'
pool_fd = memfd_create("yambar-wayland-shm-buffer-pool", MFD_CLOEXEC);
^
Without this change yambar can't be installed/used without libmpdclient even for
people who do not use MPD. Let's make this optional.
We could put the optional module summary in the module meson.build but we'd have
to move summary() in main meson.build so that they appear in proper order.
Previously, only the date command inside the script was run with
LC_TIME=C.
But there’s no reason to be that conservative; we absolutely do not
want _anything_ in that script to generate locale dependent output.
This enables support for text shaping, and is required to render
e.g. 👩👩👧👧 correctly.
Since text-shaping is a fairly expensive operation, and since many
times the text is unchanged, we cache the last *rendered* string.
That is, we hash the instantiated string, and cache it along with the
text-run from fcft in the *particle* object (i.e. not the exposable).
This means two things:
* we only need to call fcft_text_run_rasterize() once per string
* if the string is the same as last time, we don’t have to call it at
all.