Commit graph

189 commits

Author SHA1 Message Date
Artem Pavlenko
43d7278352 Don't apply preserveAscpectRatio logic logic if width and height expressed as % values (#3812) 2017-12-06 11:23:54 +01:00
Artem Pavlenko
98c26bcae0 SVG parser - fix default gradient vector in linear gradient [0,0,1,0] + support units in offset attribute. 2017-11-06 12:39:50 +01:00
Artem Pavlenko
743c14d3ff add UDL via operator"" _case 2017-11-06 10:31:53 +01:00
Dane Springmeyer
4bc7ec73de fix spelling in svg parser error 2017-09-10 08:59:54 -07:00
artemp
a682cea51e svg-parser - unify error messages text + update unit test 2017-08-08 12:38:24 +01:00
artemp
6f73181e9b Enforce consistent error handling policy - always throw on fatal errors (both strict and non-strict). In strict mode throw on first parsing error. Remove return values from parse,parse_from_string and traverse_tree methods. Update unit tests. 2017-08-02 10:32:13 +01:00
artemp
a26723b4a5 add missing ' in error message. 2017-08-02 10:32:00 +01:00
artemp
b164117d99 disable handling unsupported attributes (leaving only well-known unsupported elements) to reduce verbosity. 2017-07-07 10:09:08 +02:00
artemp
1e8ec57593 add <image> and <switch> to unsupported elements. 2017-06-29 09:41:16 +02:00
artemp
47bfe7cb91 make unsupported elements/attributes arrays const. 2017-06-29 09:41:16 +02:00
artemp
5118220c4c handle "well-known" unsupported elements and attributes. 2017-06-29 09:41:16 +02:00
artemp
8f2961b9e2 svg_parser - implement preserveAspectRatio support (ref https://www.w3.org/TR/SVG/coords.html#PreserveAspectRatioAttribute) 2017-06-29 09:41:16 +02:00
artemp
3edcd4afa2 fix viewBox coordinate system logic + apply transform in <use> element 2017-06-29 09:41:16 +02:00
artemp
fafc751e42 svg_parser - add support for "href" preserving deprecated (since SVG 2) "xlink:href" 2017-06-29 09:41:16 +02:00
artemp
c2ad505899 fix method name 2017-06-29 09:41:16 +02:00
artemp
aae7253ba1 SVG parser - refactor to use switch where appropriate + experimental support for <symbol> 2017-06-29 09:41:16 +02:00
artemp
2de8ce0eb7 svg_parser - don't log unsupported entities just yet (ref #763) 2017-06-29 09:41:16 +02:00
artemp
53a69463ea SVG parser - add support for <use> element (ref #763). 2017-06-29 09:41:16 +02:00
artemp
199a281627 remove debug stderr 2017-06-29 09:41:16 +02:00
artemp
ca4d140fb0 cleanup 2017-06-29 09:41:16 +02:00
artemp
b6aa45144c svg_parser - refactor => remove mutable temporary_gradient_ member variable + process stop elements from within linearGradient and radialGradient. 2017-06-29 09:41:16 +02:00
artemp
6da83bc986 svg_parser - store unresolved gradient nodes for deferred initalisation. 2017-06-29 09:41:16 +02:00
artemp
ef6c2e71b8 svg-parser : handle parsing failures via error_handler ( throw in strict mode and log+continue when strict==false) 2017-06-29 09:41:16 +02:00
artemp
e56233833e svg_parser - fix bug introduced in previous commit. 2017-06-29 09:41:16 +02:00
artemp
3f591af871 initial support for strict SVG parsing (WIP) 2017-06-29 09:41:16 +02:00
artemp
333ef9fde1 update copyright year 2017-05-05 13:02:01 +02:00
artemp
ed648ced46 SVG transform - implement in terms of boost::spirit::x3 2016-12-23 16:32:05 +01:00
artemp
95cc560167 SVG points - implement using boost::spirit::x3 + refactor parse_rule instantiations into separate *.cpp 2016-12-23 14:40:59 +01:00
artemp
30749031cf SVG path parser - boost::spirit::x3 based implementation 2016-12-22 14:57:26 +01:00
artemp
5745bedbd9 update copyright year to 2016 2016-12-20 17:57:22 +01:00
artemp
4ba87b1e9d c++14 support is not sufficient on windows: reverting back and start tracking Windows workarounds in separate branch
Revert "move BOOST_SPIRIT_DEFINE into separate headers + use across all grammar defs (#3573)"

This reverts commit 81cfa721db.

Revert "windows : fix errors C3259 + C3249"

This reverts commit 8327905aba.

Revert "Workaround for VC++ C2995 via redifining BOOST_SPIRIT_DEFINE macro (#3573)"

This reverts commit 2a2f0bf00a.
2016-12-14 17:11:59 +01:00
artemp
81cfa721db move BOOST_SPIRIT_DEFINE into separate headers + use across all grammar defs (#3573) 2016-12-14 16:35:24 +01:00
artemp
2a2f0bf00a Workaround for VC++ C2995 via redifining BOOST_SPIRIT_DEFINE macro (#3573) 2016-12-14 15:10:22 +01:00
artemp
e46785a063 wrap grammar into anonymous namespace - attempting to fix VC++ compilation issue (#3573) 2016-12-14 10:49:11 +01:00
artemp
ce0f87fb71 merge spirit-x3 2016-10-13 17:00:11 +02:00
artemp
923efd589c geometry_to_path.hpp => geometry/to_path.hpp 2016-10-11 18:01:30 +02:00
artemp
8ce7a1c43d refactor souce code files with the following rule: the physical filesytem path matches namespace structure
e.g `mapnik::geometry::centroid()` -> `$(MAPNIK_SOURCE)/include/mapnik/geometry/centroid.hpp`
2016-10-11 18:01:29 +02:00
artemp
3788b2781e tiny format 2016-08-16 15:36:43 +01:00
Dane Springmeyer
192f5c26c1 use c++ style casts 2016-03-10 12:45:47 -08:00
Dane Springmeyer
341db51aa7 finish wrapping boost includes to suppress warnings - add agg wrapper - refs #2907 2016-03-09 16:42:15 -08:00
artemp
a5cfd27594 split svg_path_grammar,svg_points_grammar,svg_transform_grammar into *.hpp, *_impl.hpp + move boost::phoenix::function initialisation into ctor's
(ref #3343)
2016-03-04 15:34:45 +01:00
artemp
76bb2d9c01 make svg_transform_grammar stateless ref #3343
(https://github.com/mapnik/mapnik/pull/2231)
2016-03-04 13:15:11 +01:00
artemp
4659f40401 make svg_path_grammar and svg_points_grammar stateless ref #3343
(https://github.com/mapnik/mapnik/pull/2231)
2016-03-04 12:42:44 +01:00
Dane Springmeyer
a855a12532 make code comment about needing immutable grammars - refs #3342 [skip ci] 2016-03-03 09:14:06 -08:00
Mickey Rose
8a55eefbb5 derive virtual_renderer_common from renderer_common 2016-01-29 00:10:19 +01:00
Mickey Rose
8d7fca3236 svg_parse_value - add 'px' unit, report trailing garbage
- avoid operator comma in semantic action, refs #3249
2016-01-23 20:44:14 +01:00
artemp
1bfabec6be parse_svg_value - add DPI template parameter (default 90) (#3233) 2016-01-15 09:38:46 +00:00
artemp
cc635df7bc svg_parser - use parse_svg_value 2016-01-14 11:03:55 +00:00
artemp
48c043ec42 implement "parse_svg_value" supporting SVG units (https://www.w3.org/TR/SVG/coords.html#Units) (#3233) 2016-01-14 10:54:33 +00:00
artemp
1dff67e1fe fix namespace qualifiers 2016-01-14 10:24:40 +00:00