Package node_manager_fkie :: Module xml_editor :: Class XmlEditor
[frames] | no frames]

Class XmlEditor

source code

       object --+                    
                |                    
sip.simplewrapper --+                
                    |                
          sip.wrapper --+            
                        |            
     PyQt4.QtCore.QObject --+        
                            |        
           object --+       |        
                    |       |        
    sip.simplewrapper --+   |        
                        |   |        
 PyQt4.QtGui.QPaintDevice --+        
                            |        
          PyQt4.QtGui.QWidget --+    
                                |    
              PyQt4.QtGui.QDialog --+
                                    |
                                   XmlEditor

Creates a dialog to edit a launch file.

Nested Classes

Inherited from PyQt4.QtGui.QDialog: DialogCode

Inherited from PyQt4.QtGui.QWidget: RenderFlag, RenderFlags

Inherited from PyQt4.QtGui.QPaintDevice: PaintDeviceMetric

Instance Methods
 
finished_signal(...)
finished_signal has as parameter the filenames of the initialization and is emitted, if this dialog was closed.
source code
 
__init__(self, filenames, search_text='', parent=None)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
readSettings(self) source code
 
storeSetting(self) source code
 
on_load_request(self, filename, search_text='')
Loads a file in a new tab or focus the tab, if the file is already open.
source code
 
on_close_tab(self, tab_index)
Signal handling to close single tabs.
source code
 
reject(self) source code
 
closeEvent(self, event)
Test the open files for changes and save this if needed.
source code
 
on_saveButton_clicked(self)
Saves the current document.
source code
 
on_editor_textChanged(self)
If the content was changed, a '*' will be shown in the tab name.
source code
 
on_editor_positionChanged(self)
Shows the number of the line and column in a label.
source code
 
on_shortcut_find(self)
Opens a find dialog.
source code
 
on_shortcut_goto(self)
Opens a goto dialog.
source code
 
on_find_dialog_clicked(self, button)
Method to handle the button actions of the find dialog.
source code
 
find(self, search_text, recursive)
Searches for text in the current text editor.
source code
 
find_dialog_itemActivated(self, item)
On recursive search all files contained the search text are listed.
source code

Inherited from PyQt4.QtGui.QDialog: accept, accepted, contextMenuEvent, done, eventFilter, exec_, extension, finished, isSizeGripEnabled, keyPressEvent, minimumSizeHint, open, orientation, rejected, resizeEvent, result, setExtension, setModal, setOrientation, setResult, setSizeGripEnabled, setVisible, showEvent, showExtension, sizeHint

Inherited from PyQt4.QtGui.QWidget: acceptDrops, accessibleDescription, accessibleName, actionEvent, actions, activateWindow, addAction, addActions, adjustSize, autoFillBackground, backgroundRole, baseSize, changeEvent, childAt, childrenRect, childrenRegion, clearFocus, clearMask, close, contentsMargins, contentsRect, contextMenuPolicy, create, cursor, customContextMenuRequested, destroy, devType, dragEnterEvent, dragLeaveEvent, dragMoveEvent, dropEvent, effectiveWinId, enabledChange, ensurePolished, enterEvent, event, 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, keyReleaseEvent, keyboardGrabber, languageChange, layout, layoutDirection, leaveEvent, locale, lower, mapFrom, mapFromGlobal, mapFromParent, mapTo, mapToGlobal, mapToParent, mask, maximumHeight, maximumSize, maximumWidth, metric, minimumHeight, minimumSize, 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, 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, setWhatsThis, setWindowFilePath, setWindowFlags, setWindowIcon, setWindowIconText, setWindowModality, setWindowModified, setWindowOpacity, setWindowRole, setWindowState, setWindowTitle, show, showFullScreen, showMaximized, showMinimized, showNormal, size, 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, 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

Inherited from PyQt4.QtGui.QDialog: Accepted, Rejected

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
  files
list with all open files
Properties

Inherited from object: __class__

Method Details

__init__(self, filenames, search_text='', parent=None)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • filenames ([str, ...]) - a list with filenames. The last one will be activated.
  • search_text (str (Default: Empty String)) - if not empty, searches in new document for first occurrence of the given text
Overrides: object.__init__

on_load_request(self, filename, search_text='')

source code 

Loads a file in a new tab or focus the tab, if the file is already open.

Parameters:
  • filename (str) - the path to file
  • search_text (str (Default: Empty String)) - if not empty, searches in new document for first occurrence of the given text

on_close_tab(self, tab_index)

source code 

Signal handling to close single tabs.

Parameters:
  • tab_index (int) - tab index to close

reject(self)

source code 
Overrides: PyQt4.QtGui.QDialog.reject

closeEvent(self, event)

source code 

Test the open files for changes and save this if needed.

Overrides: PyQt4.QtGui.QWidget.closeEvent

on_saveButton_clicked(self)

source code 

Saves the current document. This method is called if the save button was clicked.

find(self, search_text, recursive)

source code 

Searches for text in the current text editor. If `recursive` is True, the included files will be searched.

Parameters:
  • search_text (str) - text to find
  • recursive (bool) - search in included files if this is True
Overrides: PyQt4.QtGui.QWidget.find

find_dialog_itemActivated(self, item)

source code 

On recursive search all files contained the search text are listed. If one of this file is activated, it will be open in a new tab and the cursor moved to the search text position.

Parameters:
  • item (PySide.QtGui.QListWidgetItem) - The activated item of the QListWidget