Commit Graph

58 Commits

Author SHA1 Message Date
Jérôme BOULMIER
5e5d8faf04 fix(command): broken pipe when ignoring output. 2020-05-08 23:24:29 +02:00
patrick96
587dc6c84d bar: Make module separator a label
Some people use text modules instead of the `separator` key in the bar
section to better configure the separator (colors, fonts).
Since we disallowed the same module being used multiple times in #1534,
this will now print an error message.

This should help with this a bit.

Ref #1913
2019-10-27 16:02:33 +01:00
patrick96
211b0bbfd8 Incorporate Reviews 2019-08-06 21:36:20 +02:00
patrick96
57d364a2fc Reset all tags at the end of a module
The %{PR} tag is introduced for this. It resets all colors as well as
the activation of the underline and overline and font.

This has become necessary because we don't track what raw tags a user
injects into the formatting string and otherwise their raw tags could
bleed through.

This doesn't touch action tags because even before raw action tags
weren't being tracked. Action tags also have the requirement that they
have to be used in pairs, so closing them prematurely could break things
(for example with click actions for the entire bar)
2019-08-06 21:36:20 +02:00
patrick96
b3ceedde76 refactor(bar): Remove bar_settings.center
Not used anywhere
2019-02-05 11:50:25 +01:00
patrick96
4a506d429d xbacklight: Use monitor-strict from bar settings
monitor-strict in the xbacklight module was never documented anywhere so
it's fine to remove it.
2019-01-08 17:23:28 +01:00
patrick96
e793082008 randr: Add separate key for exact monitor matching
This adds `monitor-exact = true` in the bar section

This also properly does best-match instead of first-match if multiple
matches exists. For example if there are two monitors HDMI2 and HDMI-2
and we try to match HDMI-2 with monitor-exact = false, until now HDMI2
would be matched. Now exact matches are always preferred.

Fixes #1532
2019-01-08 17:23:28 +01:00
Benno Fünfstück
eb742e228b fix(render): correctly handle semi-transparency for borders
We need to fetch the outer area from the root window, not just the inner area
because we paint the background below the borders as well.

This has the nice effect of supporting semi-transparency for borders as well.
2018-10-04 15:52:03 +02:00
NBonaparte
65edba3321 feat: add cursor change 2017-09-16 15:31:24 -07:00
Patrick Ziegler
9b98b766b2 Fix off by one error for action area (#663)
If the mouse was at the leftmost edge of the screen and there was an
action area from 0 to N, the click wouldn't register

Before if an action area was defined from A to B it was from A exclusive
to B inclusive now it is from A inclusive to B exclusive. This is the
same way that the pixel addresses work, since a pixel's coordinate is
defined by the top-left corner.

Fixes #661
2017-08-29 11:58:23 -07:00
Michael Carlberg
f3089e88f2 feat(conf): Properties for top/bottom radius #445 2017-03-21 14:49:33 +01:00
Michael Carlberg
8b9461e63e wip(refactor): Cairo drawing 2017-01-24 07:41:46 +01:00
Michael Carlberg
a59e115622 wip(refactor): Cairo drawing 2017-01-24 07:11:14 +01:00
Michael Carlberg
452afcdc68 refactor: Integral types 2017-01-24 07:11:14 +01:00
Michael Carlberg
5e1886a312 wip(refactor): Cairo drawing 2017-01-24 07:11:14 +01:00
Michael Carlberg
16a355a2b7 fix(config): Remove default value for module-margin-right 2017-01-12 17:42:09 +01:00
Michael Carlberg
30f516dd7d fix(formatting): Make formats parse specs as-is
This removes the spacing tinkering when parsing format specs.
The following example uses the old behavoir:

    format-test = <label-foo>  <label-bar>
    format-breaks = <label-foo><label-bar>/<bar-test>

`format-test` would replace all occurences of ' ' with the
a space string with defined `spacing` as its width. `format-breaks` would
not validate as the tags where split with ' ' as delimiter.

All that nonsense has been removed and each tag is extracted as is.
The `spacing` parameter can still be used to apply N extra whitespaces
between the tags, but it is now 0 by default.
2017-01-11 02:43:37 +01:00
Michael Carlberg
18cf9df86c refactor: Cleanup 2016-12-27 04:58:41 +01:00
Michael Carlberg
11aabac227 refactor(connection: Use custom base 2016-12-26 09:46:48 +01:00
Michael Carlberg
185363056a refactor(x11): Cleanup 2016-12-21 15:04:16 +01:00
Michael Carlberg
81e6fb062f wip: Window autohide 2016-12-21 04:50:43 +01:00
Michael Carlberg
8ef8900ca2 refactor: Defer buttonpress using taskqueue 2016-12-20 13:03:46 +01:00
Michael Carlberg
ccbb38798d fix(bar): Action x values should not be volatile 2016-12-20 07:46:51 +01:00
Michael Carlberg
1cccd100bb fix(bar): Remove double click 2016-12-20 07:46:30 +01:00
Michael Carlberg
8ed4de1dda fix: Use enum_hash for unordered_map 2016-12-20 02:29:18 +01:00
Michael Carlberg
a7005be82c feat: Fade if unfocused and handle double clicks 2016-12-16 06:44:55 +01:00
Michael Carlberg
9f9f438fae refactor: Remove last usage of boost::optional
Since it's the only thing boost was used for at the moment
we drop it to be able to get rid of a dependency.
2016-12-15 17:13:16 +01:00
Michael Carlberg
f9062d031c refactor(clang-tidy): Apply fixes 2016-12-15 03:30:41 +01:00
Michael Carlberg
08be86fbe1 wip(refactor): Improve signal and event handling 2016-12-14 11:01:44 +01:00
Michael Carlberg
ec39859093 feat: Window click handlers
New parameters for defining fallback click handlers
that will be triggered for the whole window unless
a module action is matched.

Parameters added to all [bar/foo] sections:

- `click-left = ...`
- `click-middle= ...`
- `click-right= ...`
- `scroll-up= ...`
- `scroll-down= ...`

Ref #226
2016-12-05 13:17:15 +01:00
Michael Carlberg
9eee27544d fix(renderer): Improve precision when shifting action blocks
Fixes #220
2016-12-04 13:50:30 +01:00
Michael Carlberg
9f16e3fff7 refactor: Rename dock to override-redirect 2016-12-03 23:21:40 +01:00
Michael Carlberg
608519363d feat(xkeyboard): New module
New module that uses the X keyboard extension
to show keyboard layout and indicators.

Ref #84, #200
2016-11-30 10:08:44 +01:00
Michael Carlberg
9f4638f42c refactor: Cleanup 2016-11-26 06:13:20 +01:00
Michael Carlberg
9fdc22843b refactor: Cleanup rendering 2016-11-25 04:42:27 +01:00
Michael Carlberg
84d58e7619 refactor: Cleanup handling of syntax tags 2016-11-25 04:34:24 +01:00
Michael Carlberg
09e0ea1932 config: Print deprecation warnings 2016-11-22 03:01:50 +01:00
Michael Carlberg
0c64b64ff8 refactor: Cleanup 2016-11-22 01:22:47 +01:00
Michael Carlberg
83ef8bcd0c fix(build): Size type 2016-11-21 16:32:56 +01:00
Michael Carlberg
ebf1bd1129 feat: Support different under-/overline
Make it possible to set different size
and color values for the two properties.

`overline-size = 2`
`overline-color = #f00`
`underline-size = 5`
`underline-size = #00f`
2016-11-21 16:16:06 +01:00
Michael Carlberg
25e33b6aab refactor: Separate render component 2016-11-21 16:16:02 +01:00
Michael Carlberg
fd57ab0f3d fix: project rename 2016-11-19 06:26:07 +01:00
Michael Carlberg
70a5f1d41e fix: Bottom strut relative to screen 2016-11-15 02:28:42 +01:00
Michael Carlberg
c480f6fd1e refactor: Move strut handling to window class 2016-11-13 16:10:20 +01:00
Michael Carlberg
4224d838a8 refactor(bar): Strut values based on EMWH spec 2016-11-13 13:25:57 +01:00
Michael Carlberg
23996fdcdc refactor: Tray transparency and code cleaning
- Make pseudo-transparency work as intended, fixes #158
- Fill tray pixmap in case a root pixmap is not found
- Split up bar bootstrap routine
- Formatting (clang-format)
2016-11-12 13:09:50 +01:00
Michael Carlberg
ae501d6ae1 fix(tray): Support for pseudo transparency
Copy contents from the root pixmap onto the background

Fixes #125
2016-11-04 19:01:51 +01:00
Michael Carlberg
e7cb345cec wip: Separate source from definitions 2016-11-03 12:54:32 +01:00
Michael Carlberg
94298741b6 tray: Align center and extend configuration
- The tray can now be centered in the bar
- Set window atoms:
  * _NET_SYSTEM_TRAY_COLORS
  * _NET_SYSTEM_TRAY_VISUAL
- New parameters added:
  * tray-background: Define background color
  * tray-offset-x: X position offset
  * tray-offset-y: Y position offset
  * tray-padding: Add spacing on the side of each icon
  * tray-maxsize: Size limit for tray icons, default: 16
  * tray-scale: Icon zoom, default: 1.0
  * tray-detached: The bar will ignore tray updates
2016-10-31 01:41:15 +01:00
Michael Carlberg
eac65cdabb fix(cmake): Make specific c++lib linking optional
- Do not enforce linking against libc++
- Fix various linter warnings
2016-10-25 20:47:53 +02:00