## GtkVUMeter

GtkVUMeter — vu meter widget

## Synopsis

    #include "bt-edit.h"

    struct              GtkVUMeter;
    GtkWidget *         gtk_vumeter_new                     (gboolean vertical);
    void                gtk_vumeter_set_min_max             (GtkVUMeter *vumeter,
                                                             gint min,
                                                             gint max);
    void                gtk_vumeter_set_levels              (GtkVUMeter *vumeter,
                                                             gint rms,
                                                             gint peak);
    void                gtk_vumeter_set_scale               (GtkVUMeter *vumeter,
                                                             gint scale);

## Object Hierarchy

      GObject
       +----GInitiallyUnowned
             +----GtkObject
                   +----GtkWidget
                         +----GtkVUMeter

## Implemented Interfaces

GtkVUMeter implements AtkImplementorIface and GtkBuildable.

## Description

Shows a vertical or horizontal gauge with a colorized bar to signal volume level.

## Details

### struct GtkVUMeter

    struct GtkVUMeter;

a volume meter widget

### gtk_vumeter_new ()

    GtkWidget *         gtk_vumeter_new                     (gboolean vertical);

Creates a new VUMeter widget.

`vertical` : | `TRUE` for a vertical VUMeter, `FALSE` for horizontal VUMeter.
Returns : | the new GtkWidget

### gtk_vumeter_set_min_max ()

    void                gtk_vumeter_set_min_max             (GtkVUMeter *vumeter,
                                                             gint min,
                                                             gint max);

Sets the minimum and maximum of the VU Meters scale. The positions are irrelevant as the widget will rearrange them. It will also increment max by one if min == max. And finally it will clamp the current level into the min,max range.

`vumeter` : | the vumeter widget to change the level bounds
`min` : | the new minimum level shown (level that is 0%)
`max` : | the new maximum level shown (level that is 100%)

### gtk_vumeter_set_levels ()

    void                gtk_vumeter_set_levels              (GtkVUMeter *vumeter,
                                                             gint rms,
                                                             gint peak);

Sets new level values for the level display. They are clamped to the min max range.

`vumeter` : | the vumeter widget to change the current level
`rms` : | the new rms level shown
`peak` : | the new peak level shown

### gtk_vumeter_set_scale ()

    void                gtk_vumeter_set_scale               (GtkVUMeter *vumeter,
                                                             gint scale);

Sets the scale of the VU Meter. It is either log or linear and defaults to linear. No matter which scale you set the input should always be linear, GtkVUMeter does the log calculation. 0db is red. -6db is yellow. -18db is green. Whatever min turns into is dark green.

`vumeter` : | the vumeter widget to change the scaling type
`scale` : | the scale type, either GTK_VUMETER_SCALE_LINEAR or GTK_VUMETER_SCALE_LOG