All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.qt.widgets.QListWidget Maven / Gradle / Ivy

There is a newer version: 6.3.0
Show newest version
package io.qt.widgets;


/**
 * 

Item-based list widget

*

Java wrapper for Qt class QListWidget

*/ public class QListWidget extends io.qt.widgets.QListView { /** * This variable stores the meta-object for the class. */ public static final io.qt.core.QMetaObject staticMetaObject = io.qt.core.QMetaObject.forType(QListWidget.class); /** *

See QListWidget::currentItemChanged(QListWidgetItem*,QListWidgetItem*)

*/ public final Signal2 currentItemChanged = new Signal2<>(); /** *

See QListWidget::currentRowChanged(int)

*/ @io.qt.QtPropertyNotify(name="currentRow") public final Signal1<@io.qt.QtPrimitiveType Integer> currentRowChanged = new Signal1<>(); /** *

See QListWidget::currentTextChanged(QString)

*/ public final Signal1 currentTextChanged = new Signal1<>(); /** *

See QListWidget::itemActivated(QListWidgetItem*)

*/ public final Signal1 itemActivated = new Signal1<>(); /** *

See QListWidget::itemChanged(QListWidgetItem*)

*/ public final Signal1 itemChanged = new Signal1<>(); /** *

See QListWidget::itemClicked(QListWidgetItem*)

*/ public final Signal1 itemClicked = new Signal1<>(); /** *

See QListWidget::itemDoubleClicked(QListWidgetItem*)

*/ public final Signal1 itemDoubleClicked = new Signal1<>(); /** *

See QListWidget::itemEntered(QListWidgetItem*)

*/ public final Signal1 itemEntered = new Signal1<>(); /** *

See QListWidget::itemPressed(QListWidgetItem*)

*/ public final Signal1 itemPressed = new Signal1<>(); /** *

See QListWidget::itemSelectionChanged()

*/ public final Signal0 itemSelectionChanged = new Signal0(); /** *

Overloaded constructor for {@link #QListWidget(io.qt.widgets.QWidget)} * with parent = null.

*/ public QListWidget() { this((io.qt.widgets.QWidget)null); } /** *

See QListWidget::QListWidget(QWidget*)

*/ public QListWidget(io.qt.widgets.QWidget parent){ super((QPrivateConstructor)null); initialize_native(this, parent); } private native static void initialize_native(QListWidget instance, io.qt.widgets.QWidget parent); /** *

See QListWidget::addItem(QListWidgetItem*)

*/ @io.qt.QtUninvokable public final void addItem(io.qt.widgets.QListWidgetItem item){ addItem_native_QListWidgetItem_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); QtJambi_LibraryUtilities.internal.setCppOwnership(item); } @io.qt.QtUninvokable private native void addItem_native_QListWidgetItem_ptr(long __this__nativeId, long item); /** *

See QListWidget::clear()

*/ public final void clear(){ clear_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } private native void clear_native(long __this__nativeId); /** *

See QListWidget::closePersistentEditor(QListWidgetItem*)

*/ @io.qt.QtUninvokable public final void closePersistentEditor(io.qt.widgets.QListWidgetItem item){ closePersistentEditor_native_QListWidgetItem_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native void closePersistentEditor_native_QListWidgetItem_ptr(long __this__nativeId, long item); /** *

See QListWidget::count()const

*/ @io.qt.QtPropertyReader(name="count") @io.qt.QtUninvokable public final int count(){ return count_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @io.qt.QtUninvokable private native int count_native_constfct(long __this__nativeId); /** *

See QListWidget::currentItem()const

*/ @io.qt.QtUninvokable public final io.qt.widgets.QListWidgetItem currentItem(){ return currentItem_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @io.qt.QtUninvokable private native io.qt.widgets.QListWidgetItem currentItem_native_constfct(long __this__nativeId); /** *

See QListWidget::currentRow()const

*/ @io.qt.QtPropertyReader(name="currentRow") @io.qt.QtPropertyUser @io.qt.QtUninvokable public final int currentRow(){ return currentRow_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @io.qt.QtUninvokable private native int currentRow_native_constfct(long __this__nativeId); /** *

See QListWidget::editItem(QListWidgetItem*)

*/ @io.qt.QtUninvokable public final void editItem(io.qt.widgets.QListWidgetItem item){ editItem_native_QListWidgetItem_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native void editItem_native_QListWidgetItem_ptr(long __this__nativeId, long item); /** *

Overloaded function for {@link #findItems(java.lang.String, io.qt.core.Qt.MatchFlags)}.

*/ @io.qt.QtUninvokable public final io.qt.core.QList findItems(java.lang.String text, io.qt.core.Qt.MatchFlag ... flags){ return findItems(text, new io.qt.core.Qt.MatchFlags(flags)); } /** *

See QListWidget::findItems(QString,Qt::MatchFlags)const

*/ @io.qt.QtUninvokable public final io.qt.core.QList findItems(java.lang.String text, io.qt.core.Qt.MatchFlags flags){ return findItems_native_cref_QString_QFlags_Qt_MatchFlag__constfct(QtJambi_LibraryUtilities.internal.nativeId(this), text, flags.value()); } @io.qt.QtUninvokable private native io.qt.core.QList findItems_native_cref_QString_QFlags_Qt_MatchFlag__constfct(long __this__nativeId, java.lang.String text, int flags); /** *

See QListWidget::indexFromItem(const QListWidgetItem*)const

*/ @io.qt.QtUninvokable public final io.qt.core.QModelIndex indexFromItem(io.qt.widgets.QListWidgetItem item){ return indexFromItem_native_const_QListWidgetItem_ptr_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native io.qt.core.QModelIndex indexFromItem_native_const_QListWidgetItem_ptr_constfct(long __this__nativeId, long item); /** *

See QListWidget::insertItem(int,QListWidgetItem*)

*/ @io.qt.QtUninvokable public final void insertItem(int row, io.qt.widgets.QListWidgetItem item){ insertItem_native_int_QListWidgetItem_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), row, QtJambi_LibraryUtilities.internal.checkedNativeId(item)); QtJambi_LibraryUtilities.internal.setCppOwnership(item); } @io.qt.QtUninvokable private native void insertItem_native_int_QListWidgetItem_ptr(long __this__nativeId, int row, long item); /** *

See QListWidget::isPersistentEditorOpen(QListWidgetItem*)const

*/ @io.qt.QtUninvokable public final boolean isPersistentEditorOpen(io.qt.widgets.QListWidgetItem item){ return isPersistentEditorOpen_native_QListWidgetItem_ptr_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native boolean isPersistentEditorOpen_native_QListWidgetItem_ptr_constfct(long __this__nativeId, long item); /** *

See QListWidget::isSortingEnabled()const

*/ @io.qt.QtPropertyReader(name="sortingEnabled") @io.qt.QtUninvokable public final boolean isSortingEnabled(){ return isSortingEnabled_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @io.qt.QtUninvokable private native boolean isSortingEnabled_native_constfct(long __this__nativeId); /** *

See QListWidget::item(int)const

*/ @io.qt.QtUninvokable public final io.qt.widgets.QListWidgetItem item(int row){ return item_native_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), row); } @io.qt.QtUninvokable private native io.qt.widgets.QListWidgetItem item_native_int_constfct(long __this__nativeId, int row); /** *

See QListWidget::itemAt(QPoint)const

*/ @io.qt.QtUninvokable public final io.qt.widgets.QListWidgetItem itemAt(io.qt.core.QPoint p){ return itemAt_native_cref_QPoint_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(p)); } @io.qt.QtUninvokable private native io.qt.widgets.QListWidgetItem itemAt_native_cref_QPoint_constfct(long __this__nativeId, long p); /** *

See QListWidget::itemAt(int,int)const

*/ @io.qt.QtUninvokable public final io.qt.widgets.QListWidgetItem itemAt(int x, int y){ return itemAt_native_int_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), x, y); } @io.qt.QtUninvokable private native io.qt.widgets.QListWidgetItem itemAt_native_int_int_constfct(long __this__nativeId, int x, int y); /** *

See QListWidget::itemFromIndex(QModelIndex)const

*/ @io.qt.QtUninvokable public final io.qt.widgets.QListWidgetItem itemFromIndex(io.qt.core.QModelIndex index){ return itemFromIndex_native_cref_QModelIndex_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), index); } @io.qt.QtUninvokable private native io.qt.widgets.QListWidgetItem itemFromIndex_native_cref_QModelIndex_constfct(long __this__nativeId, io.qt.core.QModelIndex index); /** *

See QListWidget::itemWidget(QListWidgetItem*)const

*/ @io.qt.QtUninvokable public final io.qt.widgets.QWidget itemWidget(io.qt.widgets.QListWidgetItem item){ return itemWidget_native_QListWidgetItem_ptr_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native io.qt.widgets.QWidget itemWidget_native_QListWidgetItem_ptr_constfct(long __this__nativeId, long item); /** *

See QListWidget::items(const QMimeData*)const

*/ @io.qt.QtUninvokable public final io.qt.core.QList items(io.qt.core.QMimeData data){ return items_native_const_QMimeData_ptr_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(data)); } @io.qt.QtUninvokable private native io.qt.core.QList items_native_const_QMimeData_ptr_constfct(long __this__nativeId, long data); /** *

See QListWidget::openPersistentEditor(QListWidgetItem*)

*/ @io.qt.QtUninvokable public final void openPersistentEditor(io.qt.widgets.QListWidgetItem item){ openPersistentEditor_native_QListWidgetItem_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native void openPersistentEditor_native_QListWidgetItem_ptr(long __this__nativeId, long item); /** *

See QListWidget::removeItemWidget(QListWidgetItem*)

*/ @io.qt.QtUninvokable public final void removeItemWidget(io.qt.widgets.QListWidgetItem item){ removeItemWidget_native_QListWidgetItem_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native void removeItemWidget_native_QListWidgetItem_ptr(long __this__nativeId, long item); /** *

See QListWidget::row(const QListWidgetItem*)const

*/ @io.qt.QtUninvokable public final int row(io.qt.widgets.QListWidgetItem item){ return row_native_const_QListWidgetItem_ptr_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native int row_native_const_QListWidgetItem_ptr_constfct(long __this__nativeId, long item); /** *

Overloaded function for {@link #scrollToItem(io.qt.widgets.QListWidgetItem, io.qt.widgets.QAbstractItemView.ScrollHint)} * with hint = io.qt.widgets.QAbstractItemView.ScrollHint.EnsureVisible.

*/ public final void scrollToItem(io.qt.widgets.QListWidgetItem item) { scrollToItem(item, io.qt.widgets.QAbstractItemView.ScrollHint.EnsureVisible); } /** *

See QListWidget::scrollToItem(const QListWidgetItem*,QAbstractItemView::ScrollHint)

*/ public final void scrollToItem(io.qt.widgets.QListWidgetItem item, io.qt.widgets.QAbstractItemView.ScrollHint hint){ scrollToItem_native_const_QListWidgetItem_ptr_QAbstractItemView_ScrollHint(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item), hint.value()); } private native void scrollToItem_native_const_QListWidgetItem_ptr_QAbstractItemView_ScrollHint(long __this__nativeId, long item, int hint); /** *

See QListWidget::selectedItems()const

*/ @io.qt.QtUninvokable public final io.qt.core.QList selectedItems(){ return selectedItems_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @io.qt.QtUninvokable private native io.qt.core.QList selectedItems_native_constfct(long __this__nativeId); /** *

See QListWidget::setCurrentItem(QListWidgetItem*)

*/ @io.qt.QtUninvokable public final void setCurrentItem(io.qt.widgets.QListWidgetItem item){ setCurrentItem_native_QListWidgetItem_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native void setCurrentItem_native_QListWidgetItem_ptr(long __this__nativeId, long item); /** *

Overloaded function for {@link #setCurrentItem(io.qt.widgets.QListWidgetItem, io.qt.core.QItemSelectionModel.SelectionFlags)}.

*/ @io.qt.QtUninvokable public final void setCurrentItem(io.qt.widgets.QListWidgetItem item, io.qt.core.QItemSelectionModel.SelectionFlag ... command){ setCurrentItem(item, new io.qt.core.QItemSelectionModel.SelectionFlags(command)); } /** *

See QListWidget::setCurrentItem(QListWidgetItem*,QItemSelectionModel::SelectionFlags)

*/ @io.qt.QtUninvokable public final void setCurrentItem(io.qt.widgets.QListWidgetItem item, io.qt.core.QItemSelectionModel.SelectionFlags command){ setCurrentItem_native_QListWidgetItem_ptr_QFlags_QItemSelectionModel_SelectionFlag_(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item), command.value()); } @io.qt.QtUninvokable private native void setCurrentItem_native_QListWidgetItem_ptr_QFlags_QItemSelectionModel_SelectionFlag_(long __this__nativeId, long item, int command); /** *

See QListWidget::setCurrentRow(int)

*/ @io.qt.QtPropertyWriter(name="currentRow") @io.qt.QtUninvokable public final void setCurrentRow(int row){ setCurrentRow_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), row); } @io.qt.QtUninvokable private native void setCurrentRow_native_int(long __this__nativeId, int row); /** *

Overloaded function for {@link #setCurrentRow(int, io.qt.core.QItemSelectionModel.SelectionFlags)}.

*/ @io.qt.QtUninvokable public final void setCurrentRow(int row, io.qt.core.QItemSelectionModel.SelectionFlag ... command){ setCurrentRow(row, new io.qt.core.QItemSelectionModel.SelectionFlags(command)); } /** *

See QListWidget::setCurrentRow(int,QItemSelectionModel::SelectionFlags)

*/ @io.qt.QtPropertyWriter(name="currentRow") @io.qt.QtUninvokable public final void setCurrentRow(int row, io.qt.core.QItemSelectionModel.SelectionFlags command){ setCurrentRow_native_int_QFlags_QItemSelectionModel_SelectionFlag_(QtJambi_LibraryUtilities.internal.nativeId(this), row, command.value()); } @io.qt.QtUninvokable private native void setCurrentRow_native_int_QFlags_QItemSelectionModel_SelectionFlag_(long __this__nativeId, int row, int command); /** *

See QListWidget::setItemWidget(QListWidgetItem*,QWidget*)

*/ @io.qt.QtUninvokable public final void setItemWidget(io.qt.widgets.QListWidgetItem item, io.qt.widgets.QWidget widget){ setItemWidget_native_QListWidgetItem_ptr_QWidget_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item), QtJambi_LibraryUtilities.internal.checkedNativeId(widget)); } @io.qt.QtUninvokable private native void setItemWidget_native_QListWidgetItem_ptr_QWidget_ptr(long __this__nativeId, long item, long widget); /** *

See QAbstractItemView::setModel(QAbstractItemModel*)

*/ @Deprecated @io.qt.QtUninvokable public final void setModel(io.qt.core.QAbstractItemModel model) throws io.qt.QNoImplementationException { setModel_native_QAbstractItemModel_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(model)); QtJambi_LibraryUtilities.internal.setReferenceCount(this, io.qt.widgets.QAbstractItemView.class, "__rcItemModel", false, false, model); // setModel() creates a new selection model for the object QtJambi_LibraryUtilities.internal.setReferenceCount(this, io.qt.widgets.QAbstractItemView.class, "__rcItemSelectionModel", false, false, null); } @Deprecated private static void setModel_native_QAbstractItemModel_ptr(long __this__nativeId, long model) throws io.qt.QNoImplementationException { throw new io.qt.QNoImplementationException(); } /** *

See QListWidget::setSortingEnabled(bool)

*/ @io.qt.QtPropertyWriter(name="sortingEnabled") @io.qt.QtUninvokable public final void setSortingEnabled(boolean enable){ setSortingEnabled_native_bool(QtJambi_LibraryUtilities.internal.nativeId(this), enable); } @io.qt.QtUninvokable private native void setSortingEnabled_native_bool(long __this__nativeId, boolean enable); /** *

Overloaded function for {@link #sortItems(io.qt.core.Qt.SortOrder)} * with order = io.qt.core.Qt.SortOrder.AscendingOrder.

*/ @io.qt.QtUninvokable public final void sortItems() { sortItems(io.qt.core.Qt.SortOrder.AscendingOrder); } /** *

See QListWidget::sortItems(Qt::SortOrder)

*/ @io.qt.QtUninvokable public final void sortItems(io.qt.core.Qt.SortOrder order){ sortItems_native_Qt_SortOrder(QtJambi_LibraryUtilities.internal.nativeId(this), order.value()); } @io.qt.QtUninvokable private native void sortItems_native_Qt_SortOrder(long __this__nativeId, int order); /** *

See QListWidget::takeItem(int)

*/ @io.qt.QtUninvokable public final io.qt.widgets.QListWidgetItem takeItem(int row){ return takeItem_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), row); } @io.qt.QtUninvokable private native io.qt.widgets.QListWidgetItem takeItem_native_int(long __this__nativeId, int row); /** *

See QListWidget::visualItemRect(const QListWidgetItem*)const

*/ @io.qt.QtUninvokable public final io.qt.core.QRect visualItemRect(io.qt.widgets.QListWidgetItem item){ return visualItemRect_native_const_QListWidgetItem_ptr_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(item)); } @io.qt.QtUninvokable private native io.qt.core.QRect visualItemRect_native_const_QListWidgetItem_ptr_constfct(long __this__nativeId, long item); /** *

See QWidget::dropEvent(QDropEvent*)

*/ @io.qt.QtUninvokable protected void dropEvent(io.qt.gui.QDropEvent event){ dropEvent_native_QDropEvent_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(event)); } @io.qt.QtUninvokable private native void dropEvent_native_QDropEvent_ptr(long __this__nativeId, long event); /** *

See QListWidget::dropMimeData(int,const QMimeData*,Qt::DropAction)

*/ @io.qt.QtUninvokable protected boolean dropMimeData(int index, io.qt.core.QMimeData data, io.qt.core.Qt.DropAction action){ return dropMimeData_native_int_const_QMimeData_ptr_Qt_DropAction(QtJambi_LibraryUtilities.internal.nativeId(this), index, QtJambi_LibraryUtilities.internal.checkedNativeId(data), action.value()); } @io.qt.QtUninvokable private native boolean dropMimeData_native_int_const_QMimeData_ptr_Qt_DropAction(long __this__nativeId, int index, long data, int action); /** *

See QObject::event(QEvent*)

*/ @io.qt.QtUninvokable public boolean event(io.qt.core.QEvent e){ return event_native_QEvent_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(e)); } @io.qt.QtUninvokable private native boolean event_native_QEvent_ptr(long __this__nativeId, long e); /** *

See QListWidget::mimeData(QList<QListWidgetItem*>)const

*/ @io.qt.QtUninvokable protected io.qt.core.QMimeData mimeData(java.util.Collection items){ return mimeData_native_cref_QList_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), items); } @io.qt.QtUninvokable private native io.qt.core.QMimeData mimeData_native_cref_QList_constfct(long __this__nativeId, java.util.Collection items); /** *

See QListWidget::mimeTypes()const

*/ @io.qt.QtUninvokable protected java.util.List mimeTypes(){ return mimeTypes_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @io.qt.QtUninvokable private native java.util.List mimeTypes_native_constfct(long __this__nativeId); /** *

See QAbstractItemView::setSelectionModel(QItemSelectionModel*)

*/ @io.qt.QtUninvokable public void setSelectionModel(io.qt.core.QItemSelectionModel selectionModel){ setSelectionModel_native_QItemSelectionModel_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(selectionModel)); QtJambi_LibraryUtilities.internal.setReferenceCount(this, io.qt.widgets.QAbstractItemView.class, "__rcItemSelectionModel", false, false, selectionModel); } @io.qt.QtUninvokable private native void setSelectionModel_native_QItemSelectionModel_ptr(long __this__nativeId, long selectionModel); /** *

See QListWidget::supportedDropActions()const

*/ @io.qt.QtUninvokable protected io.qt.core.Qt.DropActions supportedDropActions(){ return new io.qt.core.Qt.DropActions(supportedDropActions_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this))); } @io.qt.QtUninvokable private native int supportedDropActions_native_constfct(long __this__nativeId); /** * Constructor for internal use only. * @param p expected to be null. */ @io.qt.NativeAccess protected QListWidget(QPrivateConstructor p) { super(p); } /** * Constructor for internal use only. * It is not allowed to call the declarative constructor from inside Java. */ @io.qt.NativeAccess protected QListWidget(QDeclarativeConstructor constructor) { super((QPrivateConstructor)null); initialize_native(this, constructor); } @io.qt.QtUninvokable private static native void initialize_native(QListWidget instance, QDeclarativeConstructor constructor); /** * Inserts an item with the text label at the end of the list widget. * * @param label The text of the new item. */ public final void addItem(String label) { addItem(new QListWidgetItem(label, this)); } /** * Inserts items with the text labels at the end of the list widget. * * @param labels The collection of labels for the new items. */ public final void addItems(java.util.List labels) { for (String label : labels) addItem(label); } /** * This is an overloaded member function, provided for convenience. * Inserts an item with the text label in the list widget at the position given by row. * * @param row The position in which to insert the new item. * @param label The text of the new item. */ public final void insertItem(int row, String label) { insertItem(row, new QListWidgetItem(label, this)); } /** * Inserts items from the list of labels into the list, starting at the given row. * * @param row The position in which to insert the new items. * @param labels The collection of labels for the new items. */ public final void insertItems(int row, java.util.List labels) { for (String label : labels) insertItem(row++, label); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy