diff --git a/src/modal.c b/src/modal.c index 77ea3c8..6d34bdc 100644 --- a/src/modal.c +++ b/src/modal.c @@ -65,10 +65,22 @@ put_reg(char r) for(i = 0; i < depth; i++) *dst_++ = ')'; } - } else if(r == '.') { /* unpack */ + } else if(r == '.') { /* special unpack */ if(*s == '(') s++, --ss; while(s < ss) *dst_++ = *s++; + } else if(r == '^') { /* special align */ + int i, depth = 0; + s++; + while(s < ss) { + *dst_++ = '('; + while((c = *s) && !spacer(c)) + *dst_++ = c, s++; + if(s < ss - 1) *dst_++ = ' '; + s++, depth++; + } + for(i = 0; i < depth; i++) + *dst_++ = ')'; } else if(r == ':') { /* special stdout */ if(*s == '(') s++, --ss; while(s < ss) {