HistoryProvider Class Reference
from PyKDE4.kparts import *
Inherits: QObject
Namespace: KParts
Detailed Description
Basic class to manage a history of "items". This class is only meant for fast lookup, if an item is in the history or not.
May be subclassed to implement a persistent history for example. For usage with khtml, just create your provider and call the HistoryProvider constructor _before_ you do any khtml stuff. That way, khtml, using the self()-method, will use your subclassed provider.
Signals | |
cleared () | |
inserted (QString item) | |
updated (QStringList items) | |
Methods | |
__init__ (self, QObject parent=0) | |
clear (self) | |
cleared (self) | |
bool | contains (self, QString item) |
insert (self, QString item) | |
inserted (self, QString item) | |
remove (self, QString item) | |
updated (self, QStringList items) | |
Static Methods | |
KParts.HistoryProvider | self () |
Method Documentation
__init__ | ( | self, | ||
QObject | parent=0 | |||
) |
Creates a KHistoryProvider with an optional parent and name
clear | ( | self ) |
Clears the history. The cleared() signal is emitted after clearing.
cleared | ( | self ) |
Emitted after the history has been cleared.
- Signal syntax:
QObject.connect(source, SIGNAL("cleared()"), target_slot)
bool contains | ( | self, | ||
QString | item | |||
) |
- Returns:
- true if item is present in the history.
insert | ( | self, | ||
QString | item | |||
) |
Inserts item into the history.
inserted | ( | self, | ||
QString | item | |||
) |
Emitted after the item has been inserted
- Signal syntax:
QObject.connect(source, SIGNAL("inserted(const QString&)"), target_slot)
remove | ( | self, | ||
QString | item | |||
) |
Removes item from the history.
KParts.HistoryProvider self | ( | ) |
updated | ( | self, | ||
QStringList | items | |||
) |
This signal is never emitted from this class, it is only meant as an interface for subclasses. Emit this signal to notify others that the history has changed. Put those items that were added or removed from the history into items.
- Signal syntax:
QObject.connect(source, SIGNAL("updated(const QStringList&)"), target_slot)