I have some SVG files that specifies width
and height
as well as viewbox
like this:
<svg width="576pt" height="432pt" viewBox="0 0 576 432" > ...
but how to display them in the browser at a size I decide? I want them smaller and have tried:
<object width="400" data="image.svg"></object>
but then I get visible scrollbars.
It works if I change the SVG files to set width
and height
to 100%
instead, but I want to decide the size in the HTML regardless of what sizes are used in the SVG file. Is this possible ?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…