Skip to content

Commit e1e1f0d

Browse files
committedApr 3, 2017
Strip \a from doxygen comments in sipify
1 parent 5813eb1 commit e1e1f0d

File tree

5 files changed

+20
-17
lines changed

5 files changed

+20
-17
lines changed
 

‎python/core/qgsanimatedicon.sip

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ class QgsAnimatedIcon : QObject
2121

2222
QgsAnimatedIcon( const QString &iconPath = QString(), QObject *parent = 0 );
2323
%Docstring
24-
Create a new animated icon. Optionally, the \a iconPath can already be specified.
24+
Create a new animated icon. Optionally, the iconPath can already be specified.
2525
%End
2626

2727
QString iconPath() const;

‎python/core/qgspropertytransformer.sip

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class QgsCurveTransform
2626

2727
QgsCurveTransform( const QList< QgsPoint > &controlPoints );
2828
%Docstring
29-
Constructs a QgsCurveTransform using a specified list of \a controlPoints.
29+
Constructs a QgsCurveTransform using a specified list of controlPoints.
3030
Behavior is undefined if duplicate x values exist in the control points
3131
list.
3232
%End
@@ -69,12 +69,12 @@ class QgsCurveTransform
6969

7070
double y( double x ) const;
7171
%Docstring
72-
Returns the mapped y value corresponding to the specified \a x value.
72+
Returns the mapped y value corresponding to the specified x value.
7373
%End
7474

7575
QVector< double > y( const QVector< double > &x ) const;
7676
%Docstring
77-
Returns a list of y values corresponding to a list of \a x values.
77+
Returns a list of y values corresponding to a list of x values.
7878
Calling this method is faster then calling the double variant multiple
7979
times.
8080
%End
@@ -232,7 +232,7 @@ class QgsPropertyTransformer
232232
void setCurveTransform( QgsCurveTransform *transform /Transfer/ );
233233
%Docstring
234234
Sets a curve transform to apply to input values before they are transformed
235-
by the individual transform subclasses. Ownership of \a transform is transferred
235+
by the individual transform subclasses. Ownership of transform is transferred
236236
to the property transformer.
237237
\see curveTransform()
238238
%End
@@ -247,7 +247,7 @@ class QgsPropertyTransformer
247247

248248
virtual QString toExpression( const QString &baseExpression ) const = 0;
249249
%Docstring
250-
Converts the transformer to a QGIS expression string. The \a baseExpression string consists
250+
Converts the transformer to a QGIS expression string. The baseExpression string consists
251251
of a sub-expression reflecting the parent property's state.
252252
%End
253253

@@ -270,7 +270,7 @@ class QgsPropertyTransformer
270270
double transformNumeric( double input ) const;
271271
%Docstring
272272
Applies base class numeric transformations. Derived classes should call this
273-
to transform an \a input numeric value before they apply any transform to the result.
273+
to transform an input numeric value before they apply any transform to the result.
274274
This applies any curve transforms which may exist on the transformer.
275275
%End
276276
};
@@ -329,7 +329,7 @@ class QgsGenericNumericTransformer : QgsPropertyTransformer
329329

330330
double value( double input ) const;
331331
%Docstring
332-
Calculates the size corresponding to a specific \a input value.
332+
Calculates the size corresponding to a specific input value.
333333
\returns calculated size using size scale transformer's parameters and type
334334
%End
335335

@@ -610,7 +610,7 @@ Copy constructor
610610

611611
void setRampName( const QString &name );
612612
%Docstring
613-
Sets the color ramp's \a name. The ramp name must be set to match
613+
Sets the color ramp's name. The ramp name must be set to match
614614
a color ramp available in the style database for conversion to expression
615615
to work correctly.
616616
\see rampName()

‎python/gui/symbology-ng/characterwidget.sip

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ class CharacterWidget : QWidget
5858

5959
void setFont( const QFont &font );
6060
%Docstring
61-
Sets the \a font to show in the widget.
61+
Sets the font to show in the widget.
6262
\see font()
6363
.. versionadded:: 3.0
6464
%End
@@ -85,7 +85,7 @@ class CharacterWidget : QWidget
8585

8686
void setCharacter( QChar character );
8787
%Docstring
88-
Sets the currently selected \a character in the widget.
88+
Sets the currently selected character in the widget.
8989
\see character()
9090
\see characterSelected()
9191
%End

‎scripts/sipify.pl

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,22 @@
99

1010
sub processDoxygenLine
1111
{
12-
if ( $_[0] =~ m/[\\@](ingroup|class)/ ) {
12+
my $line = $_[0];
13+
# remove \a formatting
14+
$line =~ s/\\a //g;
15+
if ( $line =~ m/[\\@](ingroup|class)/ ) {
1316
return ""
1417
}
15-
if ( $_[0] =~ m/\\since .*?([\d\.]+)/i ) {
18+
if ( $line =~ m/\\since .*?([\d\.]+)/i ) {
1619
return ".. versionadded:: $1\n";
1720
}
18-
if ( $_[0] =~ m/[\\@]note (.*)/ ) {
21+
if ( $line =~ m/[\\@]note (.*)/ ) {
1922
return ".. note::\n\n $1\n";
2023
}
21-
if ( $_[0] =~ m/[\\@]brief (.*)/ ) {
24+
if ( $line =~ m/[\\@]brief (.*)/ ) {
2225
return " $1\n";
2326
}
24-
return $_[0];
27+
return $line;
2528
}
2629

2730

‎tests/scripts/sipifyheader.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ class CORE_EXPORT QgsSipifyHeader : public QtClass<QVariant>, private QgsBaseCla
152152

153153
/**
154154
* \brief some brief
155-
* My long doc string
155+
* My long doc \a string
156156
* is not very interesting!
157157
*/
158158
void LongDocStringMethodWithBrief();

0 commit comments

Comments
 (0)
Please sign in to comment.