This article introduces a Small Basic program called "Shapes". This is a program for editing picture with Small Basic Shapes objects.
Output of "Shapes" program is a Small Basic program which shows picture you created. So you can modify the output program to move and rotate the picture. Program
RQB683-3 is a sample output program.
These instructions are for Shapes 1.5b.
Import as program ID XFZ657-15, remove comment from lines with File objects and save the program as "Shapes1_5b.smallbasic".
Click Pen Width menu and change the pen width. Click Pen Color menu and select pen color. Click Brush Color menu and select brush color.
Click Rectangle, Ellipse, Triangle or Line menu and drag on the window to draw these shapes. Created shapes can be re-sized or rotated to drag one of the pinches on the shape. Click twice on the menu to add shapes consecutively.
Select a shape and click Cut menu to cut the shape, Copy menu to copy the shape. After cut or copy, click Paste menu to paste the shape. Cut and Paste will change the shape z-order also.
Click Save menu to save shapes to a Small Basic file. On the textbox on Save popup window, push Ctrl+A and Ctrl+C to copy the source code, paste it to Small Basic IDE or your text editor and save it as a Small Basic program.
Click Open menu to read shapes from saved file. On the textbox on Open popup window, enter filename of the saved shapes program.
Following tools are for Shapes.
Following list shows typical versions of Shapes editor.
[*] A part if this program is published as GTV460. This part outputs move and rotation code. You can insert GTV460 in WriteShapes subroutine if you need.
[**] A part if this program is published as GTV460-0. This part outputs move and rotation code. You can insert GTV460-0 in WriteShapes subroutine if you need.
Following list shows known issues of Shapes 1.5b.
Very cool, Nonki! I did a blog post on this. It's an amazing app you made!
Thanks Ed, I added link to your blog post.
This is amazing Nonki.Really informative sample. Looks like all native SB. Big program, 2465 lines. There are things in here that I want to learn, e.g. in the save file pop-up the right click menu appears. And this interesting line:
"If silverlight And Text.IsSubText("tri|line", shape[i]["func"]) Then".
You show what SB can do. A lot. It's always worth checking out your code. Thanks
Congratulations on winning the gold medal! blogs.technet.com/.../technet-guru-awards-july-2013.aspx
This article was also featured on the Small Basic blog here: blogs.msdn.com/.../nonki-takahashi-s-shapes-editor-small-basic-guru-for-july.aspx
And finally it was featured on the home page of TechNet Wiki!