• Login
Community
  • Login

Managing session with a lot of open files

Scheduled Pinned Locked Moved General Discussion
tabssessionsession manager
17 Posts 3 Posters 1.1k Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D
    dz15mlru
    last edited by Feb 7, 2022, 10:44 AM

    I have a lot of open files, over 200 up to 300
    https://imgur.com/piZFWaM
    And they - only file names - covers almost all my display, leaving little space to view the file content.
    How can I deal with them, how to hide/unhide open files tabs panel, without closing them?
    I really need to keep them open and unsaved, so closing them is not a sollution.

    A D 2 Replies Last reply Feb 7, 2022, 12:56 PM Reply Quote 0
    • A
      Alan Kilborn @dz15mlru
      last edited by Feb 7, 2022, 12:56 PM

      @dz15mlru said in Managing session with a lot of open files:

      How can I deal with them, how to hide/unhide open files tabs panel

      Hide the tab bar entirely or turn off multiline:

      277fb5c2-2a59-432d-af90-5144092104f8-image.png

      Not sure how one deals with so many tabs mentally, but…if you can do it then good for you.

      @dz15mlru said in Managing session with a lot of open files:

      I really need to keep them open and unsaved

      IMO this is just asking for trouble, if you care about the data.

      D 1 Reply Last reply Feb 7, 2022, 5:20 PM Reply Quote 3
      • D
        dz15mlru @Alan Kilborn
        last edited by Feb 7, 2022, 5:20 PM

        @alan-kilborn Mm. Thx. Probably useful options, but not for me. I need the multi-line enabled. If hiding the tab bar, I’ll need a hot key to easily toggle -show/hide the tab bar. Now I know what I need )
        Is there such a hot key, or should I request one?

        P A 2 Replies Last reply Feb 7, 2022, 5:47 PM Reply Quote 0
        • P
          PeterJones @dz15mlru
          last edited by Feb 7, 2022, 5:47 PM

          @dz15mlru ,

          You could hide the tab bar through the option once, and assign a keyboard shortcut to the View > Document List , which gives an alternate method of navigating all the tabs you have open.

          a013cdf3-9385-485a-a3e8-b0e611c6ef88-image.png

          D 1 Reply Last reply Feb 7, 2022, 8:10 PM Reply Quote 4
          • A
            Alan Kilborn
            last edited by Feb 7, 2022, 5:58 PM

            Also, if you use the PythonScript plugin, there are a couple of commands that could be tied to custom keycombos:

            notepad.hideTabBar()
            notepad.showTabBar()

            Rather than burn two available keycombos, you could write a script that will toggle, but there’s no corresponding .isTabBarVisible() function. :-(

            However, you could call showTabBar in startup.py and then have a toggling script that could internally keep track of the state.

            1 Reply Last reply Reply Quote 4
            • A
              Alan Kilborn @dz15mlru
              last edited by Feb 7, 2022, 6:38 PM

              @dz15mlru said in Managing session with a lot of open files:

              Is there such a hot key, or should I request one?

              Apparently, you requested one:

              https://github.com/notepad-plus-plus/notepad-plus-plus/issues/11145

              A 1 Reply Last reply Feb 7, 2022, 6:52 PM Reply Quote 3
              • A
                Alan Kilborn @Alan Kilborn
                last edited by Feb 7, 2022, 6:52 PM

                Here’s a PythonScript called TabBarVisibilityToggle.py that will (somewhat obviously) toggle the visibility of the tab bar with each run of the script. I tied it to the single hotkey suggestion of Ctrl+Alt+Shift+t.

                As indicated before, the startup state of N++ doesn’t know if the tab bar is showing or hiding, so I default to showing it with this single line in startup.py : notepad.showTabBar()

                So here’s the script:

                # -*- coding: utf-8 -*-
                from __future__ import print_function
                
                from Npp import *
                
                #-------------------------------------------------------------------------------
                
                class TBVT(object):
                
                    def __init__(self):
                        self.tab_bar_visible = True
                
                    def run(self):
                        self.tab_bar_visible = not self.tab_bar_visible
                        notepad.showTabBar() if self.tab_bar_visible else notepad.hideTabBar()
                
                #-------------------------------------------------------------------------------
                
                if __name__ == '__main__':
                    try:
                        tbvt
                    except NameError:
                        tbvt = TBVT()
                    tbvt.run()
                
                D 1 Reply Last reply Feb 7, 2022, 8:03 PM Reply Quote 3
                • D
                  dz15mlru @Alan Kilborn
                  last edited by Feb 7, 2022, 8:03 PM

                  @alan-kilborn said in Managing session with a lot of open files:

                  Also, if you use the PythonScript plugin[…]

                  I am not really into these plugins with user scripts.
                  Thanks for you efforts!
                  Tried to do it.
                  Added notepad.showTabBar() in startup.py
                  Created a new script with your code.
                  Can’t find how to assign hotkey to a script?
                  Now it works from menu’s script button.

                  A 1 Reply Last reply Feb 7, 2022, 8:10 PM Reply Quote 0
                  • D
                    dz15mlru @PeterJones
                    last edited by Feb 7, 2022, 8:10 PM

                    @peterjones
                    Oh, I’ve forgot about Document List mode. Thanks for suggestion.

                    I’ll stick to this variation for a while:
                    Show tab bar in single line and enable Document List mode.
                    Not really what I wanted; I’ll wait for the reqested hot key.

                    A 1 Reply Last reply Feb 7, 2022, 8:11 PM Reply Quote 0
                    • A
                      Alan Kilborn @dz15mlru
                      last edited by Feb 7, 2022, 8:10 PM

                      @dz15mlru said in Managing session with a lot of open files:

                      Can’t find how to assign hotkey to a script?

                      There’s a nice demo of how to do that HERE.
                      At least I call it nice because I wrote it. :-)

                      D 1 Reply Last reply Feb 7, 2022, 8:16 PM Reply Quote 0
                      • A
                        Alan Kilborn @dz15mlru
                        last edited by Feb 7, 2022, 8:11 PM

                        @dz15mlru said in Managing session with a lot of open files:

                        I’ll wait for the reqested hot key.

                        Not all requests are fulfilled.
                        Typically devs will see issues that can be solved by plugins and they let that solution ride.
                        So…

                        1 Reply Last reply Reply Quote 1
                        • D
                          dz15mlru @dz15mlru
                          last edited by Feb 7, 2022, 8:14 PM

                          @dz15mlru said in Managing session with a lot of open files:

                          I have a lot of open files, over 200 up to 300[…]

                          Session.xml says that actually there are 340+ open tabs ))

                          1 Reply Last reply Reply Quote 0
                          • D
                            dz15mlru
                            last edited by Feb 7, 2022, 8:14 PM

                            @alan-kilborn said in Managing session with a lot of open files:

                            Apparently, you requested one:
                            https://github.com/notepad-plus-plus/notepad-plus-plus/issues/11145

                            Yes.
                            Waiting, maybe it will be implemented soon.

                            A 1 Reply Last reply Feb 7, 2022, 8:16 PM Reply Quote 0
                            • A
                              Alan Kilborn @dz15mlru
                              last edited by Feb 7, 2022, 8:16 PM

                              @dz15mlru said in Managing session with a lot of open files:

                              Waiting, maybe it will be implemented soon.

                              I take it you are new to this. ;-)
                              Good luck.

                              1 Reply Last reply Reply Quote 1
                              • D
                                dz15mlru @Alan Kilborn
                                last edited by Feb 7, 2022, 8:16 PM

                                @alan-kilborn said in Managing session with a lot of open files:

                                There’s a nice demo of how to do that HERE.

                                Can you check the link pls? It’s broken.

                                A 1 Reply Last reply Feb 7, 2022, 8:17 PM Reply Quote 0
                                • A
                                  Alan Kilborn @dz15mlru
                                  last edited by Feb 7, 2022, 8:17 PM

                                  @dz15mlru said in Managing session with a lot of open files:

                                  Can you check the link pls? It’s broken.

                                  So it is. Try THIS instead.

                                  D 1 Reply Last reply Feb 7, 2022, 8:23 PM Reply Quote 2
                                  • D
                                    dz15mlru @Alan Kilborn
                                    last edited by Feb 7, 2022, 8:23 PM

                                    @alan-kilborn Thank you! I’ve succeeded. It works fine!
                                    Great job!

                                    1 Reply Last reply Reply Quote 2
                                    • TeasyT Teasy referenced this topic on May 18, 2024, 7:47 AM
                                    1 out of 17
                                    • First post
                                      1/17
                                      Last post
                                    The Community of users of the Notepad++ text editor.
                                    Powered by NodeBB | Contributors