File tree Expand file tree Collapse file tree 4 files changed +9
-3
lines changed
specs/zero-width-strokes-text Expand file tree Collapse file tree 4 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -9,11 +9,13 @@ type TextRenderingMode = typeof tol.renderingMode
9
9
10
10
export function getTextRenderingMode ( attributeState : AttributeState ) : TextRenderingMode {
11
11
let renderingMode : TextRenderingMode = 'invisible'
12
- if ( attributeState . fill && attributeState . stroke ) {
12
+ const doStroke = attributeState . stroke && attributeState . strokeWidth !== 0
13
+ const doFill = attributeState . fill
14
+ if ( doFill && doStroke ) {
13
15
renderingMode = 'fillThenStroke'
14
- } else if ( attributeState . fill ) {
16
+ } else if ( doFill ) {
15
17
renderingMode = 'fill'
16
- } else if ( attributeState . stroke ) {
18
+ } else if ( doStroke ) {
17
19
renderingMode = 'stroke'
18
20
}
19
21
return renderingMode
Original file line number Diff line number Diff line change @@ -64,6 +64,7 @@ window.tests = [
64
64
'vertical-align' ,
65
65
'xml-space' ,
66
66
'zero-width-strokes' ,
67
+ 'zero-width-strokes-text' ,
67
68
'current-color' ,
68
69
'text-length'
69
70
]
You can’t perform that action at this time.
0 commit comments