# eric7.Preferences.SubstyleDefinitionDialog

Module implementing the sub-style definition dialog.

### Global Attributes

None

### Classes

SubstyleDefinitionDialog | Class implementing the sub-style definition dialog.

### Functions

None

## SubstyleDefinitionDialog

Class implementing the sub-style definition dialog.

### Derived from

QDialog, Ui_SubstyleDefinitionDialog

### Class Attributes

None

### Class Methods

None

### Methods

SubstyleDefinitionDialog | Constructor
__updateOk | Private slot to update the state of the OK button.
getData | Public method to get the entered data.
on_defaultButton_clicked | Private slot to set the dialog contents to default values.
on_descriptionEdit_textChanged | Private slot handling changes of the description.
on_resetButton_clicked | Private slot to reset the dialog contents.
on_wordsEdit_textChanged | Private slot handling changes of the word list.

### Static Methods

None

#### SubstyleDefinitionDialog (Constructor)

SubstyleDefinitionDialog(lexer, style, substyle, parent=None)

Constructor

lexer (PreferencesLexer)
  reference to the lexer object
style (int)
  style number
substyle (int)
  sub-style number
parent (QWidget)
  reference to the parent widget

#### SubstyleDefinitionDialog.__updateOk

__updateOk()

Private slot to update the state of the OK button.

#### SubstyleDefinitionDialog.getData

getData()

Public method to get the entered data.

Return:
  tuple containing the sub-style description and words list.

Return Type:
  tuple of (str, str)

#### SubstyleDefinitionDialog.on_defaultButton_clicked

on_defaultButton_clicked()

Private slot to set the dialog contents to default values.

#### SubstyleDefinitionDialog.on_descriptionEdit_textChanged

on_descriptionEdit_textChanged(txt)

Private slot handling changes of the description.

txt (str)
  text of the description

#### SubstyleDefinitionDialog.on_resetButton_clicked

on_resetButton_clicked()

Private slot to reset the dialog contents.

#### SubstyleDefinitionDialog.on_wordsEdit_textChanged

on_wordsEdit_textChanged()

Private slot handling changes of the word list.

Up