Package node_manager_fkie :: Module main_window :: Class MainWindow
[frames] | no frames]

Class MainWindow

source code

       object --+                    
                |                    
sip.simplewrapper --+                
                    |                
          sip.wrapper --+            
                        |            
     PyQt4.QtCore.QObject --+        
                            |        
           object --+       |        
                    |       |        
    sip.simplewrapper --+   |        
                        |   |        
 PyQt4.QtGui.QPaintDevice --+        
                            |        
          PyQt4.QtGui.QWidget --+    
                                |    
          PyQt4.QtGui.QMainWindow --+
                                    |
                                   MainWindow

The class to create the main window of the application.

Nested Classes

Inherited from PyQt4.QtGui.QMainWindow: DockOption, DockOptions

Inherited from PyQt4.QtGui.QWidget: RenderFlag, RenderFlags

Inherited from PyQt4.QtGui.QPaintDevice: PaintDeviceMetric

Instance Methods
 
__init__(self, files=[], restricted_to_one_master=False, parent=None)
Creates the window, connects the signals and init the class.
source code
 
on_hide_docks_toggled(self, checked) source code
 
on_currentChanged_tab(self, index) source code
 
readSettings(self) source code
 
storeSetting(self) source code
 
closeEvent(self, event) source code
 
finish(self) source code
str or None
getMasteruri(self)
Requests the ROS master URI from the ROS master through the RPC interface and returns it.
source code
 
removeMaster(self, masteruri)
Removed master with given master URI from the list.
source code
MasterViewProxy
getMaster(self, masteruri, create_new=True)
Returns: the Widget which represents the master of given ROS master URI.
source code
 
on_host_update_request(self, host) source code
 
on_host_description_updated(self, masteruri, host, descr) source code
 
on_capabilities_update(self, masteruri, address, config_node, descriptions) source code
 
on_remove_config(self, cfg) source code
 
on_master_list_err_retrieved(self, masteruri, error)
The callback method connected to the signal, which is emitted on an error while call the service to determine the discovered ROS master.
source code
 
hasDiscoveryService(self, minfo)
Test whether the new retrieved MasterInfo contains the master_discovery node.
source code
 
on_master_list_retrieved(self, masteruri, servic_name, master_list)
Handle the retrieved list with ROS master.
source code
 
on_master_state_changed(self, msg)
Handle the received master state message.
source code
 
on_master_monitor_err(self, msg) source code
 
on_master_info_retrieved(self, minfo)
Integrate the received master info.
source code
 
on_master_info_error(self, masteruri, error) source code
 
on_conn_stats_updated(self, stats)
Handle the retrieved connection statistics.
source code
 
on_info_clicked(self) source code
 
on_refresh_master_clicked(self) source code
 
on_run_node_clicked(self)
Open a dialog to run a ROS node without a configuration
source code
 
on_rqt_plugin_start(self, name, plugin) source code
 
on_sync_dialog_released(self, released=False, masteruri=None, external_call=False) source code
 
on_sync_released(self, external_call=False)
Enable or disable the synchronization of the master cores
source code
 
on_master_timecheck(self) source code
 
showMasterName(self, masteruri, name, timestamp, online=True)
Update the view of the info frame.
source code
 
timestampStr(self, timestamp) source code
 
updateDuplicateNodes(self) source code
 
on_master_table_pressed(self, selected) source code
 
on_master_table_clicked(self, selected)
On click on the sync item, the master_sync node will be started or stopped, depending on run state.
source code
 
on_master_table_activated(self, selected) source code
 
on_master_selection_changed(self, selected)
If a master was selected, set the corresponding Widget of the stacked layout to the current widget and shows the state of the selected master.
source code
 
setCurrentMaster(self, master)
Changes the view of the master.
source code
 
on_user_changed(self, user) source code
 
on_masterTableView_selection_changed(self, selected, deselected)
On selection of a master list.
source code
 
on_all_master_refresh_clicked(self)
Retrieves from the master_discovery node the list of all discovered ROS master and get their current state.
source code
 
on_discover_network_clicked(self) source code
 
on_start_robot_clicked(self)
Tries to start the master_discovery node on the machine requested by a dialog.
source code
 
on_load_launch_file(self, path)
Load the launch file.
source code
 
on_load_launch_as_default(self, path, host=None)
Load the launch file as default configuration.
source code
 
on_launch_edit(self, files, search_text='', trynr=1)
Opens the given files in an editor.
source code
 
on_launch_transfer(self, files)
Copies the selected file to a remote host :param file: A list with paths :type file: list of strings
source code
 
on_configfile_changed(self, changed, affected)
Signal hander to handle the changes of a loaded configuration file
source code
 
on_configparamfile_changed(self, changed, affected)
Signal handler to handle the changes of a configuration file referenced by a parameter value
source code
 
changeEvent(self, event)
Check for changed files, if the main gui is activated.
source code
 
on_start_nodes(self, masteruri, cfg, nodes) source code
 
on_stop_nodes(self, masteruri, nodes) source code
 
on_description_update(self, title, text) source code
 
on_description_update_cap(self, title, text) source code
 
on_description_anchorClicked(self, url) source code
 
keyReleaseEvent(self, event)
Defines some of shortcuts for navigation/management in launch list view or topics view.
source code
 
image_mouseDoubleClickEvent(self, event)
Set the robot image
source code

Inherited from PyQt4.QtGui.QMainWindow: addDockWidget, addToolBar, addToolBarBreak, centralWidget, contextMenuEvent, corner, createPopupMenu, dockOptions, dockWidgetArea, documentMode, event, iconSize, iconSizeChanged, insertToolBar, insertToolBarBreak, isAnimated, isDockNestingEnabled, isSeparator, menuBar, menuWidget, removeDockWidget, removeToolBar, removeToolBarBreak, restoreDockWidget, restoreState, saveState, setAnimated, setCentralWidget, setCorner, setDockNestingEnabled, setDockOptions, setDocumentMode, setIconSize, setMenuBar, setMenuWidget, setStatusBar, setTabPosition, setTabShape, setToolButtonStyle, setUnifiedTitleAndToolBarOnMac, splitDockWidget, statusBar, tabPosition, tabShape, tabifiedDockWidgets, tabifyDockWidget, toolBarArea, toolBarBreak, toolButtonStyle, toolButtonStyleChanged, unifiedTitleAndToolBarOnMac

Inherited from PyQt4.QtGui.QWidget: acceptDrops, accessibleDescription, accessibleName, actionEvent, actions, activateWindow, addAction, addActions, adjustSize, autoFillBackground, backgroundRole, baseSize, childAt, childrenRect, childrenRegion, clearFocus, clearMask, close, contentsMargins, contentsRect, contextMenuPolicy, create, cursor, customContextMenuRequested, destroy, devType, dragEnterEvent, dragLeaveEvent, dragMoveEvent, dropEvent, effectiveWinId, enabledChange, ensurePolished, enterEvent, find, focusInEvent, focusNextChild, focusNextPrevChild, focusOutEvent, focusPolicy, focusPreviousChild, focusProxy, focusWidget, font, fontChange, fontInfo, fontMetrics, foregroundRole, frameGeometry, frameSize, geometry, getContentsMargins, grabGesture, grabKeyboard, grabMouse, grabShortcut, graphicsEffect, graphicsProxyWidget, handle, hasFocus, hasMouseTracking, height, heightForWidth, hide, hideEvent, inputContext, inputMethodEvent, inputMethodHints, inputMethodQuery, insertAction, insertActions, isActiveWindow, isAncestorOf, isEnabled, isEnabledTo, isEnabledToTLW, isFullScreen, isHidden, isLeftToRight, isMaximized, isMinimized, isModal, isRightToLeft, isTopLevel, isVisible, isVisibleTo, isWindow, isWindowModified, keyPressEvent, keyboardGrabber, languageChange, layout, layoutDirection, leaveEvent, locale, lower, mapFrom, mapFromGlobal, mapFromParent, mapTo, mapToGlobal, mapToParent, mask, maximumHeight, maximumSize, maximumWidth, metric, minimumHeight, minimumSize, minimumSizeHint, minimumWidth, mouseDoubleClickEvent, mouseGrabber, mouseMoveEvent, mousePressEvent, mouseReleaseEvent, move, moveEvent, nativeParentWidget, nextInFocusChain, normalGeometry, overrideWindowFlags, overrideWindowState, paintEngine, paintEvent, palette, paletteChange, parentWidget, pos, previousInFocusChain, raise_, rect, releaseKeyboard, releaseMouse, releaseShortcut, removeAction, render, repaint, resetInputContext, resize, resizeEvent, restoreGeometry, saveGeometry, scroll, setAcceptDrops, setAccessibleDescription, setAccessibleName, setAttribute, setAutoFillBackground, setBackgroundRole, setBaseSize, setContentsMargins, setContextMenuPolicy, setCursor, setDisabled, setEnabled, setFixedHeight, setFixedSize, setFixedWidth, setFocus, setFocusPolicy, setFocusProxy, setFont, setForegroundRole, setGeometry, setGraphicsEffect, setHidden, setInputContext, setInputMethodHints, setLayout, setLayoutDirection, setLocale, setMask, setMaximumHeight, setMaximumSize, setMaximumWidth, setMinimumHeight, setMinimumSize, setMinimumWidth, setMouseTracking, setPalette, setParent, setShortcutAutoRepeat, setShortcutEnabled, setShown, setSizeIncrement, setSizePolicy, setStatusTip, setStyle, setStyleSheet, setTabOrder, setToolTip, setUpdatesEnabled, setVisible, setWhatsThis, setWindowFilePath, setWindowFlags, setWindowIcon, setWindowIconText, setWindowModality, setWindowModified, setWindowOpacity, setWindowRole, setWindowState, setWindowTitle, show, showEvent, showFullScreen, showMaximized, showMinimized, showNormal, size, sizeHint, sizeIncrement, sizePolicy, stackUnder, statusTip, style, styleSheet, tabletEvent, testAttribute, toolTip, topLevelWidget, underMouse, ungrabGesture, unsetCursor, unsetLayoutDirection, unsetLocale, update, updateGeometry, updateMicroFocus, updatesEnabled, visibleRegion, whatsThis, wheelEvent, width, winId, window, windowActivationChange, windowFilePath, windowFlags, windowIcon, windowIconText, windowModality, windowOpacity, windowRole, windowState, windowTitle, windowType, x, x11Info, x11PictureHandle, y

Inherited from PyQt4.QtCore.QObject: __getattr__, blockSignals, childEvent, children, connect, connectNotify, customEvent, deleteLater, destroyed, disconnect, disconnectNotify, dumpObjectInfo, dumpObjectTree, dynamicPropertyNames, emit, eventFilter, findChild, findChildren, inherits, installEventFilter, isWidgetType, killTimer, metaObject, moveToThread, objectName, parent, property, pyqtConfigure, receivers, removeEventFilter, sender, senderSignalIndex, setObjectName, setProperty, signalsBlocked, startTimer, thread, timerEvent, tr, trUtf8

Inherited from PyQt4.QtGui.QPaintDevice: colorCount, depth, heightMM, logicalDpiX, logicalDpiY, numColors, paintingActive, physicalDpiX, physicalDpiY, widthMM

Inherited from sip.simplewrapper: __new__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables
  DELAYED_NEXT_REQ_ON_ERR = 5.0

Inherited from PyQt4.QtGui.QMainWindow: AllowNestedDocks, AllowTabbedDocks, AnimatedDocks, ForceTabbedDocks, VerticalTabs

Inherited from PyQt4.QtGui.QWidget: DrawChildren, DrawWindowBackground, IgnoreMask

Inherited from PyQt4.QtCore.QObject: staticMetaObject

Inherited from PyQt4.QtGui.QPaintDevice: PdmDepth, PdmDpiX, PdmDpiY, PdmHeight, PdmHeightMM, PdmNumColors, PdmPhysicalDpiX, PdmPhysicalDpiY, PdmWidth, PdmWidthMM

Instance Variables
  editor_dialogs
stores the open XmlEditor
Properties

Inherited from object: __class__

Method Details

__init__(self, files=[], restricted_to_one_master=False, parent=None)
(Constructor)

source code 

Creates the window, connects the signals and init the class.

Overrides: object.__init__

closeEvent(self, event)

source code 
Overrides: PyQt4.QtGui.QWidget.closeEvent

getMasteruri(self)

source code 

Requests the ROS master URI from the ROS master through the RPC interface and returns it. The 'materuri' attribute will be set to the requested value.

Returns: str or None
ROS master URI

removeMaster(self, masteruri)

source code 

Removed master with given master URI from the list.

Parameters:
  • masteruri (str) - the URI of the ROS master

getMaster(self, masteruri, create_new=True)

source code 
Returns: MasterViewProxy
the Widget which represents the master of given ROS master URI. If no Widget for given URI is available a new one will be created.

on_master_list_err_retrieved(self, masteruri, error)

source code 

The callback method connected to the signal, which is emitted on an error while call the service to determine the discovered ROS master. On the error the local monitoring will be enabled.

hasDiscoveryService(self, minfo)

source code 

Test whether the new retrieved MasterInfo contains the master_discovery node. This is identified by a name of the contained 'list_masters' service.

Parameters:
  • minfo (master_discovery_fkie.MasterInfo) - the ROS master Info

on_master_list_retrieved(self, masteruri, servic_name, master_list)

source code 

Handle the retrieved list with ROS master.

  1. update the ROS Network view
Parameters:
  • master_list ([master_discovery_fkie.msg.MasterState]) - a list with ROS masters

on_master_state_changed(self, msg)

source code 

Handle the received master state message.

  1. update the ROS Network view
  2. enable local master monitoring, if all masters are removed (the local master too)
Parameters:
  • msg (master_discovery_fkie.msg.MasterState) - the ROS message with new master state

on_master_info_retrieved(self, minfo)

source code 

Integrate the received master info.

Parameters:
  • minfo (master_discovery_fkie.MasterInfo) - the ROS master Info

on_conn_stats_updated(self, stats)

source code 

Handle the retrieved connection statistics.

  1. update the ROS Network view
Parameters:
  • stats ([master_discovery_fkie.msg.LinkState]) - a list with connection statistics

setCurrentMaster(self, master)

source code 

Changes the view of the master. :param master: the MasterViewProxy object or masteruri :type master: MasterViewProxy or str

on_load_launch_file(self, path)

source code 

Load the launch file. A ROS master must be selected first. :param path: the path of the launch file. :type path: str

on_load_launch_as_default(self, path, host=None)

source code 

Load the launch file as default configuration. A ROS master must be selected first. :param path: the path of the launch file. :type path: str :param host: The host name, where the configuration start. :type host: str (Default: None)

on_launch_edit(self, files, search_text='', trynr=1)

source code 

Opens the given files in an editor. If the first file is already open, select the editor. If search text is given, search for the text in files an goto the line. :param file: A list with paths :type file: list of strings :param search_text: A string to search in file :type search_text: str

on_configfile_changed(self, changed, affected)

source code 

Signal hander to handle the changes of a loaded configuration file

Parameters:
  • changed (str) - the changed file
  • affected (list) - the list of tuples with masteruri and launchfile, which are affected by file change

on_configparamfile_changed(self, changed, affected)

source code 

Signal handler to handle the changes of a configuration file referenced by a parameter value

Parameters:
  • changed (str) - the changed file
  • affected (list) - the list of tuples with masteruri and launchfile, which are affected by file change

changeEvent(self, event)

source code 

Check for changed files, if the main gui is activated.

Overrides: PyQt4.QtGui.QWidget.changeEvent

keyReleaseEvent(self, event)

source code 

Defines some of shortcuts for navigation/management in launch list view or topics view.

Overrides: PyQt4.QtGui.QWidget.keyReleaseEvent