![]() |
PanTilt
1.3.2
RoadNarrows Robotics Pan-Tilt Project
|
Window class supporting application. More...
Public Member Functions | |
| def | __init__ (self, master=None, cnf={}, kw) |
| Constructor. More... | |
| def | initData (self, kw) |
| Initialize class state data. More... | |
| def | createWidgets (self) |
| Create gui widgets with supporting data and show. | |
| def | createHeading (self) |
| Create top gui heading. | |
| def | createLeftButtons (self) |
| Create gui left hand side buttons. | |
| def | createCenterPanel (self) |
| Create gui center panel. | |
| def | createRightButtons (self) |
| Create gui right hand side buttons. | |
| def | createStatusBar (self) |
| Create gui multi-line status bar at bottom of gui window. | |
| def | createButton (self, parent, text, imagefile, command, fg='black') |
| Create button. More... | |
| def | clearSelect (self) |
| Clear all select checkboxes. | |
| def | cbSelect (self) |
| Checkbox change state callback. | |
| def | cbStartServices (self) |
| Start selected services callback. | |
| def | cbStopServices (self) |
| Stop selected services callback. | |
| def | cbRestartServices (self) |
| Restart selected services callback. | |
| def | cbRefreshStatus (self) |
| Refresh services status callback. | |
| def | cbSave (self) |
| Save new settings callback. | |
| def | destroy (self) |
| Destroy window callback. | |
| def | showSbInfo (self, text) |
| Show information text on status bar. More... | |
| def | showSbError (self, text) |
| Show error text on status bar. More... | |
| def | showSbOk (self, text) |
| Show ok text on status bar. More... | |
| def | showSbResult (self, text, success) |
| Show operation result on status bar. More... | |
| def | showSbStatus (self, text, status) |
| Show service status result on status bar. More... | |
| def | setStatus (self, service, status) |
| Set service status field. More... | |
| def | autoRefresh (self) |
| def | refresh (self) |
| Refresh status of all services. | |
| def | execStart (self, service) |
| Execute 'service <service> start' subprocess. More... | |
| def | execStop (self, service) |
| Execute 'service <service> stop' subprocess. More... | |
| def | execRestart (self, service) |
| Execute 'service <service> restart' subprocess. More... | |
| def | execStatus (self, service) |
| Execute 'service <service> status' subprocess. More... | |
Public Attributes | |
| m_imageLoader | |
| m_debug | |
| m_icons | |
| m_wBttn | |
| m_svcKeys | |
| m_svcDesc | |
| m_lock | |
| m_service | |
| m_wScrollBar | |
| m_wStatusBar | |
Window class supporting application.
Definition at line 98 of file pantilt_console.py.
| def pantilt_console.window.__init__ | ( | self, | |
master = None, |
|||
cnf = {}, |
|||
| kw | |||
| ) |
Constructor.
| master | Window parent master widget. |
| cnf | Configuration dictionary. |
| kw | Keyword options. |
Definition at line 106 of file pantilt_console.py.
References pantilt_console.window.autoRefresh(), pantilt_console.window.createWidgets(), pantilt_console.window.initData(), pantilt_console.window.m_icons, and pantilt_console.window.m_imageLoader.
| def pantilt_console.window.createButton | ( | self, | |
| parent, | |||
| text, | |||
| imagefile, | |||
| command, | |||
fg = 'black' |
|||
| ) |
Create button.
| parent | Parent widget. |
| text | Button text. |
| imagefile | Image file name. None for no image. |
| command | Callback for button push. |
| fg | Foreground text color. |
Definition at line 382 of file pantilt_console.py.
References pantilt_console.window.m_icons, and pantilt_console.window.m_wBttn.
Referenced by pantilt_console.window.createLeftButtons(), and pantilt_console.window.createRightButtons().
| def pantilt_console.window.execRestart | ( | self, | |
| service | |||
| ) |
Execute 'service <service> restart' subprocess.
| servcie | Service (key). |
Definition at line 647 of file pantilt_console.py.
Referenced by pantilt_console.window.cbRestartServices().
| def pantilt_console.window.execStart | ( | self, | |
| service | |||
| ) |
Execute 'service <service> start' subprocess.
| servcie | Service (key). |
Definition at line 603 of file pantilt_console.py.
Referenced by pantilt_console.window.cbStartServices().
| def pantilt_console.window.execStatus | ( | self, | |
| service | |||
| ) |
Execute 'service <service> status' subprocess.
| servcie | Service (key). |
Definition at line 671 of file pantilt_console.py.
Referenced by pantilt_console.window.cbRefreshStatus(), and pantilt_console.window.refresh().
| def pantilt_console.window.execStop | ( | self, | |
| service | |||
| ) |
Execute 'service <service> stop' subprocess.
| servcie | Service (key). |
Definition at line 625 of file pantilt_console.py.
Referenced by pantilt_console.window.cbStopServices().
| def pantilt_console.window.initData | ( | self, | |
| kw | |||
| ) |
Initialize class state data.
Any keywords for this application specific window that are not supported by the Frame Tkinter class must be removed.
| kw | Keyword options. |
Definition at line 139 of file pantilt_console.py.
References pantilt_console.window.m_debug, pantilt_console.window.m_icons, pantilt_console.window.m_lock, pantilt_console.window.m_svcDesc, pantilt_console.window.m_svcKeys, and pantilt_console.window.m_wBttn.
Referenced by pantilt_console.window.__init__().
| def pantilt_console.window.setStatus | ( | self, | |
| service, | |||
| status | |||
| ) |
Set service status field.
| servcie | Service (key). |
| status | Service status. One of: 'running' 'stopped' 'unknown' |
Definition at line 580 of file pantilt_console.py.
References pantilt_console.window.autoRefresh(), pantilt_console.window.m_service, and pantilt_console.window.refresh().
Referenced by pantilt_console.window.cbRefreshStatus(), and pantilt_console.window.refresh().
| def pantilt_console.window.showSbError | ( | self, | |
| text | |||
| ) |
Show error text on status bar.
| text | Error text string. |
Definition at line 516 of file pantilt_console.py.
References pantilt_console.window.m_wStatusBar.
Referenced by pantilt_console.window.showSbResult(), and pantilt_console.window.showSbStatus().
| def pantilt_console.window.showSbInfo | ( | self, | |
| text | |||
| ) |
Show information text on status bar.
| text | Info text string. |
Definition at line 501 of file pantilt_console.py.
References pantilt_console.window.m_wStatusBar.
Referenced by pantilt_console.window.cbRefreshStatus(), pantilt_console.window.cbRestartServices(), pantilt_console.window.cbSave(), pantilt_console.window.cbStartServices(), pantilt_console.window.cbStopServices(), and pantilt_console.window.showSbStatus().
| def pantilt_console.window.showSbOk | ( | self, | |
| text | |||
| ) |
Show ok text on status bar.
| text | Ok text string. |
Definition at line 531 of file pantilt_console.py.
References pantilt_console.window.m_wStatusBar.
Referenced by pantilt_console.window.showSbResult(), and pantilt_console.window.showSbStatus().
| def pantilt_console.window.showSbResult | ( | self, | |
| text, | |||
| success | |||
| ) |
Show operation result on status bar.
| text | Prefix text already displayed on current status bar line. |
| success | Operation was [not] a success. |
Definition at line 547 of file pantilt_console.py.
References pantilt_console.window.m_wStatusBar, pantilt_console.window.showSbError(), and pantilt_console.window.showSbOk().
Referenced by pantilt_console.window.cbRestartServices(), pantilt_console.window.cbStartServices(), and pantilt_console.window.cbStopServices().
| def pantilt_console.window.showSbStatus | ( | self, | |
| text, | |||
| status | |||
| ) |
Show service status result on status bar.
| text | Prefix text already displayed on current status bar line. |
| status | Service status. One of: 'running' 'stopped' 'unknown' |
Definition at line 562 of file pantilt_console.py.
References pantilt_console.window.m_wStatusBar, pantilt_console.window.showSbError(), pantilt_console.window.showSbInfo(), and pantilt_console.window.showSbOk().
Referenced by pantilt_console.window.cbRefreshStatus().