Download

Support

Ewl_Histogram: A Simple Histogram widget


Detailed Description

Remarks:
Inherits from Ewl_Image.

Tutorial


Data Structures

struct  Ewl_Histogram
 Inherit from the Ewl_Image and extends to create a histogram widget. More...

Defines

#define EWL_HISTOGRAM(histogram)   ((Ewl_Histogram *)histogram)
#define EWL_HISTOGRAM_IS(w)   (ewl_widget_type_is(EWL_WIDGET(w), EWL_HISTOGRAM_TYPE))
#define EWL_HISTOGRAM_TYPE   "histogram"

Typedefs

typedef Ewl_Histogram Ewl_Histogram

Functions

void ewl_histogram_cb_configure (Ewl_Widget *w, void *event, void *data)
Ewl_Histogram_Channel ewl_histogram_channel_get (Ewl_Histogram *histogram)
 Sets the color channel to graph in the histogram.
void ewl_histogram_channel_set (Ewl_Histogram *histogram, Ewl_Histogram_Channel channel)
 Sets the color channel to graph in the histogram.
void ewl_histogram_color_get (Ewl_Histogram *histogram, unsigned int *r, unsigned int *g, unsigned int *b, unsigned int *a)
 Get the current color values for drawing the histogram.
void ewl_histogram_color_set (Ewl_Histogram *histogram, unsigned int r, unsigned int g, unsigned int b, unsigned int a)
 Changes the drawing color of a histogram.
Ewl_Imageewl_histogram_image_get (Ewl_Histogram *histogram)
 Get the source image used to generate the histogram.
void ewl_histogram_image_set (Ewl_Histogram *histogram, Ewl_Image *image)
 Change the source image used to generate the histogram.
int ewl_histogram_init (Ewl_Histogram *histogram)
 Initialize a histogram widget to starting values.
Ewl_Widgetewl_histogram_new (void)
 Create a new Ewl_Histogram widget.

Define Documentation

#define EWL_HISTOGRAM ( histogram   )     ((Ewl_Histogram *)histogram)

Typecast a pointer to an Ewl_Histogram pointer.

#define EWL_HISTOGRAM_IS (  )     (ewl_widget_type_is(EWL_WIDGET(w), EWL_HISTOGRAM_TYPE))

Returns TRUE if the widget is an Ewl_Histogram, FALSE otherwise

#define EWL_HISTOGRAM_TYPE   "histogram"

The type name for the Ewl_Histogram widget


Typedef Documentation

typedef struct Ewl_Histogram Ewl_Histogram


Function Documentation

void ewl_histogram_cb_configure ( Ewl_Widget w,
void *  event,
void *  data 
)

Ewl_Histogram_Channel ewl_histogram_channel_get ( Ewl_Histogram hist  ) 

Sets the color channel to graph in the histogram.

Parameters:
hist,: the histogram to change the channel drawn
Returns:
Returns the currently drawn color channel.

void ewl_histogram_channel_set ( Ewl_Histogram hist,
Ewl_Histogram_Channel  channel 
)

Sets the color channel to graph in the histogram.

Parameters:
hist,: the histogram to change the channel drawn
channel,: the color channel to draw in the histogram
Returns:
Returns no value.

void ewl_histogram_color_get ( Ewl_Histogram hist,
unsigned int *  r,
unsigned int *  g,
unsigned int *  b,
unsigned int *  a 
)

Get the current color values for drawing the histogram.

Parameters:
hist,: the histogram widget to retrieve display color
r,: red value for histogram drawing color
g,: green value for histogram drawing color
b,: blue value for histogram drawing color
a,: apha value for histogram drawing color
Returns:
Returns no value.

void ewl_histogram_color_set ( Ewl_Histogram hist,
unsigned int  r,
unsigned int  g,
unsigned int  b,
unsigned int  a 
)

Changes the drawing color of a histogram.

Parameters:
hist,: the histogram widget to change display color
r,: red value for histogram drawing color
g,: green value for histogram drawing color
b,: blue value for histogram drawing color
a,: apha value for histogram drawing color
Returns:
Returns no value.

Ewl_Image* ewl_histogram_image_get ( Ewl_Histogram hist  ) 

Get the source image used to generate the histogram.

Parameters:
hist,: the histogram to get source image
Returns:
Returns a pointer to the current source image.

void ewl_histogram_image_set ( Ewl_Histogram hist,
Ewl_Image image 
)

Change the source image used to generate the histogram.

Parameters:
hist,: the histogram to change source image
image,: the new source image for the histogram
Returns:
Returns no value.

int ewl_histogram_init ( Ewl_Histogram hist  ) 

Initialize a histogram widget to starting values.

Parameters:
hist,: the histogram widget to initialize
Returns:
Returns TRUE on success, FALSE on failure.

Ewl_Widget* ewl_histogram_new ( void   ) 

Create a new Ewl_Histogram widget.

Returns:
Returns a new Ewl_Histogram widget.


Copyright © Enlightenment.org

Enlightened Widget Library Documentation Generated: Sun Sep 27 01:49:46 2009