• Multiply value

    2
    0 Votes
    2 Posts
    735 Views
    PeterJonesP

    regular expressions in search-and-replace are powerful, but they don’t have built-in arbitrary math expressions.

    If all you wanted to do was replace all instances of Size1 = 20,40 with Size1 = 40,80, that would be easy. If you just had the two sizes, you could use some alternating expressions in the regex replace to make sure the right source got replaced with the right replacement in all the files. But if you have an arbitrary number of SizeN = XXX,YYY, where N, XXX, and YYY all have many values, then crafting a regexp to do that would be an exercise in futility, because you’d have to provide all possible combinations (and you’d miss one)

    You need a programming language, where you would then have to extract the data from each line of your file, do the math, and write to a new file (or use in-place editing features of your language of choice).

    You could write that code in Notepad++. If you use PythonScript or LuaScript plugins, you could even run that code on files that are open in Notepad++. But it really is not a task specific to Notepad++, and the problem is not something that Notepad++ can solve for you.

  • How to implement Notetab outline files?

    5
    0 Votes
    5 Posts
    857 Views
    David SpectorD

    I’ve got this task done. It should be useful to others moving from NoteTab to Notepad++.

    I’ve added an end-of-outline-entry symbol “End=Entry” that should appear at the end of each entry. I’ve also written a migration program in PHP to insert these end-of-outline-entry symbols automatically into outline files (.otl). I’m using the “.out” extension for the output of this program. These .out files will be “outline” files in Notepad++.

    Here is the migration program:

    <?php //--------------------------------------------------------------------// // Program to migrate .otl files to .out files // Springtime Software, David Spector, 10/3/19, public domain. //--------------------------------------------------------------------// define("NL"," "); $FileName=GetGetArg(); $PathIn="$FileName.otl"; $PathOut="$FileName.out"; $C=file_get_contents($PathIn,true); $Lines=explode(NL,$C); // Delete two header lines array_shift($Lines); array_shift($Lines); $firstLine=true; $bloat=0; foreach ($Lines as $n=>$Line) { $R=preg_match('@^H=@',$Line,$F); if ($R && !$firstLine) { array_splice($Lines,$n+$bloat,0,"End=Entry"); ++$bloat; } $firstLine=false; } // Terminate last entry array_splice($Lines,$n+$bloat+1,0,"End=Entry"); $C=implode("\n",$Lines); $BytesOrFalse=file_put_contents($PathOut,$C); function GetGetArg() { foreach ($_GET as $ArgName=>$ArgVal) { return $ArgName; } // Each expected arg } // GetGetArg ?>
  • Severe performance degradation of new forum

    6
    3 Votes
    6 Posts
    844 Views
    MeMyselfAnd_IM

    I have seen the loss of connection a number of times

  • 0 Votes
    1 Posts
    285 Views
    No one has replied
  • 0 Votes
    5 Posts
    918 Views
    dinkumoilD

    @Ekopalypse said in How to change the match higlighting tags in notepad++ like sublime?:

    @dinkumoil - maybe something your ExtSettings plugin might offer too?

    Done, see download page and announcement in the forum.

  • Suggestion to add a search criteria

    2
    0 Votes
    2 Posts
    244 Views
    Alan KilbornA

    @Abhilash-Guha

    72d07c16-5090-4228-8bda-6d5be528e092-image.png

  • Small bug

    1
    0 Votes
    1 Posts
    208 Views
    No one has replied
  • JSON Schema Support?

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • Website links broken

    2
    0 Votes
    2 Posts
    287 Views
    No one has replied
  • How do I activate the auto hide folder margin style in notepad ++?

    2
    0 Votes
    2 Posts
    589 Views
    PeterJonesP

    @Benny-Iskandar ,

    You enable it using Settings > Preferences > Editing > Folder Margin Style.

    90b5237a-88e3-40f4-b354-dc8b5fe82f82-image.png

    You can change the colors using Settings > Style configurator > Global Styles > Fold Margin

    3d296b0c-b576-46b2-97e1-f0f138a243d0-image.png

  • notepad++ fonts display too small on UBUNTU 16.04 (200%

    5
    0 Votes
    5 Posts
    3k Views
    pnedevP

    @ortollj ,

    How do you run Notepad++ under Ubuntu then? By Snap?

  • Feature Request: Show only line-final whitespace.

    28
    2 Votes
    28 Posts
    17k Views
    dinkumoilD

    I wrote a plugin that can be used to display whitespace used for indentation normally but after the first visible character, it is shown as dots and arrows. Its name is ExtSettings. You can download it >>> here <<<. It will also be available soon via PluginsAdmin.

  • Decode problem

    2
    0 Votes
    2 Posts
    649 Views
  • Notepad++ won't allowed me to run google chrome

    2
    0 Votes
    2 Posts
    315 Views
    PeterJonesP

    I assume you were used to the old Run > Launch in Chrome menu item, and you upgraded Notepad++ or moved to a new computer with a newer version of Notepad++, and now you’re looking for where that went. If so, there’s an equivalent command now in View > View Current File In… > Chrome.

    If that’s not what you mean, you’ll have to explain yourself better, including giving version information (easiest and most complete by grabbing ? > Debug Info > Copy debug info into clipboard)

  • NppExec clipboard data from windows

    2
    0 Votes
    2 Posts
    630 Views
    Vitaliy DovganV

    As discussed in e-mail, the usage of
    sci_sendmsg SCI_PASTE
    instead of the
    npp_menucommand Macro/a2
    solves the problem.

  • How can I use the NOTEPAD HTML, to create a CSS document?

    2
    0 Votes
    2 Posts
    778 Views
    PeterJonesP

    I assume by “NOTEPAD HTML”, you mean the Notepad++ text editor, which is the topic of these forums. The process with Notepad++ is quite similar to any other text editor: File > New, then File > Save As: main.css, then start typing CSS.

    If there’s some other application called “NOTEPAD HTML” that’s unrelated to Notepad++ (and that I’ve never heard of), that’s not what these forums are about – asking in a forum dedicated to that application would be better

    If you’re asking how to craft CSS (syntax, tricks, etc), that’s not what these forums are about – asking in an HTML/CSS forum would be better. .

  • Search & Replace with carriage return regex (?-s)"." doesn't work

    3
    1 Votes
    3 Posts
    441 Views
    Alan KilbornA

    @Edwin-T

    I think what Eko is getting at is that there are several types of double quotes when one considers unicode and maybe what you are searching for isn’t the same type as in your document. Note also that sometimes the opening double quote is the same as the closing double quote, and sometimes they are different. Know your data.

  • NPP with TextFx versions, what are the latest?

    2
    0 Votes
    2 Posts
    1k Views
    dinkumoilD

    @Ben-Nash

    Some years ago the TextFX plugin was part of all Notepad++ installations. This has changed somewhere in the past. Now you have to install it separately via PluginsAdmin, the new build-in plugin management system of Notepad++ since v7.6.

    Note: Do not use the old PluginManager anymore, it is not suitable for recent versions of Notepad++ !!.

    Though there is also a 64 bit version of TextFX you should not use it, it isn’t working reliable. Take the 32 bit version instead. Thus you have to install a 32 bit version of Notepad++ as well.

    But you should use the latest version of Notepad++ which is v7.7.1. You can download it at the project’s website.

  • Notepad++ WebEdit

    3
    0 Votes
    3 Posts
    695 Views
    Michael VincentM

    Here’s a quick example with NppExec which will handle Bold for HTML and Markdown based on file extension:

    NPP_CONSOLE keep IF "$(EXT_PART)"~=".html" THEN SEL_SETTEXT <b>$(CURRENT_WORD)</b> ELSE IF "$(EXT_PART)"~=".md" THEN SEL_SETTEXT __$(CURRENT_WORD)__ ENDIF

    Save that script as “Bold Current Word” and add it to the Macro menu with NppExec and then use “Settings” => “Shortcut Mapper…” to map the CTRL-B shortcut to it.

    Adding additional scripts to do Italics for example can be done with simple modifications to the above example and is left as an exercise for the reader.

    Cheers.

  • Changing into Admin mode removes all changes

    4
    0 Votes
    4 Posts
    754 Views
    Anders Eriksson22A

    Thanks for the tip of NppSaveAsAdmin . It was not available from the PluginsAdmin, but I downloaded it from SourceForge

    Works perfectly!!

    One problem less…

    // Anders