• Merge multiple blank lines into a single blank line?

    Locked
    7
    0 Votes
    7 Posts
    3k Views
    guy038G

    Hello, @gabor-szakacs, @scott-sumner, and All,

    Indeed, Scott, I thought about capturing \R ! But, as my regex have two alternatives, when it matches \h+\R, the group 2 ( = \R ), in the first alternative does not exist. Thus, I need to capture \R in the second alternative, too ( group 3 )

    So :

    SEARCH (\h*(\R)){3,}|\h+(\R)

    REPLACE (?1\2\2:\3)

    And, of course, the conditional replacement rewrites :

    Two line-breaks \2\2, if the first alternative is found

    One line-break \3, if the second alternative is found

    However, to my mind, this second syntax does not look as elegant as my previous one ;-))

    Cheers,

    guy038

    BTW, my previous regex S/R may be slightly shortened as :

    SEARCH (\h*\R){3,}|\h+\R

    REPLACE \r\n?1\r\n ( or \n?1\n on UNIX files )

  • Text Search + Line Position

    Locked
    1
    0 Votes
    1 Posts
    467 Views
    No one has replied
  • sort file removing duplicates possible?

    75
    0 Votes
    75 Posts
    43k Views
    Vasile CarausV

    ^([A-Z])([a-z]+)\R(?i:\1)\2$

  • Monitor function seems a bit bugged

    Locked
    2
    0 Votes
    2 Posts
    712 Views
    NexusTheBronyN

    I just found a plugin that I assume enhances the Monitor function to always update every 3 seconds. Hope this fixes it (if this plugin works that does not mean the issue is resolved)

  • Last upgrade changed open file path

    4
    1 Votes
    4 Posts
    2k Views
    gitit1G

    Thank you! I’ve been looking for that solution

  • After the computer restarted, all the text in the notebook disappeared!

    Locked
    3
    1 Votes
    3 Posts
    779 Views
    Scott SumnerS

    @УменяМодем-ОграниченныйТрафик

    Or maybe see this FAQ which will not solve your issue and likely will make you sad…

  • I change the encoding sometimes the text disappears

    Locked
    2
    0 Votes
    2 Posts
    641 Views
    Claudia FrankC

    @УменяМодем-ОграниченныйТрафик

    can you replicate this? If so, can you post some sample text?

    Cheers
    Claudia

  • add new text in multiple files

    Locked
    11
    0 Votes
    11 Posts
    4k Views
    rajesh patilR

    it works ….thank you so much…

  • help with Oxygen Basic syntax definition

    Locked
    1
    0 Votes
    1 Posts
    523 Views
    No one has replied
  • multiple (highlight) languages in one file ((PHP +) HTML + CSS + JS)

    Locked
    2
    1 Votes
    2 Posts
    2k Views
    Claudia FrankC

    @Pete-Wright

    creating an UDL lexer for HTML, PHP, CSS and JavaScript is nearly impossible
    as you can’t specify when a new lexer needs to jump in.

    The lexer can be modified to support another lexer as seen
    in the code itself.

    I have no idea how complicated, in terms of lexing, css is, but in theory we could
    use python script plugin and indicators to do this.

    Cheers
    Claudia

  • Smart highlighting foreground color

    Locked
    10
    0 Votes
    10 Posts
    2k Views
    Claudia FrankC

    @dreamforceinc

    yes, but then you won’t have the rectangular anymore.
    You need to call it like SCI_INDICSETSTYLE(29, 17)
    17 = TEXTFORE
    and 29 you already know :-)

    Btw. this is the only way, I guess to use an bultin lexer and add additional syntax coloring.

    Cheers
    Claudia

  • Problem with C++

    Locked
    4
    0 Votes
    4 Posts
    2k Views
    Vitaliy DovganV
    Typing help npp_save

    in the NppExec Console says:

    COMMAND: npp_save USAGE: npp_save npp_save <file> DESCRIPTION: 1. Saves current file ("npp_save" without parameters) 2. Saves specified file if it's opened in Notepad++ (supports a partial file path/name) EXAMPLES: npp_save // saves current file npp_save $(#2) // saves 2nd file opened in Notepad++ npp_save txt // saves a first file which contains "txt" in its name SEE ALSO: npp_saveas, npp_saveall, npp_open Typing help cd

    in the NppExec Console says:

    COMMAND: cd USAGE: cd cd <relative_path> cd <absolute_path> DESCRIPTION: 1. Changes current directory ("cd" with parameters) 2. Shows current directory path ("cd" without parameters) EXAMPLES: cd // shows current directory path cd .. // go to up-directory cd \ // go to root-directory cd $(NPP_DIRECTORY) // go to notepad++'s directory cd e:\temp // change drive and directory SEE ALSO: dir Typing help npp_run

    in the NppExec Console says:

    COMMAND: npp_run USAGE: npp_run <command> npp_run <file> DESCRIPTION: 1. The same as Notepad++'s Run command - runs an external process 2. Opens specified file in its associated program (requires NppExec v0.2 RC3.1 or higher) EXAMPLES: npp_run calc.exe (*) * if you type just "calc.exe" without "npp_run", then NppExec runs "calc.exe" as a child process and waits until it returns (i.e. until you close the calc's window) npp_run "index.html" // opens "index.html" in your default web-browser npp_run "C:\Program Files\Mozilla Firefox\firefox.exe" "index.html" // in Firefox npp_run "$(FULL_CURRENT_PATH)" // opening using the associated program REMARKS: In terms of an application (a program), NPP_RUN allows to run it in its own window without waiting for its execution: npp_run application.exe npp_run application.exe <arguments> If, however, there is a need to wait until the application has been executed, while still running it in its own window, it can be achieved without NPP_RUN: cmd /c start /wait application.exe cmd /c start /wait application.exe <arguments> In this last case, NppExec waits for cmd to be executed, while cmd itself starts the application in its own separate window and waits until it has been executed. Type just help

    in the NppExec Console to see all the available environment variables and commands.

  • Problem setting annotation text

    Locked
    6
    0 Votes
    6 Posts
    1k Views
    Grahame GrieveG

    Actually, my question was about Call Tips - and once I found out what I was supposed to asking, my own error was also obvious… sorry

  • Can not open file "$STRT_REPLACES$"

    8
    1 Votes
    8 Posts
    11k Views
    SOMEBADHATS

    TAKE OWNERSHIP AS ADMINSTRATOR AND GIVE ADMINISTRATOR FULL PERMISSIONS.
    “Can not open file “$STRT_REPLACES$”” MESSAGE WHEN TRYING TO OPEN FILE W/ NOTEPAD++ (SEE DEBUG INFO BELOW). THIS IS HOW I SOLVED IT.
    YOUR MILEAGE MAY VARY.
    I HAPPENED TO BE IN THE BUILT-IN ADMINSTRATOR ACCOUNT WHEN I GOT THE MESSAGE. FROM THE FILE’S PROPERTIES-SECURITY-ADVANCED-OWNER CHANGE OWNER TO ADMINISTRATOR. IT WOULD NOT LET ME CHANGE OWNER TO ME, THE CREATOR OF THE FILE EVEN THOUGH I HAVE ADMINISTRATIVE PRIVILEGES. YOU ALSO HAVE TO ADD ADMINISTRATOR TO PROPERTIES-SECURITY-GROUP AND GIVE ADMINISTRATOR FULL PRIVILEGES.

    WINDOWS 10 PRO 64-BIT APRIL 2018 UPDATE Version 10.0.17134.48
    Notepad++ v7.5.6 (32-bit)
    Build time : Mar 19 2018 - 00:26:59
    Path : C:\Program Files (x86)\Notepad++\notepad++.exe
    Admin mode : ON
    Local Conf mode : OFF
    OS : Windows 10 (64-bit)
    Plugins : ComparePlugin.dll CustomizeToolbar.dll DSpellCheck.dll mimeTools.dll NppConverter.dll NppExport.dll NppFTP.dll PluginManager.dll SessionMgr.dll SpellChecker.dll

  • The cursor became horizontal - blue

    9
    1 Votes
    9 Posts
    6k Views
    Scott SumnerS

    @УменяМодем-ОграниченныйТрафик

    I have a UTF-8…

    You really should start a new thread to ask a totally unrelated question…

  • can't find mysqli_query (

    Locked
    4
    0 Votes
    4 Posts
    865 Views
    David RossiD

    @Scott-Sumner said:

    \

    Thank you , the ( search works

  • Replace string \ ... .cue

    Locked
    3
    0 Votes
    3 Posts
    851 Views
    Vadim ZhivotovskyV

    Thanks!!! It’s working.

  • Saving Settings

    Locked
    9
    0 Votes
    9 Posts
    2k Views
    CodeSchlockerC

    Fantastic,

    Yeah, there is a bug in the 64-bit version of Notepad++ v7.5.6. I downloaded and installed v7.5.5, and it works just perfect.

    Not only that, it copied the settings from my 32-bit version.

    Thanks for all of your help, Claudia.

    Problem solved.

  • only ????? appearing when i type.

    Locked
    1
    0 Votes
    1 Posts
    409 Views
    No one has replied
  • LUA files won't save to data folder

    Locked
    2
    0 Votes
    2 Posts
    895 Views
    Claudia FrankC

    @Brent-Kulseth

    if it complains about it then there is a good chance that the user (operating system account)
    which started notepad++ has no sufficient rights to the directory you want to write to.

    In such a case there are two ways to solve it.

    start npp with an user which has more privileges (aka run as administrator) change the permissions on the folder (BUT DO THIS ONLY IF YOU KNOW WHAT YOU DO - otherwise you might corrupt your system)

    If you tell us which file should be save under which directory (full path) then we could,
    maybe, offer additional information how this may be solved.

    Cheers
    Claudia