哪里有源码?
checkComboBox 在哪里能下载到QT源码呢?
有人能把下面这个实现出来吗?
这是我在
http://www.qtcentre.org/forum/f-qt-programming-2/t-checkcombobox-how-to-do-3411.html 提问的答案。
If you mean something like this, it really shouldn't bee too hard since QComboBox allows you to use your own model (and view, which you probably don't event need..). You need to make the combobox non-editable and make the model to return Qt::ItemIsUserCheckable for all indexes QAbstractItemModel::flags(). I think all you need to do by hand is the filling of the line edit of the combobox.
Edit: Oh, and about the model. In my opinion, QStandardItemModel could be a good choice to start with, as QStringListModel doesn't support storing of check states..
checkComboBox界面如 :
http://www.codeproject.com/combobox/checkcombo.asp[ 此贴被qiank128在2006-08-24 20:06重新编辑 ]