Reply To: Tab interpretation vs Tab expand

Product Compare Forums Multi-Edit Support Tab interpretation vs Tab expand Reply To: Tab interpretation vs Tab expand

#6858
Clay Martin
Keymaster

I ran into this when creating EZRTools (for the SAS language). Given that many of our users would be working on code intended for the mainframe environment where there is a 72 character limit on a line’s length we did not want the indents eating up the available space. We decided that indent for line in a block (do … end) should be 2 chars. Since SAS lines are ended with a ; and given the 72 char limit we wanted to further distinguish continued lines with a 4 character indent. The only way to do this in Me was write a completely new indent macro. In the end this worked out ok as it allowed us to out-dent the close of the block structure automatically. This also offered us the ability to place a comment on the close of the block that id’ed what the start was (if, else, for, switch etc.).

Unfortunately this left the indent routine closely tied to the language. So a more generic indent routine that could examine a lexical description of a language in order to know what defined bocks of control structures and their start end clues would be a monster to write, fun yes, but a real hour eater.