sp-paint-server.cpp revision ea4c3217d91f40557abd8519207aea1ad5ff1e68
/*
* Base class for gradients and patterns
*
* Author:
* Lauris Kaplinski <lauris@kaplinski.com>
* Jon A. Cruz <jon@joncruz.org>
*
* Copyright (C) 1999-2002 Lauris Kaplinski
* Copyright (C) 2000-2001 Ximian, Inc.
* Copyright (C) 2000-2001 Ximian, Inc.
* Copyright (C) 2010 Authors
*
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#include <string.h>
#include "libnr/nr-pixblock-pattern.h"
#include "sp-paint-server.h"
#include "sp-gradient.h"
static SPObjectClass *parent_class;
GType sp_paint_server_get_type (void)
{
if (!type) {
sizeof(SPPaintServerClass),
NULL, /* base_init */
NULL, /* base_finalize */
NULL, /* class_finalize */
NULL, /* class_data */
sizeof(SPPaintServer),
16, /* n_preallocs */
NULL, /* value_table */
};
}
return type;
}
{
}
{
}
{
}
}
}
{
if ( psc->painter_new ) {
}
if (painter) {
}
return painter;
}
{
if (p == painter) {
if (r) {
} else {
}
if (psc->painter_free) {
}
return;
}
r = p;
}
}
{
} else {
if (psc->painter_free)
}
return NULL;
}
{
}
bool SPPaintServer::isSwatch() const
{
// Temporary for now. Later expand to more
return isSolid();
}
bool SPPaintServer::isSolid() const
{
bool solid = false;
if (SP_IS_GRADIENT(this)) {
solid = true;
}
}
}
return solid;
}
/*
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 :