RoleSorter QML Type
Ordina i dati in un SortFilterProxyModel in base al nome del ruolo configurato. Altro...
| Import Statement: | import QtQml.Models |
| Since: | Qt 6.10 |
| Inherits: | |
| Status: | Technology preview |
Questo tipo è in anteprima tecnologica ed è soggetto a modifiche.
Proprietà
- roleName : string
Descrizione dettagliata
RoleSorter consente all'utente di ordinare i dati in base al nome del ruolo, come configurato nel modello di origine.
RoleSorter può essere configurato nel modello proxy del filtro di ordinamento come indicato di seguito,
SortFilterProxyModel {
sourceModel: model
sorters: [
RoleSorter { roleName: "firstname" }
]
}Documentazione delle proprietà
roleName : string
Questa proprietà contiene il nome del ruolo che verrà utilizzato per ordinare i dati.
Il valore predefinito è "ruolo di visualizzazione".
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.