1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
19 #ifndef __com_sun_star_rendering_StrokeAttributes_idl__
20 #define __com_sun_star_rendering_StrokeAttributes_idl__
22 module com
{ module sun
{ module star
{ module rendering
{
24 /** This structure contains all attributes required for path stroking.<p>
26 Path stroking is the process of drawing a polygon with a thick
27 pen. The various attributes contained in this structure can be
28 used to customize that process.<p>
30 struct StrokeAttributes
32 /** Defines the width of the stroke, measured in user
35 This value must be positive (or 0.0)
40 /** Determines the maximal length of the diagonal in mitered
43 This attribute is only used when
44 StrokeAttributes::JoinType is set to
45 PathJoinType::MITER. Should the length of a
46 corner's diagonal exceed this limit, a beveled join is used
47 instead. This value must be positive (or 0.0, which is
49 StrokeAttributes::JoinType to
50 PathJoinType::BEVEL.<p>
52 Before performing the actual comparison, implementations will
53 multiply the MiterLimit with the current StrokeWidth, such
54 that, with phi being the angle between the two joining
55 segments, MiterLimit=1/sin(phi/2.0).<p>
60 /** Array of ink on and off lengths, measured in user coordinate
63 The first element specifies the length of the first "on"
64 segment of the dashing, the second element the length of the
65 first "off" segment, and so forth. Give zero elements here for
66 solid strokes. This array always have an even number of
67 elements, with zero, as usual, counting as even
68 here. Furthermore, each entry in this array must have a value
69 that is positive (or 0.0)<p>
71 sequence
<double> DashArray
;
74 /** Array of line widths and spacings for multiple-line
77 The entries here are relative to the
78 StrokeAttributes::StrokeWidth attribute
79 above, i.e. the total width of all lines and spacings will
81 StrokeAttributes::StrokeWidth. The first
82 element specifies the width of the rightmost line, when
83 traveling from the start point of the path to the end
84 point. The second element specifies the space between the
85 first line and the second line, and so forth. If the array
86 ends with a spacing, this spacing is included in the total
87 width of the multiple-line stroke. That is, the stroke becomes
90 sequence
<double> LineArray
;
93 /** The start shape of the stroke.<p>
95 The start point is the first point of every polygon of the
103 /** The end shape of the stroke.<p>
105 The end point is the last point of every polygon of the path
113 /** The join shape of the stroke.<p>
115 After every sub-stroke, i.e. after every line or curve segment
116 within a single path polygon, a shape of this type is inserted
117 into the stroke to glue the segments together. Please note
118 that distinct polygons within the path poly-polygon are not
119 connected, and therefore also not joined via the shape
132 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */