Community
    • Login

    Feature request: separate tabs for "Find in Files" and "Replace in Files"

    Scheduled Pinned Locked Moved General Discussion
    12 Posts 5 Posters 3.5k 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.
    • Scott SumnerS
      Scott Sumner @Nicholas Moses
      last edited by

      @Nicholas-Moses

      Your logic is totally invalid, and here’s why: Replace in Files has an Are You Sure? confirmation popup. Any “accidental” Replace data destruction when you really meant Find is totally on you–because you had to say “OK” to the confirmation (…thinking about it maybe “OK” and “Cancel” here would be better as “Yes” and “No”…at least “Cancel” is the default choice…but this is another matter…).

      That being said, your desire to have 2 separate tabs for Find in Files and Replace in Files is okay. I don’t see the need for it, but I respect that you want it that way. :-)

      1 Reply Last reply Reply Quote 0
      • Nicholas MosesN
        Nicholas Moses
        last edited by

        @Scott Sumner

        Thank you for your reply. That is useful and good information and in fact I will admit that I have never used “Replace in Files.” That does make me a little bit less paranoid about using the “Find in Files” feature.

        That said, I do think that two separate tabs would a more ergonomic choice, and safer still.

        1 Reply Last reply Reply Quote 1
        • David BainesD
          David Baines
          last edited by

          I would agree with Nicholas-Moses. The logic is perfectly valid whether or not there are extra safeguards in place.

          Scott SumnerS 1 Reply Last reply Reply Quote 0
          • Scott SumnerS
            Scott Sumner @David Baines
            last edited by

            @David-Baines

            The “invalid logic” part was about the assertion by @Nicholas-Moses that one could accidentally destroy data simply by pressing the wrong button (Replace in Files when one intended Find in Files). This data destruction simply can’t happen…because of the confirmation that must be made by the user for the replace command. Thus I stand by my original statement of “totally invalid logic”. And, BTW, @Nicholas-Moses seemed to agree with me after reading my explanation.

            Now if you, @David-Baines, meant to say that it is logical to have the file-based Find and Replace controls on separate tabs of the Find window family (without the qualifier about data loss), I’ve already stated that this personal-preference desire is fine. But my feeling is that this would be a worse user interface than the way it exists currently.

            1 Reply Last reply Reply Quote 0
            • David BainesD
              David Baines
              last edited by

              It seemed to me that Nicholas was offering some useful feedback about how he feels about an aspect of the design. He mentioned feeling ‘less paranoid’ knowing that there is a warning dialog that pops up.

              Personally I notice that I feel some anxiety when I’m using the Replace tab because of the ‘Replace All in All open documents’ button right next to the ‘Replace All’ button. There’s no warning dialog for that button. I’m aware that I could easily do a lot of damage to code if I’m not very careful, especially if any of the open documents have had work done on them that has not been saved. All that work could potentially be lost.

              The programmers give up lots of their time to develop N++ and make it available for free. So this isn’t meant to be critical of the program.

              Users that take the time to make comments like that are also giving up their time to provide potentially useful information to the developers.

              Scott SumnerS 1 Reply Last reply Reply Quote 2
              • Scott SumnerS
                Scott Sumner @David Baines
                last edited by

                @David-Baines said:

                It seemed to me that Nicholas was offering some useful feedback about how he feels about an aspect of the design

                Yes, and I acknowledged that, TWICE. :-)

                Users that take the time to make comments like that are also giving up their time to provide potentially useful information

                Yes, I ack that too. +1

                I feel some anxiety…

                Sorry for your anxious feelings. :)

                …because of the ‘Replace All in All open documents’ button right next to the ‘Replace All’ button…no warning dialog for that button

                YES! A VALID CONCERN! Maybe that button should have a confirmation as well.
                Reduce your anxiety somewhat, though, as the UNDO feature can fix an errant button press here. However, the UNDO would have to be done manually once per open document, and if one has a lot of open documents it could get rather annoying. But at that point it is a choice between annoying and not getting your original data back, so…

                1 Reply Last reply Reply Quote 0
                • guy038G
                  guy038
                  last edited by guy038

                  Hello, @david-baines, @scott-sumner and All,

                  David, I do agree with you, regarding a warning pop-up dialog when clicking on the Replace All in All opened documents button, of the Replace dialog. It could be identical to the dialog which occurs when clicking on the Replace in Files button, in the Find in Files dialog

                  Indeed, Scott, it would be sensible to add such a security level ! I, recently, did the same mistake, on more than 40 opened documents. Luckily, my search regex was restrictive enough and the replacement regex, a very specific string. So, only few files were modified ;-))

                  However, David, you can identify, easily enough, the files concerned by a wrong replacement : all the tabs of the modified files, opened in N++, should have, this time, a red file icon, instead of the blue colour !

                  Best Regards,

                  guy038

                  Scott SumnerS 1 Reply Last reply Reply Quote 0
                  • Scott SumnerS
                    Scott Sumner @guy038
                    last edited by

                    @guy038 said:

                    a red file icon, instead of the blue colour

                    Let’s just hope that just before an errant replacement, all files were saved! Otherwise, even trying to use the Undo feature on all open (red-tabbed) files is problematic! :-(

                    Now I am paranoid. For years I ignored the Replace All In All Open Documents button (don’t think I’ve ever used it, except maybe when a Community posting about it occurred and I wanted to test something out…). But NOW I am like a downhill skier, drawn inexorably and unexplainably toward that single tree in my field of view…I am going to accidentally press this button at the wrong time soon, I just know it…

                    1 Reply Last reply Reply Quote 1
                    • AZJIO AZJIOA
                      AZJIO AZJIO
                      last edited by

                      I suggest adding a checkbox with the ability to reserve changed files. In the settings, specify the path. A reservation creates a date and a path, for example 2018-02-03_12-45-31_C_ProgramData_NewFolder
                      Usually the size of text files is small, so this function will not be a problem

                      1 Reply Last reply Reply Quote 0
                      • guy038G
                        guy038
                        last edited by guy038

                        Hi, @scott-sumner,

                        But NOW I am like a downhill skier, drawn inexorably and unexplainably toward that single tree in my field of view…I am going to accidentally press this button at the wrong time soon, I just know it…

                        I do like your humour ! Regarding skiing, no problem ! Do not be paralysed and try the Parallel or Hockey Stop method ;-)) I do hope that you’ve got a ski helmet, just in case your speed is, still, above 0, when reaching that bloody tree !!

                        Now, regarding N++, may be a new feature, which would always keep the pointer outside the Replace All in All Opened Documents button ( so only accessible after numerous hits on the Tabulation key ! ) ? Of course, I’m joking.

                        Cheers,

                        guy038

                        1 Reply Last reply Reply Quote 1
                        • AZJIO AZJIOA
                          AZJIO AZJIO
                          last edited by

                          I adhere to the safety criterion:

                          1. Do not press what you do not know.
                          2. Before you press make a copy (always)
                          3. Allow yourself to test for things that do not have value
                          1 Reply Last reply Reply Quote 1
                          • First post
                            Last post
                          The Community of users of the Notepad++ text editor.
                          Powered by NodeBB | Contributors