Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!sun-barr!newstop!sun!pepper!cmcmanis From: cmcmanis%pepper@Sun.COM (Chuck McManis) Newsgroups: comp.sys.amiga Subject: Re: Looking for editor which hides lines indented more than x levels Summary: Not to easy but doable Message-ID: <125967@sun.Eng.Sun.COM> Date: 6 Oct 89 23:26:24 GMT References: <785@lpami.wimsey.bc.ca> <3476@stsusa.com> Sender: news@sun.Eng.Sun.COM Reply-To: cmcmanis@sun.UUCP (Chuck McManis) Organization: Sun Microsystems, Mountain View Lines: 34 In <3909@blake.acs.washington.edu>, (Dale Larson) writes: > I would like to find an editor which will allow me to look at just the > top level routines in a program by hiding lines with more than a certain > number of tabs at the begining. In article <3476@stsusa.com> jellson@stsusa.com writes: >XEDIT on IBM mainframes had the ability to selectively hide lines. Then with >the aid of REXX you could write macros to hide lines according to any criterea >you liked, such as indentation. I got a similar response to my announcement of a beta MicroEMACS and looked into this kind of thing for emacs. I wouldn't be to tough, except that it touches almost *everything* in the display/file routines. The easiest (??) way to do it seems to be to modify the LINE structure such that it has a "visible" attribute and then modify the display routine appropriately so that instead of a line is displays something like : <<<< Excluded Text >>>> and of course all of the line movement routines have to be updated so that they jump over excluded lines, and one probably wants two flags one for making lines invisible and the other for forcing them to be visible temporarily. The second comment about using REXX to pick which lines are excluded is an excellent one. One might also want to add a bunch of uemacs commands such as exclude-line, exclude-region, and unexclude-line/region. Some policy questions come up to, what happens if you are asked to go to an excluded line? Do you force it to be visible ? And is there a move-down-exactly-one-line such that you can move into an excluded region and unexclude lines one at a time? XEDIT has these wonderful little mode bits in the right hand column, which emacs doesn't have a parallel for. Any discussion would be enlightening for sure. --Chuck McManis uucp: {anywhere}!sun!cmcmanis BIX: cmcmanis ARPAnet: cmcmanis@sun.com These opinions are my own and no one elses, but you knew that didn't you. "If I were driving a Macintosh, I'd have to stop before I could turn the wheel."