summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2021-10-08 16:30:15 +0100
committerCaolán McNamara <caolanm@redhat.com>2021-10-08 18:24:15 +0200
commit49e02381a301e4634eb7077fcb08eb4e8a95fb08 (patch)
tree2167c3a08fd26ecce6752c92c25c0b9d64e7278c
parent263d2f0b3d1143d6caa467204f187648c43b0e89 (diff)
remove GtkLabel "xpad" property
Change-Id: I237eb9e35367b8b75c8e72b857620747840383cd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123267 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rwxr-xr-xbin/ui-rules-enforcer.py21
-rw-r--r--svtools/uiconfig/ui/graphicexport.ui1
2 files changed, 21 insertions, 1 deletions
diff --git a/bin/ui-rules-enforcer.py b/bin/ui-rules-enforcer.py
index a344c88d6c2e..16764533ea59 100755
--- a/bin/ui-rules-enforcer.py
+++ b/bin/ui-rules-enforcer.py
@@ -256,6 +256,26 @@ def remove_spin_button_max_length(current):
if max_length != None:
current.remove(max_length)
+def remove_label_pad(current):
+ xpad = None
+ ypad = None
+ islabel = current.get('class') == "GtkLabel"
+ for child in current:
+ remove_label_pad(child)
+ if not islabel:
+ continue
+ if child.tag == "property":
+ attributes = child.attrib
+ if attributes.get("name") == "xpad":
+ xpad = child
+ elif attributes.get("name") == "ypad":
+ ypad = child
+
+ if xpad != None:
+ current.remove(xpad)
+ if ypad != None:
+ current.remove(ypad)
+
def remove_track_visited_links(current):
track_visited_links = None
islabel = current.get('class') == "GtkLabel"
@@ -451,6 +471,7 @@ remove_check_button_image_position(root)
remove_spin_button_input_purpose(root)
remove_spin_button_max_length(root)
remove_track_visited_links(root)
+remove_label_pad(root)
remove_expander_label_fill(root)
remove_expander_spacing(root)
enforce_menubutton_indicator_consistency(root)
diff --git a/svtools/uiconfig/ui/graphicexport.ui b/svtools/uiconfig/ui/graphicexport.ui
index b4360b9edab5..b14a8869a25c 100644
--- a/svtools/uiconfig/ui/graphicexport.ui
+++ b/svtools/uiconfig/ui/graphicexport.ui
@@ -142,7 +142,6 @@
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="margin-start">25</property>
- <property name="xpad">0</property>
<property name="label" translatable="yes" context="graphicexport|label5">Width:</property>
<property name="use-underline">True</property>
<property name="xalign">1</property>