summaryrefslogtreecommitdiffstats
path: root/src/ui/widget
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/widget')
-rw-r--r--src/ui/widget/button.cpp16
-rw-r--r--src/ui/widget/button.h14
-rw-r--r--src/ui/widget/entry.cpp1
-rw-r--r--src/ui/widget/entry.h2
4 files changed, 32 insertions, 1 deletions
diff --git a/src/ui/widget/button.cpp b/src/ui/widget/button.cpp
index 1ba531ddf..bac866920 100644
--- a/src/ui/widget/button.cpp
+++ b/src/ui/widget/button.cpp
@@ -31,6 +31,22 @@ CheckButton::CheckButton(Glib::ustring const &label, Glib::ustring const &toolti
set_tooltip_text(tooltip);
}
+CheckButton::CheckButton(Glib::ustring const &label, Glib::ustring const &tooltip, bool active)
+{
+ set_use_underline (true);
+ set_label (label);
+ set_tooltip_text(tooltip);
+ set_active(active);
+}
+
+RadioButton::RadioButton(Glib::ustring const &label, Glib::ustring const &tooltip)
+{
+ set_use_underline (true);
+ set_label (label);
+ set_tooltip_text(tooltip);
+}
+
+
} // namespace Widget
} // namespace UI
} // namespace Inkscape
diff --git a/src/ui/widget/button.h b/src/ui/widget/button.h
index 362cdf8ff..b219fc3db 100644
--- a/src/ui/widget/button.h
+++ b/src/ui/widget/button.h
@@ -11,6 +11,7 @@
#define INKSCAPE_UI_WIDGET_BUTTON_H
#include <gtkmm/checkbutton.h>
+#include <gtkmm/radiobutton.h>
namespace Inkscape {
namespace UI {
@@ -34,6 +35,19 @@ class CheckButton : public Gtk::CheckButton
public:
CheckButton();
CheckButton(Glib::ustring const &label, Glib::ustring const &tooltip);
+ CheckButton(Glib::ustring const &label, Glib::ustring const &tooltip, bool active);
+
+};
+
+/**
+ * RadioButton widget.
+ */
+class RadioButton : public Gtk::RadioButton
+{
+public:
+ RadioButton();
+ RadioButton(Glib::ustring const &label, Glib::ustring const &tooltip);
+
};
} // namespace Widget
diff --git a/src/ui/widget/entry.cpp b/src/ui/widget/entry.cpp
index 7ac8532fb..173e014d9 100644
--- a/src/ui/widget/entry.cpp
+++ b/src/ui/widget/entry.cpp
@@ -24,7 +24,6 @@ Entry::Entry( Glib::ustring const &label, Glib::ustring const &tooltip,
: Labelled(label, tooltip, new Gtk::Entry(), suffix, icon, mnemonic)
{
}
-
} // namespace Widget
} // namespace UI
diff --git a/src/ui/widget/entry.h b/src/ui/widget/entry.h
index d332dde1b..53b848fc9 100644
--- a/src/ui/widget/entry.h
+++ b/src/ui/widget/entry.h
@@ -11,8 +11,10 @@
#define INKSCAPE_UI_WIDGET_ENTRY__H
#include "labelled.h"
+#include <gtkmm.h>
#include <gtkmm/entry.h>
+#include <gtkmm/comboboxtext.h>
namespace Inkscape {
namespace UI {