On Tue, 1 May 2007, James Buchanan wrote: > Hello, > > I'm writing some simple workbooks for kids in grades 1 to 10 to help > them with their math. I've worked with TeX and LaTeX for a while, until > I was attracted to ConTeXt for is nice colors and things like that. > > I need to know how to: > > * Draw simple number lines, color if possible, label the cm dots or > vertical lines, label the number line, fill in the numbers (or miss some > out), place it where I want it, and perhaps have the label in a > different color > > * Draw plane shapes like squares, rectangles, triangles and so on, just > 2-D plane shapes. Outline in some color, inside with another color. > Label them. Place them where I a want them. Sometimes I would like to > extend the lines to show that all exterior angles add up to 360 degrees, > things like that, and add in the arc and shade it in a different color.
Metapost or pstricks is the easiest way to draw such things. I would recommend metapost, as it is well integrated with Context. See http://melusine.eu.org/syracuse/metapost/cours/ for some examples of geometric figures using metapost. Also see http://wiki.contextgarden.net/Metapost http://wiki.contextgarden.net/MetaFun http://wiki.contextgarden.net/Mpgraphic The last page does not list \usempgraphic and \startMPcode ... \stopMPcode which are perhaps the easiest way to include MP figures. See the metafun manual for details. > When doing basic material like: > > Solve: > > 6 + 7 + 4 = [box] > > Have the equals signs and boxes lined up (or not), two sets of simple > add these numbers (or whatever) per column. The answer box could be > filled with a light color. This can be done easily using context's alignment mechanism. I am in a bit of a hurry right now, and will post an example later in the evening. > Is there a manual I should start with to learn how to do these things, > and develop my own macros? First I would just like to learn how to do > them, then gradually write my own macros. The material in my TeX Book > and my Guide to LaTeX series gives instruction in drawing but it quickly > progresses beyond my ability into 2-D shapes and so on. I understand > basic things like \move{} and lineto{} and \lvec{} but that's where I > get confused. Have a look at the metapost manual. If you think geometrically, then metapost is fairly easy to use. Aditya ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : [email protected] / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________
