ProxyMapper
Qt Base Class: QObject
Signature: QObject(self, parent: Optional[PySide6.QtCore.QObject] = None) -> None
Base classes
Name | Children | Inherits |
---|---|---|
Object prettyqt.core.object |
|
⋔ Inheritance diagram
graph TD
1473290764768["itemmodels.ProxyMapper"]
1473299782816["core.Object"]
1473299815024["core.ObjectMixin"]
140713234304496["builtins.object"]
1473288842240["QtCore.QObject"]
1473291690208["Shiboken.Object"]
1473299782816 --> 1473290764768
1473299815024 --> 1473299782816
140713234304496 --> 1473299815024
1473288842240 --> 1473299782816
1473291690208 --> 1473288842240
140713234304496 --> 1473291690208
🛈 DocStrings
Bases: Object
Class to map indexes / ItemSelections from one proxy to another.
Also handles cases like:
When mapping from 1_2 to 2_2, it will find the closest parent ("shared proxy" here), use mapToSource / mapSelectionFromSource until it gets there, and then mapFromSource / mapSelectionFromSource to get down to 2_2.mapper = ProxyMapper(proxy_1_2, proxy_2_1)
index = proxy_1_2.index(0, 0)
mapped_index = mapper.map_index(source=0, target=1, index)
Source code in prettyqt\itemmodels\proxies\proxymapper.py
map_index(source: int, target: int, index: core.ModelIndex) -> core.ModelIndex
Map index from source to target.
Source code in prettyqt\itemmodels\proxies\proxymapper.py
map_selection(source: int, target: int, selection: core.QItemSelection) -> core.QItemSelection
Map selection from source to target.
Source code in prettyqt\itemmodels\proxies\proxymapper.py
⌗ Property table
Qt Property | Type | Doc |
---|---|---|
objectName |
QString |