-
Notifications
You must be signed in to change notification settings - Fork 754
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
updated the text costumes library with a special case for a space cha…
…racter
- Loading branch information
Showing
2 changed files
with
4 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
<blocks app="Snap! 10, https://snap.berkeley.edu" version="2"><block-definition s="costume from text %'text' size %'size'" type="reporter" category="looks"><header></header><code></code><translations>de:Kostüm aus Text _ Größe _
pt:um traje com o texto _ de tamanho _
ca:vestit amb el text _ i mida _
pl:kostium z tekstu _ rozmiar _
</translations><inputs><input type="%s">A</input><input type="%n">72</input></inputs><script><block s="doDeclareVariables"><list><l>costume</l><l>x</l><l>y</l><l>dir</l><l>cst</l><l>trails</l><l>pen state</l></list></block><block s="doSetVar"><l>x</l><block s="xPosition"></block></block><block s="doSetVar"><l>y</l><block s="yPosition"></block></block><block s="doSetVar"><l>dir</l><block s="direction"></block></block><block s="doSetVar"><l>cst</l><block s="reportGet"><l><option>costume</option></l></block></block><block s="doSetVar"><l>pen state</l><block s="getPenDown"></block></block><block s="up"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="setHeading"><l>90</l></block><block s="doSwitchToCostume"><l><option>Turtle</option></l></block><block s="doSetVar"><l>trails</l><block s="reportPenTrailsAsCostume"></block></block><block s="clear"></block><block s="gotoXY"><block s="reportAttributeOf"><l><option>left</option></l><l>Stage</l></block><l>0</l></block><block s="write"><block var="text"/><block var="size"/></block><block s="gotoXY"><block s="reportAttributeOf"><l><option>left</option></l><l>Stage</l></block><l>0</l></block><block s="doSetVar"><l>costume</l><block s="reportPenTrailsAsCostume"></block></block><block s="clear"></block><block s="doApplyExtension"><l>obj_name(obj, name)</l><list><block var="costume"/><block s="reportJoinWords"><list><block var="text"/></list></block></list></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSwitchToCostume"><block var="trails"/></block><block s="doStamp"></block><block s="doSwitchToCostume"><block var="cst"/></block><block s="gotoXY"><block var="x"/><block var="y"/></block><block s="setHeading"><block var="dir"/></block><block s="doIf"><block var="pen state"/><script><block s="down"></block></script><list></list></block><block s="doReport"><block var="costume"/></block></script></block-definition><block-definition s="costume %'cst' with background RGBA %'rgb' padding %'padding'" type="reporter" category="looks"><header></header><code></code><translations>pl:kostium _ z tłem RGBA _ rozmiar tła _
</translations><inputs><input type="%s" readonly="true"><options>§_costumesMenu</options></input><input type="%n">200</input><input type="%n">2</input></inputs><script><block s="doDeclareVariables"><list><l>old</l><l>clr</l><l>new</l><l>x</l><l>y</l><l>dir</l><l>trails</l><l>flat</l><l>old size</l><l>old pen state</l></list></block><block s="doSetVar"><l>x</l><block s="xPosition"></block></block><block s="doSetVar"><l>y</l><block s="yPosition"></block></block><block s="doSetVar"><l>dir</l><block s="direction"></block></block><block s="doSetVar"><l>old</l><block s="reportGet"><l><option>costume</option></l></block></block><block s="doSetVar"><l>clr</l><block s="getPenAttribute"><l><option>r-g-b-a</option></l></block></block><block s="doSetVar"><l>flat</l><block s="reportGlobalFlag"><l><option>flat line ends</option></l></block></block><block s="doSetVar"><l>old size</l><block s="getPenAttribute"><l><option>size</option></l></block></block><block s="doSetVar"><l>old pen state</l><block s="getPenDown"></block></block><block s="up"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSetVar"><l>trails</l><block s="reportPenTrailsAsCostume"></block></block><block s="clear"></block><block s="gotoXY"><block s="reportMonadic"><l><option>neg</option></l><block s="reportVariadicSum"><list><block s="reportQuotient"><block s="reportGetImageAttribute"><l><option>width</option></l><block var="cst"/></block><l>2</l></block><block var="padding"/></list></block></block><l>0</l></block><block s="setHeading"><l>90</l></block><block s="doSetGlobalFlag"><l><option>flat line ends</option></l><l><bool>true</bool></l></block><block s="setSize"><block s="reportVariadicSum"><list><block s="reportGetImageAttribute"><l><option>height</option></l><block var="cst"/></block><block s="reportVariadicProduct"><list><block var="padding"/><l>2</l></list></block></list></block></block><block s="setPenColorDimension"><l><option>r-g-b(-a)</option></l><block var="rgb"/></block><block s="down"></block><block s="setXPosition"><block s="reportMonadic"><l><option>neg</option></l><block s="xPosition"></block></block></block><block s="up"></block><block s="doSwitchToCostume"><block var="cst"/></block><block s="doGotoObject"><l><option>center</option></l></block><block s="gotoXY"><block s="reportMonadic"><l><option>neg</option></l><block s="reportGet"><l><option>center x</option></l></block></block><block s="reportMonadic"><l><option>neg</option></l><block s="reportGet"><l><option>center y</option></l></block></block></block><block s="doStamp"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSetVar"><l>new</l><block s="reportPenTrailsAsCostume"></block></block><block s="doApplyExtension"><l>obj_name(obj, name)</l><list><block var="new"/><block s="reportIfElse"><block s="reportListContainsItem"><block s="reportTextSplit"><block s="reportAttributeOf"><l><option>costume name</option></l><l>Sprite</l></block><l><option>word</option></l></block><l>button</l></block><block s="reportAttributeOf"><l><option>costume name</option></l><l>Sprite</l></block><block s="reportJoinWords"><list><block s="reportAttributeOf"><l><option>costume name</option></l><l>Sprite</l></block><l> button</l></list></block></block></list></block><block s="clear"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSwitchToCostume"><block var="trails"/></block><block s="doStamp"></block><block s="doSwitchToCostume"><block var="old"/></block><block s="gotoXY"><block var="x"/><block var="y"/></block><block s="setHeading"><block var="dir"/></block><block s="setPenColorDimension"><l><option>r-g-b(-a)</option></l><block var="clr"/></block><block s="doSetGlobalFlag"><l><option>flat line ends</option></l><block var="flat"/></block><block s="setSize"><block var="old size"/></block><block s="doIf"><block var="old pen state"/><script><block s="down"></block></script><list></list></block><block s="doReport"><block var="new"/></block></script><scripts><script x="255" y="186.19999999999993"><custom-block s="costume %s with background RGBA %n padding %n"><custom-block s="costume %s with background RGBA %n padding %n"><custom-block s="costume from text %s size %n"><l>Snap!</l><l>36</l></custom-block><l>200</l><l>10</l></custom-block><l>100</l><l>2</l></custom-block></script><comment x="248.685546875" y="121.03333333333336" w="106" collapsed="false">Use this block to make "clickable" buttons:</comment></scripts></block-definition></blocks> | ||
<blocks app="Snap! 10.1-dev, https://snap.berkeley.edu" version="2"><block-definition s="costume from text %'text' size %'size'" type="reporter" category="looks"><header></header><code></code><translations>de:Kostüm aus Text _ Größe _
pt:um traje com o texto _ de tamanho _
ca:vestit amb el text _ i mida _
</translations><inputs><input type="%s">A</input><input type="%n">72</input></inputs><script><block s="doDeclareVariables"><list><l>costume</l><l>x</l><l>y</l><l>dir</l><l>cst</l><l>tmp</l><l>trails</l><l>pen state</l></list></block><block s="doIf"><block s="reportVariadicEquals"><list><block var="text"/><l> </l></list></block><script><block s="doSetVar"><l>tmp</l><custom-block s="costume from text %s size %n"><l>A</l><block var="size"/></custom-block></block><block s="doReport"><block s="reportNewCostume"><block s="reportReshape"><l>0</l><block s="reportListAttribute"><l><option>dimensions</option></l><block s="reportGetImageAttribute"><l><option>pixels</option></l><block var="tmp"/></block></block></block><block s="reportGetImageAttribute"><l><option>width</option></l><block var="tmp"/></block><block s="reportGetImageAttribute"><l><option>height</option></l><block var="tmp"/></block></block></block></script><list></list></block><block s="doSetVar"><l>x</l><block s="xPosition"></block></block><block s="doSetVar"><l>y</l><block s="yPosition"></block></block><block s="doSetVar"><l>dir</l><block s="direction"></block></block><block s="doSetVar"><l>cst</l><block s="reportGet"><l><option>costume</option></l></block></block><block s="doSetVar"><l>pen state</l><block s="getPenDown"></block></block><block s="up"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="setHeading"><l>90</l></block><block s="doSwitchToCostume"><l><option>Turtle</option></l></block><block s="doSetVar"><l>trails</l><block s="reportPenTrailsAsCostume"></block></block><block s="clear"></block><block s="gotoXY"><block s="reportAttributeOf"><l><option>left</option></l><l>Stage</l></block><l>0</l></block><block s="write"><block var="text"/><block var="size"/></block><block s="gotoXY"><block s="reportAttributeOf"><l><option>left</option></l><l>Stage</l></block><l>0</l></block><block s="doSetVar"><l>costume</l><block s="reportPenTrailsAsCostume"></block></block><block s="clear"></block><block s="doApplyExtension"><l>obj_name(obj, name)</l><list><block var="costume"/><block s="reportJoinWords"><list><block var="text"/></list></block></list></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSwitchToCostume"><block var="trails"/></block><block s="doStamp"></block><block s="doSwitchToCostume"><block var="cst"/></block><block s="gotoXY"><block var="x"/><block var="y"/></block><block s="setHeading"><block var="dir"/></block><block s="doIf"><block var="pen state"/><script><block s="down"></block></script><list></list></block><block s="doReport"><block var="costume"/></block></script></block-definition><block-definition s="costume %'cst' with background RGBA %'rgb' padding %'padding'" type="reporter" category="looks"><header></header><code></code><translations>pl:kostium _ z tłem RGBA _ rozmiar tła _
</translations><inputs><input type="%s" readonly="true"><options>§_costumesMenu</options></input><input type="%n">200</input><input type="%n">2</input></inputs><script><block s="doDeclareVariables"><list><l>old</l><l>clr</l><l>new</l><l>x</l><l>y</l><l>dir</l><l>trails</l><l>flat</l><l>old size</l><l>old pen state</l></list></block><block s="doSetVar"><l>x</l><block s="xPosition"></block></block><block s="doSetVar"><l>y</l><block s="yPosition"></block></block><block s="doSetVar"><l>dir</l><block s="direction"></block></block><block s="doSetVar"><l>old</l><block s="reportGet"><l><option>costume</option></l></block></block><block s="doSetVar"><l>clr</l><block s="getPenAttribute"><l><option>r-g-b-a</option></l></block></block><block s="doSetVar"><l>flat</l><block s="reportGlobalFlag"><l><option>flat line ends</option></l></block></block><block s="doSetVar"><l>old size</l><block s="getPenAttribute"><l><option>size</option></l></block></block><block s="doSetVar"><l>old pen state</l><block s="getPenDown"></block></block><block s="up"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSetVar"><l>trails</l><block s="reportPenTrailsAsCostume"></block></block><block s="clear"></block><block s="gotoXY"><block s="reportMonadic"><l><option>neg</option></l><block s="reportVariadicSum"><list><block s="reportQuotient"><block s="reportGetImageAttribute"><l><option>width</option></l><block var="cst"/></block><l>2</l></block><block var="padding"/></list></block></block><l>0</l></block><block s="setHeading"><l>90</l></block><block s="doSetGlobalFlag"><l><option>flat line ends</option></l><l><bool>true</bool></l></block><block s="setSize"><block s="reportVariadicSum"><list><block s="reportGetImageAttribute"><l><option>height</option></l><block var="cst"/></block><block s="reportVariadicProduct"><list><block var="padding"/><l>2</l></list></block></list></block></block><block s="setPenColorDimension"><l><option>r-g-b(-a)</option></l><block var="rgb"/></block><block s="down"></block><block s="setXPosition"><block s="reportMonadic"><l><option>neg</option></l><block s="xPosition"></block></block></block><block s="up"></block><block s="doSwitchToCostume"><block var="cst"/></block><block s="doGotoObject"><l><option>center</option></l></block><block s="gotoXY"><block s="reportMonadic"><l><option>neg</option></l><block s="reportGet"><l><option>center x</option></l></block></block><block s="reportMonadic"><l><option>neg</option></l><block s="reportGet"><l><option>center y</option></l></block></block></block><block s="doStamp"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSetVar"><l>new</l><block s="reportPenTrailsAsCostume"></block></block><block s="doApplyExtension"><l>obj_name(obj, name)</l><list><block var="new"/><block s="reportIfElse"><block s="reportListContainsItem"><block s="reportTextSplit"><block s="reportAttributeOf"><l><option>costume name</option></l><l>Sprite</l></block><l><option>word</option></l></block><l>button</l></block><block s="reportAttributeOf"><l><option>costume name</option></l><l>Sprite</l></block><block s="reportJoinWords"><list><block s="reportAttributeOf"><l><option>costume name</option></l><l>Sprite</l></block><l> button</l></list></block></block></list></block><block s="clear"></block><block s="doGotoObject"><l><option>center</option></l></block><block s="doSwitchToCostume"><block var="trails"/></block><block s="doStamp"></block><block s="doSwitchToCostume"><block var="old"/></block><block s="gotoXY"><block var="x"/><block var="y"/></block><block s="setHeading"><block var="dir"/></block><block s="setPenColorDimension"><l><option>r-g-b(-a)</option></l><block var="clr"/></block><block s="doSetGlobalFlag"><l><option>flat line ends</option></l><block var="flat"/></block><block s="setSize"><block var="old size"/></block><block s="doIf"><block var="old pen state"/><script><block s="down"></block></script><list></list></block><block s="doReport"><block var="new"/></block></script><scripts><script x="255" y="186.19999999999993"><custom-block s="costume %s with background RGBA %n padding %n"><custom-block s="costume %s with background RGBA %n padding %n"><custom-block s="costume from text %s size %n"><l>Snap!</l><l>36</l></custom-block><l>200</l><l>10</l></custom-block><l>100</l><l>2</l></custom-block></script><comment x="248.685546875" y="121.03333333333336" w="106" collapsed="false">Use this block to make "clickable" buttons:</comment></scripts></block-definition></blocks> |