eric3.Preferences.Shortcuts

Module implementing functions dealing with keyboard shortcuts.

Note: These functions are imported into the Preferences package and should be called like Preferences.readShortcuts(...).

Classes

None

Functions

_write Private method used to do the real write operation.
exportShortcuts Module function to export the keyboard shortcuts for the defined QActions.
importShortcuts Module function to import the keyboard shortcuts for the defined QActions.
readShortcuts Module function to read the keyboard shortcuts for the defined QActions.
saveShortcuts Module function to write the keyboard shortcuts for the defined QActions.

_write

_write(f, s, newline=1)

Private method used to do the real write operation.

f
open file object of the XML file
newline
flag indicating a linebreak
s
string to be written to the XML file
Up

exportShortcuts

exportShortcuts(fn)

Module function to export the keyboard shortcuts for the defined QActions.

fn
filename of the export file (string)
Returns:
flag indicating success
Up

importShortcuts

importShortcuts(fn)

Module function to import the keyboard shortcuts for the defined QActions.

fn
filename of the import file (string)
Returns:
flag indicating success
Up

readShortcuts

readShortcuts(ui, prefClass = Prefs)

Module function to read the keyboard shortcuts for the defined QActions.

prefClass
preferences class used as the storage area
ui
reference to the main widget (UI.UserInterface)
Up

saveShortcuts

saveShortcuts(prefClass = Prefs)

Module function to write the keyboard shortcuts for the defined QActions.

prefClass
preferences class used as the storage area
Up