eric4.Helpviewer.HelpLanguagesDialog

Module implementing a dialog to configure the preferred languages.

Global Attributes

None

Classes

HelpLanguagesDialog Class implementing a dialog to configure the preferred languages.

Functions

None


HelpLanguagesDialog

Class implementing a dialog to configure the preferred languages.

Derived from

QDialog, Ui_HelpLanguagesDialog

Class Attributes

None

Methods

HelpLanguagesDialog Constructor
__currentChanged Private slot to handle a change of the current selection.
accept Public method to accept the data entered.
defaultAcceptLanguages Class method to get the list of default accept languages.
expand Class method to expand a language enum to a readable languages list.
httpString Class method to convert a list of acceptable languages into a byte array that can be sent along with the Accept-Language http header (see RFC 2616).
on_addButton_clicked Private slot to add a language to the list of acceptable languages.
on_downButton_clicked Private slot to move a language down.
on_removeButton_clicked Private slot to remove a language from the list of acceptable languages.
on_upButton_clicked Private slot to move a language up.

HelpLanguagesDialog (Constructor)

HelpLanguagesDialog(parent = None)

Constructor

parent
reference to the parent widget (QWidget)

HelpLanguagesDialog.__currentChanged

__currentChanged(current, previous)

Private slot to handle a change of the current selection.

current
index of the currently selected item (QModelIndex)
previous
index of the previously selected item (QModelIndex)

HelpLanguagesDialog.accept

accept()

Public method to accept the data entered.

HelpLanguagesDialog.defaultAcceptLanguages

defaultAcceptLanguages()

Class method to get the list of default accept languages.

Returns:
list of acceptable languages (QStringList)

HelpLanguagesDialog.expand

expand(language)

Class method to expand a language enum to a readable languages list.

language
language number (QLocale.Language)
Returns:
list of expanded language names (QStringList)

HelpLanguagesDialog.httpString

httpString(languages)

Class method to convert a list of acceptable languages into a byte array that can be sent along with the Accept-Language http header (see RFC 2616).

languages
list of acceptable languages (QStringList)
Returns:
converted list (QByteArray)

HelpLanguagesDialog.on_addButton_clicked

on_addButton_clicked()

Private slot to add a language to the list of acceptable languages.

HelpLanguagesDialog.on_downButton_clicked

on_downButton_clicked()

Private slot to move a language down.

HelpLanguagesDialog.on_removeButton_clicked

on_removeButton_clicked()

Private slot to remove a language from the list of acceptable languages.

HelpLanguagesDialog.on_upButton_clicked

on_upButton_clicked()

Private slot to move a language up.

Up