# eric4.Helpviewer.HelpWindow

Module implementing the helpviewer main window.

### Classes

HelpWindow | Class implementing the helpviewer main window.

### Functions

None

## HelpWindow

Class implementing the helpviewer main window.

#### Signals

helpClosed()
  emitted after the window was requested to close down

### Derived from

QMainWindow

### Methods

HelpWindow | Constructor
__about | Private slot to show the about information.
__aboutQt | Private slot to show info about Qt.
__addBookmark | Private slot called to add the displayed file to the bookmarks.
__backward | Private slot called to handle the backward action.
__bookmarkChosen | Private slot called by the bookmarks menu to display the selected file.
__clearHistory | Private slot called to clear the current history.
__close | Private slot called to handle the close action.
__closeAll | Private slot called to handle the close all action.
__copy | Private slot called to handle the copy action.
__currentChanged | Private slot to handle the currentChanged signal.
__editBookmarks | Private slot called to edit the bookmarks.
__find | Private slot to handle the find action.
__forward | Private slot called to handle the forward action.
__historyChosen | Private slot called by the history menu to display the selected file.
__home | Private slot called to handle the home action.
__initActions | Private method to define the user interface actions.
__initMenus | Private method to create the menus.
__initTabContextMenu | Private mezhod to create the tab context menu.
__initToolbars | Private method to create the toolbars.
__openFile | Private slot called to open a file.
__openFileNewTab | Private slot called to open a file in a new tab.
__pathSelected | Private slot called when a file is selected in the combobox.
__printFile | Private slot called to print the displayed file.
__readBookmarks | Private function to read the bookmarks from the eric4 preferences file.
__readHistory | Private function to read the history from the eric4 preferences file.
__reload | Private slot called to handle the reload action.
__setBackwardAvailable | Private slot called when backward references are available.
__setForwardAvailable | Private slot called when forward references are available.
__showBookmarksMenu | Private slot called in order to show the bookmarks menu.
__showContextMenu | Private slot to show the tab context menu.
__showHistoryMenu | Private slot called in order to show the history menu.
__sourceChanged | Private slot called when the displayed text of the combobox is changed.
__tabContextMenuClose | Private method to close the selected tab.
__tabContextMenuMoveLeft | Private method to move a tab one position to the left.
__tabContextMenuMoveRight | Private method to move a tab one position to the right.
__tabContextMenuPrint | Private method to print the selected tab.
__whatsThis | Private slot called in to enter Whats This mode.
__zoomIn | Private slot called to handle the zoom in action.
__zoomOut | Private slot called to handle the zoom out action.
closeEvent | Private event handler for the close event.
currentBrowser | Public method to get a reference to the current help browser.
getActions | Public method to get a list of all actions.
newBrowser | Public method to create a new help browser tab.
newTab | Public slot called to open a new help window tab.
newWindow | Public slot called to open a new help browser dialog.
writeBookmarks | Public function to write the bookmarks to the eric4 preferences file.

#### HelpWindow (Constructor)

HelpWindow(home, path, parent, name, fromEric = False)

Constructor

home
  the helpfile to be shown (string or QString)
path
  the path of the working dir (usually '.') (string or QString)
parent
  parent widget of this window (QWidget)
name
  name of this window (string or QString)
fromEric
  flag indicating whether it was called from within eric4 (boolean)

#### HelpWindow.__about

__about()

Private slot to show the about information.

#### HelpWindow.__aboutQt

__aboutQt()

Private slot to show info about Qt.

#### HelpWindow.__addBookmark

__addBookmark()

Private slot called to add the displayed file to the bookmarks.

#### HelpWindow.__backward

__backward()

Private slot called to handle the backward action.

#### HelpWindow.__bookmarkChosen

__bookmarkChosen(act)

Private slot called by the bookmarks menu to display the selected file.

act
  reference to the action that triggered (QAction)

#### HelpWindow.__clearHistory

__clearHistory()

Private slot called to clear the current history.

#### HelpWindow.__close

__close()

Private slot called to handle the close action.

#### HelpWindow.__closeAll

__closeAll()

Private slot called to handle the close all action.

#### HelpWindow.__copy

__copy()

Private slot called to handle the copy action.

#### HelpWindow.__currentChanged

__currentChanged(index)

Private slot to handle the currentChanged signal.

index
  index of the current tab

#### HelpWindow.__editBookmarks

__editBookmarks()

Private slot called to edit the bookmarks.

It opens the bookmark dialog to rearrange, delete or edit the collection of bookmarks.

#### HelpWindow.__find

__find()

Private slot to handle the find action.

It opens the search dialog in order to perform the various search actions and to collect the various search info.

#### HelpWindow.__forward

__forward()

Private slot called to handle the forward action.

#### HelpWindow.__historyChosen

__historyChosen(act)

Private slot called by the history menu to display the selected file.

act
  reference to the action that triggered (QAction)

#### HelpWindow.__home

__home()

Private slot called to handle the home action.

#### HelpWindow.__initActions

__initActions()

Private method to define the user interface actions.

#### HelpWindow.__initMenus

__initMenus()

Private method to create the menus.

#### HelpWindow.__initTabContextMenu

__initTabContextMenu()

Private mezhod to create the tab context menu.

#### HelpWindow.__initToolbars

__initToolbars()

Private method to create the toolbars.

#### HelpWindow.__openFile

__openFile()

Private slot called to open a file.

#### HelpWindow.__openFileNewTab

__openFileNewTab()

Private slot called to open a file in a new tab.

#### HelpWindow.__pathSelected

__pathSelected(path)

Private slot called when a file is selected in the combobox.

#### HelpWindow.__printFile

__printFile(document = None)

Private slot called to print the displayed file.

document
  reference to the document to be printed (QTextDocument)

#### HelpWindow.__readBookmarks

__readBookmarks()

Private function to read the bookmarks from the eric4 preferences file.

#### HelpWindow.__readHistory

__readHistory()

Private function to read the history from the eric4 preferences file.

#### HelpWindow.__reload

__reload()

Private slot called to handle the reload action.

#### HelpWindow.__setBackwardAvailable

__setBackwardAvailable(b)

Private slot called when backward references are available.

#### HelpWindow.__setForwardAvailable

__setForwardAvailable(b)

Private slot called when forward references are available.

#### HelpWindow.__showBookmarksMenu

__showBookmarksMenu()

Private slot called in order to show the bookmarks menu.

#### HelpWindow.__showContextMenu

__showContextMenu(coord, index)

Private slot to show the tab context menu.

coord
  the position of the mouse pointer (QPoint)
index
  index of the tab the menu is requested for (integer)

#### HelpWindow.__showHistoryMenu

__showHistoryMenu()

Private slot called in order to show the history menu.

#### HelpWindow.__sourceChanged

__sourceChanged(url)

Private slot called when the displayed text of the combobox is changed.

#### HelpWindow.__tabContextMenuClose

__tabContextMenuClose()

Private method to close the selected tab.

#### HelpWindow.__tabContextMenuMoveLeft

__tabContextMenuMoveLeft()

Private method to move a tab one position to the left.

#### HelpWindow.__tabContextMenuMoveRight

__tabContextMenuMoveRight()

Private method to move a tab one position to the right.

#### HelpWindow.__tabContextMenuPrint

__tabContextMenuPrint()

Private method to print the selected tab.

#### HelpWindow.__whatsThis

__whatsThis()

Private slot called in to enter Whats This mode.

#### HelpWindow.__zoomIn

__zoomIn()

Private slot called to handle the zoom in action.

#### HelpWindow.__zoomOut

__zoomOut()

Private slot called to handle the zoom out action.

#### HelpWindow.closeEvent

closeEvent(e)

Private event handler for the close event.

This handler saves the current history entries and the window geomety to the eric4 Preferences file.

e
  the close event (QCloseEvent)
  This event is simply accepted after the history has been saved and all window references have been deleted.

#### HelpWindow.currentBrowser

currentBrowser()

Public method to get a reference to the current help browser.

Returns:
  reference to the current help browser (HelpBrowser)

#### HelpWindow.getActions

getActions()

Public method to get a list of all actions.

Returns:
  list of all actions (list of E4Action)

#### HelpWindow.newBrowser

newBrowser(link)

Public method to create a new help browser tab.

link
  link to be shown (string or QString)

#### HelpWindow.newTab

newTab(link = None)

Public slot called to open a new help window tab.

link
  file to be displayed in the new window (QUrl)

#### HelpWindow.newWindow

newWindow(link = None)

Public slot called to open a new help browser dialog.

link
  file to be displayed in the new window (QUrl)

#### HelpWindow.writeBookmarks

writeBookmarks()

Public function to write the bookmarks to the eric4 preferences file.

Up