nux-0.9.46

nux::RGBValuator Class Reference

#include <Nux/RGBValuator.h>

Inheritance diagram for nux::RGBValuator:
nux::View nux::InputArea nux::Area nux::InitiallyUnownedObject nux::Focusable nux::Object nux::Trackable

Public Types

enum  ColorFormat { COLORFORMAT_FLOAT = 0, COLORFORMAT_HEX, COLORFORMAT_INT }

Public Member Functions

 RGBValuator (NUX_FILE_LINE_PROTO)
 RGBValuator (Color color, NUX_FILE_LINE_PROTO)
 RGBValuator (float red, float green, float blue, float alpha, NUX_FILE_LINE_PROTO)
 RGBValuator (eColorModel colorModel, float x, float y, float z, float alpha, NUX_FILE_LINE_PROTO)
 ~RGBValuator ()
void SetColorModel (eColorModel cm)
void SetColorFormat (ColorFormat cf)
Color GetColor ()
float GetRed ()
float GetGreen ()
float GetBlue ()
float GetAlpha ()
virtual long ProcessEvent (IEvent &ievent, long TraverseInfo, long ProcessEventInfo)
virtual void Draw (GraphicsEngine &GfxContext, bool force_draw)
virtual void DrawContent (GraphicsEngine &GfxContext, bool force_draw)
virtual void PostDraw (GraphicsEngine &GfxContext, bool force_draw)
void SetRGB (Color color)
void SetRGB (float r, float g, float b)
void SetAlpha (float alpha)
void SetRGBA (Color color)
void SetRGBA (float r, float g, float b, float a)
void SetHSV (float h, float s, float v)
void SetHLS (float h, float l, float s)
void OnReceiveMouseDown_Red (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseDown_Green (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseDown_Blue (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseDown_Alpha (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseDrag_Red (int x, int y, int dx, int dy, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseDrag_Green (int x, int y, int dx, int dy, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseDrag_Blue (int x, int y, int dx, int dy, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseDrag_Alpha (int x, int y, int dx, int dy, unsigned long button_flags, unsigned long key_flags)
void OnChangeColorModel ()
void OnChangeColorFormat ()
void RecvMouseDownColorModel (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseUp_Red (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseUp_Green (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnReceiveMouseUp_Blue (int x, int y, unsigned long button_flags, unsigned long key_flags)
void OnComponentInput (EditTextBox *textbox, const NString &s, int componentIndex)
void OnChannelKeyboardFocus ()
void OnChannelLostKeyboardFocus ()
void OnChannelValidateKeyboardEntry ()
void OnChannelCharacter (unsigned int character, int componentIndex)
void EmitColorChangedSignal ()
 Cause the widget to emit sigColorChanged signal.

Data Fields

sigc::signal< void, float,
float, float, float > 
sigColorChanged

Protected Member Functions

void InitializeWidgets ()
void InitializeLayout ()
void DestroyLayout ()

Member Enumeration Documentation

Enumerator:
COLORFORMAT_FLOAT 
COLORFORMAT_HEX 
COLORFORMAT_INT 

Constructor & Destructor Documentation

nux::RGBValuator::RGBValuator ( NUX_FILE_LINE_PROTO  )
nux::RGBValuator::RGBValuator ( Color  color,
NUX_FILE_LINE_PROTO   
)
nux::RGBValuator::RGBValuator ( float  red,
float  green,
float  blue,
float  alpha,
NUX_FILE_LINE_PROTO   
)

Create an initialize the widget with the CM_RGB color model and value.

Parameters:
red
green
blue
alpha
nux::RGBValuator::RGBValuator ( eColorModel  colorModel,
float  x,
float  y,
float  z,
float  alpha,
NUX_FILE_LINE_PROTO   
)

Create an initialize the widget with the appropriate color model and value.

Parameters:
ColorModelThe color model (CM_RGB, CM_HSV, CM_HLS)
xRed if CM_RGB, Hue if CM_HSV, Hue if CM_HLS
yGreen if CM_RGB, Saturation if CM_HSV, Light if CM_HLS
zBlue if CM_RGB, Value if CM_HSV, Saturation if CM_HLS
alpha
nux::RGBValuator::~RGBValuator ( )

Member Function Documentation

void nux::RGBValuator::DestroyLayout ( ) [protected]

Reimplemented from nux::View.

virtual void nux::RGBValuator::Draw ( GraphicsEngine GfxContext,
bool  force_draw 
) [virtual]

Implements nux::View.

virtual void nux::RGBValuator::DrawContent ( GraphicsEngine GfxContext,
bool  force_draw 
) [virtual]

Reimplemented from nux::View.

void nux::RGBValuator::EmitColorChangedSignal ( )

Cause the widget to emit sigColorChanged signal.

Cause the widget to emit sigColorChanged signal. Useful for initialization of the signal receivers.

float nux::RGBValuator::GetAlpha ( )
float nux::RGBValuator::GetBlue ( )
Color nux::RGBValuator::GetColor ( )
float nux::RGBValuator::GetGreen ( )
float nux::RGBValuator::GetRed ( )
void nux::RGBValuator::InitializeLayout ( ) [protected]

Reimplemented from nux::View.

void nux::RGBValuator::InitializeWidgets ( ) [protected]

Reimplemented from nux::View.

void nux::RGBValuator::OnChangeColorFormat ( )
void nux::RGBValuator::OnChangeColorModel ( )
void nux::RGBValuator::OnChannelCharacter ( unsigned int  character,
int  componentIndex 
)
void nux::RGBValuator::OnChannelKeyboardFocus ( )
void nux::RGBValuator::OnChannelLostKeyboardFocus ( )
void nux::RGBValuator::OnChannelValidateKeyboardEntry ( )
void nux::RGBValuator::OnComponentInput ( EditTextBox textbox,
const NString s,
int  componentIndex 
)
void nux::RGBValuator::OnReceiveMouseDown_Alpha ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseDown_Blue ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseDown_Green ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseDown_Red ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseDrag_Alpha ( int  x,
int  y,
int  dx,
int  dy,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseDrag_Blue ( int  x,
int  y,
int  dx,
int  dy,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseDrag_Green ( int  x,
int  y,
int  dx,
int  dy,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseDrag_Red ( int  x,
int  y,
int  dx,
int  dy,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseUp_Blue ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseUp_Green ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::OnReceiveMouseUp_Red ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
virtual void nux::RGBValuator::PostDraw ( GraphicsEngine GfxContext,
bool  force_draw 
) [virtual]

Reimplemented from nux::View.

virtual long nux::RGBValuator::ProcessEvent ( IEvent ievent,
long  TraverseInfo,
long  ProcessEventInfo 
) [virtual]

Implements nux::View.

void nux::RGBValuator::RecvMouseDownColorModel ( int  x,
int  y,
unsigned long  button_flags,
unsigned long  key_flags 
)
void nux::RGBValuator::SetAlpha ( float  alpha)
void nux::RGBValuator::SetColorFormat ( ColorFormat  cf)
void nux::RGBValuator::SetColorModel ( eColorModel  cm)
void nux::RGBValuator::SetHLS ( float  h,
float  l,
float  s 
)
void nux::RGBValuator::SetHSV ( float  h,
float  s,
float  v 
)
void nux::RGBValuator::SetRGB ( Color  color)
void nux::RGBValuator::SetRGB ( float  r,
float  g,
float  b 
)
void nux::RGBValuator::SetRGBA ( Color  color)
void nux::RGBValuator::SetRGBA ( float  r,
float  g,
float  b,
float  a 
)

Field Documentation

sigc::signal<void, float, float, float, float> nux::RGBValuator::sigColorChanged

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