mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-01 02:38:43 -05:00
Fix SVG examples that make use of display: none;
This commit is contained in:
parent
6aaeb81869
commit
a775d1eca4
2 changed files with 3 additions and 1 deletions
|
@ -6,7 +6,8 @@
|
||||||
<script type="text/javascript" src="../../dist/paper-full.js"></script>
|
<script type="text/javascript" src="../../dist/paper-full.js"></script>
|
||||||
<script type="text/paperscript" canvas="canvas">
|
<script type="text/paperscript" canvas="canvas">
|
||||||
// Import the tiger svg:
|
// Import the tiger svg:
|
||||||
project.importSVG(document.getElementById('svg'));
|
var svg = project.importSVG(document.getElementById('svg'));
|
||||||
|
svg.visible = true; // Turn off display: none;
|
||||||
|
|
||||||
// Resize the tiger to fit within the window:
|
// Resize the tiger to fit within the window:
|
||||||
project.activeLayer.fitBounds(view.bounds);
|
project.activeLayer.fitBounds(view.bounds);
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
<script type="text/javascript" src="../../dist/paper-full.js"></script>
|
<script type="text/javascript" src="../../dist/paper-full.js"></script>
|
||||||
<script type="text/paperscript" canvas="canvas">
|
<script type="text/paperscript" canvas="canvas">
|
||||||
var words = project.importSVG(document.getElementById('svg'));
|
var words = project.importSVG(document.getElementById('svg'));
|
||||||
|
words.visible = true; // Turn off display: none;
|
||||||
words.fillColor = null;
|
words.fillColor = null;
|
||||||
words.strokeColor = 'black';
|
words.strokeColor = 'black';
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue