[−][src]Struct qt_widgets::QListWidget
The QListWidget class provides an item-based list widget.
C++ class: QListWidget
.
The QListWidget class provides an item-based list widget.
QListWidget is a convenience class that provides a list view similar to the one supplied by QListView, but with a classic item-based interface for adding and removing items. QListWidget uses an internal model to manage each QListWidgetItem in the list.
For a more flexible list view widget, use the QListView class with a standard model.
List widgets are constructed in the same way as other widgets:
QListWidget *listWidget = new QListWidget(this);
The selectionMode() of a list widget determines how many of the items in the list can be selected at the same time, and whether complex selections of items can be created. This can be set with the setSelectionMode() function.
There are two ways to add items to the list: they can be constructed with the list widget as their parent widget, or they can be constructed with no parent widget and added to the list later. If a list widget already exists when the items are constructed, the first method is easier to use:
new QListWidgetItem(tr("Oak"), listWidget); new QListWidgetItem(tr("Fir"), listWidget); new QListWidgetItem(tr("Pine"), listWidget);
If you need to insert a new item into the list at a particular position, then it should be constructed without a parent widget. The insertItem() function should then be used to place it within the list. The list widget will take ownership of the item.
QListWidgetItem *newItem = new QListWidgetItem; newItem->setText(itemText); listWidget->insertItem(row, newItem);
For multiple items, insertItems() can be used instead. The number of items in the list is found with the count() function. To remove items from the list, use takeItem().
The current item in the list can be found with currentItem(), and changed with setCurrentItem(). The user can also change the current item by navigating with the keyboard or clicking on a different item. When the current item changes, the currentItemChanged() signal is emitted with the new current item and the item that was previously current.
Methods
impl QListWidget
[src]
pub fn slot_scroll_to_item(
&self
) -> Receiver<(*const QListWidgetItem, ScrollHint)>
[src]
&self
) -> Receiver<(*const QListWidgetItem, ScrollHint)>
Scrolls the view if necessary to ensure that the item is visible.
Returns a built-in Qt slot QListWidget::scrollToItem
that can be passed to qt_core::Signal::connect
.
Scrolls the view if necessary to ensure that the item is visible.
hint specifies where the item should be located after the operation.
pub fn slot_clear(&self) -> Receiver<()>
[src]
Removes all items and selections in the view.
Returns a built-in Qt slot QListWidget::clear
that can be passed to qt_core::Signal::connect
.
Removes all items and selections in the view.
Warning: All items will be permanently deleted.
pub fn item_pressed(&self) -> Signal<(*mut QListWidgetItem,)>
[src]
This signal is emitted with the specified item when a mouse button is pressed on an item in the widget.
Returns a built-in Qt signal QListWidget::itemPressed
that can be passed to qt_core::Signal::connect
.
This signal is emitted with the specified item when a mouse button is pressed on an item in the widget.
See also itemClicked() and itemDoubleClicked().
pub fn item_clicked(&self) -> Signal<(*mut QListWidgetItem,)>
[src]
This signal is emitted with the specified item when a mouse button is clicked on an item in the widget.
Returns a built-in Qt signal QListWidget::itemClicked
that can be passed to qt_core::Signal::connect
.
This signal is emitted with the specified item when a mouse button is clicked on an item in the widget.
See also itemPressed() and itemDoubleClicked().
pub fn item_double_clicked(&self) -> Signal<(*mut QListWidgetItem,)>
[src]
This signal is emitted with the specified item when a mouse button is double clicked on an item in the widget.
Returns a built-in Qt signal QListWidget::itemDoubleClicked
that can be passed to qt_core::Signal::connect
.
This signal is emitted with the specified item when a mouse button is double clicked on an item in the widget.
See also itemClicked() and itemPressed().
pub fn item_activated(&self) -> Signal<(*mut QListWidgetItem,)>
[src]
This signal is emitted when the item is activated. The item is activated when the user clicks or double clicks on it, depending on the system configuration. It is also activated when the user presses the activation key (on Windows and X11 this is the Return key, on Mac OS X it is Command+O).
Returns a built-in Qt signal QListWidget::itemActivated
that can be passed to qt_core::Signal::connect
.
This signal is emitted when the item is activated. The item is activated when the user clicks or double clicks on it, depending on the system configuration. It is also activated when the user presses the activation key (on Windows and X11 this is the Return key, on Mac OS X it is Command+O).
pub fn item_entered(&self) -> Signal<(*mut QListWidgetItem,)>
[src]
This signal is emitted when the mouse cursor enters an item. The item is the item entered. This signal is only emitted when mouseTracking is turned on, or when a mouse button is pressed while moving into an item.
Returns a built-in Qt signal QListWidget::itemEntered
that can be passed to qt_core::Signal::connect
.
This signal is emitted when the mouse cursor enters an item. The item is the item entered. This signal is only emitted when mouseTracking is turned on, or when a mouse button is pressed while moving into an item.
See also QWidget::setMouseTracking().
pub fn item_changed(&self) -> Signal<(*mut QListWidgetItem,)>
[src]
This signal is emitted whenever the data of item has changed.
Returns a built-in Qt signal QListWidget::itemChanged
that can be passed to qt_core::Signal::connect
.
This signal is emitted whenever the data of item has changed.
pub fn current_item_changed(
&self
) -> Signal<(*mut QListWidgetItem, *mut QListWidgetItem)>
[src]
&self
) -> Signal<(*mut QListWidgetItem, *mut QListWidgetItem)>
This signal is emitted whenever the current item changes.
Returns a built-in Qt signal QListWidget::currentItemChanged
that can be passed to qt_core::Signal::connect
.
This signal is emitted whenever the current item changes.
previous is the item that previously had the focus; current is the new current item.
pub fn current_text_changed(&self) -> Signal<(*const QString,)>
[src]
This signal is emitted whenever the current item changes.
Returns a built-in Qt signal QListWidget::currentTextChanged
that can be passed to qt_core::Signal::connect
.
This signal is emitted whenever the current item changes.
currentText is the text data in the current item. If there is no current item, the currentText is invalid.
pub fn current_row_changed(&self) -> Signal<(c_int,)>
[src]
This signal is emitted whenever the current item changes.
Returns a built-in Qt signal QListWidget::currentRowChanged
that can be passed to qt_core::Signal::connect
.
This signal is emitted whenever the current item changes.
currentRow is the row of the current item. If there is no current item, the currentRow is -1.
Note: Notifier signal for property currentRow.
pub fn item_selection_changed(&self) -> Signal<()>
[src]
This signal is emitted whenever the selection changes.
Returns a built-in Qt signal QListWidget::itemSelectionChanged
that can be passed to qt_core::Signal::connect
.
This signal is emitted whenever the selection changes.
See also selectedItems(), QListWidgetItem::isSelected(), and currentItemChanged().
pub unsafe fn add_item_q_string(&mut self, label: impl CastInto<Ref<QString>>)
[src]
Inserts an item with the text label at the end of the list widget.
Calls C++ function: void QListWidget::addItem(const QString& label)
.
Inserts an item with the text label at the end of the list widget.
pub unsafe fn add_item_q_list_widget_item(
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
[src]
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
Inserts the item at the end of the list widget.
Calls C++ function: void QListWidget::addItem(QListWidgetItem* item)
.
Inserts the item at the end of the list widget.
Warning: A QListWidgetItem can only be added to a QListWidget once. Adding the same QListWidgetItem multiple times to a QListWidget will result in undefined behavior.
See also insertItem().
pub unsafe fn add_items(&mut self, labels: impl CastInto<Ref<QStringList>>)
[src]
Inserts items with the text labels at the end of the list widget.
Calls C++ function: void QListWidget::addItems(const QStringList& labels)
.
Inserts items with the text labels at the end of the list widget.
See also insertItems().
pub unsafe fn clear(&mut self)
[src]
Removes all items and selections in the view.
Calls C++ function: [slot] void QListWidget::clear()
.
Removes all items and selections in the view.
Warning: All items will be permanently deleted.
pub unsafe fn close_persistent_editor(
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
[src]
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
Closes the persistent editor for the given item.
Calls C++ function: void QListWidget::closePersistentEditor(QListWidgetItem* item)
.
Closes the persistent editor for the given item.
See also openPersistentEditor().
pub unsafe fn count(&self) -> c_int
[src]
This property holds the number of items in the list including any hidden items.
Calls C++ function: int QListWidget::count() const
.
This property holds the number of items in the list including any hidden items.
Access functions:
int | count() const |
pub unsafe fn current_item(&self) -> MutPtr<QListWidgetItem>
[src]
Returns the current item.
Calls C++ function: QListWidgetItem* QListWidget::currentItem() const
.
Returns the current item.
See also setCurrentItem().
pub unsafe fn current_row(&self) -> c_int
[src]
This property holds the row of the current item.
Calls C++ function: int QListWidget::currentRow() const
.
This property holds the row of the current item.
Depending on the current selection mode, the row may also be selected.
Access functions:
int | currentRow() const |
void | setCurrentRow(int row) |
void | setCurrentRow(int row, QItemSelectionModel::SelectionFlags command) |
Notifier signal:
void | currentRowChanged(int currentRow) |
pub unsafe fn drop_event(&mut self, event: impl CastInto<MutPtr<QDropEvent>>)
[src]
Reimplemented from QWidget::dropEvent().
Calls C++ function: virtual void QListWidget::dropEvent(QDropEvent* event)
.
Reimplemented from QWidget::dropEvent().
pub unsafe fn edit_item(&mut self, item: impl CastInto<MutPtr<QListWidgetItem>>)
[src]
Starts editing the item if it is editable.
Calls C++ function: void QListWidget::editItem(QListWidgetItem* item)
.
Starts editing the item if it is editable.
pub unsafe fn find_items(
&self,
text: impl CastInto<Ref<QString>>,
flags: QFlags<MatchFlag>
) -> CppBox<QListOfQListWidgetItem>
[src]
&self,
text: impl CastInto<Ref<QString>>,
flags: QFlags<MatchFlag>
) -> CppBox<QListOfQListWidgetItem>
Finds items with the text that matches the string text using the given flags.
Calls C++ function: QList<QListWidgetItem*> QListWidget::findItems(const QString& text, QFlags<Qt::MatchFlag> flags) const
.
Finds items with the text that matches the string text using the given flags.
pub unsafe fn insert_item_int_q_list_widget_item(
&mut self,
row: c_int,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
[src]
&mut self,
row: c_int,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
Inserts the item at the position in the list given by row.
Calls C++ function: void QListWidget::insertItem(int row, QListWidgetItem* item)
.
Inserts the item at the position in the list given by row.
See also addItem().
pub unsafe fn insert_item_int_q_string(
&mut self,
row: c_int,
label: impl CastInto<Ref<QString>>
)
[src]
&mut self,
row: c_int,
label: impl CastInto<Ref<QString>>
)
Inserts an item with the text label in the list widget at the position given by row.
Calls C++ function: void QListWidget::insertItem(int row, const QString& label)
.
Inserts an item with the text label in the list widget at the position given by row.
See also addItem().
pub unsafe fn insert_items(
&mut self,
row: c_int,
labels: impl CastInto<Ref<QStringList>>
)
[src]
&mut self,
row: c_int,
labels: impl CastInto<Ref<QStringList>>
)
Inserts items from the list of labels into the list, starting at the given row.
Calls C++ function: void QListWidget::insertItems(int row, const QStringList& labels)
.
Inserts items from the list of labels into the list, starting at the given row.
See also insertItem() and addItem().
[src]
Returns true
if the item is explicitly hidden; otherwise returns false
.
Calls C++ function: bool QListWidget::isItemHidden(const QListWidgetItem* item) const
.
Returns true
if the item is explicitly hidden; otherwise returns false
.
This function is deprecated. Use QListWidgetItem::isHidden() instead.
pub unsafe fn is_item_selected(
&self,
item: impl CastInto<Ptr<QListWidgetItem>>
) -> bool
[src]
&self,
item: impl CastInto<Ptr<QListWidgetItem>>
) -> bool
Returns true
if item is selected; otherwise returns false
.
Calls C++ function: bool QListWidget::isItemSelected(const QListWidgetItem* item) const
.
Returns true
if item is selected; otherwise returns false
.
This function is deprecated. Use QListWidgetItem::isSelected() instead.
pub unsafe fn is_persistent_editor_open(
&self,
item: impl CastInto<MutPtr<QListWidgetItem>>
) -> bool
[src]
&self,
item: impl CastInto<MutPtr<QListWidgetItem>>
) -> bool
Returns whether a persistent editor is open for item item.
Calls C++ function: bool QListWidget::isPersistentEditorOpen(QListWidgetItem* item) const
.
Returns whether a persistent editor is open for item item.
This function was introduced in Qt 5.10.
See also openPersistentEditor() and closePersistentEditor().
This item is available if any(cpp_lib_version="5.11.3", cpp_lib_version="5.12.2", cpp_lib_version="5.13.0")
.
pub unsafe fn is_sorting_enabled(&self) -> bool
[src]
This property holds whether sorting is enabled
Calls C++ function: bool QListWidget::isSortingEnabled() const
.
This property holds whether sorting is enabled
If this property is true
, sorting is enabled for the list; if the property is false, sorting is not enabled.
The default value is false.
This property was introduced in Qt 4.2.
Access functions:
bool | isSortingEnabled() const |
void | setSortingEnabled(bool enable) |
pub unsafe fn item(&self, row: c_int) -> MutPtr<QListWidgetItem>
[src]
Returns the item that occupies the given row in the list if one has been set; otherwise returns 0.
Calls C++ function: QListWidgetItem* QListWidget::item(int row) const
.
Returns the item that occupies the given row in the list if one has been set; otherwise returns 0.
See also row().
pub unsafe fn item_at_1a(
&self,
p: impl CastInto<Ref<QPoint>>
) -> MutPtr<QListWidgetItem>
[src]
&self,
p: impl CastInto<Ref<QPoint>>
) -> MutPtr<QListWidgetItem>
Returns a pointer to the item at the coordinates p. The coordinates are relative to the list widget's viewport().
Calls C++ function: QListWidgetItem* QListWidget::itemAt(const QPoint& p) const
.
Returns a pointer to the item at the coordinates p. The coordinates are relative to the list widget's viewport().
pub unsafe fn item_at_2a(&self, x: c_int, y: c_int) -> MutPtr<QListWidgetItem>
[src]
This is an overloaded function.
Calls C++ function: QListWidgetItem* QListWidget::itemAt(int x, int y) const
.
This is an overloaded function.
Returns a pointer to the item at the coordinates (x, y). The coordinates are relative to the list widget's viewport().
pub unsafe fn item_widget(
&self,
item: impl CastInto<MutPtr<QListWidgetItem>>
) -> MutPtr<QWidget>
[src]
&self,
item: impl CastInto<MutPtr<QListWidgetItem>>
) -> MutPtr<QWidget>
Returns the widget displayed in the given item.
Calls C++ function: QWidget* QListWidget::itemWidget(QListWidgetItem* item) const
.
Returns the widget displayed in the given item.
This function was introduced in Qt 4.1.
See also setItemWidget() and removeItemWidget().
pub unsafe fn meta_object(&self) -> Ptr<QMetaObject>
[src]
Calls C++ function: virtual const QMetaObject* QListWidget::metaObject() const
.
pub unsafe fn new_1a(
parent: impl CastInto<MutPtr<QWidget>>
) -> CppBox<QListWidget>
[src]
parent: impl CastInto<MutPtr<QWidget>>
) -> CppBox<QListWidget>
Constructs an empty QListWidget with the given parent.
Calls C++ function: [constructor] void QListWidget::QListWidget(QWidget* parent = …)
.
Constructs an empty QListWidget with the given parent.
pub unsafe fn new_0a() -> CppBox<QListWidget>
[src]
The QListWidget class provides an item-based list widget.
Calls C++ function: [constructor] void QListWidget::QListWidget()
.
The QListWidget class provides an item-based list widget.
QListWidget is a convenience class that provides a list view similar to the one supplied by QListView, but with a classic item-based interface for adding and removing items. QListWidget uses an internal model to manage each QListWidgetItem in the list.
For a more flexible list view widget, use the QListView class with a standard model.
List widgets are constructed in the same way as other widgets:
QListWidget *listWidget = new QListWidget(this);
The selectionMode() of a list widget determines how many of the items in the list can be selected at the same time, and whether complex selections of items can be created. This can be set with the setSelectionMode() function.
There are two ways to add items to the list: they can be constructed with the list widget as their parent widget, or they can be constructed with no parent widget and added to the list later. If a list widget already exists when the items are constructed, the first method is easier to use:
new QListWidgetItem(tr("Oak"), listWidget); new QListWidgetItem(tr("Fir"), listWidget); new QListWidgetItem(tr("Pine"), listWidget);
If you need to insert a new item into the list at a particular position, then it should be constructed without a parent widget. The insertItem() function should then be used to place it within the list. The list widget will take ownership of the item.
QListWidgetItem *newItem = new QListWidgetItem; newItem->setText(itemText); listWidget->insertItem(row, newItem);
For multiple items, insertItems() can be used instead. The number of items in the list is found with the count() function. To remove items from the list, use takeItem().
The current item in the list can be found with currentItem(), and changed with setCurrentItem(). The user can also change the current item by navigating with the keyboard or clicking on a different item. When the current item changes, the currentItemChanged() signal is emitted with the new current item and the item that was previously current.
pub unsafe fn open_persistent_editor(
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
[src]
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
Opens an editor for the given item. The editor remains open after editing.
Calls C++ function: void QListWidget::openPersistentEditor(QListWidgetItem* item)
.
Opens an editor for the given item. The editor remains open after editing.
See also closePersistentEditor().
pub unsafe fn qt_metacall(
&mut self,
arg1: Call,
arg2: c_int,
arg3: impl CastInto<MutPtr<*mut c_void>>
) -> c_int
[src]
&mut self,
arg1: Call,
arg2: c_int,
arg3: impl CastInto<MutPtr<*mut c_void>>
) -> c_int
Calls C++ function: virtual int QListWidget::qt_metacall(QMetaObject::Call arg1, int arg2, void** arg3)
.
pub unsafe fn qt_metacast(
&mut self,
arg1: impl CastInto<Ptr<c_char>>
) -> MutPtr<c_void>
[src]
&mut self,
arg1: impl CastInto<Ptr<c_char>>
) -> MutPtr<c_void>
Calls C++ function: virtual void* QListWidget::qt_metacast(const char* arg1)
.
pub unsafe fn remove_item_widget(
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
[src]
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
Removes the widget set on the given item.
Calls C++ function: void QListWidget::removeItemWidget(QListWidgetItem* item)
.
Removes the widget set on the given item.
To remove an item (row) from the list entirely, either delete the item or use takeItem().
This function was introduced in Qt 4.3.
See also itemWidget() and setItemWidget().
pub unsafe fn row(&self, item: impl CastInto<Ptr<QListWidgetItem>>) -> c_int
[src]
Returns the row containing the given item.
Calls C++ function: int QListWidget::row(const QListWidgetItem* item) const
.
Returns the row containing the given item.
See also item().
pub unsafe fn scroll_to_item_2a(
&mut self,
item: impl CastInto<Ptr<QListWidgetItem>>,
hint: ScrollHint
)
[src]
&mut self,
item: impl CastInto<Ptr<QListWidgetItem>>,
hint: ScrollHint
)
Scrolls the view if necessary to ensure that the item is visible.
Calls C++ function: [slot] void QListWidget::scrollToItem(const QListWidgetItem* item, QAbstractItemView::ScrollHint hint = …)
.
Scrolls the view if necessary to ensure that the item is visible.
hint specifies where the item should be located after the operation.
pub unsafe fn scroll_to_item_1a(
&mut self,
item: impl CastInto<Ptr<QListWidgetItem>>
)
[src]
&mut self,
item: impl CastInto<Ptr<QListWidgetItem>>
)
Scrolls the view if necessary to ensure that the item is visible.
Calls C++ function: [slot] void QListWidget::scrollToItem(const QListWidgetItem* item)
.
Scrolls the view if necessary to ensure that the item is visible.
hint specifies where the item should be located after the operation.
pub unsafe fn selected_items(&self) -> CppBox<QListOfQListWidgetItem>
[src]
Returns a list of all selected items in the list widget.
Calls C++ function: QList<QListWidgetItem*> QListWidget::selectedItems() const
.
Returns a list of all selected items in the list widget.
pub unsafe fn set_current_item_1a(
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
[src]
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>
)
Sets the current item to item.
Calls C++ function: void QListWidget::setCurrentItem(QListWidgetItem* item)
.
Sets the current item to item.
Unless the selection mode is NoSelection, the item is also selected.
See also currentItem().
pub unsafe fn set_current_item_2a(
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>,
command: QFlags<SelectionFlag>
)
[src]
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>,
command: QFlags<SelectionFlag>
)
Set the current item to item, using the given command.
Calls C++ function: void QListWidget::setCurrentItem(QListWidgetItem* item, QFlags<QItemSelectionModel::SelectionFlag> command)
.
Set the current item to item, using the given command.
This function was introduced in Qt 4.4.
pub unsafe fn set_current_row_1a(&mut self, row: c_int)
[src]
This property holds the row of the current item.
Calls C++ function: void QListWidget::setCurrentRow(int row)
.
This property holds the row of the current item.
Depending on the current selection mode, the row may also be selected.
Access functions:
int | currentRow() const |
void | setCurrentRow(int row) |
void | setCurrentRow(int row, QItemSelectionModel::SelectionFlags command) |
Notifier signal:
void | currentRowChanged(int currentRow) |
pub unsafe fn set_current_row_2a(
&mut self,
row: c_int,
command: QFlags<SelectionFlag>
)
[src]
&mut self,
row: c_int,
command: QFlags<SelectionFlag>
)
This property holds the row of the current item.
Calls C++ function: void QListWidget::setCurrentRow(int row, QFlags<QItemSelectionModel::SelectionFlag> command)
.
This property holds the row of the current item.
Depending on the current selection mode, the row may also be selected.
Access functions:
int | currentRow() const |
void | setCurrentRow(int row) |
void | setCurrentRow(int row, QItemSelectionModel::SelectionFlags command) |
Notifier signal:
void | currentRowChanged(int currentRow) |
[src]
If hide is true, the item will be hidden; otherwise it will be shown.
Calls C++ function: void QListWidget::setItemHidden(const QListWidgetItem* item, bool hide)
.
If hide is true, the item will be hidden; otherwise it will be shown.
This function is deprecated. Use QListWidgetItem::setHidden() instead.
See also isItemHidden().
pub unsafe fn set_item_selected(
&mut self,
item: impl CastInto<Ptr<QListWidgetItem>>,
select: bool
)
[src]
&mut self,
item: impl CastInto<Ptr<QListWidgetItem>>,
select: bool
)
Selects or deselects the given item depending on whether select is true of false.
Calls C++ function: void QListWidget::setItemSelected(const QListWidgetItem* item, bool select)
.
Selects or deselects the given item depending on whether select is true of false.
This function is deprecated. Use QListWidgetItem::setSelected() instead.
See also isItemSelected().
pub unsafe fn set_item_widget(
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>,
widget: impl CastInto<MutPtr<QWidget>>
)
[src]
&mut self,
item: impl CastInto<MutPtr<QListWidgetItem>>,
widget: impl CastInto<MutPtr<QWidget>>
)
Sets the widget to be displayed in the given item.
Calls C++ function: void QListWidget::setItemWidget(QListWidgetItem* item, QWidget* widget)
.
Sets the widget to be displayed in the given item.
This function should only be used to display static content in the place of a list widget item. If you want to display custom dynamic content or implement a custom editor widget, use QListView and subclass QItemDelegate instead.
This function was introduced in Qt 4.1.
See also itemWidget(), removeItemWidget(), and Delegate Classes.
pub unsafe fn set_selection_model(
&mut self,
selection_model: impl CastInto<MutPtr<QItemSelectionModel>>
)
[src]
&mut self,
selection_model: impl CastInto<MutPtr<QItemSelectionModel>>
)
Reimplemented from QAbstractItemView::setSelectionModel().
Calls C++ function: virtual void QListWidget::setSelectionModel(QItemSelectionModel* selectionModel)
.
Reimplemented from QAbstractItemView::setSelectionModel().
pub unsafe fn set_sorting_enabled(&mut self, enable: bool)
[src]
This property holds whether sorting is enabled
Calls C++ function: void QListWidget::setSortingEnabled(bool enable)
.
This property holds whether sorting is enabled
If this property is true
, sorting is enabled for the list; if the property is false, sorting is not enabled.
The default value is false.
This property was introduced in Qt 4.2.
Access functions:
bool | isSortingEnabled() const |
void | setSortingEnabled(bool enable) |
pub unsafe fn sort_items_1a(&mut self, order: SortOrder)
[src]
Sorts all the items in the list widget according to the specified order.
Calls C++ function: void QListWidget::sortItems(Qt::SortOrder order = …)
.
Sorts all the items in the list widget according to the specified order.
pub unsafe fn sort_items_0a(&mut self)
[src]
Sorts all the items in the list widget according to the specified order.
Calls C++ function: void QListWidget::sortItems()
.
Sorts all the items in the list widget according to the specified order.
pub unsafe fn static_meta_object() -> Ref<QMetaObject>
[src]
Returns a reference to the staticMetaObject
field.
pub unsafe fn take_item(&mut self, row: c_int) -> MutPtr<QListWidgetItem>
[src]
Removes and returns the item from the given row in the list widget; otherwise returns 0.
Calls C++ function: QListWidgetItem* QListWidget::takeItem(int row)
.
Removes and returns the item from the given row in the list widget; otherwise returns 0.
Items removed from a list widget will not be managed by Qt, and will need to be deleted manually.
See also insertItem() and addItem().
pub unsafe fn tr(
s: impl CastInto<Ptr<c_char>>,
c: impl CastInto<Ptr<c_char>>,
n: c_int
) -> CppBox<QString>
[src]
s: impl CastInto<Ptr<c_char>>,
c: impl CastInto<Ptr<c_char>>,
n: c_int
) -> CppBox<QString>
Calls C++ function: static QString QListWidget::tr(const char* s, const char* c, int n)
.
pub unsafe fn tr_utf8(
s: impl CastInto<Ptr<c_char>>,
c: impl CastInto<Ptr<c_char>>,
n: c_int
) -> CppBox<QString>
[src]
s: impl CastInto<Ptr<c_char>>,
c: impl CastInto<Ptr<c_char>>,
n: c_int
) -> CppBox<QString>
Calls C++ function: static QString QListWidget::trUtf8(const char* s, const char* c, int n)
.
pub unsafe fn visual_item_rect(
&self,
item: impl CastInto<Ptr<QListWidgetItem>>
) -> CppBox<QRect>
[src]
&self,
item: impl CastInto<Ptr<QListWidgetItem>>
) -> CppBox<QRect>
Returns the rectangle on the viewport occupied by the item at item.
Calls C++ function: QRect QListWidget::visualItemRect(const QListWidgetItem* item) const
.
Returns the rectangle on the viewport occupied by the item at item.
Methods from Deref<Target = QListView>
pub fn indexes_moved(&self) -> Signal<(*const QListOfQModelIndex,)>
[src]
This signal is emitted when the specified indexes are moved in the view.
Returns a built-in Qt signal QListView::indexesMoved
that can be passed to qt_core::Signal::connect
.
This signal is emitted when the specified indexes are moved in the view.
This function was introduced in Qt 4.2.
pub unsafe fn batch_size(&self) -> c_int
[src]
This property holds the number of items laid out in each batch if layoutMode is set to Batched
Calls C++ function: int QListView::batchSize() const
.
This property holds the number of items laid out in each batch if layoutMode is set to Batched
The default value is 100.
This property was introduced in Qt 4.2.
Access functions:
int | batchSize() const |
void | setBatchSize(int batchSize) |
pub unsafe fn clear_property_flags(&mut self)
[src]
Clears the QListView-specific property flags. See viewMode.
Calls C++ function: void QListView::clearPropertyFlags()
.
Clears the QListView-specific property flags. See viewMode.
Properties inherited from QAbstractItemView are not covered by the property flags. Specifically, dragEnabled and acceptsDrops are computed by QListView when calling setMovement() or setViewMode().
pub unsafe fn do_items_layout(&mut self)
[src]
Calls C++ function: virtual void QListView::doItemsLayout()
.
pub unsafe fn flow(&self) -> Flow
[src]
This property holds which direction the items layout should flow.
Calls C++ function: QListView::Flow QListView::flow() const
.
This property holds which direction the items layout should flow.
If this property is LeftToRight, the items will be laid out left to right. If the isWrapping property is true
, the layout will wrap when it reaches the right side of the visible area. If this property is TopToBottom, the items will be laid out from the top of the visible area, wrapping when it reaches the bottom.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property is set to TopToBottom.
Access functions:
Flow | flow() const |
void | setFlow(Flow flow) |
See also viewMode.
pub unsafe fn grid_size(&self) -> CppBox<QSize>
[src]
This property holds the size of the layout grid
Calls C++ function: QSize QListView::gridSize() const
.
This property holds the size of the layout grid
This property is the size of the grid in which the items are laid out. The default is an empty size which means that there is no grid and the layout is not done in a grid. Setting this property to a non-empty size switches on the grid layout. (When a grid layout is in force the spacing property is ignored.)
Setting this property when the view is visible will cause the items to be laid out again.
Access functions:
QSize | gridSize() const |
void | setGridSize(const QSize &size) |
See also viewMode.
pub unsafe fn index_at(
&self,
p: impl CastInto<Ref<QPoint>>
) -> CppBox<QModelIndex>
[src]
&self,
p: impl CastInto<Ref<QPoint>>
) -> CppBox<QModelIndex>
Reimplemented from QAbstractItemView::indexAt().
Calls C++ function: virtual QModelIndex QListView::indexAt(const QPoint& p) const
.
Reimplemented from QAbstractItemView::indexAt().
[src]
Returns true
if the row is hidden; otherwise returns false
.
Calls C++ function: bool QListView::isRowHidden(int row) const
.
Returns true
if the row is hidden; otherwise returns false
.
pub unsafe fn is_selection_rect_visible(&self) -> bool
[src]
if the selection rectangle should be visible
Calls C++ function: bool QListView::isSelectionRectVisible() const
.
if the selection rectangle should be visible
If this property is true
then the selection rectangle is visible; otherwise it will be hidden.
Note: The selection rectangle will only be visible if the selection mode is in a mode where more than one item can be selected; i.e., it will not draw a selection rectangle if the selection mode is QAbstractItemView::SingleSelection.
By default, this property is false
.
This property was introduced in Qt 4.3.
Access functions:
bool | isSelectionRectVisible() const |
void | setSelectionRectVisible(bool show) |
pub unsafe fn is_wrapping(&self) -> bool
[src]
This property holds whether the items layout should wrap.
Calls C++ function: bool QListView::isWrapping() const
.
This property holds whether the items layout should wrap.
This property holds whether the layout should wrap when there is no more space in the visible area. The point at which the layout wraps depends on the flow property.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property is false
.
Access functions:
bool | isWrapping() const |
void | setWrapping(bool enable) |
See also viewMode.
pub unsafe fn item_alignment(&self) -> QFlags<AlignmentFlag>
[src]
This property holds the alignment of each item in its cell
Calls C++ function: QFlags<Qt::AlignmentFlag> QListView::itemAlignment() const
.
This property holds the alignment of each item in its cell
This is only supported in ListMode with TopToBottom flow and with wrapping enabled. The default alignment is 0, which means that an item fills its cell entirely.
This property was introduced in Qt 5.12.
Access functions:
Qt::Alignment | itemAlignment() const |
void | setItemAlignment(Qt::Alignment alignment) |
This item is available if any(cpp_lib_version="5.12.2", cpp_lib_version="5.13.0")
.
pub unsafe fn layout_mode(&self) -> LayoutMode
[src]
determines whether the layout of items should happen immediately or be delayed.
Calls C++ function: QListView::LayoutMode QListView::layoutMode() const
.
determines whether the layout of items should happen immediately or be delayed.
This property holds the layout mode for the items. When the mode is SinglePass (the default), the items are laid out all in one go. When the mode is Batched, the items are laid out in batches of batchSize items, while processing events. This makes it possible to instantly view and interact with the visible items while the rest are being laid out.
Access functions:
LayoutMode | layoutMode() const |
void | setLayoutMode(LayoutMode mode) |
See also viewMode.
pub unsafe fn meta_object(&self) -> Ptr<QMetaObject>
[src]
Calls C++ function: virtual const QMetaObject* QListView::metaObject() const
.
pub unsafe fn model_column(&self) -> c_int
[src]
This property holds the column in the model that is visible
Calls C++ function: int QListView::modelColumn() const
.
This property holds the column in the model that is visible
By default, this property contains 0, indicating that the first column in the model will be shown.
Access functions:
int | modelColumn() const |
void | setModelColumn(int column) |
pub unsafe fn movement(&self) -> Movement
[src]
This property holds whether the items can be moved freely, are snapped to a grid, or cannot be moved at all.
Calls C++ function: QListView::Movement QListView::movement() const
.
This property holds whether the items can be moved freely, are snapped to a grid, or cannot be moved at all.
This property determines how the user can move the items in the view. Static means that the items can't be moved the user. Free means that the user can drag and drop the items to any position in the view. Snap means that the user can drag and drop the items, but only to the positions in a notional grid signified by the gridSize property.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property is set to Static.
Access functions:
Movement | movement() const |
void | setMovement(Movement movement) |
See also gridSize, resizeMode, and viewMode.
pub unsafe fn qt_metacall(
&mut self,
arg1: Call,
arg2: c_int,
arg3: impl CastInto<MutPtr<*mut c_void>>
) -> c_int
[src]
&mut self,
arg1: Call,
arg2: c_int,
arg3: impl CastInto<MutPtr<*mut c_void>>
) -> c_int
Calls C++ function: virtual int QListView::qt_metacall(QMetaObject::Call arg1, int arg2, void** arg3)
.
pub unsafe fn qt_metacast(
&mut self,
arg1: impl CastInto<Ptr<c_char>>
) -> MutPtr<c_void>
[src]
&mut self,
arg1: impl CastInto<Ptr<c_char>>
) -> MutPtr<c_void>
Calls C++ function: virtual void* QListView::qt_metacast(const char* arg1)
.
pub unsafe fn reset(&mut self)
[src]
Calls C++ function: virtual void QListView::reset()
.
pub unsafe fn resize_mode(&self) -> ResizeMode
[src]
This property holds whether the items are laid out again when the view is resized.
Calls C++ function: QListView::ResizeMode QListView::resizeMode() const
.
This property holds whether the items are laid out again when the view is resized.
If this property is Adjust, the items will be laid out again when the view is resized. If the value is Fixed, the items will not be laid out when the view is resized.
By default, this property is set to Fixed.
Access functions:
ResizeMode | resizeMode() const |
void | setResizeMode(ResizeMode mode) |
pub unsafe fn scroll_to_2a(
&mut self,
index: impl CastInto<Ref<QModelIndex>>,
hint: ScrollHint
)
[src]
&mut self,
index: impl CastInto<Ref<QModelIndex>>,
hint: ScrollHint
)
Reimplemented from QAbstractItemView::scrollTo().
Calls C++ function: virtual void QListView::scrollTo(const QModelIndex& index, QAbstractItemView::ScrollHint hint = …)
.
Reimplemented from QAbstractItemView::scrollTo().
pub unsafe fn scroll_to_1a(&mut self, index: impl CastInto<Ref<QModelIndex>>)
[src]
Reimplemented from QAbstractItemView::scrollTo().
Calls C++ function: virtual void QListView::scrollTo(const QModelIndex& index)
.
Reimplemented from QAbstractItemView::scrollTo().
pub unsafe fn set_batch_size(&mut self, batch_size: c_int)
[src]
This property holds the number of items laid out in each batch if layoutMode is set to Batched
Calls C++ function: void QListView::setBatchSize(int batchSize)
.
This property holds the number of items laid out in each batch if layoutMode is set to Batched
The default value is 100.
This property was introduced in Qt 4.2.
Access functions:
int | batchSize() const |
void | setBatchSize(int batchSize) |
pub unsafe fn set_flow(&mut self, flow: Flow)
[src]
This property holds which direction the items layout should flow.
Calls C++ function: void QListView::setFlow(QListView::Flow flow)
.
This property holds which direction the items layout should flow.
If this property is LeftToRight, the items will be laid out left to right. If the isWrapping property is true
, the layout will wrap when it reaches the right side of the visible area. If this property is TopToBottom, the items will be laid out from the top of the visible area, wrapping when it reaches the bottom.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property is set to TopToBottom.
Access functions:
Flow | flow() const |
void | setFlow(Flow flow) |
See also viewMode.
pub unsafe fn set_grid_size(&mut self, size: impl CastInto<Ref<QSize>>)
[src]
This property holds the size of the layout grid
Calls C++ function: void QListView::setGridSize(const QSize& size)
.
This property holds the size of the layout grid
This property is the size of the grid in which the items are laid out. The default is an empty size which means that there is no grid and the layout is not done in a grid. Setting this property to a non-empty size switches on the grid layout. (When a grid layout is in force the spacing property is ignored.)
Setting this property when the view is visible will cause the items to be laid out again.
Access functions:
QSize | gridSize() const |
void | setGridSize(const QSize &size) |
See also viewMode.
pub unsafe fn set_item_alignment(&mut self, alignment: QFlags<AlignmentFlag>)
[src]
This property holds the alignment of each item in its cell
Calls C++ function: void QListView::setItemAlignment(QFlags<Qt::AlignmentFlag> alignment)
.
This property holds the alignment of each item in its cell
This is only supported in ListMode with TopToBottom flow and with wrapping enabled. The default alignment is 0, which means that an item fills its cell entirely.
This property was introduced in Qt 5.12.
Access functions:
Qt::Alignment | itemAlignment() const |
void | setItemAlignment(Qt::Alignment alignment) |
This item is available if any(cpp_lib_version="5.12.2", cpp_lib_version="5.13.0")
.
pub unsafe fn set_layout_mode(&mut self, mode: LayoutMode)
[src]
determines whether the layout of items should happen immediately or be delayed.
Calls C++ function: void QListView::setLayoutMode(QListView::LayoutMode mode)
.
determines whether the layout of items should happen immediately or be delayed.
This property holds the layout mode for the items. When the mode is SinglePass (the default), the items are laid out all in one go. When the mode is Batched, the items are laid out in batches of batchSize items, while processing events. This makes it possible to instantly view and interact with the visible items while the rest are being laid out.
Access functions:
LayoutMode | layoutMode() const |
void | setLayoutMode(LayoutMode mode) |
See also viewMode.
pub unsafe fn set_model_column(&mut self, column: c_int)
[src]
This property holds the column in the model that is visible
Calls C++ function: void QListView::setModelColumn(int column)
.
This property holds the column in the model that is visible
By default, this property contains 0, indicating that the first column in the model will be shown.
Access functions:
int | modelColumn() const |
void | setModelColumn(int column) |
pub unsafe fn set_movement(&mut self, movement: Movement)
[src]
This property holds whether the items can be moved freely, are snapped to a grid, or cannot be moved at all.
Calls C++ function: void QListView::setMovement(QListView::Movement movement)
.
This property holds whether the items can be moved freely, are snapped to a grid, or cannot be moved at all.
This property determines how the user can move the items in the view. Static means that the items can't be moved the user. Free means that the user can drag and drop the items to any position in the view. Snap means that the user can drag and drop the items, but only to the positions in a notional grid signified by the gridSize property.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property is set to Static.
Access functions:
Movement | movement() const |
void | setMovement(Movement movement) |
See also gridSize, resizeMode, and viewMode.
pub unsafe fn set_resize_mode(&mut self, mode: ResizeMode)
[src]
This property holds whether the items are laid out again when the view is resized.
Calls C++ function: void QListView::setResizeMode(QListView::ResizeMode mode)
.
This property holds whether the items are laid out again when the view is resized.
If this property is Adjust, the items will be laid out again when the view is resized. If the value is Fixed, the items will not be laid out when the view is resized.
By default, this property is set to Fixed.
Access functions:
ResizeMode | resizeMode() const |
void | setResizeMode(ResizeMode mode) |
pub unsafe fn set_root_index(&mut self, index: impl CastInto<Ref<QModelIndex>>)
[src]
Calls C++ function: virtual void QListView::setRootIndex(const QModelIndex& index)
.
[src]
If hide is true, the given row will be hidden; otherwise the row will be shown.
Calls C++ function: void QListView::setRowHidden(int row, bool hide)
.
If hide is true, the given row will be hidden; otherwise the row will be shown.
See also isRowHidden().
pub unsafe fn set_selection_rect_visible(&mut self, show: bool)
[src]
if the selection rectangle should be visible
Calls C++ function: void QListView::setSelectionRectVisible(bool show)
.
if the selection rectangle should be visible
If this property is true
then the selection rectangle is visible; otherwise it will be hidden.
Note: The selection rectangle will only be visible if the selection mode is in a mode where more than one item can be selected; i.e., it will not draw a selection rectangle if the selection mode is QAbstractItemView::SingleSelection.
By default, this property is false
.
This property was introduced in Qt 4.3.
Access functions:
bool | isSelectionRectVisible() const |
void | setSelectionRectVisible(bool show) |
pub unsafe fn set_spacing(&mut self, space: c_int)
[src]
This property holds the space around the items in the layout
Calls C++ function: void QListView::setSpacing(int space)
.
This property holds the space around the items in the layout
This property is the size of the empty space that is padded around an item in the layout.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property contains a value of 0.
Access functions:
int | spacing() const |
void | setSpacing(int space) |
See also viewMode.
pub unsafe fn set_uniform_item_sizes(&mut self, enable: bool)
[src]
This property holds whether all items in the listview have the same size
Calls C++ function: void QListView::setUniformItemSizes(bool enable)
.
This property holds whether all items in the listview have the same size
This property should only be set to true if it is guaranteed that all items in the view have the same size. This enables the view to do some optimizations for performance purposes.
By default, this property is false
.
This property was introduced in Qt 4.1.
Access functions:
bool | uniformItemSizes() const |
void | setUniformItemSizes(bool enable) |
pub unsafe fn set_view_mode(&mut self, mode: ViewMode)
[src]
This property holds the view mode of the QListView.
Calls C++ function: void QListView::setViewMode(QListView::ViewMode mode)
.
This property holds the view mode of the QListView.
This property will change the other unset properties to conform with the set view mode. QListView-specific properties that have already been set will not be changed, unless clearPropertyFlags() has been called.
Setting the view mode will enable or disable drag and drop based on the selected movement. For ListMode, the default movement is Static (drag and drop disabled); for IconMode, the default movement is Free (drag and drop enabled).
Access functions:
ViewMode | viewMode() const |
void | setViewMode(ViewMode mode) |
See also isWrapping, spacing, gridSize, flow, movement, and resizeMode.
pub unsafe fn set_word_wrap(&mut self, on: bool)
[src]
This property holds the item text word-wrapping policy
Calls C++ function: void QListView::setWordWrap(bool on)
.
This property holds the item text word-wrapping policy
If this property is true
then the item text is wrapped where necessary at word-breaks; otherwise it is not wrapped at all. This property is false
by default.
Please note that even if wrapping is enabled, the cell will not be expanded to make room for the text. It will print ellipsis for text that cannot be shown, according to the view's textElideMode.
This property was introduced in Qt 4.2.
Access functions:
bool | wordWrap() const |
void | setWordWrap(bool on) |
pub unsafe fn set_wrapping(&mut self, enable: bool)
[src]
This property holds whether the items layout should wrap.
Calls C++ function: void QListView::setWrapping(bool enable)
.
This property holds whether the items layout should wrap.
This property holds whether the layout should wrap when there is no more space in the visible area. The point at which the layout wraps depends on the flow property.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property is false
.
Access functions:
bool | isWrapping() const |
void | setWrapping(bool enable) |
See also viewMode.
pub unsafe fn spacing(&self) -> c_int
[src]
This property holds the space around the items in the layout
Calls C++ function: int QListView::spacing() const
.
This property holds the space around the items in the layout
This property is the size of the empty space that is padded around an item in the layout.
Setting this property when the view is visible will cause the items to be laid out again.
By default, this property contains a value of 0.
Access functions:
int | spacing() const |
void | setSpacing(int space) |
See also viewMode.
pub unsafe fn uniform_item_sizes(&self) -> bool
[src]
This property holds whether all items in the listview have the same size
Calls C++ function: bool QListView::uniformItemSizes() const
.
This property holds whether all items in the listview have the same size
This property should only be set to true if it is guaranteed that all items in the view have the same size. This enables the view to do some optimizations for performance purposes.
By default, this property is false
.
This property was introduced in Qt 4.1.
Access functions:
bool | uniformItemSizes() const |
void | setUniformItemSizes(bool enable) |
pub unsafe fn view_mode(&self) -> ViewMode
[src]
This property holds the view mode of the QListView.
Calls C++ function: QListView::ViewMode QListView::viewMode() const
.
This property holds the view mode of the QListView.
This property will change the other unset properties to conform with the set view mode. QListView-specific properties that have already been set will not be changed, unless clearPropertyFlags() has been called.
Setting the view mode will enable or disable drag and drop based on the selected movement. For ListMode, the default movement is Static (drag and drop disabled); for IconMode, the default movement is Free (drag and drop enabled).
Access functions:
ViewMode | viewMode() const |
void | setViewMode(ViewMode mode) |
See also isWrapping, spacing, gridSize, flow, movement, and resizeMode.
pub unsafe fn visual_rect(
&self,
index: impl CastInto<Ref<QModelIndex>>
) -> CppBox<QRect>
[src]
&self,
index: impl CastInto<Ref<QModelIndex>>
) -> CppBox<QRect>
Reimplemented from QAbstractItemView::visualRect().
Calls C++ function: virtual QRect QListView::visualRect(const QModelIndex& index) const
.
Reimplemented from QAbstractItemView::visualRect().
pub unsafe fn word_wrap(&self) -> bool
[src]
This property holds the item text word-wrapping policy
Calls C++ function: bool QListView::wordWrap() const
.
This property holds the item text word-wrapping policy
If this property is true
then the item text is wrapped where necessary at word-breaks; otherwise it is not wrapped at all. This property is false
by default.
Please note that even if wrapping is enabled, the cell will not be expanded to make room for the text. It will print ellipsis for text that cannot be shown, according to the view's textElideMode.
This property was introduced in Qt 4.2.
Access functions:
bool | wordWrap() const |
void | setWordWrap(bool on) |
Trait Implementations
impl CppDeletable for QListWidget
[src]
unsafe fn delete(&mut self)
[src]
Destroys the list widget and all its items.
Calls C++ function: virtual [destructor] void QListWidget::~QListWidget()
.
Destroys the list widget and all its items.
impl Deref for QListWidget
[src]
type Target = QListView
The resulting type after dereferencing.
fn deref(&self) -> &QListView
[src]
Calls C++ function: QListView* static_cast<QListView*>(QListWidget* ptr)
.
impl DerefMut for QListWidget
[src]
fn deref_mut(&mut self) -> &mut QListView
[src]
Calls C++ function: QListView* static_cast<QListView*>(QListWidget* ptr)
.
impl DynamicCast<QListWidget> for QListView
[src]
unsafe fn dynamic_cast(ptr: Ptr<QListView>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QListView* ptr)
.
unsafe fn dynamic_cast_mut(ptr: MutPtr<QListView>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QListView* ptr)
.
impl DynamicCast<QListWidget> for QAbstractItemView
[src]
unsafe fn dynamic_cast(ptr: Ptr<QAbstractItemView>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QAbstractItemView* ptr)
.
unsafe fn dynamic_cast_mut(
ptr: MutPtr<QAbstractItemView>
) -> MutPtr<QListWidget>
[src]
ptr: MutPtr<QAbstractItemView>
) -> MutPtr<QListWidget>
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QAbstractItemView* ptr)
.
impl DynamicCast<QListWidget> for QAbstractScrollArea
[src]
unsafe fn dynamic_cast(ptr: Ptr<QAbstractScrollArea>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QAbstractScrollArea* ptr)
.
unsafe fn dynamic_cast_mut(
ptr: MutPtr<QAbstractScrollArea>
) -> MutPtr<QListWidget>
[src]
ptr: MutPtr<QAbstractScrollArea>
) -> MutPtr<QListWidget>
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QAbstractScrollArea* ptr)
.
impl DynamicCast<QListWidget> for QFrame
[src]
unsafe fn dynamic_cast(ptr: Ptr<QFrame>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QFrame* ptr)
.
unsafe fn dynamic_cast_mut(ptr: MutPtr<QFrame>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QFrame* ptr)
.
impl DynamicCast<QListWidget> for QWidget
[src]
unsafe fn dynamic_cast(ptr: Ptr<QWidget>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QWidget* ptr)
.
unsafe fn dynamic_cast_mut(ptr: MutPtr<QWidget>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QWidget* ptr)
.
impl DynamicCast<QListWidget> for QObject
[src]
unsafe fn dynamic_cast(ptr: Ptr<QObject>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QObject* ptr)
.
unsafe fn dynamic_cast_mut(ptr: MutPtr<QObject>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QObject* ptr)
.
impl DynamicCast<QListWidget> for QPaintDevice
[src]
unsafe fn dynamic_cast(ptr: Ptr<QPaintDevice>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QPaintDevice* ptr)
.
unsafe fn dynamic_cast_mut(ptr: MutPtr<QPaintDevice>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* dynamic_cast<QListWidget*>(QPaintDevice* ptr)
.
impl StaticDowncast<QListWidget> for QListView
[src]
unsafe fn static_downcast(ptr: Ptr<QListView>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QListView* ptr)
.
unsafe fn static_downcast_mut(ptr: MutPtr<QListView>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QListView* ptr)
.
impl StaticDowncast<QListWidget> for QAbstractItemView
[src]
unsafe fn static_downcast(ptr: Ptr<QAbstractItemView>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QAbstractItemView* ptr)
.
unsafe fn static_downcast_mut(
ptr: MutPtr<QAbstractItemView>
) -> MutPtr<QListWidget>
[src]
ptr: MutPtr<QAbstractItemView>
) -> MutPtr<QListWidget>
Calls C++ function: QListWidget* static_cast<QListWidget*>(QAbstractItemView* ptr)
.
impl StaticDowncast<QListWidget> for QAbstractScrollArea
[src]
unsafe fn static_downcast(ptr: Ptr<QAbstractScrollArea>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QAbstractScrollArea* ptr)
.
unsafe fn static_downcast_mut(
ptr: MutPtr<QAbstractScrollArea>
) -> MutPtr<QListWidget>
[src]
ptr: MutPtr<QAbstractScrollArea>
) -> MutPtr<QListWidget>
Calls C++ function: QListWidget* static_cast<QListWidget*>(QAbstractScrollArea* ptr)
.
impl StaticDowncast<QListWidget> for QFrame
[src]
unsafe fn static_downcast(ptr: Ptr<QFrame>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QFrame* ptr)
.
unsafe fn static_downcast_mut(ptr: MutPtr<QFrame>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QFrame* ptr)
.
impl StaticDowncast<QListWidget> for QWidget
[src]
unsafe fn static_downcast(ptr: Ptr<QWidget>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QWidget* ptr)
.
unsafe fn static_downcast_mut(ptr: MutPtr<QWidget>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QWidget* ptr)
.
impl StaticDowncast<QListWidget> for QObject
[src]
unsafe fn static_downcast(ptr: Ptr<QObject>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QObject* ptr)
.
unsafe fn static_downcast_mut(ptr: MutPtr<QObject>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QObject* ptr)
.
impl StaticDowncast<QListWidget> for QPaintDevice
[src]
unsafe fn static_downcast(ptr: Ptr<QPaintDevice>) -> Ptr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QPaintDevice* ptr)
.
unsafe fn static_downcast_mut(ptr: MutPtr<QPaintDevice>) -> MutPtr<QListWidget>
[src]
Calls C++ function: QListWidget* static_cast<QListWidget*>(QPaintDevice* ptr)
.
impl StaticUpcast<QAbstractItemView> for QListWidget
[src]
unsafe fn static_upcast(ptr: Ptr<QListWidget>) -> Ptr<QAbstractItemView>
[src]
Calls C++ function: QAbstractItemView* static_cast<QAbstractItemView*>(QListWidget* ptr)
.
unsafe fn static_upcast_mut(
ptr: MutPtr<QListWidget>
) -> MutPtr<QAbstractItemView>
[src]
ptr: MutPtr<QListWidget>
) -> MutPtr<QAbstractItemView>
Calls C++ function: QAbstractItemView* static_cast<QAbstractItemView*>(QListWidget* ptr)
.
impl StaticUpcast<QAbstractScrollArea> for QListWidget
[src]
unsafe fn static_upcast(ptr: Ptr<QListWidget>) -> Ptr<QAbstractScrollArea>
[src]
Calls C++ function: QAbstractScrollArea* static_cast<QAbstractScrollArea*>(QListWidget* ptr)
.
unsafe fn static_upcast_mut(
ptr: MutPtr<QListWidget>
) -> MutPtr<QAbstractScrollArea>
[src]
ptr: MutPtr<QListWidget>
) -> MutPtr<QAbstractScrollArea>
Calls C++ function: QAbstractScrollArea* static_cast<QAbstractScrollArea*>(QListWidget* ptr)
.
impl StaticUpcast<QFrame> for QListWidget
[src]
unsafe fn static_upcast(ptr: Ptr<QListWidget>) -> Ptr<QFrame>
[src]
Calls C++ function: QFrame* static_cast<QFrame*>(QListWidget* ptr)
.
unsafe fn static_upcast_mut(ptr: MutPtr<QListWidget>) -> MutPtr<QFrame>
[src]
Calls C++ function: QFrame* static_cast<QFrame*>(QListWidget* ptr)
.
impl StaticUpcast<QListView> for QListWidget
[src]
unsafe fn static_upcast(ptr: Ptr<QListWidget>) -> Ptr<QListView>
[src]
Calls C++ function: QListView* static_cast<QListView*>(QListWidget* ptr)
.
unsafe fn static_upcast_mut(ptr: MutPtr<QListWidget>) -> MutPtr<QListView>
[src]
Calls C++ function: QListView* static_cast<QListView*>(QListWidget* ptr)
.
impl StaticUpcast<QObject> for QListWidget
[src]
unsafe fn static_upcast(ptr: Ptr<QListWidget>) -> Ptr<QObject>
[src]
Calls C++ function: QObject* static_cast<QObject*>(QListWidget* ptr)
.
unsafe fn static_upcast_mut(ptr: MutPtr<QListWidget>) -> MutPtr<QObject>
[src]
Calls C++ function: QObject* static_cast<QObject*>(QListWidget* ptr)
.
impl StaticUpcast<QPaintDevice> for QListWidget
[src]
unsafe fn static_upcast(ptr: Ptr<QListWidget>) -> Ptr<QPaintDevice>
[src]
Calls C++ function: QPaintDevice* static_cast<QPaintDevice*>(QListWidget* ptr)
.
unsafe fn static_upcast_mut(ptr: MutPtr<QListWidget>) -> MutPtr<QPaintDevice>
[src]
Calls C++ function: QPaintDevice* static_cast<QPaintDevice*>(QListWidget* ptr)
.
impl StaticUpcast<QWidget> for QListWidget
[src]
unsafe fn static_upcast(ptr: Ptr<QListWidget>) -> Ptr<QWidget>
[src]
Calls C++ function: QWidget* static_cast<QWidget*>(QListWidget* ptr)
.
unsafe fn static_upcast_mut(ptr: MutPtr<QListWidget>) -> MutPtr<QWidget>
[src]
Calls C++ function: QWidget* static_cast<QWidget*>(QListWidget* ptr)
.
Auto Trait Implementations
impl RefUnwindSafe for QListWidget
impl Send for QListWidget
impl Sync for QListWidget
impl Unpin for QListWidget
impl UnwindSafe for QListWidget
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> CastInto<U> for T where
U: CastFrom<T>,
[src]
U: CastFrom<T>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> StaticUpcast<T> for T
[src]
unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>
[src]
unsafe fn static_upcast_mut(ptr: MutPtr<T>) -> MutPtr<T>
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,