Inkscape
Vector Graphics Editor
Loading...
Searching...
No Matches
pointlight.h
Go to the documentation of this file.
1// SPDX-License-Identifier: GPL-2.0-or-later
5#ifndef SP_FEPOINTLIGHT_H_SEEN
6#define SP_FEPOINTLIGHT_H_SEEN
7
8/*
9 * Authors:
10 * Hugo Rodrigues <haa.rodrigues@gmail.com>
11 * Niko Kiirala <niko@kiirala.com>
12 * Jean-Rene Reinhard <jr@komite.net>
13 *
14 * Copyright (C) 2006,2007 Authors
15 *
16 * Released under GNU GPL v2+, read the file 'COPYING' for more information.
17 */
18
19#include "object/sp-object.h"
20
21class SPFePointLight final
22 : public SPObject
23{
24public:
26 ~SPFePointLight() override;
27 int tag() const override { return tag_of<decltype(*this)>; }
28
30 float x;
31 bool x_set : 1;
33 float y;
34 bool y_set : 1;
36 float z;
37 bool z_set : 1;
38
39protected:
40 void build(SPDocument *doc, Inkscape::XML::Node *repr) override;
41 void release() override;
42 void set(SPAttr key, char const *value) override;
44};
45
46#endif // SP_FEPOINTLIGHT_H_SEEN
47
48/*
49 Local Variables:
50 mode:c++
51 c-file-style:"stroustrup"
52 c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
53 indent-tabs-mode:nil
54 fill-column:99
55 End:
56*/
57// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :
SPAttr
Definition attributes.h:27
constexpr int tag_of
Convenience function to retrieve the tag (class id) of a given type.
Definition cast.h:26
Interface for refcounted XML nodes.
Definition node.h:80
Typed SVG document implementation.
Definition document.h:101
float z
z coordinate of the light source
Definition pointlight.h:36
float x
x coordinate of the light source
Definition pointlight.h:30
float y
y coordinate of the light source
Definition pointlight.h:33
~SPFePointLight() override
int tag() const override
Definition pointlight.h:27
void release() override
Inkscape::XML::Node * write(Inkscape::XML::Document *doc, Inkscape::XML::Node *repr, unsigned flags) override
void build(SPDocument *doc, Inkscape::XML::Node *repr) override
SPObject is an abstract base class of all of the document nodes at the SVG document level.
Definition sp-object.h:160
Inkscape::XML::Node * repr
Definition sp-object.h:193
static cairo_user_data_key_t key
Interface for XML documents.
Definition document.h:43