Fly my pretties!
[ardour.git] / gtk2_ardour / tempo_dialog.h
1 #ifndef __ardour_gtk_tempo_dialog_h__
2 #define __ardour_gtk_tempo_dialog_h__
3
4 #include <gtkmm.h>
5 #include <ardour/types.h>
6 #include <ardour/tempo.h>
7
8 #include "ardour_dialog.h"
9
10 struct TempoDialog : public ArdourDialog 
11 {
12     Gtk::Entry   bpm_entry;
13     Gtk::Frame   bpm_frame;
14     Gtk::VBox    vpacker;
15     Gtk::Button  ok_button;
16     Gtk::Button  cancel_button;
17     Gtk::HBox    button_box;
18     Gtk::HBox    hspacer1;
19     Gtk::VBox    vspacer1;
20     Gtk::Entry   when_bar_entry;
21     Gtk::Entry   when_beat_entry;
22     Gtk::Label   when_bar_label;
23     Gtk::Label   when_beat_label;
24     Gtk::Table   when_table;
25     Gtk::Frame   when_frame;
26     char buf[64];
27     
28     TempoDialog (ARDOUR::TempoMap&, jack_nframes_t, string action);
29     TempoDialog (ARDOUR::TempoSection&, string action);
30
31     double get_bpm ();
32     bool   get_bbt_time (ARDOUR::BBT_Time&);
33     
34   private:
35     void init (const ARDOUR::BBT_Time& start, double, bool);
36 };
37
38 struct MeterDialog : public ArdourDialog 
39 {
40     Gtk::Entry   bpb_entry;
41     Gtk::Combo   note_types;
42     vector<const gchar *> strings;
43     Gtk::Frame   note_frame;
44     Gtk::Frame   bpb_frame;
45     Gtk::VBox    vpacker;
46     Gtk::Button  ok_button;
47     Gtk::Button  cancel_button;
48     Gtk::HBox    button_box;
49     Gtk::HBox    hspacer1, hspacer2;
50     Gtk::VBox    vspacer1, vspacer2;
51     Gtk::Entry   when_bar_entry;
52     Gtk::Entry   when_beat_entry;
53     Gtk::Label   when_bar_label;
54     Gtk::Label   when_beat_label;
55     Gtk::Table   when_table;
56     Gtk::Frame   when_frame;
57     char buf[64];
58     
59     MeterDialog (ARDOUR::TempoMap&, jack_nframes_t, string action);
60     MeterDialog (ARDOUR::MeterSection&, string action);
61
62     double get_bpb ();
63     double get_note_type ();
64     bool   get_bbt_time (ARDOUR::BBT_Time&);
65
66   private:
67     void init (const ARDOUR::BBT_Time&, double, double, bool);
68 };
69
70 #endif /* __ardour_gtk_tempo_dialog_h__ */