LibreOffice Module drawinglayer (master) 1
fillhatchprimitive2d.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice 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 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#pragma once
21
26
27
28// FillHatchPrimitive2D class
29
31{
47 {
48 private:
51
55
58
61
63 virtual void create2DDecomposition(Primitive2DContainer& rContainer, const geometry::ViewInformation2D& rViewInformation) const override;
64
65 public:
68 const basegfx::B2DRange& rOutputRange,
69 const basegfx::BColor& rBColor,
72 const basegfx::B2DRange& rOutputRange,
73 const basegfx::B2DRange& rDefinitionRange,
74 const basegfx::BColor& rBColor,
76
81 const basegfx::BColor& getBColor() const { return maBColor; }
82
84 virtual bool operator==(const BasePrimitive2D& rPrimitive) const override;
85
87 virtual basegfx::B2DRange getB2DRange(const geometry::ViewInformation2D& rViewInformation) const override;
88
90 virtual void get2DDecomposition(Primitive2DDecompositionVisitor& rVisitor, const geometry::ViewInformation2D& rViewInformation) const override;
91
93 virtual sal_uInt32 getPrimitive2DID() const override;
94 };
95} // end of namespace drawinglayer::primitive2d
96
97/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
basegfx::BColor maBColor
hatch background color (if used)
basegfx::B2DRange maDefinitionRange
the area the gradient definition is based on in the simplest case identical to OutputRange
virtual basegfx::B2DRange getB2DRange(const geometry::ViewInformation2D &rViewInformation) const override
get range
virtual void create2DDecomposition(Primitive2DContainer &rContainer, const geometry::ViewInformation2D &rViewInformation) const override
local decomposition.
const basegfx::B2DRange & getOutputRange() const
data read access
FillHatchPrimitive2D(const basegfx::B2DRange &rOutputRange, const basegfx::BColor &rBColor, attribute::FillHatchAttribute aFillHatch)
constructors. The one without definition range will use output range as definition range
virtual bool operator==(const BasePrimitive2D &rPrimitive) const override
compare operator
attribute::FillHatchAttribute maFillHatch
the hatch definition
basegfx::B2DRange maOutputRange
the geometrically visible area
const attribute::FillHatchAttribute & getFillHatch() const
const basegfx::B2DRange & getDefinitionRange() const
virtual sal_uInt32 getPrimitive2DID() const override
provide unique ID
virtual void get2DDecomposition(Primitive2DDecompositionVisitor &rVisitor, const geometry::ViewInformation2D &rViewInformation) const override
Override standard getDecomposition to be view-dependent here.