mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-26 00:02:08 -05:00
[symbology] add diamond ellipse marker
This commit is contained in:
parent
b7a4e20627
commit
7c779aea3c
@ -597,6 +597,14 @@ void QgsEllipseSymbolLayerV2::preparePath( const QString& symbolName, QgsSymbolV
|
||||
{
|
||||
mPainterPath.addRect( QRectF( -size.width() / 2.0, -size.height() / 2.0, size.width(), size.height() ) );
|
||||
}
|
||||
else if ( symbolName == "diamond" )
|
||||
{
|
||||
mPainterPath.moveTo( -size.width() / 2.0, 0 );
|
||||
mPainterPath.lineTo( 0, size.height() / 2.0 );
|
||||
mPainterPath.lineTo( size.width() / 2.0, 0 );
|
||||
mPainterPath.lineTo( 0, -size.height() / 2.0 );
|
||||
mPainterPath.lineTo( -size.width() / 2.0, 0 );
|
||||
}
|
||||
else if ( symbolName == "cross" )
|
||||
{
|
||||
mPainterPath.moveTo( 0, -size.height() / 2.0 );
|
||||
|
@ -896,7 +896,7 @@ QString QgsDataDefinedButton::fillStyleDesc()
|
||||
|
||||
QString QgsDataDefinedButton::markerStyleDesc()
|
||||
{
|
||||
return trString() + QLatin1String( "[<b>circle</b>|<b>rectangle</b>|<b>cross</b>|<b>triangle"
|
||||
return trString() + QLatin1String( "[<b>circle</b>|<b>rectangle</b>|<b>diamond</b>|<b>cross</b>|<b>triangle"
|
||||
"</b>|<b>right_half_triangle</b>|<b>left_half_triangle</b>|<b>semi_circle</b>]" );
|
||||
}
|
||||
|
||||
|
@ -46,7 +46,7 @@ QgsEllipseSymbolLayerV2Widget::QgsEllipseSymbolLayerV2Widget( const QgsVectorLay
|
||||
mRotationSpinBox->setClearValue( 0.0 );
|
||||
|
||||
QStringList names;
|
||||
names << "circle" << "rectangle" << "cross" << "triangle" << "right_half_triangle" << "left_half_triangle" << "semi_circle";
|
||||
names << "circle" << "rectangle" << "diamond" << "cross" << "triangle" << "right_half_triangle" << "left_half_triangle" << "semi_circle";
|
||||
QSize iconSize = mShapeListWidget->iconSize();
|
||||
|
||||
Q_FOREACH ( const QString& name, names )
|
||||
|
Loading…
x
Reference in New Issue
Block a user