![]() | TextBox Class |
Namespace: Mentula.GuiItems.Items
public class TextBox : Label
The TextBox type exposes the following members.
Name | Description | |
---|---|---|
![]() | TextBox(SpriteBatch, SpriteFont) |
Initializes a new instance of the TextBox class with default settings.
|
![]() | TextBox(SpriteBatch, Rect, SpriteFont) |
Initializes a new instance of the TextBox class with a specific size.
|
Name | Description | |
---|---|---|
![]() | AutoRefresh | (Inherited from Label.) |
![]() | AutoSize |
Gets or sets a value indicating if the Label will adjust its size to the text.
(Inherited from Label.) |
![]() | BackColor |
Gets or sets the background color for the GuiItem.
(Inherited from GuiItem.) |
![]() | BackgroundImage |
Gets or sets the background image displayed in the GuiItem.
(Inherited from GuiItem.) |
![]() | BorderStyle |
Gets or sets the type of border given to the Label.
(Inherited from Label.) |
![]() | Bounds |
Gets or sets the size of the GuiItem including its nonclient elements in pixels.
(Inherited from GuiItem.) |
![]() ![]() | DefaultMinimumSize |
Gets the default minimum size of the TextBox.
|
![]() | Disposing |
Gets a value indicating wether the base GuiItem class is in the process of disposing.
(Inherited from GuiItem.) |
![]() | Enabled |
Gets or sets a value indicating whether the GuiItem can respond to user interaction.
(Inherited from GuiItem.) |
![]() | FlickerStyle |
Gets or sets a value indicating how the TextBox should flicker.
|
![]() | Focused |
Gets or sets a value indicating if the TextBox is in focus.
|
![]() | Font |
Gets or sets the font used by the Label.
(Inherited from Label.) |
![]() | ForeColor |
Gets or sets the foregound color for the GuiItem.
(Inherited from GuiItem.) |
![]() | ForegroundRectangle |
Gets or sets the Rectangle used to draw the text.
(Inherited from Label.) |
![]() | Height |
Gets or sets the height of the GuiItem including its nonclient elements in pixels.
(Inherited from GuiItem.) |
![]() | InputType |
Gets or sets a value indicating the types of input allowed in this TextBox.
|
![]() | IsDisposed |
Gets a value indicating whether the GuiItem has been disposed.
(Inherited from GuiItem.) |
![]() | LineStart |
Gets or sets a value indicating from what line the Label should be shown.
(Inherited from Label.) |
![]() | MaximumSize |
Gets or sets a value indicating the maximum size of the TextBox.
Default value is the screen size.
|
![]() | MaxLength |
Gets or sets a value indicating the maximum length of the text input.
Negative values indicate no maximum length.
Default value = -1
|
![]() | MinimumSize |
Gets or sets a value indicating the minimum size of the TextBox.
|
![]() | MultiLine |
Gets or sets a value indicating of the TextBox can be multiline.
|
![]() | Name |
Gets or sets the name of the GuiItem.
(Inherited from GuiItem.) |
![]() | Origin |
Gets or sets a value indicating the origin of rotation.
(Inherited from GuiItem.) |
![]() | PasswordChar |
Gets or set a value indicating if the TextBox is a password field and which char it should use.
Default value = '\0' indicating that it is not a password field.
|
![]() | Position |
Gets or sets the position of the GuiItem.
(Inherited from GuiItem.) |
![]() | Rotation |
Gets or sets the client side rotation of the GuiItem.
(Inherited from GuiItem.) |
![]() | Size |
Gets or sets the size of the GuiItem.
(Inherited from GuiItem.) |
![]() | SuppressDraw |
Gets or sets a value indicating whether a MenuT should call the Draw(SpriteBatch) method.
(Inherited from GuiItem.) |
![]() | SuppressUpdate |
Gets or sets a value indicating whether a MenuT should call the Update(Single) method.
(Inherited from GuiItem.) |
![]() | Text |
Gets or sets the text of the Label.
(Inherited from Label.) |
![]() | Visible |
Gets or sets a value indicating whether the GuiItem is displayed.
(Inherited from GuiItem.) |
![]() | VisisbleText |
Gets the visible text of the TextBox.
|
![]() | Width |
Gets or sets the width of the GuiItem including its nonclient elements in pixels.
(Inherited from GuiItem.) |
![]() | X |
Gets or sets the horizontal component of the GuiItem.
(Inherited from GuiItem.) |
![]() | Y |
Gets or sets the vertical component of the GuiItem.
(Inherited from GuiItem.) |
Name | Description | |
---|---|---|
![]() | Dispose |
Releases the managed and unmanaged resources used by the GuiItem.
(Inherited from GuiItem.) |
![]() | Dispose(Boolean) |
Releases the unmanaged and managed resources used by the GuiItem.
(Inherited from GuiItem.) |
![]() | Draw |
Draws the TextBox to the specified SpriteBatch.
(Overrides GuiItemDraw(SpriteBatch).) |
![]() | Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) |
![]() | Finalize |
Disposes the unmanaged resources.
(Inherited from GuiItem.) |
![]() | GetHashCode | Serves as the default hash function. (Inherited from Object.) |
![]() | GetLineCount |
Get the number of lines in this Label (Inherited from Label.) |
![]() | GetMouseEventArgs |
Gets the mouse state as a MouseEventArgs object.
(Inherited from GuiItem.) |
![]() ![]() | GetRotatedMouse |
Gets the position of the mouse in respect to the GuiItem.
(Inherited from GuiItem.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | HandleAutoSize |
Handles the AutoSize functionality.
(Overrides LabelHandleAutoSize.) |
![]() | Hide |
Disables the GuiItem and makes it hiden.
(Inherited from GuiItem.) |
![]() | InitEvents |
Handles the initializing of the events.
(Overrides LabelInitEvents.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | MoveRelative |
Moves the GuiItem to a specified relative position.
If x is set the horizontal component of the anchor will have no effect.
If y is set the vertical component of the anchor will have no effect.
(Inherited from GuiItem.) |
![]() | OnBackColorChanged |
This method is called when the BackColorChanged event is raised.
(Inherited from GuiItem.) |
![]() | OnBackgroundImageChanged |
This method is called when the BackgroundImageChanged event is raised.
(Inherited from GuiItem.) |
![]() | OnEnabledChanged |
This method is called when the EnabledChanged event is raised.
(Inherited from GuiItem.) |
![]() | OnFocusChanged |
This method gets called when the FocusChanged event is raised.
|
![]() | OnFontChanged |
This method is called when the FontChanged event is raised.
(Inherited from Label.) |
![]() | OnForeColorChanged |
This method is called when the ForeColorChanged event is raised.
(Inherited from Label.) |
![]() | OnMove |
This method is called when the Moved event is raised.
(Inherited from Label.) |
![]() | OnNameChange |
This method is called when the NameChanged event is raised.
(Inherited from GuiItem.) |
![]() | OnResize |
This method is called when the Resized event is raised.
(Inherited from Label.) |
![]() | OnRotationChanged |
This method is called when the Rotated event is raised.
(Inherited from GuiItem.) |
![]() | OnTextChanged |
This method gets called when the TextChanged event is raised.
(Overrides LabelOnTextChanged(Label, ValueChangedEventArgsString).) |
![]() | OnVisibilityChanged |
This method is called when the VisibilityChanged event is raised.
(Inherited from GuiItem.) |
![]() | PerformClick |
Perform a mouse click.
(Inherited from GuiItem.) |
![]() | Refresh |
Recalculates the background and the foreground.
(Inherited from Label.) |
![]() | SetBackgroundTexture |
Sets the background texture for the Label.
(Inherited from Label.) |
![]() | SetForegroundTexture |
Sets the foreground texture for the TextBox.
(Overrides LabelSetForegroundTexture.) |
![]() | SetTextureHandler |
Sets textures to the required TextureHandler.
(Overrides LabelSetTextureHandler.) |
![]() | Show |
Enables the GuiItem and makes it visible.
(Inherited from GuiItem.) |
![]() | ToString |
Returns a string that represents the current GuiItem.
(Inherited from GuiItem.) |
![]() | Update |
Updates the TextBox, checking if any mouse- or keyboard event are occuring.
Use like: myTextBox.Update(Mouse.GetState(), Keyboard.GetState(), (float)gameTime.ElapsedGameTime.TotalSeconds);
(Overrides GuiItemUpdate(Single).) |
Name | Description | |
---|---|---|
![]() | BackColorChanged |
Occurs when the value of the BackColor property changes.
(Inherited from GuiItem.) |
![]() | BackgroundImageChanged |
Occurs when the value of the BackgroundImage property changes.
(Inherited from GuiItem.) |
![]() | Clicked |
Occurs when the GuiItem is clicked.
(Inherited from GuiItem.) |
![]() | Confirmed |
Occures when return is pressed on a non MultiLineTextBox.
|
![]() | EnabledChanged |
Occurs when the Enabled property changes.
(Inherited from GuiItem.) |
![]() | FocusChanged |
Occurs when the value of the Focused propery is changed.
|
![]() | FontChanged |
Occurs when the value of the Font propery is changed.
(Inherited from Label.) |
![]() | ForeColorChanged |
Occurs when the ForeColor property changes.
(Inherited from GuiItem.) |
![]() | Hover |
Occurs when the mouse pointer rests on the GuiItem.
(Inherited from GuiItem.) |
![]() | HoverEnter |
Occurs when the mouse pointer enters the GuiItem.
(Inherited from GuiItem.) |
![]() | HoverLeave |
Occurs when the mouse pointer leaves the GuiItem.
(Inherited from GuiItem.) |
![]() | Moved |
Occurs when the GuiItem is moved.
(Inherited from GuiItem.) |
![]() | NameChanged |
Occurs when the Name proprty changes.
(Inherited from GuiItem.) |
![]() | Resized |
Occurs when the GuiItem is resized.
(Inherited from GuiItem.) |
![]() | Rotated |
Occurs when the Rotation propery changes.
(Inherited from GuiItem.) |
![]() | TextChanged |
Occurs when the value of the Text propery is changed.
(Inherited from Label.) |
![]() | VisibilityChanged |
Occurs when the Visible property changes.
(Inherited from GuiItem.) |
Name | Description | |
---|---|---|
![]() | batch | The SpriteBatch used for generating the underlying Texture2D. (Inherited from GuiItem.) |
![]() | font | The specified SpriteFont. (Inherited from Label.) |
![]() | foregroundRectangle | The rectangle used in the foreground. (Inherited from Label.) |
![]() | leftDown | Whether the GuiItem is left clicked. (Inherited from GuiItem.) |
![]() | over | (Inherited from GuiItem.) |
![]() | rightDown | Whether the GuiItem is right clicked. (Inherited from GuiItem.) |
![]() | textures | Stores the Texture2D used for drawing. (Inherited from GuiItem.) |