|
|
6447fd7 |
diff --git a/GstInspector/GUI.py b/GstInspector/GUI.py
|
|
|
6447fd7 |
index 108fdc6..7642ea1 100644
|
|
|
6447fd7 |
--- a/GstInspector/GUI.py
|
|
|
6447fd7 |
+++ b/GstInspector/GUI.py
|
|
|
6447fd7 |
@@ -1292,21 +1292,22 @@ class DetailsPage (Page):
|
|
|
6447fd7 |
self.link_button.connect ("clicked", self.handle_link_button_clicked)
|
|
|
6447fd7 |
self.link_button.show ()
|
|
|
6447fd7 |
|
|
|
6447fd7 |
- # Little hack to make the label inside the LinkButton align with all
|
|
|
6447fd7 |
- # the others. The LinkButton has a margin around the label. A shadow
|
|
|
6447fd7 |
- # (border) is drawn there on mouse over only, so it looks totally odd
|
|
|
6447fd7 |
- # without this little adjustment.
|
|
|
6447fd7 |
- button_req_width = self.link_button.size_request ()[0]
|
|
|
6447fd7 |
- child_req_width = self.link_button.child.size_request ()[0]
|
|
|
6447fd7 |
- extra_pad = (button_req_width - child_req_width) / 2
|
|
|
6447fd7 |
- children = [label]
|
|
|
6447fd7 |
- children += iter_container (self.widgets.element_details_table,
|
|
|
6447fd7 |
- left_attach = 1, right_attach = 2)
|
|
|
6447fd7 |
- children += iter_container (self.widgets.plugin_details_table,
|
|
|
6447fd7 |
- left_attach = 1, right_attach = 2)
|
|
|
6447fd7 |
- for child in children:
|
|
|
6447fd7 |
- if child != box:
|
|
|
6447fd7 |
- child.props.xpad = extra_pad
|
|
|
6447fd7 |
+ if self.link_button.child is not None:
|
|
|
6447fd7 |
+ # Little hack to make the label inside the LinkButton align with all
|
|
|
6447fd7 |
+ # the others. The LinkButton has a margin around the label. A shadow
|
|
|
6447fd7 |
+ # (border) is drawn there on mouse over only, so it looks totally odd
|
|
|
6447fd7 |
+ # without this little adjustment.
|
|
|
6447fd7 |
+ button_req_width = self.link_button.size_request ()[0]
|
|
|
6447fd7 |
+ child_req_width = self.link_button.child.size_request ()[0]
|
|
|
6447fd7 |
+ extra_pad = (button_req_width - child_req_width) / 2
|
|
|
6447fd7 |
+ children = [label]
|
|
|
6447fd7 |
+ children += iter_container (self.widgets.element_details_table,
|
|
|
6447fd7 |
+ left_attach = 1, right_attach = 2)
|
|
|
6447fd7 |
+ children += iter_container (self.widgets.plugin_details_table,
|
|
|
6447fd7 |
+ left_attach = 1, right_attach = 2)
|
|
|
6447fd7 |
+ for child in children:
|
|
|
6447fd7 |
+ if child != box:
|
|
|
6447fd7 |
+ child.props.xpad = extra_pad
|
|
|
6447fd7 |
|
|
|
6447fd7 |
box.pack_start (self.link_button, False, False)
|
|
|
6447fd7 |
|