@@ -45,6 +45,15 @@ class SvgSaveOptionsData extends FixedPageSaveOptionsData {
4545 set fitToViewPort (bool ? val) => _fitToViewPort = val;
4646
4747
48+ /// Gets or sets a value in pixels per inch that limits resolution of exported raster images.
49+ /// If the value of this property is non-zero, it limits resolution of exported raster images.
50+ /// That is, higher-resolution images are resampled down to the limit and lower-resolution images are exported as is.
51+ int ? _maxImageResolution;
52+
53+ int ? get maxImageResolution => _maxImageResolution;
54+ set maxImageResolution (int ? val) => _maxImageResolution = val;
55+
56+
4857 /// Gets or sets the physical folder where resources (images) are saved when exporting.
4958 String ? _resourcesFolder;
5059
@@ -241,6 +250,12 @@ class SvgSaveOptionsData extends FixedPageSaveOptionsData {
241250 fitToViewPort = null ;
242251 }
243252
253+ if (json.containsKey ('MaxImageResolution' )) {
254+ maxImageResolution = json['MaxImageResolution' ] as int ;
255+ } else {
256+ maxImageResolution = null ;
257+ }
258+
244259 if (json.containsKey ('ResourcesFolder' )) {
245260 resourcesFolder = json['ResourcesFolder' ] as String ;
246261 } else {
@@ -283,6 +298,10 @@ class SvgSaveOptionsData extends FixedPageSaveOptionsData {
283298 _result['FitToViewPort' ] = fitToViewPort! ;
284299 }
285300
301+ if (maxImageResolution != null ) {
302+ _result['MaxImageResolution' ] = maxImageResolution! ;
303+ }
304+
286305 if (resourcesFolder != null ) {
287306 _result['ResourcesFolder' ] = resourcesFolder! ;
288307 }
0 commit comments