polybar-dwm/include
patrick96 5be532c51b refactor(font): More robust font size calculation
Originally the size function returned the scaled `size` property for
scalable fonts and the non-scaled `pixelsize` property for non-scalable
fonts. This caused lots of issues when that property was 0 (empty bars,
characters not drawn without warning, see references at the bottom).
This behavior was mostly observed on debian where `size` is set to 0 if
`pixelsize` is set.

We now try to use both properties for both types, but prefering `size`
for scalable fonts and `pixelsize` for non-scalable ones.

This behavior doesn't break existing correct behavior but now never
returns 0. It will always try to fall back to the other property or to
some fallback value if both properties are 0.

I originally thought this could also make font patterns more expressive
by being able to specify the size of scalable fonts directly in pixels
like so:

  Unifont:size=0:pixelsize=20

or to scale non-scalable fonts by forcing polybar to fall back to the
`size` property (which is always scaled):

  Wuncon Siji:pixelsize=0:size=20

But how these two patterns are matched by `fc-match` depends both on the
font and on the distro/fontconfig setup.

Ref #706
Ref #1450
Ref #1257
2019-06-03 00:49:48 +02:00
..
adapters feat(net): Support bridge interfaces (#1528) 2018-11-28 16:09:00 +01:00
cairo refactor(font): More robust font size calculation 2019-06-03 00:49:48 +02:00
components refactor: Remove all mentions of icon_t 2019-04-08 09:01:48 +02:00
drawtypes refactor: Remove all mentions of icon_t 2019-04-08 09:01:48 +02:00
events signal_emitter: Don't swallow exceptions 2019-02-05 11:50:57 +01:00
modules feat(battery): add %percentage_raw% token (#1756) 2019-05-14 15:01:54 +02:00
utils fix(tray): fix offset for negative percentage (#1669) 2019-03-22 09:55:08 +01:00
x11 build: remove xdamage extension 2019-06-03 00:46:12 +02:00
CMakeLists.txt build: remove xdamage extension 2019-06-03 00:46:12 +02:00
common.hpp refactor(build): Remove version number namespace 2019-05-17 16:49:47 +02:00
debug.hpp refactor: Cleanup 2017-01-11 03:07:28 +01:00
errors.hpp refactor: Move all event handling to the controller 2016-12-20 05:16:04 +01:00
settings.hpp.cmake build: remove xdamage extension 2019-06-03 00:46:12 +02:00