RenameWidget.RenameWidget Class Reference


Detailed Description

This is a simple text-edit control, that can be popped up by itself, not in a window.

It can be used to rename objects on the fly. When the user presses enter, or this widget loses focus for any other reason, then the field transmits the new object name and destroys itself.

#include <class_rename_widget_1_1_rename_widget.h>

Inheritance diagram for RenameWidget.RenameWidget:
Inheritance graph
[legend]

List of all members.

Public Member Functions

  __init__ ()
  parentWindow: The window this edit field is appearing over initialString: The string that should be showing in the field when it appears position: (x,y) relative to its parent window size: (x,y) messageToSend: the name of the application message that will be sent when the user presses ENTER data: A tuple - the data to send with the message.
  OnCancelIfEscape ()
  The escape key is interpreted as 'cancel'.
  OnKillFocus ()

Public Attributes

  myID
  myMessage
  myData
  myInitialString
  myMessageSent
  myFrame

Member Function Documentation

RenameWidget.RenameWidget.__init__ ( )

parentWindow: The window this edit field is appearing over initialString: The string that should be showing in the field when it appears position: (x,y) relative to its parent window size: (x,y) messageToSend: the name of the application message that will be sent when the user presses ENTER data: A tuple - the data to send with the message.

When the message is sent, the new string value be added as the last member of this tuple. maxLength: Maximum length of the string in the widget (use the greater of this value and the length of initialString). 0=no maximum.

Reimplemented in NumericalInputWidget.NumericalInputWidget.

RenameWidget.RenameWidget.OnCancelIfEscape ( )

The escape key is interpreted as 'cancel'.

Reimplemented in NumericalInputWidget.NumericalInputWidget.

RenameWidget.RenameWidget.OnKillFocus ( )

Member Data Documentation


RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget
RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget RenameWidget.RenameWidget