OmegaEngine API  1.0.3
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Properties | Events | List of all members
OmegaGUI.Render.Dialog Class Reference

A dialog model containing DirectX-based controls More...

Inheritance diagram for OmegaGUI.Render.Dialog:
OmegaGUI.Render.MessageBox

Public Member Functions

void SetSize (int w, int h)
 Called to set dialog's size More...
 
void SetCaptionText (string text)
 Called to set dialog's caption More...
 
void SetBackgroundColors (Color4 topLeft, Color4 topRight, Color4 bottomLeft, Color4 bottomRight)
 Called to set dialog's border colors More...
 
void SetBackgroundColors (Color4 allCorners)
 Called to set dialog's border colors More...
 
void SetCaptionColor (Color4 color)
 
 Dialog (DialogManager manager, Color4 defaultTextColor, string defaultTexture, string defaultFont, uint defaultFontSize)
 Create a new instance of the dialog class More...
 
 Dialog (DialogManager manager, Color4 defaultTextColor)
 Create a new instance of the dialog class More...
 
 Dialog (DialogManager manager)
 Create a new instance of the dialog class More...
 
void RemoveAllControls ()
 Removes all controls from this dialog More...
 
void ClearRadioButtonGroup (uint groupIndex)
 Clears the radio button group More...
 
bool MessageProc (IntPtr hWnd, WindowMessage msg, IntPtr wParam, IntPtr lParam)
 Handle messages for this dialog More...
 
Control GetControlAtPoint (Point pt)
 Returns the control located at a point (if one exists) More...
 
void SetDefaultElement (ControlType ctype, uint index, Element e)
 Sets the default element More...
 
Element GetDefaultElement (ControlType ctype, uint index)
 Gets the default element More...
 
void SetFont (uint index, string faceName, uint fontHeight, FontWeight weight)
 Shared resource access. Indexed fonts and textures are shared among all the controls. More...
 
FontNode GetFont (uint index)
 Shared resource access. Indexed fonts and textures are shared among all the controls. More...
 
void SetTexture (uint index, string filename)
 Shared resource access. Indexed fonts and textures are shared among all the controls. More...
 
TextureNode GetTexture (uint index)
 Shared resource access. Indexed fonts and textures are shared among all the controls. More...
 
void InitializeControl (Control control)
 Initializes a control More...
 
void AddControl (Control control)
 Adds a control to the dialog More...
 
Label AddStatic (int id, string text, int x, int y, int w, int h, bool isDefault)
 Adds a static text control to the dialog More...
 
Label AddStatic (int id, string text, int x, int y, int w, int h)
 Adds a static text control to the dialog More...
 
PictureBox AddPictureBox (int id, int x, int y, int w, int h, Element fill)
 Adds a picture box control to the dialog More...
 
GroupBox AddGroupBox (int id, int x, int y, int w, int h, Color4 borderColor, Color4 fillCo)
 Adds a group box control to the dialog More...
 
Button AddButton (int id, string text, int x, int y, int w, int h, Keys hotkey, bool isDefault)
 Adds a button control to the dialog More...
 
Button AddButton (int id, string text, int x, int y, int w, int h)
 Adds a button control to the dialog More...
 
CheckBox AddCheckBox (int id, string text, int x, int y, int w, int h, bool ischecked, Keys hotkey, bool isDefault)
 Adds a checkbox to the dialog More...
 
CheckBox AddCheckBox (int id, string text, int x, int y, int w, int h, bool ischecked)
 Adds a checkbox control to the dialog More...
 
RadioButton AddRadioButton (int id, uint groupId, string text, int x, int y, int w, int h, bool ischecked, Keys hotkey, bool isDefault)
 Adds a radiobutton to the dialog More...
 
RadioButton AddRadioButton (int id, uint groupId, string text, int x, int y, int w, int h, bool ischecked)
 Adds a radio button control to the dialog More...
 
DropdownList AddDropdownList (int id, int x, int y, int w, int h, Keys hotkey, bool isDefault)
 Adds a dropdown list control to the dialog More...
 
DropdownList AddDropdownList (int id, int x, int y, int w, int h)
 Adds a dropdown list control to the dialog More...
 
Slider AddSlider (int id, int x, int y, int w, int h, int min, int max, int initialValue, bool isDefault)
 Adds a slider control to the dialog More...
 
Slider AddSlider (int id, int x, int y, int w, int h)
 Adds a slider control to the dialog More...
 
ScrollBar AddScrollBar (int id, int x, int y, int w, int h, int min, int max, int initialValue, bool isDefault)
 Adds a scroll bar control to the dialog More...
 
ScrollBar AddScrollBar (int id, int x, int y, int w, int h)
 Adds a scroll bar control to the dialog More...
 
ListBox AddListBox (int id, int x, int y, int w, int h, ListBoxStyle style)
 Adds a listbox control to the dialog More...
 
ListBox AddListBox (int id, int x, int y, int w, int h)
 Adds a listbox control to the dialog More...
 
TextBox AddTextBox (int id, string text, int x, int y, int w, int h, bool isDefault)
 Adds an edit box control to the dialog More...
 
TextBox AddTextBox (int id, string text, int x, int y, int w, int h)
 Adds an edit box control to the dialog More...
 
void OnRender (float elapsedTime)
 Render the dialog More...
 
void Refresh ()
 Refresh the dialog More...
 
void DrawText (string text, Element element, Rectangle rect, bool shadow)
 Draw's some text More...
 
void DrawSprite (Element element, Rectangle rect)
 Draw a sprite More...
 
void DrawText (string text, Element element, Rectangle rect)
 Draw's some text More...
 
void DrawRectangle (Rectangle rect, Color4 color, bool filled)
 Draw a rectangle More...
 

Static Public Member Functions

static void SetRefreshTime (float time)
 Set the static refresh time More...
 
static void RequestFocus (Control control)
 Request that this control has focus More...
 
static void ClearFocus ()
 Clears focus of the dialog More...
 

Public Attributes

const int WheelDelta = 120
 
bool IsMinimized
 
bool IsUsingNonUserEvents
 
bool IsUsingKeyboardInput
 
bool IsUsingMouseInput
 

Static Public Attributes

static readonly Color4 WhiteColorValue = new Color4(1.0f, 1.0f, 1.0f)
 
static readonly Color4 TransparentWhite = new Color4(0.0f, 1.0f, 1.0f, 1.0f)
 
static readonly Color4 BlackColorValue = new Color4(0.0f, 0.0f, 0.0f)
 

Properties

uint DefaultFontSize [get, set]
 
Point Location [get, set]
 The dialog's location More...
 
int Width [get, set]
 Dialogs width More...
 
int Height [get, set]
 Dialogs height More...
 
int CaptionHeight [get, set]
 The height of the caption bar at the top of the dialog More...
 

Events

EventHandler Resize
 

Detailed Description

A dialog model containing DirectX-based controls

Constructor & Destructor Documentation

◆ Dialog() [1/3]

OmegaGUI.Render.Dialog.Dialog ( DialogManager  manager,
Color4  defaultTextColor,
string  defaultTexture,
string  defaultFont,
uint  defaultFontSize 
)
inline

Create a new instance of the dialog class

Parameters
managerThe DialogManager instance that provides the resources for rendering of this dialog
defaultTextColorThe default color of text on this dialog
defaultTextureThe texture file containing the controls
defaultFontThe name of default font for text on controls
defaultFontSizeThe default font size

◆ Dialog() [2/3]

OmegaGUI.Render.Dialog.Dialog ( DialogManager  manager,
Color4  defaultTextColor 
)
inline

Create a new instance of the dialog class

Parameters
managerThe DialogManager instance that provides the resources for rendering of this dialog
defaultTextColorThe default color of text on this dialog

◆ Dialog() [3/3]

OmegaGUI.Render.Dialog.Dialog ( DialogManager  manager)
inline

Create a new instance of the dialog class

Parameters
managerThe DialogManager instance that provides the resources for rendering of this dialog

Member Function Documentation

◆ AddButton() [1/2]

Button OmegaGUI.Render.Dialog.AddButton ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h,
Keys  hotkey,
bool  isDefault 
)
inline

Adds a button control to the dialog

◆ AddButton() [2/2]

Button OmegaGUI.Render.Dialog.AddButton ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h 
)
inline

Adds a button control to the dialog

◆ AddCheckBox() [1/2]

CheckBox OmegaGUI.Render.Dialog.AddCheckBox ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h,
bool  ischecked,
Keys  hotkey,
bool  isDefault 
)
inline

Adds a checkbox to the dialog

◆ AddCheckBox() [2/2]

CheckBox OmegaGUI.Render.Dialog.AddCheckBox ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h,
bool  ischecked 
)
inline

Adds a checkbox control to the dialog

◆ AddControl()

void OmegaGUI.Render.Dialog.AddControl ( Control  control)
inline

Adds a control to the dialog

◆ AddDropdownList() [1/2]

DropdownList OmegaGUI.Render.Dialog.AddDropdownList ( int  id,
int  x,
int  y,
int  w,
int  h,
Keys  hotkey,
bool  isDefault 
)
inline

Adds a dropdown list control to the dialog

◆ AddDropdownList() [2/2]

DropdownList OmegaGUI.Render.Dialog.AddDropdownList ( int  id,
int  x,
int  y,
int  w,
int  h 
)
inline

Adds a dropdown list control to the dialog

◆ AddGroupBox()

GroupBox OmegaGUI.Render.Dialog.AddGroupBox ( int  id,
int  x,
int  y,
int  w,
int  h,
Color4  borderColor,
Color4  fillCo 
)
inline

Adds a group box control to the dialog

◆ AddListBox() [1/2]

ListBox OmegaGUI.Render.Dialog.AddListBox ( int  id,
int  x,
int  y,
int  w,
int  h,
ListBoxStyle  style 
)
inline

Adds a listbox control to the dialog

◆ AddListBox() [2/2]

ListBox OmegaGUI.Render.Dialog.AddListBox ( int  id,
int  x,
int  y,
int  w,
int  h 
)
inline

Adds a listbox control to the dialog

◆ AddPictureBox()

PictureBox OmegaGUI.Render.Dialog.AddPictureBox ( int  id,
int  x,
int  y,
int  w,
int  h,
Element  fill 
)
inline

Adds a picture box control to the dialog

◆ AddRadioButton() [1/2]

RadioButton OmegaGUI.Render.Dialog.AddRadioButton ( int  id,
uint  groupId,
string  text,
int  x,
int  y,
int  w,
int  h,
bool  ischecked,
Keys  hotkey,
bool  isDefault 
)
inline

Adds a radiobutton to the dialog

◆ AddRadioButton() [2/2]

RadioButton OmegaGUI.Render.Dialog.AddRadioButton ( int  id,
uint  groupId,
string  text,
int  x,
int  y,
int  w,
int  h,
bool  ischecked 
)
inline

Adds a radio button control to the dialog

◆ AddScrollBar() [1/2]

ScrollBar OmegaGUI.Render.Dialog.AddScrollBar ( int  id,
int  x,
int  y,
int  w,
int  h,
int  min,
int  max,
int  initialValue,
bool  isDefault 
)
inline

Adds a scroll bar control to the dialog

◆ AddScrollBar() [2/2]

ScrollBar OmegaGUI.Render.Dialog.AddScrollBar ( int  id,
int  x,
int  y,
int  w,
int  h 
)
inline

Adds a scroll bar control to the dialog

◆ AddSlider() [1/2]

Slider OmegaGUI.Render.Dialog.AddSlider ( int  id,
int  x,
int  y,
int  w,
int  h,
int  min,
int  max,
int  initialValue,
bool  isDefault 
)
inline

Adds a slider control to the dialog

◆ AddSlider() [2/2]

Slider OmegaGUI.Render.Dialog.AddSlider ( int  id,
int  x,
int  y,
int  w,
int  h 
)
inline

Adds a slider control to the dialog

◆ AddStatic() [1/2]

Label OmegaGUI.Render.Dialog.AddStatic ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h,
bool  isDefault 
)
inline

Adds a static text control to the dialog

◆ AddStatic() [2/2]

Label OmegaGUI.Render.Dialog.AddStatic ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h 
)
inline

Adds a static text control to the dialog

◆ AddTextBox() [1/2]

TextBox OmegaGUI.Render.Dialog.AddTextBox ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h,
bool  isDefault 
)
inline

Adds an edit box control to the dialog

◆ AddTextBox() [2/2]

TextBox OmegaGUI.Render.Dialog.AddTextBox ( int  id,
string  text,
int  x,
int  y,
int  w,
int  h 
)
inline

Adds an edit box control to the dialog

◆ ClearFocus()

static void OmegaGUI.Render.Dialog.ClearFocus ( )
inlinestatic

Clears focus of the dialog

◆ ClearRadioButtonGroup()

void OmegaGUI.Render.Dialog.ClearRadioButtonGroup ( uint  groupIndex)
inline

Clears the radio button group

◆ DrawRectangle()

void OmegaGUI.Render.Dialog.DrawRectangle ( Rectangle  rect,
Color4  color,
bool  filled 
)
inline

Draw a rectangle

◆ DrawSprite()

void OmegaGUI.Render.Dialog.DrawSprite ( Element  element,
Rectangle  rect 
)
inline

Draw a sprite

◆ DrawText() [1/2]

void OmegaGUI.Render.Dialog.DrawText ( string  text,
Element  element,
Rectangle  rect,
bool  shadow 
)
inline

Draw's some text

◆ DrawText() [2/2]

void OmegaGUI.Render.Dialog.DrawText ( string  text,
Element  element,
Rectangle  rect 
)
inline

Draw's some text

◆ GetControlAtPoint()

Control OmegaGUI.Render.Dialog.GetControlAtPoint ( Point  pt)
inline

Returns the control located at a point (if one exists)

◆ GetDefaultElement()

Element OmegaGUI.Render.Dialog.GetDefaultElement ( ControlType  ctype,
uint  index 
)
inline

Gets the default element

◆ GetFont()

FontNode OmegaGUI.Render.Dialog.GetFont ( uint  index)
inline

Shared resource access. Indexed fonts and textures are shared among all the controls.

◆ GetTexture()

TextureNode OmegaGUI.Render.Dialog.GetTexture ( uint  index)
inline

Shared resource access. Indexed fonts and textures are shared among all the controls.

◆ InitializeControl()

void OmegaGUI.Render.Dialog.InitializeControl ( Control  control)
inline

Initializes a control

◆ MessageProc()

bool OmegaGUI.Render.Dialog.MessageProc ( IntPtr  hWnd,
WindowMessage  msg,
IntPtr  wParam,
IntPtr  lParam 
)
inline

Handle messages for this dialog

Returns
true if the message was handled and no further processing is necessary

◆ OnRender()

void OmegaGUI.Render.Dialog.OnRender ( float  elapsedTime)
inline

Render the dialog

◆ Refresh()

void OmegaGUI.Render.Dialog.Refresh ( )
inline

Refresh the dialog

◆ RemoveAllControls()

void OmegaGUI.Render.Dialog.RemoveAllControls ( )
inline

Removes all controls from this dialog

◆ RequestFocus()

static void OmegaGUI.Render.Dialog.RequestFocus ( Control  control)
inlinestatic

Request that this control has focus

◆ SetBackgroundColors() [1/2]

void OmegaGUI.Render.Dialog.SetBackgroundColors ( Color4  topLeft,
Color4  topRight,
Color4  bottomLeft,
Color4  bottomRight 
)
inline

Called to set dialog's border colors

◆ SetBackgroundColors() [2/2]

void OmegaGUI.Render.Dialog.SetBackgroundColors ( Color4  allCorners)
inline

Called to set dialog's border colors

◆ SetCaptionText()

void OmegaGUI.Render.Dialog.SetCaptionText ( string  text)
inline

Called to set dialog's caption

◆ SetDefaultElement()

void OmegaGUI.Render.Dialog.SetDefaultElement ( ControlType  ctype,
uint  index,
Element  e 
)
inline

Sets the default element

◆ SetFont()

void OmegaGUI.Render.Dialog.SetFont ( uint  index,
string  faceName,
uint  fontHeight,
FontWeight  weight 
)
inline

Shared resource access. Indexed fonts and textures are shared among all the controls.

◆ SetRefreshTime()

static void OmegaGUI.Render.Dialog.SetRefreshTime ( float  time)
inlinestatic

Set the static refresh time

◆ SetSize()

void OmegaGUI.Render.Dialog.SetSize ( int  w,
int  h 
)
inline

Called to set dialog's size

◆ SetTexture()

void OmegaGUI.Render.Dialog.SetTexture ( uint  index,
string  filename 
)
inline

Shared resource access. Indexed fonts and textures are shared among all the controls.

Property Documentation

◆ CaptionHeight

int OmegaGUI.Render.Dialog.CaptionHeight
getset

The height of the caption bar at the top of the dialog

◆ Height

int OmegaGUI.Render.Dialog.Height
getset

Dialogs height

◆ Location

Point OmegaGUI.Render.Dialog.Location
getset

The dialog's location

◆ Width

int OmegaGUI.Render.Dialog.Width
getset

Dialogs width


The documentation for this class was generated from the following file: