[gsettings-desktop-schemas] schemas: Add tablet/stylus/pad schemas
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gsettings-desktop-schemas] schemas: Add tablet/stylus/pad schemas
- Date: Fri, 22 Jul 2016 11:44:37 +0000 (UTC)
commit ddd425ba00ec1c62ced3e4815e3bb81f8b5dcb75
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed May 4 13:42:17 2016 +0200
schemas: Add tablet/stylus/pad schemas
Compared to the g-s-d schemas, there's a few notable differences:
- There are no compositor actions for rings/strips, with the libinput
driver this is rather seen as a continuous axis, so we can't tell
much about how it's being made discrete. It is preferred that clients
manage the related pad events.
- Tablet area is interpreted as an array of four 0..1 doubles, being
each of those the padding on one side, relative to the full output
size. We can no longer use values relative to the device resolution,
because it might not be available.
- Button mapping has been split into "primary" and "secondary"
button settings, rather than an array of button numbers. The allowed
values are now an enum, as button numbers are troublesome (especially
the [4-7] scrolling button range, which can't be made to work on
wayland)
https://bugzilla.gnome.org/show_bug.cgi?id=769034
headers/gdesktop-enums.h | 24 +++++++++
.../org.gnome.desktop.peripherals.gschema.xml.in | 54 ++++++++++++++++++++
2 files changed, 78 insertions(+), 0 deletions(-)
---
diff --git a/headers/gdesktop-enums.h b/headers/gdesktop-enums.h
index 2ddca49..da16f27 100644
--- a/headers/gdesktop-enums.h
+++ b/headers/gdesktop-enums.h
@@ -184,4 +184,28 @@ typedef enum
G_DESKTOP_DEVICE_SEND_EVENTS_DISABLED_ON_EXTERNAL_MOUSE
} GDesktopDeviceSendEvents;
+typedef enum
+{
+ G_DESKTOP_TABLET_MAPPING_ABSOLUTE,
+ G_DESKTOP_TABLET_MAPPING_RELATIVE
+} GDesktopTabletMapping;
+
+typedef enum
+{
+ G_DESKTOP_PAD_BUTTON_ACTION_NONE,
+ G_DESKTOP_PAD_BUTTON_ACTION_HELP,
+ G_DESKTOP_PAD_BUTTON_ACTION_SWITCH_MONITOR,
+ G_DESKTOP_PAD_BUTTON_ACTION_KEYBINDING
+} GDesktopPadButtonAction;
+
+typedef enum
+{
+ G_DESKTOP_STYLUS_BUTTON_ACTION_DEFAULT,
+ G_DESKTOP_STYLUS_BUTTON_ACTION_MIDDLE,
+ G_DESKTOP_STYLUS_BUTTON_ACTION_RIGHT,
+ G_DESKTOP_STYLUS_BUTTON_ACTION_BACK,
+ G_DESKTOP_STYLUS_BUTTON_ACTION_FORWARD
+} GDesktopStylusButtonAction;
+
+
#endif /* __gdesktop_enums_h__ */
diff --git a/schemas/org.gnome.desktop.peripherals.gschema.xml.in
b/schemas/org.gnome.desktop.peripherals.gschema.xml.in
index 9f109ef..283278d 100644
--- a/schemas/org.gnome.desktop.peripherals.gschema.xml.in
+++ b/schemas/org.gnome.desktop.peripherals.gschema.xml.in
@@ -86,6 +86,60 @@
<summary>Drawing tablet mapping</summary>
<description>EDID information of the monitor the tablet is mapped to. Must be in the format [vendor,
product, serial]. ["","",""] disables mapping.</description>
</key>
+ <key name="mapping" enum="org.gnome.desktop.GDesktopTabletMapping">
+ <default>'absolute'</default>
+ <summary>Tablet mapping</summary>
+ <description>How input affects the pointer on the screen</description>
+ </key>
+ <key name="area" type="ad">
+ <default>[0, 0, 0, 0]</default>
+ <summary>Tablet area</summary>
+ <description>Dead area padding around the active area, in percentages. Respectively applied to
left,right,top and bottom sides.</description>
+ </key>
+ <key name="keep-aspect" type="b">
+ <default>false</default>
+ <summary>Tablet aspect ratio</summary>
+ <description>Enable this to restrict the tablet area to match the aspect ratio of the
output.</description>
+ </key>
+ <key name="left-handed" type="b">
+ <default>false</default>
+ <summary>Tablet left-handed mode</summary>
+ <description>Enable this to allow physically rotating the tablet for left-handed setups</description>
+ </key>
+ </schema>
+ <schema gettext-domain="@GETTEXT_PACKAGE@" id="org.gnome.desktop.peripherals.tablet.stylus">
+ <key name="pressure-curve" type="ai">
+ <default>[0, 0, 100, 100]</default>
+ <summary>Stylus pressure curve</summary>
+ <description>Set this to x1, y1 and x2, y2 of the pressure curve applied to the stylus.</description>
+ </key>
+ <key name="eraser-pressure-curve" type="ai">
+ <default>[0, 0, 100, 100]</default>
+ <summary>Eraser pressure curve</summary>
+ <description>Set this to x1, y1 and x2, y2 of the pressure curve applied to the eraser.</description>
+ </key>
+ <key name="button-action" enum="org.gnome.desktop.GDesktopStylusButtonAction">
+ <default>'default'</default>
+ <summary>Button action</summary>
+ <description>Stylus button action, this button is located along the pen handle.</description>
+ </key>
+ <key name="secondary-button-action" enum="org.gnome.desktop.GDesktopStylusButtonAction">
+ <default>'default'</default>
+ <summary>Secondary button action</summary>
+ <description>Secondary stylus button action, this button is located along the pen handle on some styli
like the Grip Pen. Other styli like the Airbrush Pen or the Inking Pen only have one button, this setting is
ineffective on those.</description>
+ </key>
+ </schema>
+ <schema gettext-domain="@GETTEXT_PACKAGE@" id="org.gnome.desktop.peripherals.tablet.pad-button">
+ <key name="action" enum="org.gnome.desktop.GDesktopPadButtonAction">
+ <default>'none'</default>
+ <summary>Pad button action type</summary>
+ <description>The type of action triggered by the button being pressed.</description>
+ </key>
+ <key type="s" name="keybinding">
+ <default>''</default>
+ <summary>Key combination for the custom action</summary>
+ <description>The keyboard shortcut generated when the button is pressed for custom
actions.</description>
+ </key>
</schema>
<schema gettext-domain="@GETTEXT_PACKAGE@" id="org.gnome.desktop.peripherals.touchscreen">
<key name="display" type="as">
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]