Subversion Repositories Scribus

Rev

Rev 934 | Rev 4430 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
82 Franz 1
#ifndef CMDMANI_H
2
#define CMDMANI_H
3
 
792 subik 4
// Pulls in <Python.h> first
5
#include "cmdvar.h"
82 Franz 6
 
7
/** Manipulating Objects */
733 subik 8
 
9
/*! docstring */
10
PyDoc_STRVAR(scribus_moveobjrel__doc__,
899 cbradney 11
QT_TR_NOOP("moveObject(dx, dy [, \"name\"])\n\
12
\n\
13
Moves the object \"name\" by dx and dy relative to its current position. The\n\
14
distances are expressed in the current measurement unit of the document (see\n\
15
UNIT constants). If \"name\" is not given the currently selected item is used.\n\
16
If the object \"name\" belongs to a group, the whole group is moved.\n\
17
"));
733 subik 18
/*! Move REL the object */
934 subik 19
PyObject *scribus_moveobjrel(PyObject */*self*/, PyObject* args);
733 subik 20
 
21
/*! docstring */
22
PyDoc_STRVAR(scribus_moveobjabs__doc__,
899 cbradney 23
QT_TR_NOOP("moveObjectAbs(x, y [, \"name\"])\n\
24
\n\
25
Moves the object \"name\" to a new location. The coordinates are expressed in\n\
26
the current measurement unit of the document (see UNIT constants).  If \"name\"\n\
27
is not given the currently selected item is used.  If the object \"name\"\n\
28
belongs to a group, the whole group is moved.\n\
29
"));
733 subik 30
/*! Move ABS the object */
934 subik 31
PyObject *scribus_moveobjabs(PyObject */*self*/, PyObject* args);
733 subik 32
 
33
/*! docstring */
34
PyDoc_STRVAR(scribus_rotobjrel__doc__,
899 cbradney 35
QT_TR_NOOP("rotateObject(rot [, \"name\"])\n\
36
\n\
37
Rotates the object \"name\" by \"rot\" degrees relatively. The object is\n\
38
rotated by the vertex that is currently selected as the rotation point - by\n\
39
default, the top left vertext at zero rotation. Positive values mean counter\n\
40
clockwise rotation when the default rotation point is used. If \"name\" is not\n\
41
given the currently selected item is used.\n\
42
"));
733 subik 43
/*! Rotate REL the object */
934 subik 44
PyObject *scribus_rotobjrel(PyObject */*self*/, PyObject* args);
733 subik 45
 
46
/*! docstring */
47
PyDoc_STRVAR(scribus_rotobjabs__doc__,
899 cbradney 48
QT_TR_NOOP("rotateObjectAbs(rot [, \"name\"])\n\
49
\n\
50
Sets the rotation of the object \"name\" to \"rot\". Positve values\n\
51
mean counter clockwise rotation. If \"name\" is not given the currently\n\
52
selected item is used.\n\
53
"));
733 subik 54
/*! Rotate ABS the object */
934 subik 55
PyObject *scribus_rotobjabs(PyObject */*self*/, PyObject* args);
733 subik 56
 
57
/*! docstring */
58
PyDoc_STRVAR(scribus_sizeobjabs__doc__,
899 cbradney 59
QT_TR_NOOP("sizeObject(width, height [, \"name\"])\n\
60
\n\
61
Resizes the object \"name\" to the given width and height. If \"name\"\n\
62
is not given the currently selected item is used.\n\
63
"));
733 subik 64
/*! Resize ABS the object */
934 subik 65
PyObject *scribus_sizeobjabs(PyObject */*self*/, PyObject* args);
733 subik 66
 
67
/*! docstring */
68
PyDoc_STRVAR(scribus_getselobjnam__doc__,
899 cbradney 69
QT_TR_NOOP("getSelectedObject([nr]) -> string\n\
70
\n\
71
Returns the name of the selected object. \"nr\" if given indicates the number\n\
72
of the selected object, e.g. 0 means the first selected object, 1 means the\n\
73
second selected Object and so on.\n\
74
"));
733 subik 75
/*! Returns name of the selected object */
934 subik 76
PyObject *scribus_getselobjnam(PyObject */*self*/, PyObject* args);
733 subik 77
 
78
/*! docstring */
79
PyDoc_STRVAR(scribus_selcount__doc__,
899 cbradney 80
QT_TR_NOOP("selectionCount() -> integer\n\
81
\n\
82
Returns the number of selected objects.\n\
83
"));
733 subik 84
/*! Returns count of the selected object */
934 subik 85
PyObject *scribus_selcount(PyObject */*self*/);
733 subik 86
 
87
/*! docstring */
88
PyDoc_STRVAR(scribus_selectobj__doc__,
899 cbradney 89
QT_TR_NOOP("selectObject(\"name\")\n\
90
\n\
91
Selects the object with the given \"name\".\n\
92
"));
733 subik 93
/*! Count selection */
934 subik 94
PyObject *scribus_selectobj(PyObject */*self*/, PyObject* args);
733 subik 95
 
96
/*! docstring */
97
PyDoc_STRVAR(scribus_deselect__doc__,
899 cbradney 98
QT_TR_NOOP("deselectAll()\n\
99
\n\
100
Deselects all objects in the whole document.\n\
101
"));
733 subik 102
/*! Remove all selection */
934 subik 103
PyObject *scribus_deselect(PyObject */*self*/);
733 subik 104
 
105
/*! docstring */
106
PyDoc_STRVAR(scribus_groupobj__doc__,
899 cbradney 107
QT_TR_NOOP("groupObjects(list)\n\
108
\n\
109
Groups the objects named in \"list\" together. \"list\" must contain the names\n\
110
of the objects to be grouped. If \"list\" is not given the currently selected\n\
111
items are used.\n\
112
"));
733 subik 113
/*! Group objects named in list. */
934 subik 114
PyObject *scribus_groupobj(PyObject */*self*/, PyObject* args);
733 subik 115
 
116
/*! docstring */
117
PyDoc_STRVAR(scribus_ungroupobj__doc__,
899 cbradney 118
QT_TR_NOOP("unGroupObjects(\"name\")\n\n\
747 subik 119
Destructs the group the object \"name\" belongs to.\
899 cbradney 120
If \"name\" is not given the currently selected item is used."));
733 subik 121
/*! Ungroup objects named in list. */
934 subik 122
PyObject *scribus_ungroupobj(PyObject */*self*/, PyObject* args);
733 subik 123
 
124
/*! docstring */
125
PyDoc_STRVAR(scribus_scalegroup__doc__,
899 cbradney 126
QT_TR_NOOP("scaleGroup(factor [,\"name\"])\n\
127
\n\
128
Scales the group the object \"name\" belongs to. Values greater than 1 enlarge\n\
129
the group, values smaller than 1 make the group smaller e.g a value of 0.5\n\
130
scales the group to 50 % of its original size, a value of 1.5 scales the group\n\
131
to 150 % of its original size.  The value for \"factor\" must be greater than\n\
132
0. If \"name\" is not given the currently selected item is used.\n\
133
\n\
134
May raise ValueError if an invalid scale factor is passed.\n\
135
"));
733 subik 136
/*! Scale group with object name */
934 subik 137
PyObject *scribus_scalegroup(PyObject */*self*/, PyObject* args);
733 subik 138
 
139
/*! docstring */
140
PyDoc_STRVAR(scribus_loadimage__doc__,
899 cbradney 141
QT_TR_NOOP("loadImage(\"filename\" [, \"name\"])\n\
142
\n\
143
Loads the picture \"picture\" into the image frame \"name\". If \"name\" is\n\
144
not given the currently selected item is used.\n\
145
\n\
146
May raise WrongFrameTypeError if the target frame is not an image frame\n\
147
"));
733 subik 148
/*! Loads image file into frame. */
934 subik 149
PyObject *scribus_loadimage(PyObject */*self*/, PyObject* args);
733 subik 150
 
151
/*! docstring */
152
PyDoc_STRVAR(scribus_scaleimage__doc__,
899 cbradney 153
QT_TR_NOOP("scaleImage(x, y [, \"name\"])\n\
154
\n\
155
Sets the scaling factors of the picture in the image frame \"name\".\n\
156
If \"name\" is not given the currently selected item is used. A number of 1\n\
157
means 100 %.\n\
158
\n\
159
May raise WrongFrameTypeError if the target frame is not an image frame\n\
160
"));
733 subik 161
/*! Scale Image. */
934 subik 162
PyObject *scribus_scaleimage(PyObject */*self*/, PyObject* args);
733 subik 163
 
164
/*! docstring */
165
PyDoc_STRVAR(scribus_lockobject__doc__,
899 cbradney 166
QT_TR_NOOP("lockObject([\"name\"]) -> bool\n\
167
\n\
168
Locks the object \"name\" if it's unlocked or unlock it if it's locked.\n\
169
If \"name\" is not given the currently selected item is used. Returns true\n\
170
if locked.\n\
171
"));
733 subik 172
/*! (Un)Lock the object 2004/7/10 pv.*/
934 subik 173
PyObject *scribus_lockobject(PyObject */*self*/, PyObject* args);
733 subik 174
 
175
/*! docstring */
176
PyDoc_STRVAR(scribus_islocked__doc__,
899 cbradney 177
QT_TR_NOOP("isLocked([\"name\"]) -> bool\n\
178
\n\
179
Returns true if is the object \"name\" locked.  If \"name\" is not given the\n\
180
currently selected item is used.\n\
181
"));
747 subik 182
/*! Status of locking 2004/7/10 pv.*/
934 subik 183
PyObject *scribus_islocked(PyObject */*self*/, PyObject* args);
733 subik 184
 
1381 cbradney 185
PyDoc_STRVAR(scribus_setscaleimagetoframe__doc__,
186
QT_TR_NOOP("setScaleImageToFrame(scaletoframe, proportional=None, name=<selection>)\n\
187
\n\
188
Sets the scale to frame on the selected or specified image frame to `scaletoframe'.\n\
189
If `proportional' is specified, set fixed aspect ratio scaling to `proportional'.\n\
190
Both `scaletoframe' and `proportional' are boolean.\n\
191
\n\
192
May raise WrongFrameTypeError.\n\
193
"));
194
PyObject *scribus_setscaleimagetoframe(PyObject */*self*/, PyObject* args, PyObject* kwargs);
195
 
82 Franz 196
#endif