nr-style.cpp revision 2a233c0f7e1ddd1c973ff5fb1f4225d7fe48da43
/**
* @file
* Style information for rendering.
*//*
* Authors:
* Krzysztof KosiĆski <tweenk.pl@gmail.com>
*
* Copyright (C) 2010 Authors
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#include "display/nr-style.h"
#include "style.h"
#include "sp-paint-server.h"
#include "display/canvas-bpath.h" // contains SPStrokeJoinType, SPStrokeCapType etc. (WTF!)
#include "display/drawing-context.h"
{
if (server) {
}
type = PAINT_NONE;
}
{
clear();
type = PAINT_COLOR;
color = c;
}
{
clear();
if (ps) {
type = PAINT_SERVER;
}
}
: fill()
, stroke()
, stroke_width(0.0)
, miter_limit(0.0)
, n_dash(0)
, dash_offset(0.0)
, fill_pattern(NULL)
{}
{
if (dash){
delete [] dash;
}
}
{
} else {
}
case SP_WIND_RULE_EVENODD:
break;
case SP_WIND_RULE_NONZERO:
break;
default:
}
} else {
}
case SP_STROKE_LINECAP_ROUND:
break;
case SP_STROKE_LINECAP_SQUARE:
break;
case SP_STROKE_LINECAP_BUTT:
break;
default:
}
case SP_STROKE_LINEJOIN_ROUND:
break;
case SP_STROKE_LINEJOIN_BEVEL:
break;
case SP_STROKE_LINEJOIN_MITER:
break;
default:
}
if (dash){
delete [] dash;
}
if (n_dash != 0) {
for (unsigned int i = 0; i < n_dash; ++i) {
}
} else {
dash_offset = 0.0;
}
update();
}
{
// update fill pattern
if (!fill_pattern) {
case PAINT_SERVER: {
} break;
case PAINT_COLOR: {
} break;
default: break;
}
}
if (!fill_pattern) return false;
return true;
}
{
}
{
if (!stroke_pattern) {
case PAINT_SERVER: {
} break;
case PAINT_COLOR: {
} break;
default: break;
}
}
if (!stroke_pattern) return false;
return true;
}
{
}
{
// force pattern update
fill_pattern = NULL;
}
/*
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:fileencoding=utf-8:textwidth=99 :