eric7.Project.FiletypeAssociationDialog

Module implementing a dialog to enter filetype associations for the project.

Global Attributes

None

Classes

FiletypeAssociationDialog Class implementing a dialog to enter filetype associations for the project.

Functions

None


FiletypeAssociationDialog

Class implementing a dialog to enter filetype associations for the project.

Derived from

QDialog, Ui_FiletypeAssociationDialog

Class Attributes

None

Class Methods

None

Methods

FiletypeAssociationDialog Constructor
__createItem Private slot to create a new entry in the association list.
__reformat Private method to reformat the tree.
__resort Private method to resort the tree.
__updateAddButton Private method to update the enabled state of the 'add' button.
getData Public method to get the entered associations into.
on_addAssociationButton_clicked Private slot to add the association displayed to the list.
on_deleteAssociationButton_clicked Private slot to delete the currently selected association of the listbox.
on_filePatternEdit_textChanged Private slot to handle the textChanged signal of the pattern lineedit.
on_filetypeAssociationList_itemSelectionChanged Private slot to handle a change of the selected item.
on_filetypeCombo_currentIndexChanged Private slot handling the selection of a file type.

Static Methods

None

FiletypeAssociationDialog (Constructor)

FiletypeAssociationDialog(project, fileTypesDict, parent=None)

Constructor

project (Project)
reference to the project object
fileTypesDict (dict)
dictionary containing the file type associations
parent (QWidget (optional))
reference to the parent widget (defaults to None)

FiletypeAssociationDialog.__createItem

__createItem(pattern, filetypeStr, fileCategory)

Private slot to create a new entry in the association list.

pattern (str)
pattern of the entry
filetypeStr (str)
file type user string of the entry
fileCategory (str)
category of the file
Return:
reference to the newly generated entry
Return Type:
QTreeWidgetItem

FiletypeAssociationDialog.__reformat

__reformat()

Private method to reformat the tree.

FiletypeAssociationDialog.__resort

__resort()

Private method to resort the tree.

FiletypeAssociationDialog.__updateAddButton

__updateAddButton()

Private method to update the enabled state of the 'add' button.

FiletypeAssociationDialog.getData

getData()

Public method to get the entered associations into.

Return:
dictionary containing the defined file type associations
Return Type:
dict

FiletypeAssociationDialog.on_addAssociationButton_clicked

on_addAssociationButton_clicked()

Private slot to add the association displayed to the list.

FiletypeAssociationDialog.on_deleteAssociationButton_clicked

on_deleteAssociationButton_clicked()

Private slot to delete the currently selected association of the listbox.

FiletypeAssociationDialog.on_filePatternEdit_textChanged

on_filePatternEdit_textChanged(txt)

Private slot to handle the textChanged signal of the pattern lineedit.

txt (str)
text of the line edit

FiletypeAssociationDialog.on_filetypeAssociationList_itemSelectionChanged

on_filetypeAssociationList_itemSelectionChanged()

Private slot to handle a change of the selected item.

FiletypeAssociationDialog.on_filetypeCombo_currentIndexChanged

on_filetypeCombo_currentIndexChanged(index)

Private slot handling the selection of a file type.

index (int)
index of the selected entry
Up