Wt::WLineEdit Class Reference

A widget that provides a single line edit. More...

#include <WLineEdit>

Inheritance diagram for Wt::WLineEdit:

Inheritance graph
[legend]

List of all members.

Public Types

enum  EchoMode { Normal, Password }
 Enum that describes how the contents is displayed. More...

Public Member Functions

 WLineEdit (WContainerWidget *parent=0)
 Construct a line edit with empty content and optional parent.
 WLineEdit (const WString &content, WContainerWidget *parent=0)
 Construct a line edit with given content and optional parent.
void setTextSize (int chars)
 Specify the width of the line edit in number of characters.
int textSize () const
 Get the current width of the line edit in number of characters.
void setText (const WString &text)
 Change the content of the line edit.
const WStringtext () const
 Get the current content.
void setEchoMode (EchoMode echoMode)
 Set the echo mode.
EchoMode echoMode () const
 Get the echo mode.
WValidator::State validate ()
 Validate the field.


Detailed Description

A widget that provides a single line edit.

WLineEdit is an inline widget.

To act upon text changes, connect a slot to the changed() signal. This signal is emitted when the user changed the content, and subsequently removes the focus from the line edit.

To act upon editing, connect a slot to the WInteractWidget::keyWentUp signal.

At all times, the current content may be accessed with the text() method.

See also:
WTextArea

Member Enumeration Documentation

enum Wt::WLineEdit::EchoMode

Enum that describes how the contents is displayed.

See also:
setEchoMode

echoMode

Enumerator:
Normal  Characters are shown.
Password  Hide the contents as for a password.


Member Function Documentation

int Wt::WLineEdit::textSize (  )  const [inline]

Get the current width of the line edit in number of characters.

See also:
setTextSize(int)

void Wt::WLineEdit::setEchoMode ( EchoMode  echoMode  ) 

Set the echo mode.

The default echo mode is Normal.


The documentation for this class was generated from the following files:
Generated on Mon Apr 14 15:15:01 2008 for Wt by doxygen 1.5.3