gradient-selector.cpp revision 06647770089c65d52a60a84f7d143ef0ac523f1e
/*
* Gradient vector widget
*
* Authors:
* Lauris Kaplinski <lauris@kaplinski.com>
* bulia byak <buliabyak@users.sf.net>
* Jon A. Cruz <jon@joncruz.org>
*
* Copyright (C) 2001-2002 Lauris Kaplinski
* Copyright (C) 2001 Ximian, Inc.
* Copyright (C) 2010 Jon A. Cruz
*
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include "document.h"
#include "../document-private.h"
#include "../gradient-chemistry.h"
#include "gradient-vector.h"
#include "gradient-selector.h"
enum {
};
/* Signal handlers */
static void sp_gradient_selector_vector_set (SPGradientVectorSelector *gvs, SPGradient *gr, SPGradientSelector *sel);
static GtkVBoxClass *parent_class;
{
if (!type) {
sizeof(SPGradientSelectorClass),
NULL, /* base_init */
NULL, /* base_finalize */
NULL, /* class_finalize */
NULL, /* class_data */
sizeof(SPGradientSelector),
0, /* n_preallocs */
0, /* value_table */
};
"SPGradientSelector",
&info,
static_cast< GTypeFlags > (0) );
}
return type;
}
static void
{
G_TYPE_NONE, 0);
G_TYPE_NONE, 0);
G_TYPE_NONE, 0);
G_TYPE_NONE, 0);
}
{
sel->safelyInit = true;
/* Vectors */
g_signal_connect (G_OBJECT (sel->vectors), "vector_set", G_CALLBACK (sp_gradient_selector_vector_set), sel);
/* Create box for buttons */
g_signal_connect (G_OBJECT (sel->add), "clicked", G_CALLBACK (sp_gradient_selector_add_vector_clicked), sel);
g_signal_connect (G_OBJECT (sel->edit), "clicked", G_CALLBACK (sp_gradient_selector_edit_vector_clicked), sel);
/* Spread selector */
// The GtkComboBoxText API only appeared in Gtk 2.24 but Inkscape supports
// builds for Gtk >= 2.20.
// Older versions need to use now-deprecated parts of
// the GtkComboBox API instead.
#else
#endif
// TRANSLATORS: for info, see http://www.w3.org/TR/2000/CR-SVG-20000802/pservers.html#LinearGradientSpreadMethodAttribute
_("Whether to fill with flat color beyond the ends of the gradient vector "
"(spreadMethod=\"pad\"), or repeat the gradient in the same direction "
"(spreadMethod=\"repeat\"), or repeat the gradient in alternating opposite "
"directions (spreadMethod=\"reflect\")"));
}
{
if ( sel->safelyInit ) {
sel->safelyInit = false;
}
}
}
sp_gradient_selector_new (void)
{
}
{
if (mode == MODE_SWATCH) {
{
}
vs->setSwatched();
}
}
}
{
}
{
}
{
return gradientUnits;
}
{
return gradientSpread;
}
{
return;
}
if (vector) {
{
}
} else {
{
}
}
}
if (edit) {
}
if (add) {
}
} else {
if (edit) {
}
if (add) {
}
}
}
{
/* fixme: */
}
static void
sp_gradient_selector_vector_set (SPGradientVectorSelector */*gvs*/, SPGradient *gr, SPGradientSelector *sel)
{
if (!blocked) {
}
}
static void
{
/* fixme: */
}
static void
{
if (!doc)
return;
if (gr) {
} else {
}
}
static void
{
}
/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :