AgsNavigation

AgsNavigation — control audio object's playback.

Synopsis

#include <ags/X/ags_navigation.h>

#define             AGS_NAVIGATION_DEFAULT_TACT_STEP
#define             AGS_NAVIGATION_REWIND_STEPS
#define             AGS_NAVIGATION_SEEK_STEPS
struct              AgsNavigation;
struct              AgsNavigationClass;
enum                AgsNavigationFlags;
void                ags_navigation_change_position      (AgsNavigation *navigation,
                                                         gdouble tact);
AgsNavigation *     ags_navigation_new                  ();
void                ags_navigation_set_seeking_sensitive
                                                        (AgsNavigation *navigation,
                                                         gboolean enabled);
gchar *             ags_navigation_tact_to_time_string  (gdouble tact);
void                ags_navigation_update_time_string   (double tact,
                                                         gchar *time_string);

Description

AgsNavigation is a composite widget to control playback of AgsAudio objects. It can start AgsMachine in bulk mode or position the stream.

Details

AGS_NAVIGATION_DEFAULT_TACT_STEP

#define AGS_NAVIGATION_DEFAULT_TACT_STEP (1.0)

AGS_NAVIGATION_REWIND_STEPS

#define AGS_NAVIGATION_REWIND_STEPS (4.0)

AGS_NAVIGATION_SEEK_STEPS

#define AGS_NAVIGATION_SEEK_STEPS (1.0)

struct AgsNavigation

struct AgsNavigation {
  GtkVBox vbox;

  guint flags;

  AgsDevout *devout;

  GtkToggleButton *expander;

  GtkSpinButton *bpm;
  gdouble current_bpm;

  GtkToggleButton *rewind;
  GtkButton *previous;
  GtkToggleButton *play;
  GtkButton *stop;
  GtkButton *next;
  GtkToggleButton *forward;

  GtkCheckButton *loop;

  GtkLabel *position_time;
  GtkSpinButton *position_tact;

  GtkLabel *duration_time;
  GtkSpinButton *duration_tact;

  GtkSpinButton *loop_left_tact;
  GtkSpinButton *loop_right_tact;

  GtkCheckButton *scroll;
};

struct AgsNavigationClass

struct AgsNavigationClass {
  GtkVBoxClass vbox;

  void (*change_position)(AgsNavigation *navigation,
			  gdouble tact);
};

enum AgsNavigationFlags

typedef enum {
  AGS_NAVIGATION_BLOCK_TACT   = 1,
  AGS_NAVIGATION_BLOCK_PLAY   = 1 << 1,
  AGS_NAVIGATION_BLOCK_TIC    = 1 << 2,
} AgsNavigationFlags;

ags_navigation_change_position ()

void                ags_navigation_change_position      (AgsNavigation *navigation,
                                                         gdouble tact);

Change tact position of editor. The scrollbar is adjustet and its playback position seeked.

navigation :

the AgsNavigation

tact :

the new position

Since 0.4


ags_navigation_new ()

AgsNavigation *     ags_navigation_new                  ();

Creates an AgsNavigation to control the tree.

Returns :

a new AgsNavigation

Since 0.4


ags_navigation_set_seeking_sensitive ()

void                ags_navigation_set_seeking_sensitive
                                                        (AgsNavigation *navigation,
                                                         gboolean enabled);

ags_navigation_tact_to_time_string ()

gchar *             ags_navigation_tact_to_time_string  (gdouble tact);

Convert tact unit to time.

tact :

the new position

Returns :

tact as time string

Since 0.4


ags_navigation_update_time_string ()

void                ags_navigation_update_time_string   (double tact,
                                                         gchar *time_string);

Updates time as string.

tact :

the new position

time_str :

the pointer location to set

Since 0.4