eric7.WebBrowser.OpenSearch.OpenSearchEngineModel

Module implementing a model for search engines.

Global Attributes

None

Classes

OpenSearchEngineModel Class implementing a model for search engines.

Functions

None


OpenSearchEngineModel

Class implementing a model for search engines.

Derived from

QAbstractTableModel

Class Attributes

None

Class Methods

None

Methods

OpenSearchEngineModel Constructor
__enginesChanged Private slot handling a change of the registered engines.
columnCount Public method to get the number of columns of the model.
data Public method to get data from the model.
flags Public method to get flags for a model cell.
headerData Public method to get the header data.
removeRows Public method to remove entries from the model.
rowCount Public method to get the number of rows of the model.
setData Public method to set the data of a model cell.

Static Methods

None

OpenSearchEngineModel (Constructor)

OpenSearchEngineModel(manager, parent=None)

Constructor

manager (OpenSearchManager)
reference to the search engine manager
parent (QObject)
reference to the parent object

OpenSearchEngineModel.__enginesChanged

__enginesChanged()

Private slot handling a change of the registered engines.

OpenSearchEngineModel.columnCount

columnCount(parent=None)

Public method to get the number of columns of the model.

parent (QModelIndex)
parent index (unused)
Return:
number of columns
Return Type:
int

OpenSearchEngineModel.data

data(index, role)

Public method to get data from the model.

index (QModelIndex)
index to get data for
role (int)
role of the data to retrieve
Return:
requested data
Return Type:
Any

OpenSearchEngineModel.flags

flags(index)

Public method to get flags for a model cell.

index (QModelIndex)
index of the model cell
Return:
flags
Return Type:
Qt.ItemFlags

OpenSearchEngineModel.headerData

headerData(section, orientation, role=Qt.ItemDataRole.DisplayRole)

Public method to get the header data.

section (int)
section number
orientation (Qt.Orientation)
header orientation
role (Qt.ItemDataRole)
data role
Return:
header data
Return Type:
Any

OpenSearchEngineModel.removeRows

removeRows(row, count, parent=None)

Public method to remove entries from the model.

row (int)
start row
count (int)
number of rows to remove
parent (QModelIndex)
parent index
Return:
flag indicating success
Return Type:
bool

OpenSearchEngineModel.rowCount

rowCount(parent=None)

Public method to get the number of rows of the model.

parent (QModelIndex)
parent index
Return:
number of rows
Return Type:
int

OpenSearchEngineModel.setData

setData(index, value, role=Qt.ItemDataRole.EditRole)

Public method to set the data of a model cell.

index (QModelIndex)
index of the model cell
value (Any)
value to be set
role (int)
role of the data
Return:
flag indicating success
Return Type:
bool
Up