mirror of
https://github.com/labwc/labwc.git
synced 2025-11-01 22:58:47 -04:00
osd: add window-switcher custom field (#1670)
Add custom field with subset of printf style formatting
to replace the original field formats.
Example:
<windowSwitcher preview="no" outlines="no" allWorkspaces="yes">
<fields>
<field content="custom" format="foobar %b %3s %-10o %-20W %-10i%t" width="100%" />
</fields>
</windowSwitcher>
Mono space font recommended. May need OSD width adjusted
Co-authored-by: @Consolatis (based on work done by them)
This commit is contained in:
parent
2bf285a2c6
commit
d672765ea7
13 changed files with 490 additions and 191 deletions
|
|
@ -15,18 +15,6 @@
|
|||
#include "resize_indicator.h"
|
||||
#include "theme.h"
|
||||
|
||||
enum window_switcher_field_content {
|
||||
LAB_FIELD_NONE = 0,
|
||||
LAB_FIELD_TYPE,
|
||||
LAB_FIELD_IDENTIFIER,
|
||||
LAB_FIELD_TRIMMED_IDENTIFIER,
|
||||
LAB_FIELD_TITLE,
|
||||
LAB_FIELD_WORKSPACE,
|
||||
LAB_FIELD_WIN_STATE,
|
||||
LAB_FIELD_TYPE_SHORT,
|
||||
LAB_FIELD_OUTPUT,
|
||||
};
|
||||
|
||||
enum view_placement_policy {
|
||||
LAB_PLACE_CENTER = 0,
|
||||
LAB_PLACE_CURSOR,
|
||||
|
|
@ -53,12 +41,6 @@ struct usable_area_override {
|
|||
struct wl_list link; /* struct rcxml.usable_area_overrides */
|
||||
};
|
||||
|
||||
struct window_switcher_field {
|
||||
enum window_switcher_field_content content;
|
||||
int width;
|
||||
struct wl_list link; /* struct rcxml.window_switcher.fields */
|
||||
};
|
||||
|
||||
struct rcxml {
|
||||
/* from command line */
|
||||
char *config_dir;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue