qinputdialog.3qt - Man Page
Simple convenience dialog to get a single value from the user
Synopsis
#include <qinputdialog.h>
Inherits QDialog.
Static Public Members
<li class=fn>QString getText ( const QString & caption, const QString & label, QLineEdit::EchoMode mode = QLineEdit::Normal, const QString & text = QString::null, bool * ok = 0, QWidget * parent = 0, const char * name = 0 ) <li class=fn>int getInteger ( const QString & caption, const QString & label, int value = 0, int minValue = -2147483647, int maxValue = 2147483647, int step = 1, bool * ok = 0, QWidget * parent = 0, const char * name = 0 ) <li class=fn>double getDouble ( const QString & caption, const QString & label, double value = 0, double minValue = -2147483647, double maxValue = 2147483647, int decimals = 1, bool * ok = 0, QWidget * parent = 0, const char * name = 0 ) <li class=fn>QString getItem ( const QString & caption, const QString & label, const QStringList & list, int current = 0, bool editable = TRUE, bool * ok = 0, QWidget * parent = 0, const char * name = 0 )
Description
The QInputDialog class provides a simple convenience dialog to get a single value from the user.
The input value can be a string, a number or an item from a list. A label must be set to tell the user what they should enter.
Four static convenience functions are provided: getText(), getInteger(), getDouble() and getItem(). All the functions can be used in a similar way, for example:
bool ok; QString text = QInputDialog::getText( "MyApp 3000", "Enter your name:", QLineEdit::Normal, QString::null, &ok, this ); if ( ok && !text.isEmpty() ) { // user entered something and pressed OK } else { // user entered nothing or pressed Cancel }
<center>
[Image Omitted]
</center>
See also Dialog Classes.
Member Function Documentation
See Also
http://doc.trolltech.com/qinputdialog.html http://www.trolltech.com/faq/tech.html
Copyright
Copyright 1992-2007 Trolltech ASA, http://www.trolltech.com. See the license file included in the distribution for a complete license statement.
Author
Generated automatically from the source code.
Bugs
If you find a bug in Qt, please report it as described in http://doc.trolltech.com/bughowto.html. Good bug reports help us to help you. Thank you.
The definitive Qt documentation is provided in HTML format; it is located at $QTDIR/doc/html and can be read using Qt Assistant or with a web browser. This man page is provided as a convenience for those users who prefer man pages, although this format is not officially supported by Trolltech.
If you find errors in this manual page, please report them to qt-bugs@trolltech.com. Please include the name of the manual page (qinputdialog.3qt) and the Qt version (3.3.8).
Referenced By
The man page QInputDialog.3qt(3) is an alias of qinputdialog.3qt(3).