# widget_coloredit.cpp File Reference

Template File. More...

`#include "widget_coloredit.h"`
`#include <cmath>`
`#include "app.h"`
`#include <gtkmm/drawingarea.h>`
`#include <pangomm/attributes.h>`
`#include <pangomm/attrlist.h>`
`#include <algorithm>`
`#include <gtkmm/notebook.h>`
`#include <gtkmm/box.h>`
`#include "general.h"`

## Defines

#define | SPINBUTTON_WIDTH 100
#define | SLIDER_ROW(i, n, l)
#define | ATTACH_SPIN_BUTTON(i, n)

## Detailed Description

Template File.

$Id$

## Define Documentation

#define SPINBUTTON_WIDTH 100

Referenced by studio::Widget_ColorEdit::set_digits(), and studio::Widget_ColorEdit::set_has_frame().

#define SLIDER_ROW | ( | i,
|  | n,
|  | l |  | ) |

Value:

    slider_##n=manage(new ColorSlider(ColorSlider::TYPE_##n));  \
        slider_##n->signal_slider_moved().connect(sigc::mem_fun(*this,&studio::Widget_ColorEdit::on_slider_moved)); \
        /*slider_##n->signal_activated().connect(sigc::mem_fun(*this,&studio::Widget_ColorEdit::activated));*/ \
        slider_##n->signal_activated().connect(sigc::mem_fun(*this,&studio::Widget_ColorEdit::on_value_changed)); \
        label=manage(new class Gtk::Label(l,0.0,0.5)); \
        label->set_use_markup(false); \
        label->set_use_underline(false); \
        label->set_attributes(attr_list); \
        table->attach(*label, 0, 1, 1+2*i, 2+2*i, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0);  \
        table->attach(*slider_##n, 0, 1, 2+2*i, 3+2*i, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0)

Referenced by studio::Widget_ColorEdit::Widget_ColorEdit().

#define ATTACH_SPIN_BUTTON | ( | i,
|  | n |  | ) |

Value:

    spinbutton_##n=manage(new class Gtk::SpinButton(n##_adjustment,1,0)); \
        spinbutton_##n->set_update_policy(Gtk::UPDATE_ALWAYS); \
        spinbutton_##n->set_size_request(SPINBUTTON_WIDTH,-1); \
        spinbutton_##n->show(); \
        table->attach(*spinbutton_##n, 1, 2, 1+2*i, 3+2*i, Gtk::SHRINK, Gtk::EXPAND, 2, 0)

Referenced by studio::Widget_ColorEdit::Widget_ColorEdit().