IWORKColorElement.h Source File documentation

IWORKColorElement.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /*
3 * This file is part of the libetonyek project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
9
10 #ifndef IWORKCOLORELEMENT_H_INCLUDED
11 #define IWORKCOLORELEMENT_H_INCLUDED
12
13 #include <boost/optional.hpp>
14
15 #include "IWORKTypes.h"
16 #include "IWORKXMLContextBase.h"
17
18 namespace libetonyek
19 {
20
21 class IWORKColorElement : public IWORKXMLEmptyContextBase
22 {
23 public:
24 IWORKColorElement(IWORKXMLParserState &state, boost::optional<IWORKColor> &color);
25
26 protected:
27 virtual void attribute(int name, const char *value);
28 virtual void endOfElement();
29
30 private:
31 boost::optional<IWORKColor> &m_color;
32 double m_r;
33 double m_g;
34 double m_b;
35 double m_a;
36 };
37
38 }
39
40 #endif // IWORKCOLORELEMENT_H_INCLUDED
41
42 /* vim:set shiftwidth=2 softtabstop=2 expandtab: */
libetonyek
Definition: IWORKBezierElement.cpp:18
libetonyek::IWORKColorElement::m_a
double m_a
Definition: IWORKColorElement.h:35
IWORKXMLContextBase.h
libetonyek::IWORKColorElement::endOfElement
virtual void endOfElement()
Definition: IWORKColorElement.cpp:61
libetonyek::IWORKColorElement
Definition: IWORKColorElement.h:21
libetonyek::IWORKColorElement::attribute
virtual void attribute(int name, const char *value)
Definition: IWORKColorElement.cpp:34
libetonyek::IWORKColorElement::IWORKColorElement
IWORKColorElement(IWORKXMLParserState &state, boost::optional< IWORKColor > &color)
Definition: IWORKColorElement.cpp:24
libetonyek::IWORKToken::color
Definition: IWORKToken.h:79
name
const char * name
Definition: IWORKToken.cpp:43
libetonyek::IWORKColorElement::m_r
double m_r
Definition: IWORKColorElement.h:32
libetonyek::IWORKXMLContextBase
Definition: IWORKXMLContextBase.h:27
libetonyek::IWORKXMLParserState
Definition: IWORKXMLParserState.h:30
libetonyek::IWORKColorElement::m_b
double m_b
Definition: IWORKColorElement.h:34
IWORKTypes.h
libetonyek::IWORKColorElement::m_color
boost::optional< IWORKColor > & m_color
Definition: IWORKColorElement.h:31
libetonyek::IWORKColorElement::m_g
double m_g
Definition: IWORKColorElement.h:33