MildenhallButtonSpeller

MildenhallButtonSpeller — creates a button for speller widget

Functions

Properties

gchar * font-type Read / Write
gfloat height Read / Write
GObject * model Read / Write
gchar * name Read / Write
gchar * normal-image Read / Write
gchar * pressed-image Read / Write
gchar * type Read / Write
gfloat width Read / Write
gfloat x Read / Write
gfloat y Read / Write

Types and Values

Object Hierarchy

    GObject
    ╰── GInitiallyUnowned
        ╰── ClutterActor
            ╰── LightwoodButton
                ╰── MildenhallButtonSpeller

Implemented Interfaces

MildenhallButtonSpeller implements ClutterContainer, ClutterScriptable, ClutterAnimatable and AtkImplementorIface.

Description

MildenhallButtonSpeller widget can be used to display a button for the speller widget. Typically it displays a text describing its action. It is also possible to include an image inside the speller button. It also provides model using which the application can set the various properties using v_button_speller_set_model().

Freeing the widget

Call g_object_unref() to free the widget.

Sample C Code

1
2
3
4
5
6
7
8
9
10
11
GObject *object = NULL;
ThornburyItemFactory *item_factory = NULL;
MildenhallButtonSpeller *button = NULL;

item_factory = thornbury_item_factory_generate_widget_with_props (
	MILDENHALL_TYPE_TOGGLE_BUTTON,
	"/usr/Application/MyApp/share/mildenhall_button_speller_text_prop.json");

g_object_get (item_factory, "object", &object, NULL);
button = MILDENHALL_BUTTON_SPELLER (object);
clutter_actor_add_child (stage, CLUTTER_ACTOR (button));

Refer ThornburyItemFactory for Thornbury Item Factory details.

Functions

mildenhall_button_speller_new ()

ClutterActor *
mildenhall_button_speller_new (void);

Creates a new MildenhallButtonSpeller.

Returns

speller button object.

[transfer full]


v_button_speller_set_text ()

void
v_button_speller_set_text (ClutterActor *pActor,
                           const gchar *pText);

sets the text for button

Parameters

pActor

object reference

 

pText

text to set

 

v_button_speller_set_x ()

void
v_button_speller_set_x (MildenhallButtonSpeller *pButtonSpeller,
                        gfloat flX);

set the x position

Parameters

pButtonSpeller

object reference

 

flX

set the x position

 

v_button_speller_set_y ()

void
v_button_speller_set_y (MildenhallButtonSpeller *pButtonSpeller,
                        gfloat flY);

set the y position

Parameters

pButtonSpeller

object reference

 

flX

set the y position

 

v_button_speller_set_width ()

void
v_button_speller_set_width (MildenhallButtonSpeller *pButtonSpeller,
                            gfloat flWidth);

set the width for button

Parameters

pButtonSpeller

object reference

 

flWidth

set the width for button

 

v_button_speller_set_height ()

void
v_button_speller_set_height (MildenhallButtonSpeller *pButtonSpeller,
                             gfloat flHeight);

set the height for button

Parameters

pButtonSpeller

object reference

 

flHeight

set the height for button

 

v_button_speller_set_type ()

void
v_button_speller_set_type (MildenhallButtonSpeller *pButtonSpeller,
                           gchar *pType);

set the value according to type

Parameters

pButtonSpeller

object reference

 

pType

set the type as text/texture

 

v_button_speller_set_name ()

void
v_button_speller_set_name (MildenhallButtonSpeller *pButtonSpeller,
                           gchar *pName);

set the name for button

Parameters

pButtonSpeller

object reference

 

pName

set the name for button

 

v_button_speller_set_normal ()

void
v_button_speller_set_normal (MildenhallButtonSpeller *pButtonSpeller,
                             gchar *pNormal);

set the icon at default

Parameters

pButtonSpeller

object reference

 

pNormal

icon to set at default

 

v_button_speller_set_pressed ()

void
v_button_speller_set_pressed (MildenhallButtonSpeller *pButtonSpeller,
                              gchar *pPressed);

set the icon when button is pressed

Parameters

pButtonSpeller

object reference

 

pPressed

icon to set when pressed

 

Types and Values

struct MildenhallButtonSpeller

struct MildenhallButtonSpeller;

The MildenhallButtonSpeller struct contains only private data.


struct MildenhallButtonSpellerClass

struct MildenhallButtonSpellerClass {
  LightwoodButtonClass parent_class;
};

The MildenhallButtonSpellerClass struct contains only private data.

Property Details

The “font-type” property

  “font-type”                gchar *

Set the font to button

Flags: Read / Write

Default value: NULL


The “height” property

  “height”                   gfloat

this to set height of the button

Flags: Read / Write

Allowed values: >= 0

Default value: 0


The “model” property

  “model”                    GObject *

this to set model to button

Flags: Read / Write


The “name” property

  “name”                     gchar *

Set this to known the name of button

Flags: Read / Write

Default value: NULL


The “normal-image” property

  “normal-image”             gchar *

Set this image to button at button release

Flags: Read / Write

Default value: NULL


The “pressed-image” property

  “pressed-image”            gchar *

Set this image to button at button press

Flags: Read / Write

Default value: NULL


The “type” property

  “type”                     gchar *

Set this to known the type of button to create

Flags: Read / Write

Default value: NULL


The “width” property

  “width”                    gfloat

this to set width of the button

Flags: Read / Write

Allowed values: >= 0

Default value: 0


The “x” property

  “x”                        gfloat

this to set x position of the button

Flags: Read / Write

Allowed values: >= 0

Default value: 0


The “y” property

  “y”                        gfloat

this to set y position of the button

Flags: Read / Write

Allowed values: >= 0

Default value: 0

See Also

MildenhallButtonDrawer, LightwoodButton