Skip to content

Commit

Permalink
Additional buffer props for label styles
Browse files Browse the repository at this point in the history
  • Loading branch information
mholthausen committed May 17, 2021
1 parent 7874de1 commit 2872293
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion data/qmls/text_text_buffer.qml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<settings>
<text-style fontSize="10.6135611907387" fontLetterSpacing="0" multilineHeight="1" textColor="0,0,0,255" fontFamily="DejaVuSans" fieldName="Sample label"/>
<placement predefinedPositionOrder="TR,TL,BR,BL,R,L,TSR,BSR" xOffset="0" yOffset="0" rotationAngle="0"/>
<text-buffer bufferSize="0.7938257993384785" bufferColor="250,250,250,255"/>
<text-buffer bufferSize="0.7938257993384785" bufferColor="250,250,250,255" bufferDraw="1" bufferSizeUnits="Pixel" bufferSizeMapUnitScale="3x:0,0,0,0,0,0"/>
</settings>
</rule>
</rules>
Expand Down
5 changes: 4 additions & 1 deletion src/QGISStyleParser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -964,7 +964,10 @@ export class QGISStyleParser implements StyleParser {
textRule.settings[0]['text-buffer'] = [{
$: {
bufferSize: textSymbolizer.haloWidth || `0`,
bufferColor: this.qmlColorFromHexAndOpacity(textSymbolizer.haloColor, 1)
bufferColor: this.qmlColorFromHexAndOpacity(textSymbolizer.haloColor, 1),
bufferDraw: 1,
bufferSizeUnits: 'Pixel',
bufferSizeMapUnitScale: '3x:0,0,0,0,0,0'
}
}];
}
Expand Down

0 comments on commit 2872293

Please sign in to comment.