#N struct drawtext-template float x float y float cat float dog symbol weasel text boom;
#N canvas 649 47 583 258 12;
#X text 19 217 see also:;
#X obj 37 12 drawnumber;
#X obj 178 216 plot;
#X obj 92 216 drawpolygon;
#X obj 37 36 drawsymbol;
#X obj 37 59 drawtext;
#N canvas 287 329 1025 391 drawtext-template 0;
#X obj 506 221 drawsymbol weasel 0 -30 0 weasel=;
#X text 40 133 - the field name to draw \; - an (x \, y) pair giving relative coordinates \; - RGB color (0=black \, 999=white \, 900=red \, 90=green \, 9=blue \, 555=grey \, etc.) \; - an optional label ("cat=" for instance).;
#X obj 38 290 drawnumber cat 0 0 0 cat=;
#X msg 38 238 1;
#X msg 71 238 0;
#X text 125 258 (if no -v [field name] flag was given);
#X text 515 78 In edit mode you can move \, cut \, copy and paste the objects., f 65;
#X text 53 327 Instead of float arguments to set color and position you can specify field names., f 53;
#X text 18 16 [drawnumber]/[drawsymbol]/[drawtext] take these arguments:;
#X obj 232 290 drawnumber dog 0 -15 900 dog\ =\ ;
#X obj 591 333 struct drawtext-template float x float y float cat float dog symbol weasel text boom, f 47;
#X text 39 42 - Optional flags:, f 54;
#X text 53 63 - "-n": make invisible initially \; - "-v [const or field name]": assign a variable to make this visible/invisible., f 57;
#X text 28 114 Arguments:;
#X text 550 264 This [sruct] object below defines the fields for this template. You can see them by right-clicking on the object in the "drawtext-data" window and selecting "properties.";
#X text 104 238 <-- inlet sets visibility (1: visible \, 0: invisible);
#X obj 762 221 drawtext -n boom 0 -45 0 boom=;
#X obj 762 190 tgl 19 0 empty empty empty 0 -10 0 12 #dfdfdf #000000 #000000 0 1;
#X text 786 189 <-- visibility;
#X text 515 12 When not in "edit" mode \, you can click and drag vertically on the numbers to change their values. Keyboard entry is also supported \, just click and type. Right click gives you properties where you can change values. Alternative you can use the [set] object., f 65;
#X text 515 102 Below we use [drawsymbol] and [drawtext] to draw \, respectively \, a symbol whose field name is 'weasel' and a text whose field name is 'boom'. You can't directly edit symbols/text though - they can only be changed through [set] and [text] objects \, respectively \, or via properties., f 65;
#X connect 3 0 2 0;
#X connect 4 0 2 0;
#X connect 17 0 16 0;
#X restore 401 125 pd drawtext-template;
#N canvas 179 45 455 265 drawtext-data 1;
#X scalar drawtext-template 63 167 13 0 symbol \; \;;
#X scalar drawtext-template 235 108 0 0 symbol \; \;;
#X restore 401 152 pd drawtext-data;
#X text 353 218 updated for Pd version 0.50.;
#X obj 216 216 set;
#X obj 8 91 cnv 1 570 1 empty empty empty 8 12 0 13 #000000 #000000 0;
#N canvas 483 115 573 351 reference 0;
#X obj 6 60 cnv 5 550 5 empty empty INLET: 8 18 0 13 #202020 #000000 0;
#X obj 6 103 cnv 2 550 2 empty empty OUTLETS: 8 12 0 13 #202020 #000000 0;
#X obj 6 137 cnv 2 550 2 empty empty ARGUMENTS: 8 12 0 13 #202020 #000000 0;
#X obj 5 321 cnv 5 550 5 empty empty empty 8 18 0 13 #202020 #000000 0;
#X text 112 75 float -;
#X text 143 113 NONE, f 54;
#X text 169 75 sets visibility (1: visible \, 0: invisible)., f 46;
#X obj 6 165 cnv 1 550 1 empty empty flags: 8 12 0 13 #9f9f9f #000000 0;
#X obj 6 213 cnv 1 550 1 empty empty args: 8 12 0 13 #9f9f9f #000000 0;
#X text 97 189 "-v" <symbol>: assigns a field to make it visible/invisible., f 63;
#X text 97 171 "-n": makes it invisible initially., f 63;
#X text 102 219 1) symbol -;
#X text 185 218 field name to draw., f 46;
#X text 101 272 4) symbol - optional label., f 58;
#X text 101 236 2) list* - (x \, y) coordinates pair (default 0 0)., f 58;
#X text 101 254 3) float* - color (default 0)., f 58;
#X text 131 294 * position and color can also be field names.;
#X obj 26 21 drawtext;
#X text 94 20 - draw numbers \, symbols or texts fields in a scalars.;
#X restore 397 33 pd reference;
#X text 495 34 <= click;
#X text 25 106 All these objects are actually aliases of the same class. There's no difference in them. Use them to draw either numbers \, symbols or texts fields., f 34;
#X obj 8 199 cnv 1 570 1 empty empty empty 8 12 0 13 #000000 #000000 0;
#X obj 250 216 get;
#X text 291 125 explanation -->;
#X text 125 23 - draw numbers \, symbols or texts fields in a scalar., f 26;
