AgsScale

AgsScale — A scale widget

Stability Level

Stable, unless otherwise indicated

Functions

Properties

char * control-name Read / Write
double default-value Read / Write
double lower Read / Write
double upper Read / Write

Signals

void value-changed Run Last

Types and Values

Object Hierarchy

    GObject
    ╰── GInitiallyUnowned
        ╰── GtkWidget
            ╰── AgsScale

Includes

#include <ags/widget/ags_scale.h>

Description

AgsScale is a widget that shows you a meter.

Functions

ags_scale_set_control_name ()

void
ags_scale_set_control_name (AgsScale *scale,
                            gchar *control_name);

Set control_name of scale .

Parameters

scale

the AgsScale

 

control_name

the scale height

 

Since: 3.2.2


ags_scale_get_control_name ()

gchar *
ags_scale_get_control_name (AgsScale *scale);

Get scale height of scale .

Parameters

scale

the AgsScale

 

Returns

the scale height

Since: 3.2.2


ags_scale_set_upper ()

void
ags_scale_set_upper (AgsScale *scale,
                     gdouble upper);

Set upper of scale .

Parameters

scale

the AgsScale

 

upper

the upper

 

Since: 3.2.2


ags_scale_get_upper ()

gdouble
ags_scale_get_upper (AgsScale *scale);

Get upper of scale .

Parameters

scale

the AgsScale

 

Returns

the upper

Since: 3.2.2


ags_scale_set_lower ()

void
ags_scale_set_lower (AgsScale *scale,
                     gdouble lower);

Set lower of scale .

Parameters

scale

the AgsScale

 

lower

the lower

 

Since: 3.2.2


ags_scale_get_lower ()

gdouble
ags_scale_get_lower (AgsScale *scale);

Get lower of scale .

Parameters

scale

the AgsScale

 

Returns

the lower

Since: 3.2.2


ags_scale_set_default_value ()

void
ags_scale_set_default_value (AgsScale *scale,
                             gdouble default_value);

Set default_value of scale .

Parameters

scale

the AgsScale

 

default_value

the normalized volume

 

Since: 3.2.2


ags_scale_get_default_value ()

gdouble
ags_scale_get_default_value (AgsScale *scale);

Get normalized volume of scale .

Parameters

scale

the AgsScale

 

Returns

the normalized volume

Since: 3.2.2


ags_scale_value_changed ()

void
ags_scale_value_changed (AgsScale *scale,
                         gdouble default_value);

Emits ::value-changed event.

Parameters

scale

the AgsScale

 

default_value

the default value

 

Since: 3.0.0


ags_scale_new ()

AgsScale *
ags_scale_new (GtkOrientation orientation,
               guint width_request,
               guint height_request);

Create a new instance of AgsScale.

Parameters

orientation

the GtkOrientation

 

width_request

the scale's width

 

height_request

the scale's height

 

Returns

the new AgsScale instance

Since: 3.0.0

Types and Values

AGS_SCALE_DEFAULT_WIDTH_REQUEST

#define AGS_SCALE_DEFAULT_WIDTH_REQUEST (60)

AGS_SCALE_DEFAULT_HEIGHT_REQUEST

#define AGS_SCALE_DEFAULT_HEIGHT_REQUEST (128)

AGS_SCALE_DEFAULT_CONTROL_NAME

#define AGS_SCALE_DEFAULT_CONTROL_NAME "no name"

AGS_SCALE_DEFAULT_LOWER

#define AGS_SCALE_DEFAULT_LOWER (0.0)

AGS_SCALE_DEFAULT_UPPER

#define AGS_SCALE_DEFAULT_UPPER (1.0)

AGS_SCALE_DEFAULT_VALUE

#define AGS_SCALE_DEFAULT_VALUE (0.0)

AGS_SCALE_DEFAULT_STEP_COUNT

#define AGS_SCALE_DEFAULT_STEP_COUNT (16.0)

AGS_SCALE_DEFAULT_PAGE_SIZE

#define AGS_SCALE_DEFAULT_PAGE_SIZE (8.0)

enum AgsScaleFlags

Members

AGS_SCALE_LOGARITHMIC

   

enum AgsScaleButtonState

Members

AGS_SCALE_BUTTON_1_PRESSED

   

enum AgsScaleKeyMask

Members

AGS_SCALE_KEY_L_CONTROL

   

AGS_SCALE_KEY_R_CONTROL

   

AGS_SCALE_KEY_L_SHIFT

   

AGS_SCALE_KEY_R_SHIFT

   

enum AgsScaleLayout

Members

AGS_SCALE_LAYOUT_VERTICAL

   

AGS_SCALE_LAYOUT_HORIZONTAL

   

enum AgsScaleAction

Members

AGS_SCALE_STEP_UP

   

AGS_SCALE_STEP_DOWN

   

AGS_SCALE_PAGE_UP

   

AGS_SCALE_PAGE_DOWN

   

Property Details

The “control-name” property

  “control-name”             char *

The scale's control name.

Owner: AgsScale

Flags: Read / Write

Default value: NULL

Since: 3.0.0


The “default-value” property

  “default-value”            double

The scale's default value.

Owner: AgsScale

Flags: Read / Write

Default value: 0

Since: 3.0.0


The “lower” property

  “lower”                    double

The scale's lower range.

Owner: AgsScale

Flags: Read / Write

Default value: 0

Since: 3.0.0


The “upper” property

  “upper”                    double

The scale's upper range.

Owner: AgsScale

Flags: Read / Write

Default value: 1

Since: 3.0.0

Signal Details

The “value-changed” signal

void
user_function (AgsScale *scale,
               double    default_value,
               gpointer  user_data)

The ::value-changed signal notifies about modified default value.

Parameters

scale

the AgsScale

 

default_value

the changed default value

 

user_data

user data set when the signal handler was connected.

 

Flags: Run Last

Since: 3.0.0