[Skencil-commits] r752 - skencil/branches/skencil-0.6/src/Sketch/UI
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Sat Oct 9 01:23:41 CEST 2010
Author: igor_n
Date: 2010-10-09 01:23:35 +0200 (Sat, 09 Oct 2010)
New Revision: 752
Modified:
skencil/branches/skencil-0.6/src/Sketch/UI/canvas.py
skencil/branches/skencil-0.6/src/Sketch/UI/mainwindow.py
Log:
fixes for shotcut representation in main menu
Modified: skencil/branches/skencil-0.6/src/Sketch/UI/canvas.py
===================================================================
--- skencil/branches/skencil-0.6/src/Sketch/UI/canvas.py 2010-10-08 22:31:56 UTC (rev 751)
+++ skencil/branches/skencil-0.6/src/Sketch/UI/canvas.py 2010-10-08 23:23:35 UTC (rev 752)
@@ -1723,7 +1723,7 @@
# whenever the displayed area changes
#
- AddCmd('ForceRedraw', _("Redraw"), key_stroke = 'M-r', subscribe_to = None)
+ AddCmd('ForceRedraw', _("Redraw"), key_stroke = ('Alt+R', 'M-r'), subscribe_to = None)
def set_origin(self, xorg, yorg, move_contents = 1):
@@ -1773,10 +1773,10 @@
# other view related methods
- AddCmd('FitToWindow', _("Fit to Window"), key_stroke = 'S-F4',
+ AddCmd('FitToWindow', _("Fit to Window"), key_stroke = ('Shift+F4', 'S-F4'),
subscribe_to = None)
AddSelCmd('FitSelectedToWindow', _("Fit Selected to Window"),
- 'FitToWindow', args = 1, key_stroke = 'C-F4')
+ 'FitToWindow', args = 1, key_stroke = ('Ctrl+F4', 'C-F4'))
def FitToWindow(self, selected_only = 0, save_viewport = 1):
self.begin_transaction()
try:
@@ -1809,7 +1809,7 @@
finally:
self.end_transaction()
- AddCmd('ToggleOutlineMode', _("Outline"), key_stroke = 'S-F9',
+ AddCmd('ToggleOutlineMode', _("Outline"), key_stroke = ('Shift+F9', 'S-F9'),
value = 0, value_cb = 'IsOutlineMode', subscribe_to = VIEW,
is_check = 1)
Modified: skencil/branches/skencil-0.6/src/Sketch/UI/mainwindow.py
===================================================================
--- skencil/branches/skencil-0.6/src/Sketch/UI/mainwindow.py 2010-10-08 22:31:56 UTC (rev 751)
+++ skencil/branches/skencil-0.6/src/Sketch/UI/mainwindow.py 2010-10-08 23:23:35 UTC (rev 752)
@@ -164,14 +164,14 @@
self.SetDocument(Document(create_layer = 1))
AddCmd('LoadFromFile', _("Open..."), bitmap = pixmaps.Open,
- key_stroke = 'C-o')
- AddCmd('LoadMRU0', '', 'LoadFromFile', args = 0, key_stroke = 'M-1',
+ key_stroke = ('Ctrl+O','C-o'))
+ AddCmd('LoadMRU0', '', 'LoadFromFile', args = 0, key_stroke = ('Alt+1','M-1'),
name_cb = lambda: os.path.split(config.preferences.mru_files[0])[1])
- AddCmd('LoadMRU1', '', 'LoadFromFile', args = 1, key_stroke = 'M-2',
+ AddCmd('LoadMRU1', '', 'LoadFromFile', args = 1, key_stroke = ('Alt+2','M-2'),
name_cb = lambda: os.path.split(config.preferences.mru_files[1])[1])
- AddCmd('LoadMRU2', '', 'LoadFromFile', args = 2, key_stroke = 'M-3',
+ AddCmd('LoadMRU2', '', 'LoadFromFile', args = 2, key_stroke = ('Alt+3','M-3'),
name_cb = lambda: os.path.split(config.preferences.mru_files[2])[1])
- AddCmd('LoadMRU3', '', 'LoadFromFile', args = 3, key_stroke = 'M-4',
+ AddCmd('LoadMRU3', '', 'LoadFromFile', args = 3, key_stroke = ('Alt+4','M-4'),
name_cb = lambda: os.path.split(config.preferences.mru_files[3])[1])
def LoadFromFile(self, filename = None, directory = None):
app = self.application
@@ -212,9 +212,9 @@
AddCmd('SaveToFile', _("Save"), 'SaveToFileInteractive',
- bitmap = pixmaps.Save, key_stroke = ('C-s', 'F2'))
+ bitmap = pixmaps.Save, key_stroke = ('Ctrl+S','C-s', 'F2'))
AddCmd('SaveToFileAs', _("Save As..."), 'SaveToFileInteractive', args = 1,
- key_stroke = ('C-w', 'F3'))
+ key_stroke = ('Ctrl+W','C-w', 'F3'))
def SaveToFileInteractive(self, use_dialog = 0):
filename = self.document.meta.fullpathname
native_format = self.document.meta.native_format
@@ -319,7 +319,7 @@
- AddCmd('SavePS', _("Save as PostScript..."), key_stroke = 'M-p')
+ AddCmd('SavePS', _("Save as PostScript..."), key_stroke = ('Alt+P','M-p'))
def SavePS(self, filename = None):
app = self.application
bbox = self.document.BoundingRect(visible = 0, printable = 1)
@@ -493,7 +493,7 @@
'CreateDialog', args = ('styledlg', 'StylePanel'))
AddCmd('CreateBlendDialog', _("Blend..."),
'CreateDialog', args = ('blenddlg', 'BlendPanel'),
- key_stroke = 'C-b')
+ key_stroke = ('Ctrl+B','C-b'))
AddCmd('CreateLayoutDialog', _("Page Layout..."),
'CreateDialog', args = ('layoutdlg', 'LayoutPanel'))
#AddCmd('CreateExportDialog', 'Export...',
@@ -504,7 +504,7 @@
'CreateDialog', args = ('guidedlg', 'GuidePanel'))
AddCmd('CreatePrintDialog', _("Print..."),
'CreateDialog', args = ('printdlg', 'PrintPanel'),
- key_stroke = "C-p")
+ key_stroke = ('Ctrl+P', 'C-p'))
AddCmd('CreateReloadPanel', _("Reload Module..."),
'CreateDialog', args = ('reloaddlg', 'ReloadPanel'))
@@ -564,7 +564,7 @@
warn_tb(USER, _("Error running script `%s'"), self.run_script)
self.application.Mainloop()
- AddCmd('Exit', _("Exit"), key_stroke = ('M-Q', 'M-F4'))
+ AddCmd('Exit', _("Exit"), key_stroke = ('Alt+F4','M-Q', 'M-F4'))
def Exit(self):
if self.save_doc_if_edited(_("Exit")) != tkext.Cancel:
self.commands = None
@@ -1166,12 +1166,12 @@
AddDocCmd('SelectAll', _("Select All"), sensitive_cb = 'IsSelectionMode',
subscribe_to = MODE)
- AddDocCmd('SelectNextObject', _("Select Next"), key_stroke = 'M-Right')
+ AddDocCmd('SelectNextObject', _("Select Next"), key_stroke = ('Alt+Right','M-Right'))
AddDocCmd('SelectPreviousObject', _("Select Previous"),
key_stroke = 'M-Left')
AddDocCmd('SelectFirstChild', _("Select First Child"),
key_stroke = 'M-Down')
- AddDocCmd('SelectParent', _("Select Parent"), key_stroke = 'M-Up')
+ AddDocCmd('SelectParent', _("Select Parent"), key_stroke = ('Alt+Up','M-Up'))
# rearrange object
@@ -1185,26 +1185,26 @@
bitmap = pixmaps.MoveToBottom, key_stroke = 'End')
AddDocCmd('MoveSelectionUp', _("Move One Up"), bitmap = pixmaps.MoveOneUp,
- key_stroke = 'S-Prior')
+ key_stroke = ('Shift+PageUp', 'S-Prior'))
AddDocCmd('MoveSelectionDown', _("Move One Down"),
- bitmap = pixmaps.MoveOneDown, key_stroke = 'S-Next')
+ bitmap = pixmaps.MoveOneDown, key_stroke = ('Shift+PageDown','S-Next'))
AddDocCmd('DuplicateSelected', _("Duplicate"), bitmap = pixmaps.Duplicate,
- key_stroke = 'C-d')
+ key_stroke = ('Ctrl+D','C-d'))
#
AddDocCmd('GroupSelected', _("Group"), sensitive_cb = 'CanGroup',
- key_stroke = 'C-g', bitmap = pixmaps.Group)
+ key_stroke = ('Ctrl+G', 'C-g'), bitmap = pixmaps.Group)
AddDocCmd('UngroupSelected', _("Ungroup"), sensitive_cb = 'CanUngroup',
- key_stroke = 'C-u', bitmap = pixmaps.Ungroup)
+ key_stroke = ('Ctrl+U', 'C-u'), bitmap = pixmaps.Ungroup)
#
AddDocCmd('ConvertToCurve', _("Convert To Curve"),
- sensitive_cb = 'CanConvertToCurve')
+ sensitive_cb = 'CanConvertToCurve', key_stroke = ('Ctrl+Q','C-q'))
AddDocCmd('CombineBeziers', _("Combine Beziers"),
sensitive_cb = 'CanCombineBeziers')
@@ -1268,11 +1268,11 @@
AddDocCmd('Undo', _("Undo"), subscribe_to = UNDO,
sensitive_cb = 'CanUndo', name_cb = 'UndoMenuText',
- key_stroke = 'C-z', bitmap = pixmaps.Undo)
+ key_stroke = ('Ctrl+Z','C-z'), bitmap = pixmaps.Undo)
AddDocCmd('Redo', _("Redo"), subscribe_to = UNDO,
sensitive_cb = 'CanRedo', name_cb = 'RedoMenuText',
- key_stroke = 'C-r', bitmap = pixmaps.Redo)
+ key_stroke = ('Ctrl+R','C-r'), bitmap = pixmaps.Redo)
AddDocCmd('ResetUndo', _("Discard Undo History"), subscribe_to = None,
sensitive_cb = None)
More information about the Skencil-commits
mailing list