michael@cadilhac.name (Michaël Cadilhac) writes: > Hi guys, long time no see ! > > Indentation in the METAPOST mode has, IMO, two major flaws : > > 1. A bug. If the buffer starts with beginfig, the contents of the figure > is not properly indented (it stays on the first column). > > 2. When wrapping an expression on several lines, the indentation is the > same for each line, this is bad style : I'd prefer > > beginfig(1) > draw (0,0)--(1,2)--(10,3)-- > (0,1)--(10,3); > draw (2,2); > endfig > > I propose the following patch which considers that keywords like > beginfig does not need ending semicolon (it's /quite/ the case). > > Tell me if it's worth installing it. Please consider this extended version. It uses a complete other way to deal with the indentation which suffers from less flaws. It still has the following, however, with grouping : draw begingraph(3cm,2cm) setrange(whatever, 0, whatever, whatever); gdraw "data1"; other-instruction; endgraph; This is not that bad however. I've tested it with the 305 examples of http://tex.loria.fr/prod-graph/zoonekynd/metapost/metapost.html with great result.