# eric7.UI.Previewer

Module implementing a previewer widget for HTML, Markdown and ReST files.

### Global Attributes

None

### Classes

Previewer | Class implementing a previewer widget containing a stack of specialized previewers.

### Functions

None

## Previewer

Class implementing a previewer widget containing a stack of specialized previewers.

### Derived from

QStackedWidget

### Class Attributes

None

### Class Methods

None

### Methods

Previewer | Constructor
__editorChanged | Private slot to handle a change of the current editor.
__editorLanguageChanged | Private slot to handle a change of the current editor's language.
__editorTextChanged | Private slot to handle changes of an editor's text.
__isPreviewable | Private method to check, if a preview can be shown for the given editor.
__previewStateChanged | Private slot to toggle the display of the preview.
__processEditor | Private slot to schedule the processing of the current editor's text.
__splitterMoved | Private slot to handle the movement of the embedding splitter's handle.
hide | Public method to hide the preview widget.
preferencesChanged | Public slot handling a change of preferences.
setSplitter | Public method to set the splitter.
show | Public method to show the preview widget.
shutdown | Public method to perform shutdown actions.

### Static Methods

None

#### Previewer (Constructor)

Previewer(viewmanager, parent=None)

Constructor

viewmanager (ViewManager)
  reference to the viewmanager object
parent (QWidget)
  reference to the parent widget

#### Previewer.__editorChanged

__editorChanged(editor)

Private slot to handle a change of the current editor.

editor (Editor)
  reference to the editor

#### Previewer.__editorLanguageChanged

__editorLanguageChanged(editor)

Private slot to handle a change of the current editor's language.

editor (Editor)
  reference to the editor

#### Previewer.__editorTextChanged

__editorTextChanged(editor)

Private slot to handle changes of an editor's text.

editor (Editor)
  reference to the editor

#### Previewer.__isPreviewable

__isPreviewable(editor)

Private method to check, if a preview can be shown for the given editor.

editor (Editor)
  reference to an editor

Return:
  flag indicating if a preview can be shown

Return Type:
  bool

#### Previewer.__previewStateChanged

__previewStateChanged(on)

Private slot to toggle the display of the preview.

on (bool)
  flag indicating to show a preview

#### Previewer.__processEditor

__processEditor()

Private slot to schedule the processing of the current editor's text.

#### Previewer.__splitterMoved

__splitterMoved()

Private slot to handle the movement of the embedding splitter's handle.

#### Previewer.hide

hide()

Public method to hide the preview widget.

#### Previewer.preferencesChanged

preferencesChanged()

Public slot handling a change of preferences.

#### Previewer.setSplitter

setSplitter(splitter)

Public method to set the splitter.

splitter (QSplitter)
  reference to the embedding splitter

#### Previewer.show

show()

Public method to show the preview widget.

#### Previewer.shutdown

shutdown()

Public method to perform shutdown actions.

Up