David Robillard
35fc31a1de
Update libraries to latest stable released version (except gnomecanvasmm, which is strangely packaged...). Fixes building (at least here). git-svn-id: svn://localhost/ardour2/trunk@2790 d708f5d6-7413-0410-9779-e7cbd77b26cf
81 lines
2.3 KiB
Plaintext
81 lines
2.3 KiB
Plaintext
/* $Id: curve.hg,v 1.1 2003/01/21 13:38:47 murrayc Exp $ */
|
|
|
|
/* curve.h
|
|
*
|
|
* Copyright (C) 1998-2002 The gtkmm Development Team
|
|
*
|
|
* This library is free software; you can redistribute it and/or
|
|
* modify it under the terms of the GNU Library General Public
|
|
* License as published by the Free Software Foundation; either
|
|
* version 2 of the License, or (at your option) any later version.
|
|
*
|
|
* This library is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
* Library General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Library General Public
|
|
* License along with this library; if not, write to the Free
|
|
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
|
*/
|
|
|
|
#include <glibmm/arrayhandle.h>
|
|
#include <gtkmm/box.h>
|
|
#include <gtkmm/drawingarea.h>
|
|
_DEFS(gtkmm,gtk)
|
|
_DEFS(gtkmm,gtk)
|
|
_DEFS(gtkmm,gtk)
|
|
_PINCLUDE(gtkmm/private/drawingarea_p.h)
|
|
_PINCLUDE(gtkmm/private/box_p.h)
|
|
|
|
namespace Gtk
|
|
{
|
|
|
|
/** Allows direct editing of a curve.
|
|
*
|
|
* @ingroup Widgets
|
|
*/
|
|
class Curve : public DrawingArea
|
|
{
|
|
_CLASS_GTKOBJECT(Curve,GtkCurve,GTK_CURVE,Gtk::DrawingArea,GtkDrawingArea)
|
|
_IGNORE(gtk_curve_set_vector)
|
|
public:
|
|
|
|
_CTOR_DEFAULT
|
|
|
|
|
|
_WRAP_METHOD(void reset(), gtk_curve_reset)
|
|
_WRAP_METHOD(void set_gamma(float gamma), gtk_curve_set_gamma)
|
|
_WRAP_METHOD(void set_range(float min_x, float max_x, float min_y, float max_y), gtk_curve_set_range)
|
|
_WRAP_METHOD(void get_vector(int veclen, float* data) const, gtk_curve_get_vector)
|
|
|
|
Glib::ArrayHandle<float> get_vector(int veclen) const;
|
|
void set_vector(const Glib::ArrayHandle<float>& array);
|
|
|
|
_WRAP_METHOD(void set_curve_type(CurveType type), gtk_curve_set_curve_type)
|
|
|
|
_WRAP_SIGNAL(void curve_type_changed(), "curve_type_changed")
|
|
|
|
_WRAP_PROPERTY("curve-type", CurveType)
|
|
_WRAP_PROPERTY("min-x", float)
|
|
_WRAP_PROPERTY("max-x", float)
|
|
_WRAP_PROPERTY("min-y", float)
|
|
_WRAP_PROPERTY("max-y", float)
|
|
};
|
|
|
|
/** A subclass of Gtk::Curve for editing gamma curves.
|
|
*
|
|
* @ingroup Widgets
|
|
*/
|
|
class GammaCurve : public VBox
|
|
{
|
|
_CLASS_GTKOBJECT(GammaCurve,GtkGammaCurve,GTK_GAMMA_CURVE,Gtk::VBox,GtkVBox)
|
|
public:
|
|
_CTOR_DEFAULT
|
|
|
|
|
|
};
|
|
|
|
} /* namespace Gtk */
|
|
|