# eric3.ViewManager.Listspace

Module implementing the listspace viewmanager class.

### Classes

Listspace | Class implementing the listspace viewmanager class.
WidgetStack | Class implementing a custimized WidgetStack.

### Functions

None

## Listspace

Class implementing the listspace viewmanager class.

#### Signals

changeCaption(string)
  emitted if a change of the caption is neccessary
editorChanged(string)
  emitted when the current editor has changed

### Derived from

QSplitter, ViewManager

### Methods

Listspace | Constructor
__showSelectedView | Internal slot called to show a view selected in the list by a mouse click.
__showViewByIndex | Internal slot called to show a view (i.e.
activeWindow | Private method to return the active (i.e.
addSplit | Public method used to split the current view.
addView | Private method to add a view (i.e.
canCascade | Public method to signal if cascading of managed windows is available.
canSplit | public method to signal if splitting of the view is available.
canTile | Public method to signal if tiling of managed windows is available.
cascade | Public method to cascade the managed windows.
eventFilter | Method called to filter the event queue.
handleCaptionChange | Private method to handle Caption change signals from the editor.
handleContextClose | Private method to close the selected tab.
handleContextCloseAll | Private method to close all tabs.
handleContextMenu | Private slot to show the context menu of the listview.
handleContextPrintFile | Private method to print the selected tab.
handleContextSave | Private method to save the selected tab.
handleContextSaveAll | Private method to save all tabs.
handleContextSaveAs | Private method to save the selected tab to a new file.
handleContextSaveToProject | Private method to save the selected tab to the current project.
handleModificationStatusChanged | Private slot to handle the modificationStatusChanged signal.
handleShowMenu | Private slot to handle the aboutToShow signal of the viewlist context menu.
handleShowWindowMenu | Private method to set up the viewmanager part of the Window menu.
handleSyntaxErrorToggled | Private slot to handle the syntaxerrorToggled signal.
initMenu | Private method to initialize the viewlist context menu.
initWindowActions | Define the user interface actions for window handling.
nextSplit | Public slot used to move to the next split.
nextTab | Public slot to activate the viewlist giving it the input focus.
prevSplit | Public slot used to move to the previous split.
removeAllViews | Private method to remove all views (i.e.
removeSplit | Public method used to remove the current split view.
removeView | Private method to remove a view (i.e.
setEditorName | Change the displayed name of the editor.
setSplitOrientation | Public method used to set the orientation of the split view.
showView | Private method to show a view (i.e.
tile | Public method to tile the managed windows.

### Listspace (Constructor)

Listspace(parent, ui, dbs)

Constructor

parent
  parent widget (QWidget)
ui
  reference to the main user interface
dbs
  reference to the debug server object

### Listspace.__showSelectedView

__showSelectedView(itm)

Internal slot called to show a view selected in the list by a mouse click.

itm
  item clicked on (QListBoxItem)

### Listspace.__showViewByIndex

__showViewByIndex(index, changeFocus=False)

Internal slot called to show a view (i.e. window) selected in the list.

index
  index of the selected entry (int)
changeFocus
  flag indicating, that the editor should receive the focus (boolean)

### Listspace.activeWindow

activeWindow()

Private method to return the active (i.e. current) window.

Returns:
  reference to the active editor

### Listspace.addSplit

addSplit()

Public method used to split the current view.

### Listspace.addView

addView(win, fn=None)

Private method to add a view (i.e. window)

win
  editor window to be added
fn
  filename of this editor

### Listspace.canCascade

canCascade()

Public method to signal if cascading of managed windows is available.

Returns:
  flag indicating cascading of windows is available

### Listspace.canSplit

canSplit()

public method to signal if splitting of the view is available.

Returns:
  flag indicating splitting of the view is available.

### Listspace.canTile

canTile()

Public method to signal if tiling of managed windows is available.

Returns:
  flag indicating tiling of windows is available

### Listspace.cascade

cascade()

Public method to cascade the managed windows.

### Listspace.eventFilter

eventFilter(watched, event)

Method called to filter the event queue.

watched
  the QObject being watched
event
  the event that occurred

Returns:
  flag indicating, if we handled the event

### Listspace.handleCaptionChange

handleCaptionChange(cap, editor)

Private method to handle Caption change signals from the editor.

Updates the listview text to reflect the new caption information.

cap
  Caption for the editor
editor
  Editor to update the caption for

### Listspace.handleContextClose

handleContextClose()

Private method to close the selected tab.

### Listspace.handleContextCloseAll

handleContextCloseAll()

Private method to close all tabs.

### Listspace.handleContextMenu

handleContextMenu(itm, coord, col)

Private slot to show the context menu of the listview.

itm
  the selected listview item (QListViewItem)
coord
  the position of the mouse pointer (QPoint)
col
  the column of the mouse pointer (int)

### Listspace.handleContextPrintFile

handleContextPrintFile()

Private method to print the selected tab.

### Listspace.handleContextSave

handleContextSave()

Private method to save the selected tab.

### Listspace.handleContextSaveAll

handleContextSaveAll()

Private method to save all tabs.

### Listspace.handleContextSaveAs

handleContextSaveAs()

Private method to save the selected tab to a new file.

### Listspace.handleContextSaveToProject

handleContextSaveToProject()

Private method to save the selected tab to the current project.

### Listspace.handleModificationStatusChanged

handleModificationStatusChanged(m, editor)

Private slot to handle the modificationStatusChanged signal.

m
  flag indicating the modification status (boolean)
editor
  editor window changed

### Listspace.handleShowMenu

handleShowMenu()

Private slot to handle the aboutToShow signal of the viewlist context menu.

### Listspace.handleShowWindowMenu

handleShowWindowMenu(windowMenu)

Private method to set up the viewmanager part of the Window menu.

windowMenu
  reference to the window menu

### Listspace.handleSyntaxErrorToggled

handleSyntaxErrorToggled(editor)

Private slot to handle the syntaxerrorToggled signal.

editor
  editor that sent the signal

### Listspace.initMenu

initMenu()

Private method to initialize the viewlist context menu.

### Listspace.initWindowActions

initWindowActions()

Define the user interface actions for window handling.

### Listspace.nextSplit

nextSplit()

Public slot used to move to the next split.

### Listspace.nextTab

nextTab()

Public slot to activate the viewlist giving it the input focus.

### Listspace.prevSplit

prevSplit()

Public slot used to move to the previous split.

### Listspace.removeAllViews

removeAllViews()

Private method to remove all views (i.e. windows)

### Listspace.removeSplit

removeSplit()

Public method used to remove the current split view.

Returns:
  flag indicating successfull removal

### Listspace.removeView

removeView(win)

Private method to remove a view (i.e. window)

win
  editor window to be removed

### Listspace.setEditorName

setEditorName(editor, newName)

Change the displayed name of the editor.

editor
  editor window to be changed
newName
  new name to be shown (string or QString)

### Listspace.setSplitOrientation

setSplitOrientation(orientation)

Public method used to set the orientation of the split view.

orientation
  orientation of the split (QSplitter.Horizontal or QSplitter.Vertical)

### Listspace.showView

showView(win, fn=None, changeFocus=True)

Private method to show a view (i.e. window)

win
  editor window to be shown
fn
  filename of this editor
changeFocus
  flag indicating, that the editor should receive the focus (boolean)

### Listspace.tile

tile()

Public method to tile the managed windows.

Up

## WidgetStack

Class implementing a custimized WidgetStack.

### Derived from

QWidgetStack

### Methods

WidgetStack | Constructor
addWidget | Overwritten method to add a new widget.
firstEditor | Public method to retrieve the first editor in the list of managed editors.
hasEditor | Public method to check for an editor.
raiseWidget | Overwritten method to raise a widget.
removeWidget | Overwritten method to remove a widget.

### WidgetStack (Constructor)

WidgetStack(parent)

Constructor

parent
  parent widget (QWidget)

### WidgetStack.addWidget

addWidget(editor, id = -1)

Overwritten method to add a new widget.

editor
  the editor object to be added (QScintilla.Editor.Editor)
id
  id of the widget (integer)

### WidgetStack.firstEditor

firstEditor()

Public method to retrieve the first editor in the list of managed editors.

Returns:
  first editor in list (QScintilla.Editor.Editor)

### WidgetStack.hasEditor

hasEditor(editor)

Public method to check for an editor.

editor
  editor object to check for

Returns:
  flag indicating, whether the editor to be checked belongs to the list of editors managed by this tab widget.

### WidgetStack.raiseWidget

raiseWidget(widgetOrId)

Overwritten method to raise a widget.

widgetOrId
  widget to be raised or its id (QWidget or integer)

### WidgetStack.removeWidget

removeWidget(object)

Overwritten method to remove a widget.

object
  object to be removed (QObject)

Up