qabstractproxymodel.sip 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. // qabstractproxymodel.sip generated by MetaSIP
  2. //
  3. // This file is part of the QtCore Python extension module.
  4. //
  5. // Copyright (c) 2026 Riverbank Computing Limited <info@riverbankcomputing.com>
  6. //
  7. // This file is part of PyQt6.
  8. //
  9. // This file may be used under the terms of the GNU General Public License
  10. // version 3.0 as published by the Free Software Foundation and appearing in
  11. // the file LICENSE included in the packaging of this file. Please review the
  12. // following information to ensure the GNU General Public License version 3.0
  13. // requirements will be met: http://www.gnu.org/copyleft/gpl.html.
  14. //
  15. // If you do not wish to use this file under the terms of the GPL version 3.0
  16. // then you may purchase a commercial license. For more information contact
  17. // info@riverbankcomputing.com.
  18. //
  19. // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
  20. // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  21. class QAbstractProxyModel : public QAbstractItemModel
  22. {
  23. %TypeHeaderCode
  24. #include <qabstractproxymodel.h>
  25. %End
  26. public:
  27. explicit QAbstractProxyModel(QObject *parent /TransferThis/ = 0);
  28. virtual ~QAbstractProxyModel();
  29. virtual void setSourceModel(QAbstractItemModel *sourceModel /KeepReference/);
  30. QAbstractItemModel *sourceModel() const;
  31. virtual QModelIndex mapToSource(const QModelIndex &proxyIndex) const = 0;
  32. virtual QModelIndex mapFromSource(const QModelIndex &sourceIndex) const = 0;
  33. virtual QItemSelection mapSelectionToSource(const QItemSelection &selection) const;
  34. virtual QItemSelection mapSelectionFromSource(const QItemSelection &selection) const;
  35. virtual bool submit();
  36. virtual void revert();
  37. virtual QVariant data(const QModelIndex &proxyIndex, int role = Qt::DisplayRole) const;
  38. virtual bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole);
  39. virtual QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
  40. virtual bool setHeaderData(int section, Qt::Orientation orientation, const QVariant &value, int role = Qt::EditRole);
  41. virtual QMap<int, QVariant> itemData(const QModelIndex &index) const;
  42. virtual Qt::ItemFlags flags(const QModelIndex &index) const;
  43. virtual bool setItemData(const QModelIndex &index, const QMap<int, QVariant> &roles);
  44. virtual QModelIndex buddy(const QModelIndex &index) const;
  45. virtual bool canFetchMore(const QModelIndex &parent) const;
  46. virtual void fetchMore(const QModelIndex &parent);
  47. virtual void sort(int column, Qt::SortOrder order = Qt::AscendingOrder);
  48. virtual QSize span(const QModelIndex &index) const;
  49. virtual bool hasChildren(const QModelIndex &parent = QModelIndex()) const;
  50. virtual QMimeData *mimeData(const QModelIndexList &indexes) const /TransferBack/;
  51. virtual QStringList mimeTypes() const;
  52. virtual Qt::DropActions supportedDropActions() const;
  53. virtual QModelIndex sibling(int row, int column, const QModelIndex &idx) const;
  54. signals:
  55. void sourceModelChanged();
  56. public:
  57. virtual bool canDropMimeData(const QMimeData *data, Qt::DropAction action, int row, int column, const QModelIndex &parent) const;
  58. virtual bool dropMimeData(const QMimeData *data, Qt::DropAction action, int row, int column, const QModelIndex &parent);
  59. virtual Qt::DropActions supportedDragActions() const;
  60. virtual bool clearItemData(const QModelIndex &index);
  61. virtual QHash<int, QByteArray> roleNames() const;
  62. };