Ardour  9.0-rc2-184-gc50547f0a6
ardour_color_dialog.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2017 Robin Gareus <robin@gareus.org>
3  * Copyright (C) 2026 Paul Davis <paul@linuxaudiosystems.com>
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License along
16  * with this program; if not, write to the Free Software Foundation, Inc.,
17  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18  */
19 
20 #pragma once
21 
22 #include <memory>
23 
24 #include <ytkmm/colorbutton.h>
25 #include <ytkmm/colorselection.h>
26 
28 
29 namespace ARDOUR {
30  class Stripable;
31 }
32 
34 {
35  public:
37 
38  void popup (const std::string& name, uint32_t color, Gtk::Window* parent);
40  virtual void color_changed() {}
41 
42  protected:
44 
45  private:
47 
48  static bool palette_initialized;
49  static void palette_changed_hook (const Glib::RefPtr<Gdk::Screen>&, const Gdk::ArrayHandle_Color&);
51 };
52 
54 {
55 public:
57 
58 protected:
59  void on_clicked();
60  void color_selected ();
61  void finish (int response);
62 
63 private:
65 };
void on_clicked()
This is a default handler for the signal signal_clicked().
void finish(int response)
ArdourColorDialog _color_picker
static Gtk::ColorSelection::SlotChangePaletteHook gtk_palette_changed_hook
static bool palette_initialized
static void palette_changed_hook(const Glib::RefPtr< Gdk::Screen > &, const Gdk::ArrayHandle_Color &)
ARDOUR::PresentationInfo::color_t initial_color() const
ARDOUR::PresentationInfo::color_t _initial_color
void popup(const std::string &name, uint32_t color, Gtk::Window *parent)
void initialize_color_palette()
virtual void color_changed()
sigc::slot< void, const Glib::RefPtr< Gdk::Screen > &, const Gdk::ArrayHandle_Color & > SlotChangePaletteHook
GtkImageIconNameData name
Definition: gtkimage.h:6
PBD::PropertyDescriptor< uint32_t > color
Glib::ArrayHandle< Color, ColorTraits > ArrayHandle_Color
Definition: color.h:242