• Articles
  • Api Documentation
Show / Hide Table of Contents
  • Inferno
    • CollisionMode
    • DrawMode
    • Game
    • Game.OnResizeEventArgs
    • GameState
    • GameState.StateOnDrawEventArgs
    • GameWindow
    • Instance
    • MathHelper
    • Matrix
    • Point
    • Rectangle
    • Settings
    • SpatialMode
    • UpdateMode
    • Vector2
    • Vector3
    • Vector4
  • Inferno.Audio
    • AudioDevice
    • Sound
  • Inferno.Content
    • ContentLoader
  • Inferno.Formats.Audio
    • WaveFormat
  • Inferno.Formats.Graphics.Text
    • FontFormat
  • Inferno.Graphics
    • Camera
    • Color
    • GraphicsDevice
    • PlatformType
    • Renderable
    • RenderableType
    • Renderer
    • RenderSortMode
    • RenderTarget
    • Shader
    • ShaderLanguage
    • ShaderType
    • Sprite
    • Texture2D
    • Tileset
  • Inferno.Graphics.Text
    • Font
    • FontBuilder
  • Inferno.Input
    • ButtonState
    • Key
    • Keyboard
    • Keyboard.KeyEventArgs
    • KeyboardState
    • KeyState
    • Mouse
    • MouseState
  • Inferno.Tiled
    • RenderOrder
    • TiledLayer
    • TiledLayerChunk
    • TiledLoader
    • TiledMap
    • TiledMapOrientation
    • TiledObject
    • TiledObjectLayer
    • TiledVersion
  • Inferno.UI
    • MessageBox
    • MessageBoxType
    • UserInterface
  • Inferno.UI.Controls
    • Button
    • Control
    • Control.ControlClickedEvent
    • Control.ControlHoveredEvent
    • Control.TextChangedEventArgs
    • ControlState
    • Cursor
    • Label

Class Control

This interface implements new manditory additions which aren't present in Instance

Inheritance
System.Object
Control
Button
Cursor
Label
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Inferno.UI.Controls
Assembly: Inferno.Desktop.dll
Syntax
public abstract class Control

Constructors

| Improve this Doc View Source

Control(Nullable<Vector2>, String, Font, Nullable<Color>, Nullable<Color>, Nullable<Color>, Int32, Sprite, Int32, Int32, Boolean)

Declaration
protected Control(Vector2? position = default(Vector2? ), string text = "", Font textFont = null, Color? foreColor = default(Color? ), Color? backColor = default(Color? ), Color? borderColor = default(Color? ), int borderWidth = 1, Sprite background = null, int width = 0, int height = 0, bool highlightOnHover = false)
Parameters
Type Name Description
System.Nullable<Vector2> position
System.String text
Font textFont
System.Nullable<Color> foreColor
System.Nullable<Color> backColor
System.Nullable<Color> borderColor
System.Int32 borderWidth
Sprite background
System.Int32 width
System.Int32 height
System.Boolean highlightOnHover

Fields

| Improve this Doc View Source

BackColor

The back color

Declaration
public Color BackColor
Field Value
Type Description
Color
| Improve this Doc View Source

Background

The background applied to the control

Declaration
public Sprite Background
Field Value
Type Description
Sprite
| Improve this Doc View Source

BorderColor

The border color

Declaration
public Color BorderColor
Field Value
Type Description
Color
| Improve this Doc View Source

BorderWidth

The border width

Declaration
public int BorderWidth
Field Value
Type Description
System.Int32
| Improve this Doc View Source

ForeColor

The forecolor

Declaration
public Color ForeColor
Field Value
Type Description
Color
| Improve this Doc View Source

Height

Declaration
public int Height
Field Value
Type Description
System.Int32
| Improve this Doc View Source

HighlightOnHover

Declaration
public bool HighlightOnHover
Field Value
Type Description
System.Boolean
| Improve this Doc View Source

OnTextChanged

Declaration
public EventHandler<Control.TextChangedEventArgs> OnTextChanged
Field Value
Type Description
System.EventHandler<Control.TextChangedEventArgs>
| Improve this Doc View Source

Position

Declaration
public Vector2 Position
Field Value
Type Description
Vector2
| Improve this Doc View Source

State

The control state

Declaration
public ControlState State
Field Value
Type Description
ControlState
| Improve this Doc View Source

TabIndex

The tab index (-1 = not indexed)

Declaration
public int TabIndex
Field Value
Type Description
System.Int32
| Improve this Doc View Source

TextFont

The font applied to text

Declaration
public Font TextFont
Field Value
Type Description
Font
| Improve this Doc View Source

UIOffset

The coordinate offset for mouse input

Declaration
public Vector2 UIOffset
Field Value
Type Description
Vector2
| Improve this Doc View Source

Width

Declaration
public int Width
Field Value
Type Description
System.Int32

Properties

| Improve this Doc View Source

Bounds

Declaration
public Rectangle Bounds { get; }
Property Value
Type Description
Rectangle
| Improve this Doc View Source

Text

The text to be drawn at the center of the Control

Declaration
public string Text { get; set; }
Property Value
Type Description
System.String

Methods

| Improve this Doc View Source

Draw(Renderer)

Declaration
public virtual void Draw(Renderer renderer)
Parameters
Type Name Description
Renderer renderer
| Improve this Doc View Source

Update()

Declaration
public virtual void Update()

Events

| Improve this Doc View Source

ControlClicked

Declaration
public event Control.ControlClickedEvent ControlClicked
Event Type
Type Description
Control.ControlClickedEvent
| Improve this Doc View Source

ControlHovered

Declaration
public event Control.ControlHoveredEvent ControlHovered
Event Type
Type Description
Control.ControlHoveredEvent
  • Improve this Doc
  • View Source
Back to top Generated by DocFX