summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gtk2_ardour/icons/faderport-small.pngbin0 -> 40549 bytes
-rw-r--r--libs/surfaces/faderport/gui.cc15
-rw-r--r--libs/surfaces/faderport/gui.h3
3 files changed, 17 insertions, 1 deletions
diff --git a/gtk2_ardour/icons/faderport-small.png b/gtk2_ardour/icons/faderport-small.png
new file mode 100644
index 0000000000..cc69d11fd2
--- /dev/null
+++ b/gtk2_ardour/icons/faderport-small.png
Binary files differ
diff --git a/libs/surfaces/faderport/gui.cc b/libs/surfaces/faderport/gui.cc
index 9862cd4571..4014d0a8e3 100644
--- a/libs/surfaces/faderport/gui.cc
+++ b/libs/surfaces/faderport/gui.cc
@@ -23,6 +23,7 @@
#include "pbd/unwind.h"
#include "pbd/strsplit.h"
+#include "pbd/file_utils.h"
#include "gtkmm2ext/actions.h"
#include "gtkmm2ext/gtk_ui.h"
@@ -30,6 +31,7 @@
#include "gtkmm2ext/utils.h"
#include "ardour/audioengine.h"
+#include "ardour/filesystem_paths.h"
#include "faderport.h"
#include "gui.h"
@@ -88,6 +90,16 @@ FPGUI::FPGUI (FaderPort& p)
table.set_border_width (12);
table.set_homogeneous (false);
+ std::string data_file_path;
+ string name = "faderport-small.png";
+ Searchpath spath(ARDOUR::ardour_data_search_path());
+ spath.add_subdirectory_to_paths ("icons");
+ find_file (spath, name, data_file_path);
+ if (!data_file_path.empty()) {
+ image.set (data_file_path);
+ hpacker.pack_start (image, false, false);
+ }
+
Gtk::Label* l;
Gtk::Alignment* align;
int row = 0;
@@ -216,7 +228,8 @@ FPGUI::FPGUI (FaderPort& p)
table.attach (action_table, 0, 5, row, row+1, AttachOptions(FILL|EXPAND), AttachOptions (0));
row++;
- pack_start (table, false, false);
+ hpacker.pack_start (table, true, true);
+ pack_start (hpacker, false, false);
/* update the port connection combos */
diff --git a/libs/surfaces/faderport/gui.h b/libs/surfaces/faderport/gui.h
index a3e02141c8..62580ded6f 100644
--- a/libs/surfaces/faderport/gui.h
+++ b/libs/surfaces/faderport/gui.h
@@ -25,6 +25,7 @@
#include <gtkmm/box.h>
#include <gtkmm/combobox.h>
+#include <gtkmm/image.h>
#include <gtkmm/table.h>
#include <gtkmm/treestore.h>
@@ -45,10 +46,12 @@ public:
private:
FaderPort& fp;
+ Gtk::HBox hpacker;
Gtk::Table table;
Gtk::Table action_table;
Gtk::ComboBox input_combo;
Gtk::ComboBox output_combo;
+ Gtk::Image image;
/* the mix, proj, trns and user buttons have no obvious semantics for
* ardour, mixbus etc., so we allow the user to define their