diff options
Diffstat (limited to 'sip/tqt/tqcombobox.sip')
-rw-r--r-- | sip/tqt/tqcombobox.sip | 148 |
1 files changed, 148 insertions, 0 deletions
diff --git a/sip/tqt/tqcombobox.sip b/sip/tqt/tqcombobox.sip new file mode 100644 index 0000000..cc878ed --- /dev/null +++ b/sip/tqt/tqcombobox.sip @@ -0,0 +1,148 @@ +// This is the SIP interface definition for TQComboBox. +// +// Copyright (c) 2007 +// Riverbank Computing Limited <info@riverbankcomputing.co.uk> +// +// This file is part of PyTQt. +// +// This copy of PyTQt is free software; you can redistribute it and/or modify it +// under the terms of the GNU General Public License as published by the Free +// Software Foundation; either version 2, or (at your option) any later +// version. +// +// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY +// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more +// details. +// +// You should have received a copy of the GNU General Public License along with +// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation, +// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + + +%ExportedDoc +<Sect2><Title>TQComboBox</Title> +<Para> +<Literal>TQComboBox</Literal> is fully implemented. +</Para> +</Sect2> +%End + + +class TQComboBox : TQWidget +{ +%TypeHeaderCode +#include <tqcombobox.h> +%End + +public: + TQComboBox(TQWidget * /TransferThis/ = 0,char * = 0); + TQComboBox(bool,TQWidget * /TransferThis/ = 0,char * = 0); + + int count() const; + + void insertStringList(TQStringList &,int = -1); + void insertStrList(const TQStrList *,int = -1); +// void insertStrList(const TQStrList &,int = -1); +// void insertStrList(const char **,int = -1,int = -1); + + void insertItem(const TQString &,int = -1); + void insertItem(const TQPixmap &,int = -1); + void insertItem(const TQPixmap &,const TQString &,int = -1); + + void removeItem(int); + + int currentItem() const; + virtual void setCurrentItem(int); + + TQString currentText() const; + virtual void setCurrentText(const TQString &); + + TQString text(int) const; + const TQPixmap *pixmap(int) const; + + void changeItem(const TQString &,int); + void changeItem(const TQPixmap &,int); + void changeItem(const TQPixmap &,const TQString &,int); + + bool autoResize() const; + virtual void setAutoResize(bool); + TQSize sizeHint() const; + + void setPalette(const TQPalette &); + void setFont(const TQFont &); + void setEnabled(bool); + + virtual void setSizeLimit(int); + int sizeLimit() const; + + virtual void setMaxCount(int); + int maxCount() const; + + enum Policy { + NoInsertion, + AtTop, + AtCurrent, + AtBottom, + AfterCurrent, + BeforeCurrent + }; + + virtual void setInsertionPolicy(Policy); + Policy insertionPolicy() const; + + virtual void setValidator(const TQValidator *); + const TQValidator *validator() const; + + virtual void setListBox(TQListBox *); + TQListBox *listBox() const; + + virtual void setLineEdit(TQLineEdit *); + TQLineEdit *lineEdit() const; + + virtual void setAutoCompletion(bool); + bool autoCompletion() const; + + bool eventFilter(TQObject *,TQEvent *); + + void setDuplicatesEnabled(bool); + bool duplicatesEnabled() const; + + bool editable() const; + void setEditable(bool); + + virtual void popup(); + + void hide(); + +public slots: + void clear(); + void clearValidator(); + void clearEdit(); + virtual void setEditText(const TQString &); + +signals: + void activated(int); + void highlighted(int); + void activated(const TQString &); + void highlighted(const TQString &); + void textChanged(const TQString &); + +protected: + void paintEvent(TQPaintEvent *); + void resizeEvent(TQResizeEvent *); + void mousePressEvent(TQMouseEvent *); + void mouseMoveEvent(TQMouseEvent *); + void mouseReleaseEvent(TQMouseEvent *); + void mouseDoubleClickEvent(TQMouseEvent *); + void keyPressEvent(TQKeyEvent *); + void focusInEvent(TQFocusEvent *); + void focusOutEvent(TQFocusEvent *); + void wheelEvent(TQWheelEvent *); + void styleChange(TQStyle &); + + void updateMask(); + +private: + TQComboBox(const TQComboBox &); +}; |