SlickEdit Community

SlickEdit Product Discussion => SlickEdit® => Features and/or Improvements => Topic started by: fhlbrep on November 01, 2018, 04:35:43 pm

Title: Dockable Notes Window
Post by: fhlbrep on November 01, 2018, 04:35:43 pm
I created a very simple form with an edit control to allow me to write a few temporary notes, copy code snippets or whatever while I am working. Have not gone as far as saving/reloading them (yet?). I could easily keep a text doc open among the other source files, but I really don't like doing that. It just gets lost among the many other files I open. And having to open win notepad is not what I am after either.

I was thinking it would be nice if there were a dockable Notes window like Search Results, Build, Message List (etc.) that I could just keep a few notes to refer back to as I am working. Also, I am not talking about a todo list. That is a different thing. With a dockable/floating window I could group it below with the others like i do now and allow it to auto-hide/pin it whenever I needed it.

I am open to suggestions as to how to create a custom one using slick-C if that is possible. I have written several macros over the years. While not an expert I am comfortable with it.
Title: Re: Dockable Notes Window
Post by: Dennis on November 01, 2018, 06:03:28 pm
Have you tried the Annotations tool window ?
Title: Re: Dockable Notes Window
Post by: Graeme on November 02, 2018, 10:30:49 am
It's not hard to make your form dockable.
Here's part of my xretrace scrollbar form.  TWF_SUPPORTS_MULTIPLE means you can have more than one of these active at a time.

In the macros that I posted here there is xnotepad and xtemp-file-manager which are kind of related to what you're looking for.,16598.0.html (,16598.0.html)
You could use a timer to automatically save your notes to a file.

Code: [Select]
   tw_register_form('xretrace_scrollbar_form', TWF_SUPPORTS_MULTIPLE, DOCKAREAPOS_NONE); 

_form xretrace_scrollbar_form {
   p_caption="xretrace scrollbar";
   _list_box ctllist1 {

Title: Re: Dockable Notes Window
Post by: fhlbrep on November 02, 2018, 06:04:15 pm
Yes Dennis - I looked at that and others. They serve a different purpose and not quite what I am looking for. What I want is essentially a buffer window to take a few notes, jot down ideas, a code snippet or two, anything. And (the important part) dock it with the other tool windows.
I could easily open a text file and float that tab as a separate window, but that takes up more real estate on the screen (which is where I was going with the custom form but had not figured out the docking part yet). In my layout I have several tool windows grouped at the bottom of the editor with auto hide and refer to them as needed. I would like this notes window to be there as well. I do not need to see it all the time, but having it would be quite handy. I thank you for the suggestion though.

Thank you also Graeme. I will definitely give xnotepad.e a look over and I like the timer suggestion. Will post back when I have a chance to look at it and see if it will work for me. I appreciate the quick responses.
Title: Re: Dockable Notes Window
Post by: Graeme on November 04, 2018, 10:33:00 am
Here's a suggestion.  In xxutils.e there are some commands called xfloat1, xfloat2, xfloat3.  They open the current edit buffer in a floating edit window.  You can pre-set the size and position of the window using the commands xset_float1 etc.  The macro below opens a specific file in a floating edit window of the size and location that you previously selected.

Code: [Select]
_command show_notes() name_info(','VSARG2_MARK)