• How to Navigate to a Parent Directory in the Folder as Workspace

    2
    0 Votes
    2 Posts
    199 Views
    PeterJonesP

    @Bernard ,

    Folder as Workspace (“FaW”) uses the Folder you choose as the Workspace as the root/top-level of what it display. You cannot use it to navigate “above” that root.

    If you want generic directory navigation through a panel similar to the FaW, what you probably want is the Explorer plugin (available to install through Plugins > Plugins Admin interface), which allows you to navigate to any directory in your filesystem, rather than using a fixed folder as the root of what you see in FaW.

  • Add text to end of line

    5
    0 Votes
    5 Posts
    520 Views
    DoğancanD

    @PeterJones Now I understand. I can edit the code you gave. So much detail is unnecessary for me.

  • Help - Remove a line from a specific text but keep a part of the text

    10
    0 Votes
    10 Posts
    2k Views
    L ML

    @PeterJones Thanks it’s working now.

    I also figured out some occurences had only the CR from this answer:
    https://community.notepad-plus-plus.org/post/17010

    And could modify as this to accomodate:
    Find: \r(\sIV,)
    Replace: ($1)

  • Let Comment Flags Keep Aligned

    2
    0 Votes
    2 Posts
    204 Views
    TBugReporterT

    Here’s what I do for this. Add this to the <Macros> section of your shortcuts.xml file:

    <Macro name="Col. 1 Remark" Ctrl="yes" Alt="yes" Shift="no" Key="75"> <Action type="0" message="2349" wParam="0" lParam="0" sParam="" /> <Action type="1" message="2170" wParam="0" lParam="0" sParam="REM " /> </Macro>

    Key 75 is the letter K, so this adds a Ctrl-Alt-K keystroke to your configuration (you said Ctrl-Q, but my solution isn’t a toggle like that keystroke; if you want Ctrl-Alt-Q, change 75 to 81); message 2349 says to go to the beginning of the line (unconditionally, i.e. not just the beginning of the text on the line); and message 2170 says to type the given text - REM and a space (the forum won’t let me show the space in red here). If you edit other types of files this way, you can change to the comment string for whatever language you’re using, and assign a different key for that one.

  • My save notepad is all gone and removed, Help me restore

    2
  • How to remove first 50 lines on each files using NOTEPAD PLUS

    2
    0 Votes
    2 Posts
    675 Views
    Alan KilbornA

    @N-O

    1 - find: (?-s)(?:.*\R){50}(?s)(.*) / repl: ${1} / mode: regular expression / (note: other ways to do it certainly possible)

    2 - find: (?-s)(.*\R){50}\z / repl: nothing / mode: regular expression / (note: other ways to do it certainly possible)

    3 - not currently possible to do in one action

    (4) - you’d have to ask for it in a feature request; see HERE for a description of the process

    note: 1 and 2 could be written so that it was a single operation accomplishing both – I did not do that

  • improve SCI_LINEDELETE shortcut

    27
    1 Votes
    27 Posts
    3k Views
    Victorel PetrovichV

    @Alan-Kilborn said in improve SCI_LINEDELETE shortcut:

    The “caret by itself” situation is handled to delete its line. Just not “caret by itself on an otherwise non-selected line”.

    I prefer less exceptions; but to each his own.
    Indeed, scripting solves the differences.

    @Alan-Kilborn said in improve SCI_LINEDELETE shortcut:

    Please tell me you aren’t prototyping a Scintilla patch using these scripts you’ve submitted in this thread. Such a patch should be much simpler than that.

    I know.

  • Bold Question

    3
  • Opening file with command line in an existing instance

    3
    0 Votes
    3 Posts
    1k Views
    E

    @PeterJones Oh my gosh, that’s all I needed. Thank you so much, I made batch file also, it makes me so comfortable.

  • after update: shortcut &N lost in rightclick menu

    3
    0 Votes
    3 Posts
    324 Views
    cschardtC

    @PeterJones
    perfect, thanks!

  • No Folder as Work-Space

    4
    0 Votes
    4 Posts
    398 Views
    BernardB

    @Alan-Kilborn thank you kindly . i was wondering how NP++ would decide what folder to display . thank you again

  • replace all text in a bracket

    8
    0 Votes
    8 Posts
    2k Views
    Terry RT

    @daniel-Louwrens said in replace all text in a bracket:

    I tried a find and replace using the exact chars you suggested but
    the program showed 0 replaced.

    Did you set the search mode to regular expression?

    If that isn’t the issue then you need to provide the examples via the requested method. Follow that post I referred to, otherwise you are just wasting people’s time on this forum (who do want to help).

    Terry

  • replace in txtFile with mixed Codepage letters utf8 and ANSI

    3
    0 Votes
    3 Posts
    584 Views
    Rainer KlinglerR

    @PeterJones Thank you very much - it works! But you must be careful after some replaces exists new “wrong” Chars in ANSI view with the possibility of also not wanted newly replacements … so the replace all button is dangerous…

  • Files open twice

    17
    0 Votes
    17 Posts
    2k Views
    CoisesC

    @Coises said in Files open twice:

    I’ve opened an issue for this: Symbolic links and hard links can result in the same physical file being open in multiple tabs.

    It seems the matter is not as straightforward as it appeared to me. At least one person strongly disapproves of changing the current behavior at all.

    I don’t really use symlinks. If some of you do, and have clear ideas about how they should work — whether they should resolve to the target name, like a shortcut, or remain as their own name in their own directory, like a hard link — you might be able to contribute to the discussion at the link above.

    Three notes:

    I offered a pull request along with the issue, but another user (the same one who objects to changing anything) discovered an important flaw. While that’s mixed up in the discussion, it’s really a separate issue from what should happen. If we reach a consensus on what should happen, I’m sure there will be a way to fix the flaw (which causes symlinks with a relative path to fail completely).

    As things are, File|Open and double-click in Explorer behave differently than opening from the command line and right-click|Open with Notepad++ in Explorer. I see no way to change the File|Open and double-click behavior, because Windows is resolving the symlink in those cases before Notepad++ ever sees it. As far as I can tell, the person who doesn’t want things changed believes the other behavior is “correct,” and doesn’t care that the behavior in some cases doesn’t match. Honestly, the more I look at the way different programs behave, the more it seems to me there is no consistency regarding this in Windows. I’m not sure if that’s an argument for letting the chips fall where they may, or if Notepad++ should still at least be consistent with itself.

    Though I now think I was unwise to do so, I combined two distinct issues: opening symlinks in particular, and avoiding opening the same file by two separate names (which affects both symlinks and hardlinks). The latter is the one more directly relevant to the original complaint in this thread. The fix for that appears straightforward and is independent of the flaw that caused a problem with my pull request. (My solution just activates the tab holding a file which is already open, regardless of whether you’re trying to open it under a different name.) However, the user who does not want anything changed apparently does not want Notepad++ to suppress opening the same file under two different names either.

  • 0 Votes
    5 Posts
    391 Views
    BenLaKnetB

    @Alan-Kilborn OK many thanks, I understand the differences.

  • Is there a way to Hightlight Partial Search Results?

    3
    0 Votes
    3 Posts
    293 Views
    Cr8zy_IvanC

    @Coises Oh man! That’s so Awesome. Thank you!

  • nested keywords

    3
    0 Votes
    3 Posts
    283 Views
    Junior MaihJ

    @mkupper
    Thank you so much for the reply. Your suggestion works for another instance (!else and !elseif) but not in the case I mentioned because I also use !end in the “Folding in code 1 style”. I have even removed !end from the list of keywords but it does not help.

    Thanks again for taking the time to reply!

  • How to set characters colors at Compare Plugin

    3
    0 Votes
    3 Posts
    655 Views
    R D MR

    @PeterJones said in How to set characters colors at Compare Plugin:

    I would suggest you change the background colors (which can be set in the Plugins > Compare/ComparePlus > Settings dialog) to darker highlights… maybe a dark green, dark purple, dark navy, dark brown, dark orange, rather than the default light versions of those colors.

    Done, thanks!

  • Need to, in steps, copy/cut/paste

    4
    0 Votes
    4 Posts
    440 Views
    PeterJonesP

    @Bertil-Wallman said in Need to, in steps, copy/cut/paste:

    @PeterJones
    Hi Peter…

    (?-s)^nid (".“)\r\nnstr “”* didn’t work for me, so i tried it bit by bit and this > (?-s)^nid (".”)\nnstr “”* worked much better.

    Notepad++ is a Windows text editor, so assuming Windows line endings is natural, and works for the majority of the people; if you had mentioned that you were using Linux line endings, I would have customized the expression for your actual data.

    That instruction… "initial = 1, increase = ``, leading = none… the increase part didn’t work for me either, the box didn’t allow me to add those characters,

    That was a typo on my part. It should have said “increase = 1” – I just missed the 1 in between the ` characters for trying to make the 1 red like 1 .

    And that \bnstr \b didn’t work too, so i removed the last \b then i was back on track. :)

    There was no space between the str and the \b in my example. In my testing, I literally used \bnstr\b and it worked. If you used \bnstr \b, it would not work, because the next character after the space is a " , and between the space and the quote mark is not a word-boundary.

    But i had some other problems with the file to deal with first, …

    Glad you figured it out.

  • start and end issues

    6
    0 Votes
    6 Posts
    587 Views
    mkupperM

    @PeterJones I think the OP has disappeared but a tool that will go through the list of possible startup locations like those you mentioned is Autoruns from Microsoft’s Sysinternals team.

    Autoruns is mildly clunky but works. You start it, ideally as an administrator, and watch the status line in the lower left corner. Once it’s done scanning it’ll say “Ready.” Type Noptepad++ and you will see the various places in Windows that are set up to start or run Notepad++. There is a checkbox on the left side that you can use to disable entries.

    Autoruns is handy as it both seems to be a complete check of the various ways an application could get started and the enable/disable checkboxes allow you to easily re-enable something meaning a person can disable/enable blocks of things that could be causing the problem they are trying to track down.