summaryrefslogtreecommitdiff
path: root/GstDebugViewer
diff options
context:
space:
mode:
authorRené Stadler <mail@renestadler.de>2011-11-05 23:05:00 +0100
committerRené Stadler <mail@renestadler.de>2011-11-06 00:03:10 +0100
commit9ab7b513f4662c6df6fa5327b2f9d130b5382280 (patch)
tree08994712b5b7956cba1fc6696a4a28e426e7d569 /GstDebugViewer
parentc5abefd21164e19388eba22bf561643245555136 (diff)
Add zoom reset action
Diffstat (limited to 'GstDebugViewer')
-rw-r--r--GstDebugViewer/GUI/window.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/GstDebugViewer/GUI/window.py b/GstDebugViewer/GUI/window.py
index 411c155..832526e 100644
--- a/GstDebugViewer/GUI/window.py
+++ b/GstDebugViewer/GUI/window.py
@@ -219,7 +219,8 @@ class Window (object):
("clear-line-view", gtk.STOCK_CLEAR, None),
("show-about", gtk.STOCK_ABOUT, None),
("enlarge-text", gtk.STOCK_ZOOM_IN, _("Enlarge Text"), "<Ctrl>plus"),
- ("shrink-text", gtk.STOCK_ZOOM_OUT, _("Shrink Text"), "<Ctrl>minus")])
+ ("shrink-text", gtk.STOCK_ZOOM_OUT, _("Shrink Text"), "<Ctrl>minus"),
+ ("reset-text", gtk.STOCK_ZOOM_100, _("Normal Text Size"), "<Ctrl>0")])
self.actions.add_group (group)
self.actions.reload_file.props.sensitive = False
@@ -300,7 +301,8 @@ class Window (object):
"hide-before-line", "hide-after-line", "show-hidden-lines",
"edit-copy-line", "edit-copy-message", "set-base-time",
"hide-log-level", "hide-log-category", "hide-log-object",
- "hide-filename", "show-about", "enlarge-text", "shrink-text"):
+ "hide-filename", "show-about", "enlarge-text", "shrink-text",
+ "reset-text"):
name = action_name.replace ("-", "_")
action = getattr (self.actions, name)
handler = getattr (self, "handle_%s_action_activate" % (name,))
@@ -587,6 +589,10 @@ class Window (object):
self.update_zoom_level (-1)
+ def handle_reset_text_action_activate (self, action):
+
+ self.update_zoom_level (-self.zoom_level)
+
def update_zoom_level (self, delta_step):
if not delta_step: