~valavanisalex/ubuntu/oneiric/inkscape/inkscape_0.48.1-2ubuntu5

« back to all changes in this revision

Viewing changes to src/snap-enums.h

  • Committer: Bazaar Package Importer
  • Author(s): Alex Valavanis
  • Date: 2010-09-12 19:44:58 UTC
  • mfrom: (1.1.12 upstream) (45.1.3 maverick)
  • Revision ID: james.westby@ubuntu.com-20100912194458-4sjwmbl7dlsrk5dc
Tags: 0.48.0-1ubuntu1
* Merge with Debian unstable (LP: #628048, LP: #401567, LP: #456248, 
  LP: #463602, LP: #591986)
* debian/control: 
  - Ubuntu maintainers
  - Promote python-lxml, python-numpy, python-uniconvertor to Recommends.
  - Demote pstoedit to Suggests (universe package).
  - Suggests ttf-dejavu instead of ttf-bitstream-vera (LP: #513319)
* debian/rules:
  - Run intltool-update on build (Ubuntu-specific).
  - Add translation domain to .desktop files (Ubuntu-specific).
* debian/dirs:
  - Add usr/share/pixmaps.  Allow inkscape.xpm installation
* drop 50-poppler-API.dpatch (now upstream)
* drop 51-paste-in-unwritable-directory.dpatch (now upstream) 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef SNAPENUMS_H_
 
2
#define SNAPENUMS_H_
 
3
 
 
4
/**
 
5
 * \file snap-enums.h
 
6
 * \brief enumerations of snap source types and snap target types
 
7
 *
 
8
 * Authors:
 
9
 *   Diederik van Lierop <mail@diedenrezi.nl>
 
10
 *
 
11
 * Copyright (C) 2010 Authors
 
12
 *
 
13
 * Released under GNU GPL, read the file 'COPYING' for more information
 
14
 */
 
15
 
 
16
namespace Inkscape {
 
17
 
 
18
enum SnapTargetType {
 
19
    SNAPTARGET_UNDEFINED = 0,
 
20
    SNAPTARGET_GRID,
 
21
    SNAPTARGET_GRID_INTERSECTION,
 
22
    SNAPTARGET_GUIDE,
 
23
    SNAPTARGET_GUIDE_INTERSECTION,
 
24
    SNAPTARGET_GUIDE_ORIGIN,
 
25
    SNAPTARGET_GRID_GUIDE_INTERSECTION,
 
26
    SNAPTARGET_NODE_SMOOTH,
 
27
    SNAPTARGET_NODE_CUSP,
 
28
    SNAPTARGET_LINE_MIDPOINT,
 
29
    SNAPTARGET_OBJECT_MIDPOINT,
 
30
    SNAPTARGET_ROTATION_CENTER,
 
31
    SNAPTARGET_HANDLE,
 
32
    SNAPTARGET_PATH,
 
33
    SNAPTARGET_PATH_INTERSECTION,
 
34
    SNAPTARGET_BBOX_CORNER,
 
35
    SNAPTARGET_BBOX_EDGE,
 
36
    SNAPTARGET_BBOX_EDGE_MIDPOINT,
 
37
    SNAPTARGET_BBOX_MIDPOINT,
 
38
    SNAPTARGET_PAGE_BORDER,
 
39
    SNAPTARGET_PAGE_CORNER,
 
40
    SNAPTARGET_CONVEX_HULL_CORNER,
 
41
    SNAPTARGET_ELLIPSE_QUADRANT_POINT,
 
42
    SNAPTARGET_CENTER, // of ellipse
 
43
    SNAPTARGET_CORNER, // of image or of rectangle
 
44
    SNAPTARGET_TEXT_BASELINE,
 
45
    SNAPTARGET_CONSTRAINED_ANGLE,
 
46
    SNAPTARGET_CONSTRAINT
 
47
};
 
48
 
 
49
enum SnapSourceType {
 
50
    SNAPSOURCE_UNDEFINED = 0,
 
51
    //-------------------------------------------------------------------
 
52
    // Bbox points can be located at the edge of the stroke (for visual bboxes); they will therefore not snap
 
53
    // to nodes because these are always located at the center of the stroke
 
54
    SNAPSOURCE_BBOX_CATEGORY = 256, // will be used as a flag and must therefore be a power of two
 
55
    SNAPSOURCE_BBOX_CORNER,
 
56
    SNAPSOURCE_BBOX_MIDPOINT,
 
57
    SNAPSOURCE_BBOX_EDGE_MIDPOINT,
 
58
    //-------------------------------------------------------------------
 
59
    // For the same reason, nodes will not snap to bbox points
 
60
    SNAPSOURCE_NODE_CATEGORY = 512, // will be used as a flag and must therefore be a power of two
 
61
    SNAPSOURCE_NODE_SMOOTH, // Symmetrical nodes are also considered to be smooth; there's no dedicated type for symm. nodes
 
62
    SNAPSOURCE_NODE_CUSP,
 
63
    SNAPSOURCE_LINE_MIDPOINT,
 
64
    SNAPSOURCE_PATH_INTERSECTION,
 
65
    SNAPSOURCE_CORNER, // of image or of rectangle
 
66
    SNAPSOURCE_CONVEX_HULL_CORNER,
 
67
    SNAPSOURCE_ELLIPSE_QUADRANT_POINT,
 
68
    SNAPSOURCE_NODE_HANDLE, // eg. nodes in the path editor, handles of stars or rectangles, etc. (tied to a stroke)
 
69
    SNAPSOURCE_OBJECT_MIDPOINT,
 
70
    //-------------------------------------------------------------------
 
71
    // Other points (e.g. guides, gradient knots) will snap to both bounding boxes and nodes
 
72
    SNAPSOURCE_OTHER_CATEGORY = 1024, // will be used as a flag and must therefore be a power of two
 
73
    SNAPSOURCE_ROTATION_CENTER,
 
74
    SNAPSOURCE_CENTER, // of ellipse
 
75
    SNAPSOURCE_GUIDE,
 
76
    SNAPSOURCE_GUIDE_ORIGIN,
 
77
    SNAPSOURCE_TEXT_BASELINE,
 
78
    SNAPSOURCE_OTHER_HANDLE, // eg. the handle of a gradient of a connector (ie not being tied to a stroke)
 
79
    SNAPSOURCE_GRID_PITCH, // eg. when pasting or alt-dragging in the selector tool; not realy a snap source
 
80
};
 
81
 
 
82
}
 
83
#endif /* SNAPENUMS_H_ */