diff options
author | Luke Iannini <lukeiannini@users.sourceforge.net> | 2009-06-27 03:28:52 +0000 |
---|---|---|
committer | Luke Iannini <lukeiannini@users.sourceforge.net> | 2009-06-27 03:28:52 +0000 |
commit | a0372472d4edd03cffdfb4abf1fd2d562a3fd4d1 (patch) | |
tree | 862c9766942d9abf36b9e93727b79fc4a4c6f67d /experimental/meta-align-top2leftmost.pd | |
parent | 13aad8460777c1897b5ddadb616df6b794a0ddf4 (diff) |
added some experimental alignment abstractions based on canvasobjectposition:
*meta-align-grid takes an optional gridsize argument (defaults to 10), and aligns all selected objects to the closest multiple of that gridsize (i.e. an object at 16 32 will be placed at 20 30 with the default gridsize of 10)
*meta-align-top2leftmost and -left2topmost sort objects left-to-right or top-to-bottom and then line up their topmost or leftmost edges, respectively
svn path=/trunk/abstractions/meta-abs/; revision=11822
Diffstat (limited to 'experimental/meta-align-top2leftmost.pd')
-rw-r--r-- | experimental/meta-align-top2leftmost.pd | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/experimental/meta-align-top2leftmost.pd b/experimental/meta-align-top2leftmost.pd new file mode 100644 index 0000000..9e0f1a7 --- /dev/null +++ b/experimental/meta-align-top2leftmost.pd @@ -0,0 +1,67 @@ +#N canvas 0 22 436 680 10; +#X obj 79 170 sort; +#X obj 154 160 unpack f f; +#X obj 100 273 list split 1; +#X obj 100 316 s \$0-key_object; +#X obj 134 295 s \$0-sub_objects; +#X obj 79 136 list-map; +#X obj 100 351 r \$0-key_object; +#X obj 121 473 r \$0-sub_objects; +#X obj 100 415 unpack f f; +#X obj 154 139 canvasobjectposition 1; +#X obj 79 63 canvasselect 1; +#X obj 100 393 canvasobjectposition 1; +#X obj 100 594 unpack f f; +#X obj 100 572 canvasobjectposition 1; +#X obj 100 445 t b a; +#X obj 100 494 list; +#X obj 100 519 list-drip; +#X obj 154 117 t b a; +#X obj 100 372 t b a; +#X obj 100 542 t b a; +#X obj 55 597 t a; +#X obj 100 620 list append; +#X obj 79 34 inlet; +#X obj 100 214 list-map; +#X obj 177 243 list-idx; +#X obj 177 194 t b a; +#X obj 177 218 list; +#X obj 209 218 r \$0-selected_objects; +#X obj 79 83 t a a; +#X obj 118 83 s \$0-selected_objects; +#X connect 0 1 23 0; +#X connect 1 0 5 1; +#X connect 2 0 3 0; +#X connect 2 1 4 0; +#X connect 5 0 0 0; +#X connect 5 1 17 0; +#X connect 6 0 18 0; +#X connect 7 0 15 1; +#X connect 8 1 14 0; +#X connect 9 0 1 0; +#X connect 10 0 28 0; +#X connect 11 0 8 0; +#X connect 12 0 21 0; +#X connect 13 0 12 0; +#X connect 14 0 15 0; +#X connect 14 1 21 1; +#X connect 15 0 16 0; +#X connect 16 0 19 0; +#X connect 17 0 9 0; +#X connect 17 1 9 1; +#X connect 18 0 11 0; +#X connect 18 1 11 1; +#X connect 19 0 13 0; +#X connect 19 1 13 1; +#X connect 20 0 13 0; +#X connect 21 0 20 0; +#X connect 22 0 10 0; +#X connect 23 0 2 0; +#X connect 23 1 25 0; +#X connect 24 0 23 1; +#X connect 25 0 26 0; +#X connect 25 1 24 1; +#X connect 26 0 24 0; +#X connect 27 0 26 1; +#X connect 28 0 5 0; +#X connect 28 1 29 0; |