Code

5e8b0e48e40e9a15daf176643d6548718ea64a91
[inkscape.git] / src / libnr / nr-path.h
1 #ifndef __NR_PATH_H__
2 #define __NR_PATH_H__
4 /*
5  * NArtBpath: Curve component.  Adapted from libart.
6  */
8 /*
9  * libart_lgpl/art_bpath.h copyright information:
10  *
11  * Copyright (C) 1998 Raph Levien
12  *
13  * This library is free software; you can redistribute it and/or
14  * modify it under the terms of the GNU Library General Public
15  * License as published by the Free Software Foundation; either
16  * version 2 of the License, or (at your option) any later version.
17  *
18  * This library is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
21  * Library General Public License for more details.
22  *
23  * You should have received a copy of the GNU Library General Public
24  * License along with this library; if not, write to the
25  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
26  * Boston, MA 02111-1307, USA.
27  */
30 #include <libnr/nr-forward.h>
31 #include <libnr/nr-coord.h>
33 NArtBpath* nr_artpath_affine(NArtBpath const *s, NR::Matrix const &transform);
35 struct const_NRBPath {
36     NArtBpath const *path;
37 };
38 struct NRBPath {
39     NArtBpath *path;
40     operator const_NRBPath() { const_NRBPath bp = { path }; return bp; };
41 };
44 NRBPath *nr_path_duplicate_transform(NRBPath *d, const_NRBPath *s, NR::Matrix const *transform);
46 NRBPath *nr_path_duplicate_transform(NRBPath *d, const_NRBPath *s, NR::Matrix const transform);
48 void nr_path_matrix_point_bbox_wind_distance (const_NRBPath const *bpath, NR::Matrix const &m, NR::Point &pt,
49                                               NRRect *bbox, int *wind, NR::Coord *dist,
50                      NR::Coord tolerance, NR::Rect *viewbox);
52 void nr_path_matrix_bbox_union(const_NRBPath *bpath, NR::Matrix const &m, NRRect *bbox);
54 NArtBpath *nr_path_from_rect(NRRect const &r);
56 #endif
58 /*
59   Local Variables:
60   mode:c++
61   c-file-style:"stroustrup"
62   c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
63   indent-tabs-mode:nil
64   fill-column:99
65   End:
66 */
67 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :