Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ImportedProjects
SVG
Commits
4d4acd6e
Unverified
Commit
4d4acd6e
authored
Jan 21, 2019
by
mrbean-bremen
Browse files
Ignore color in invalid numeric format
- fixes #342
parent
f28f5a2c
Changes
4
Hide whitespace changes
Inline
Side-by-side
Source/Painting/SvgColourConverter.cs
View file @
4d4acd6e
...
...
@@ -155,7 +155,13 @@ namespace Svg
case
"windowframe"
:
return
SystemColors
.
WindowFrame
;
case
"windowtext"
:
return
SystemColors
.
WindowText
;
}
int
number
;
if
(
Int32
.
TryParse
(
colour
,
out
number
))
{
// numbers are handled as colors by System.Drawing.ColorConverter - we
// have to prevent this and ignore the color instead (see #342)
return
SvgColourServer
.
NotSet
;
}
}
finally
{
...
...
Tests/Svg.UnitTests/PassingTests.csv
View file @
4d4acd6e
...
...
@@ -186,6 +186,7 @@ __issue-323-02
__issue-323-03
__issue-329-01
__issue-338-01_stroke_width
__issue-342-01
__issue-354-01
__issue-385-01_Test_text-anchor-middle
__issue-398-01
...
...
Tests/W3CTestSuite/png/__issue-342-01.png
View replaced file @
f28f5a2c
View file @
4d4acd6e
1.58 KB
|
W:
|
H:
6.26 KB
|
W:
|
H:
2-up
Swipe
Onion skin
Tests/W3CTestSuite/svg/__issue-342-01.svg
View file @
4d4acd6e
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg
xmlns=
"http://www.w3.org/2000/svg"
version=
"1.1"
width=
"
45
"
height=
"
45
"
>
<g
style=
"opacity:1; fill:000000; fill-opacity:1; fill-rule:evenodd; stroke:#000000; stroke-width:1.5; stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4; stroke-dasharray:none; stroke-opacity:1;"
>
<svg
xmlns=
"http://www.w3.org/2000/svg"
version=
"1.1"
width=
"
180
"
height=
"
180
"
>
<g
style=
"opacity:1; fill:000000; fill-opacity:1; fill-rule:evenodd; stroke:#000000; stroke-width:1.5; stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4; stroke-dasharray:none; stroke-opacity:1;"
transform=
"scale(4)"
>
<g
style=
"fill:#000000; stroke:none;"
>
<circle
cx=
"6"
cy=
"12"
r=
"2.75"
/>
<circle
cx=
"14"
cy=
"9"
r=
"2.75"
/>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment