]> git.mdlowis.com Git - proto/labwc.git/commitdiff
action: rename "omnipresent" button options for Openbox compatibility
authorAndrew J. Hesford <ajh@sideband.org>
Sun, 25 Aug 2024 04:00:24 +0000 (00:00 -0400)
committerConsolatis <35009135+Consolatis@users.noreply.github.com>
Sun, 25 Aug 2024 05:22:23 +0000 (07:22 +0200)
- Mouse context "Omnipresent" -> "AllDesktops"
- Theme elements "window.*.button.omnipresent" -> "window.*.button.desk"
- Update documentation accordingly

docs/labwc-config.5.scd
docs/labwc-theme.5.scd
docs/rc.xml.all
include/config/default-bindings.h
src/config/mousebind.c
src/theme.c

index a5864974716e5ff5668a794aad0f018b475b403d..7436fc5f897f6900aeb0a2ead6aeaae5ced952da 100644 (file)
@@ -439,10 +439,10 @@ extending outward from the snapped edge.
        - |: empty space (can be used instead of a title)
        - W: window menu
        - I: iconify
-       - M: maximize
+       - M: maximize toggle
        - C: close
-       - S: shade
-       - D: omnipresent
+       - S: shade toggle
+       - D: all-desktops toggle
 
        Example: WLIMC
 
@@ -618,7 +618,7 @@ extending outward from the snapped edge.
        - Iconify: A button that, by default, iconifies a window.
        - Maximize: A button that, by default, toggles maximization of a window.
        - Shade: A button that, by default, toggles window shading.
-       - Omnipresent: A button that, by default, toggles omnipresence of a window.
+       - AllDesktops: A button that, by default, toggles omnipresence of a window.
        - Close: A button that, by default, closses a window.
        - Top: The top edge of the window's border.
        - Bottom: The bottom edge of the window's border.
index 9f8310affba6f99c3da787bbd363ae6abb38db6a..57957dc5123a77b25e8981e9d0c8baae50f3a8ad 100644 (file)
@@ -130,13 +130,19 @@ labwc-config(5).
        Color of the images in titlebar buttons in their default, unpressed,
        state. This element is for non-focused windows.
 
-Note: The button elements (i.e. window.[in]active.button.\*) support defining
-different types of buttons individually by inserting the type ("menu",
-"iconify", "max" and "close") after the button node. For example:
-window.active.button.iconify.unpressed.image.color
-This syntax is not documented on the openbox.org wiki, but is supported by
-openbox and is used by many popular themes. For the sake of brevity, these
-elements are not listed here, but are supported.
+Note: Button elements (i.e. window.[in]active.button.\*) may be defined uniquely
+for each type of button ("menu", "iconify", "max", "shade", "desk" or "close")
+by appending the type after the "button" node. For example:
+
+- window.active.button.iconify.unpressed.image.color indicates the color of the
+iconify button for active windows; while
+
+- window.inactive.button.close.unpressed.image.color indicates the color of the
+close button for inactive windows.
+
+This syntax is not documented by Openbox, but is supported and is used by many
+popular themes. For the sake of brevity, these elements are not listed here, but
+all are supported.
 
 *window.active.shadow.size*
        Size of the drop-shadow for the focused window, in pixels.
index d0df9760fbe4f837317a0eb186f3b655362aaaee..f7bba9988b77dd37e6baa967609b1a9cef4b1902 100644 (file)
       </mousebind>
     </context>
 
-    <context name="Omnipresent">
+    <context name="AllDesktops">
       <mousebind button="Left" action="Click">
         <action name="ToggleOmnipresent" />
       </mousebind>
index 1be873ff2c9eff02f9a298f9b02351b28e5a0019..46a3819e8965f378c4321779279ca2945aa206fa 100644 (file)
@@ -328,7 +328,7 @@ static struct mouse_combos {
                .event = "Click",
                .action = "ToggleShade",
        }, {
-               .context = "Omnipresent",
+               .context = "AllDesktops",
                .button = "Left",
                .event = "Click",
                .action = "ToggleOmnipresent",
index 82f4c6d6b249cb373fdb7f77348dc2fc6afaf15f..dc3dfb65092035479f467a6e57570032d90a812f 100644 (file)
@@ -116,7 +116,7 @@ context_from_str(const char *str)
                return LAB_SSD_BUTTON_WINDOW_MENU;
        } else if (!strcasecmp(str, "Shade")) {
                return LAB_SSD_BUTTON_SHADE;
-       } else if (!strcasecmp(str, "Omnipresent")) {
+       } else if (!strcasecmp(str, "AllDesktops")) {
                return LAB_SSD_BUTTON_OMNIPRESENT;
        } else if (!strcasecmp(str, "Titlebar")) {
                return LAB_SSD_PART_TITLEBAR;
index 94ba0a0bb7b14879625c099fb823e8bbc4ebd757..284089900534ab849256d98dcb2731abbc06b9cb 100644 (file)
@@ -793,7 +793,7 @@ entry(struct theme *theme, const char *key, const char *value)
                parse_hexstr(value,
                        theme->window_active_button_shade_unpressed_image_color);
        }
-       if (match_glob(key, "window.active.button.omnipresent.unpressed.image.color")) {
+       if (match_glob(key, "window.active.button.desk.unpressed.image.color")) {
                parse_hexstr(value,
                        theme->window_active_button_omnipresent_unpressed_image_color);
        }
@@ -817,7 +817,7 @@ entry(struct theme *theme, const char *key, const char *value)
                parse_hexstr(value,
                        theme->window_inactive_button_shade_unpressed_image_color);
        }
-       if (match_glob(key, "window.inactive.button.omnipresent.unpressed.image.color")) {
+       if (match_glob(key, "window.inactive.button.desk.unpressed.image.color")) {
                parse_hexstr(value,
                        theme->window_inactive_button_omnipresent_unpressed_image_color);
        }