[SVG][Fixed] Problems using Chrome and Firefox
- The KiCad 6 default scale is too big
This commit is contained in:
parent
bedac3f5ec
commit
623ce5c65e
|
|
@ -17,6 +17,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
- Resistor remap and flip
|
||||
- A `remap_components` option with better type checks
|
||||
- Better support for variants
|
||||
- SVG:
|
||||
- Option to control the *SVG precision* (units scale)
|
||||
|
||||
### Changed
|
||||
- Diff:
|
||||
|
|
@ -25,6 +27,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
### Fixed
|
||||
- QR lib update: Problems when moving the footprint to the bottom for
|
||||
KiCad 5.
|
||||
- SVG: Problems to display the outputs using Chrome and Firefox.
|
||||
|
||||
|
||||
## [1.4.0] - 2022-10-12
|
||||
|
|
|
|||
|
|
@ -3229,6 +3229,9 @@ Notes:
|
|||
- `plot_footprint_values`: [boolean=true] Include the footprint values.
|
||||
- `pre_transform`: [string|list(string)='_none'] Name of the filter to transform fields before applying other filters.
|
||||
A short-cut to use for simple cases where a variant is an overkill.
|
||||
- `svg_precision`: [number=4] [0,6] Scale factor used to represent 1 mm in the SVG (KiCad 6).
|
||||
The value is how much zeros has the multiplier (1 mm = 10 power `svg_precision` units).
|
||||
Note that for an A4 paper Firefox 91 and Chrome 105 can't handle more than 5.
|
||||
- `tent_vias`: [boolean=true] Cover the vias.
|
||||
- `uppercase_extensions`: [boolean=false] Use uppercase names for the extensions.
|
||||
- `variant`: [string=''] Board variant to apply.
|
||||
|
|
|
|||
|
|
@ -2002,6 +2002,10 @@ outputs:
|
|||
# [string|list(string)='_none'] Name of the filter to transform fields before applying other filters.
|
||||
# A short-cut to use for simple cases where a variant is an overkill
|
||||
pre_transform: '_none'
|
||||
# [number=4] [0,6] Scale factor used to represent 1 mm in the SVG (KiCad 6).
|
||||
# The value is how much zeros has the multiplier (1 mm = 10 power `svg_precision` units).
|
||||
# Note that for an A4 paper Firefox 91 and Chrome 105 can't handle more than 5
|
||||
svg_precision: 4
|
||||
# [boolean=true] Cover the vias
|
||||
tent_vias: true
|
||||
# [boolean=false] Use uppercase names for the extensions
|
||||
|
|
|
|||
|
|
@ -22,6 +22,10 @@ class SVGOptions(DrillMarks):
|
|||
""" Plot mirrored """
|
||||
self.negative_plot = False
|
||||
""" Invert black and white """
|
||||
self.svg_precision = 4
|
||||
""" [0,6] Scale factor used to represent 1 mm in the SVG (KiCad 6).
|
||||
The value is how much zeros has the multiplier (1 mm = 10 power `svg_precision` units).
|
||||
Note that for an A4 paper Firefox 91 and Chrome 105 can't handle more than 5 """
|
||||
self._plot_format = PLOT_FORMAT_SVG
|
||||
|
||||
def _configure_plot_ctrl(self, po, output_dir):
|
||||
|
|
@ -30,6 +34,8 @@ class SVGOptions(DrillMarks):
|
|||
if GS.ki5:
|
||||
po.SetLineWidth(FromMM(self.line_width))
|
||||
po.SetNegative(self.negative_plot)
|
||||
if GS.ki6:
|
||||
po.SetSvgPrecision(self.svg_precision, False)
|
||||
|
||||
def read_vals_from_po(self, po):
|
||||
super().read_vals_from_po(po)
|
||||
|
|
|
|||
Loading…
Reference in New Issue