summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 0acf4dc)
raw | patch | inline | side by side (parent: 0acf4dc)
author | buliabyak <buliabyak@users.sourceforge.net> | |
Fri, 26 May 2006 04:46:58 +0000 (04:46 +0000) | ||
committer | buliabyak <buliabyak@users.sourceforge.net> | |
Fri, 26 May 2006 04:46:58 +0000 (04:46 +0000) |
src/sp-shape.cpp | patch | blob | history | |
src/sp-shape.h | patch | blob | history |
diff --git a/src/sp-shape.cpp b/src/sp-shape.cpp
index 1723390950f925cf4b95335f329bd8ac905706ee..304d481bd625806ffafddb2b914f1f20a2016563 100644 (file)
--- a/src/sp-shape.cpp
+++ b/src/sp-shape.cpp
static void sp_shape_snappoints (SPItem const *item, SnapPointsIter p);
static void sp_shape_update_marker_view (SPShape *shape, NRArenaItem *ai);
-static int sp_shape_has_markers (SPShape const *shape);
-static int sp_shape_number_of_markers (SPShape* Shape, int type);
static SPItemClass *parent_class;
* \param bp Path segment.
* \return 1 if a marker is required here, otherwise 0.
*/
-static bool
+bool
sp_shape_marker_required(SPShape const *shape, int const m, NArtBpath *bp)
{
if (shape->marker[m] == NULL) {
* \return Transform matrix.
*/
-static NR::Matrix
+NR::Matrix
sp_shape_marker_get_transform(SPShape const *shape, NArtBpath const *bp)
{
g_return_val_if_fail(( is_moveto(SP_CURVE_BPATH(shape->curve)[0].code)
* \param shape Shape.
* \return TRUE if the shape has any markers, or FALSE if not.
*/
-static int
+int
sp_shape_has_markers (SPShape const *shape)
{
/* Note, we're ignoring 'marker' settings, which technically should apply for
* \param type Marker type (e.g. SP_MARKER_LOC_START)
* \return Number of markers that the shape has of this type.
*/
-static int
+int
sp_shape_number_of_markers (SPShape *shape, int type)
{
int n = 0;
diff --git a/src/sp-shape.h b/src/sp-shape.h
index 5479284365f3d03131b2e3ad1ed84d249f62d573..32774f60315abab3321bfbca0cfc41087037628e 100644 (file)
--- a/src/sp-shape.h
+++ b/src/sp-shape.h
/* Return duplicate of curve or NULL */
SPCurve *sp_shape_get_curve (SPShape *shape);
+// sets a curve, updates display
void sp_shape_set_curve (SPShape *shape, SPCurve *curve, unsigned int owner);
-/* NOT FOR GENERAL PUBLIC UNTIL SORTED OUT (Lauris) */
+// same as sp_shape_set_curve, but without updating display
void sp_shape_set_curve_insync (SPShape *shape, SPCurve *curve, unsigned int owner);
-/* PROTECTED */
+// markers API
void sp_shape_set_marker (SPObject *object, unsigned int key, const gchar *value);
-
-
+int sp_shape_has_markers (SPShape const *shape);
+int sp_shape_number_of_markers (SPShape* Shape, int type);
+NR::Matrix sp_shape_marker_get_transform(SPShape const *shape, NArtBpath const *bp);
+bool sp_shape_marker_required(SPShape const *shape, int const m, NArtBpath *bp);
#endif