> 3) indent/outdent region or selected area.
Here is a deindent block function that may be of help.
sub deindent_block (d) {
if (d.txt.mark == NULL) {
mp.move(d, mp.move_bol);
mp.delete_char (d);
return (NULL);
}
local currentY = d.txt.y;
mp.set_y (d, d.txt.mark.by);
while (d.txt.y < d.txt.mark.ey) {
mp.move(d, mp.move_bol);
mp.delete_char (d);
mp.move(d, mp.move_down);
}
mp.set_y (d, currentY);
}
mp.actions['deindent_block'] = deindent_block;
mp.actdesc['deindent_block'] = "Deindent block";
Jeremy Cowgar
-- To unsubscribe, send mail to mp-unsubscribe_at_lists.triptico.com.Received on Mon Jul 21 2008 - 08:37:48 CEST
This archive was generated by hypermail 2.2.0 : Mon Jul 21 2008 - 09:16:47 CEST