Author Topic: region markers in defs tool window  (Read 1235 times)

IkerAriz

  • Senior Community Member
  • Posts: 162
  • Hero Points: 6
region markers in defs tool window
« on: August 25, 2024, 10:02:28 PM »
Any chance the Defs tool window - or perhaps a new type of tool window - could gain support for showing user-defined region markers/blocks? This would be very useful when working with large files that have multiple "logical" sections (and which cannot be split into smaller files for whatever reason). 

Iker

Graeme

  • Senior Community Member
  • Posts: 2817
  • Hero Points: 347
Re: region markers in defs tool window
« Reply #1 on: August 25, 2024, 11:47:04 PM »
You could set a bookmark at the start of each region and use the overview bar to go there quickly - in minifind you can set multiple bookmarks in one step.  Slick seems to have support for dotnet #region so maybe you can use that.  You can also write/record a macro to run a search from a single keystroke that brings up a list of them all.  It's also not especially hard to write your own toolwindow that showed a list of them all.

IkerAriz

  • Senior Community Member
  • Posts: 162
  • Hero Points: 6
Re: region markers in defs tool window
« Reply #2 on: August 26, 2024, 01:36:24 PM »
Hi Graeme. I gave bookmarks a good spin some years ago with your help (see here - thanks again) but in the end they didn't wear well.

Iker

Graeme

  • Senior Community Member
  • Posts: 2817
  • Hero Points: 347
Re: region markers in defs tool window
« Reply #3 on: August 26, 2024, 09:44:10 PM »
ok, is there any way you could trick the defs toolwindow into showing what you want.  If you right click in the defs window and select "others" there's a few mysterious things there.

Is running a search off a single keystroke and using search results not good enough?

I might be able to sketch up some slick C code for a toolwindow in the next couple of weeks that you can play with, if you can suggest how it would work.  It might be possible to change the defs toolwindow source code to show them too.