Author Topic: Selective display using text markers?  (Read 4021 times)

drisner

  • Community Member
  • Posts: 15
  • Hero Points: 2
Selective display using text markers?
« on: September 02, 2006, 06:30:47 pm »
Many editors can use markers in the text for the selective display.  Most of the time this is done with three open braces to start the "fold" and three closed braces to end the "fold".  That is something like this:

function blah(p) { /*{{{*/
  Some stuff to be folded/hidden.
} /*}}}*/

Would fold down to:

function blah(p) {

Is there some way to get Slickedit to do this type of folding?

Thank you.

Magnus

  • Community Member
  • Posts: 5
  • Hero Points: 0
Re: Selective display using text markers?
« Reply #1 on: January 18, 2007, 11:37:04 am »
Yes, you can make foldings like you suggest with SlickEdit if you make some changes in the seldisp.e macro. There is a function called hide_block_regions with arguments for begin tag and end tag. The arguments could only be sent as normal string, with no regular expressions so I copied hide_block_regions and made some changes so it uses regular expression and it works fine for me.

hs2

  • Senior Community Member
  • Posts: 2754
  • Hero Points: 291
Re: Selective display using text markers?
« Reply #2 on: January 18, 2007, 12:20:08 pm »
See also http://community.slickedit.com/index.php?topic=878.0.
@Magnus: The patch I described is probably similar to your modifications. I hope it will be implemented in the product to avoid this kind of derived macros...

HS2