Commit Graph

1755 Commits

Author SHA1 Message Date
Rajendra Singh
94cf9d53ca Fix tool tip in document switcher showing the old name issue (after being renamed).
Fix #4910, close #4936
2018-11-10 13:53:53 +01:00
Rajendra Singh
b9b3faf307 Fix crash issue due to Unix style path input in Open file dialog.
This issue occurs when "Use New Style Dialog" setting is not used .
Ctrl+O, then type D:/*.log and hit Enter.

Fix #4946, close #4986
2018-11-10 12:15:08 +01:00
Cyril Ganchev
08b0156472 Fix auto-indent issue by typing Enter on empty line.
Do not alter indentation if we were at the beginning of the line and we pressed Enter.

Fix #443, close #4991
2018-11-10 04:17:17 +01:00
Chris Cammack
fd51703ad8 Fix a performance issue for swiching back to folded document.
Use the _isFolding flag to fix several overlooked edge case hangs.
This pull request fixes additional hangs I found after #4867 when working with deeply-nested fully-folded files. The hangs are easy to reproduce by following these steps:

Download the sample file https://raw.githubusercontent.com/notepad-plus-plus/notepad-plus-plus/master/PowerEditor/src/Parameters.cpp
Open the downloaded file by itself in NPP and fold it using Alt-0
Create a new empty tab and remain focused on it
Perform the six actions below, each of which will produce a hang as NPP tries to change focus back to the first tab. On my machine, each hang lasts about 30 seconds. After control returns, refocus the empty tab again and try the next action.
Use File>>Open to reopen the downloaded file, even though it is already open
Drag and drop the downloaded file onto NPP to reopen it
Double-click the downloaded file to reopen it
Right-click the downloaded file and select Edit with Notepad++ in the context menu
Open the downloaded file from the command line: C:\Program Files (x86)\Notepad++\notepad++.exe" .\Parameters.cpp
Click the red [X] in the upper right corner to close NPP
After applying the patch, none of the hangs should happen any more.

Close #4999
2018-11-10 03:05:13 +01:00
Silent
bfb7e863cc Update uchardet to 0.0.6 to improve UTF-8 detection quality
This PR updates uchardet (https://www.freedesktop.org/wiki/Software/uchardet/) to the newest stable version (0.0.6).
This version seems to improve UTF-8 detection quality, so updating this dependency is expected to squash numerous charset detection issues.

Fixes #4878, Fixes #4767, Fixes #4428, Fixes #4246, Fixes #3705, Fixes #3588, Fixes #431, Closes #4925
2018-11-09 13:49:58 +01:00
Silent
ac09857656 Fix UTF-8 detection for 4 byte characters
This PR fixes UTF-8 detection for 4 byte characters (a 2002 code used by npp assumed characters longer than 3 bytes are invalid -.-). This means such files will not be erroreously displayed as ANSI anymore.

Steps to reproduce:

Create a new UTF-8 file (w/out BOM)
Paste eg. this character 🍪 and save.
Reopen the file again.
Prior to this PR, file is detected as ANSI (even if Notepad++ is configured to default-assume UTF-8!!!). After this fix, file gets opened as UTF-8 correctly.

Fixes #4730, Fixes #3986, Fixes #3441, Fixes #3405, Closes #4922
2018-11-09 13:39:00 +01:00
Jeffrey Ozanne
0aafe91be9 Fixed Typos in quote eastereggs
Close #4948
2018-11-09 12:58:50 +01:00
Don HO
a87e89ea92 Add new Plugin message NPPM_GETPLUGINHOMEPATH in API
The new message NPPM_GETPLUGINHOMEPATH allows plugins to get plugin home root path. It's useful if plugins want to get its own path by appending <pluginFolderName> which is the name of plugin without extension part.
2018-11-07 23:30:59 +01:00
Don HO
8dea25feb5 Refactoring for optimizing/simplifying the code for getting plugin root path 2018-11-07 22:51:27 +01:00
Don HO
e9a489c5c9 Remove allowAppDataPlugins.xml detection.
Simply plugins loading emplacement:
NPPM_GETAPPDATAPLUGINSALLOWED to check to see if loading plugins from "%APPDATA%\..\Local\Notepad++\plugins" is allowed.
If doLocalConf no
else yes
2018-11-03 19:45:04 +01:00
Don HO
7e555b67fc Remove the legasy plugin loading way and apply only the new plugin loading method
1. Load plugins only from the new plugin folder structure. example: Notepad++\plugins\myAwesomePlugin\myAwesomePlugin.dll
2. Load plugins from only one directory. If doLocalConf.xml is present, then it will be <NPP_INSTALLATION_DIR>\plugins\
   otherwise %USERPROFILE%\AppData\Local\Notepad++\plugins\
2018-11-03 12:39:23 +01:00
Don HO
ee763ca0ad Change Plugins Admin installation behaviour
Old installation behaviour is loading installed plugins without restart Notepad++, which could make some plugins loading uncomplete.
New behaviour use the same implementation of plugin updating, witch quit notepad++ for plugin installation then restart Notepad++.
2018-11-01 18:42:35 +01:00
Don HO
fdf954f714 Revert "Fix scintilla restoring wrapped buffer issue" due to a serious performance issue
Check https://notepad-plus-plus.org/community/topic/16468/notepad-7-5-9-release

This reverts commit 40192bda0c.
2018-10-31 00:38:26 +01:00
Don HO
ab8b5dc7a0 Shift the post installation (checking if the plugin is deployed correctely) responsability to WinGup
For the sake of retro-compatibility, change the way of plugin packaging:
1. The plugin DLL file should be placed at the root level of the ZIP file. It has to be the only DLL file on this level.
2. The root level of the ZIP file can also contain additional files and folders which will be copied to the users harddisk as well.
3. Everything what gets copied from the ZIP file will be stored under <Npp-installation-folder>\plugins\<plugin-name>.
2018-10-29 20:21:15 +01:00
Don HO
b01a396668 Remove SHA-256 hash checking from Plugins Admin
Pass hash to check to WinGup. WinGup will verify sha-256 hash of zip package for the plugin installation and update.
2018-10-27 15:41:12 +02:00
Don HO
c531a4d42a Send NPPN_READY notification to loaded plugins after their installation by Plugin Admin 2018-10-25 20:48:36 +02:00
Don HO
ef5d07771a Fix checking plugin crash issue due to plugin packaging error. 2018-10-25 03:34:49 +02:00
Don HO
519fecbb82 Add SHA-256 implementation and use sha-256 instead of md5 in Plugin Admin 2018-10-24 09:45:35 +02:00
Don HO
e919d4d05a Remove getFileContain function's limitation. 2018-10-24 00:54:52 +02:00
Don HO
ec340000cc Make command line more clear. 2018-10-22 09:25:00 +02:00
Don HO
312ddff837 Notepad++ 7.5.9 release 2018-10-15 00:25:52 +02:00
Silent
0db302953b Add -notepadStyleCmdline for Notepad-style command line processing (/p -> -quickPrint and joining paths)
Close #4620
2018-10-12 00:41:52 +02:00
Silent
f0821d9835
Add stripIgnoredParams to implement "Wish: "ignore first item" command line argument (for replacing Notepad)"
Closes #852
2018-10-08 22:18:44 +02:00
Silent
74d39b1cec
Greatly simplify commandline parsing 2018-10-08 21:55:52 +02:00
Chris Cammack
fe458a7072 Fix hanging problem while switching back a fully-folded document by using shortcut (Ctrl-TAB)
Use the _isFolding flag to avoid expensive redundant operations that cause an apparent hang when opening or switching tabs to a large fully-folded file.

The released version of Notepad++ uses the _isFolding flag to avoid expensive redundant operations when switching to a fully-folded tab using the mouse pointer.

However, opening a fully-folded file or switching to a fully-folded tab with the keyboard can produce a delay so long that Notepad++ appears to hang forever.

The hang is 100% reproducible and can be demonstrated in less than 60 seconds:

Download a deeply-nested file such as https://raw.githubusercontent.com/notepad-plus-plus/notepad-plus-plus/master/PowerEditor/src/Parameters.cpp or https://github.com/notepad-plus-plus/notepad-plus-plus/files/1555939/nppTest.zip
Open the file in Notepad++ and fold it using Alt-0
Create a new empty tab
Switch back and forth between tabs using the mouse, which is fast
Switch back and forth between tabs using the keyboard (Ctrl-Tab, Ctrl-Page(Up|Down), Ctrl-NumPad[0-9]), which will hang
This pull request applies the existing _isFolding flag to the forgotten keyboard and file open operations and prevents the hang caused by opening or switching tabs to a fully-folded file.

Fix #3996, fix #1128, fix #1806, fix #4871
Close #4867
2018-10-07 23:42:47 +02:00
CFrank
84938b7b0f Add new plugin API NPPM_REMOVESHORTCUTBYCMDID to allows plugins to remove unneeded shortcuts
Fix #4674, close #4687
2018-10-07 03:08:34 +02:00
Rajendra Singh
efbc3b2160 Fix Tail moniotoring incoherent status after deleting a monitored file
Steps to Reproduce the Issue:

1. Open two files a.txt (first tab) and b.txt (second tab)
2. Start tail monitoring for a.txt (first tab) and activate b.txt (second tab)
3. Now delete a.txt from the explorer
4. Come back to notepad++
5. Observe the behavior now

Unexpected Behavior:

At step 4, if user choose to keep the file, a.txt is still marked as monitoring. As soon as del action occurs, b.txt automatically comes under "tail monitoring".
If user choose to remove file, a.txt should be removed from the notepad. This is absolutely fine.

Fix #4750, close #4751
2018-10-05 23:49:55 +02:00
Pavel Nedev
456ff70554 Fix issue with wrong smart highlighting when it is disabled
Fixes #4774, close #4893
2018-10-04 00:55:44 +02:00
Rajendra Singh
90ab58aea8 Fix last active tab is ignored on N++ restart issue
Fix #4716, fix #4755, close #4722
2018-10-03 09:36:44 +02:00
Pavel Nedev
abc6bc144b Fix possible file corruption during backup or power loss or other abnormal N++ termination
Fixes #240, Fixes #2381, Fixes #2883, Fixes #4346, Fixes #4655 and probably more issues related to loss of data.
Close #4803
2018-10-03 01:42:57 +02:00
Wurstbrot
c6e1a95098 Fix Tab non-responding after dragging bug
Short problem description:
Drag/drop a tab with the mouse to another position,
then all other tabs can't be activated with clicking anymore.

Also a missing include was added, that prevented compilation

Fix #4885, close #4886
2018-10-02 20:18:11 +02:00
Christophe Meriaux
40192bda0c Fix scintilla restoring wrapped buffer issue
When we are restoring a wrapped buffer,
we send SCI_VISIBLEFROMDOCLINE message to convert a file line number to a visual line number,
scintalla seems to ignore the "wrap" option of this buffer.
Workaroud: execute SCI_ENSUREVISIBLE after set position and before executing SCI_VISIBLEFROMDOCLINE.

It seems that this issue has been encountered in ScitillaComponent/FindReplaceDlg.cpp in Searching::displaySectionCentered

Fix #4571, close #4624
2018-10-02 02:52:34 +02:00
Don HO
050ba58a80 Add new quotes. 2018-10-01 02:38:30 +02:00
Don HO
d2c32ddc1d Add 2 more spitural quotes 2018-09-30 13:12:35 +02:00
Don HO
f0d130bbc5 Make plugin installer threadable. 2018-09-29 17:12:19 +02:00
Don HO
b662bcf5ae Add checking MD5 ability in Plugin Admin
Check MD5 after installing to prevent from MITMA
2018-09-27 09:56:58 +02:00
Don HO
6fb78db414 Fix a passing argument to wingup bug for Plugin Admin. 2018-09-24 02:25:33 +02:00
Don HO
da49749438 Define the plugin-list's path for Plugin Admin
It will be in plugins/Config/
2018-09-21 20:16:30 +02:00
Don HO
bfff12fd9c Add the load capacity after installing the plugins in Plugin Admin. 2018-09-20 09:24:11 +02:00
Don HO
6510889ba0 Add version management for Plugins update in Plugin Admin 2018-09-19 09:21:23 +02:00
Don HO
74e89bdf5f The best easter egg I could hide ;) 2018-09-19 00:32:26 +02:00
Don HO
71dd261a50 Plugin Admin: Change the way to remove & update plugin
uninstall: tell user to restart Notepad++ - Gup.exe remove all - clean in batch - relaunch Notepad++
gup.exe -clean "appPath2Launch" "dest_folder" "fold1" "a fold2" "fold3"
gup.exe -clean "c:\npp\notepad++.exe" "c:\temp\" "toto" "ti ti" "tata"

update:    tell user to restart Notepad++ - Gup.exe download - remove all in directory - unzip/clean in batch - relaunch Notepad++
gup.exe -unzip -clean  "appPath2Launch" "dest_folder" "toto http://toto" "titi http://titi" "tata http://tata"
gup.exe -unzip -clean "c:\npp\notepad++.exe" c:\temp\ "toto http://toto" "ti et ti http://titi" "tata http://tata"

Install:   GUp.exe download - create directory - unzip: one by one, no relaunch
gup.exe -unzipTo c:\donho\notepad++\plugins "https://github.com/npp-plugins/mimetools/releases/download/v2.1/mimetools.v2.1.zip"
2018-09-13 23:07:22 +02:00
Pavel Nedev
b48c086831 Fix wrong backup file deleted isuue
On doClose() delete the right backup file

Fix #4744, close #4745
2018-09-03 00:33:40 +02:00
Pavel Nedev
4969f377ad Fix backup not fully disabled issue
Fixes #4663, close #4738
2018-09-03 00:22:42 +02:00
Magnus Österlund
f92d5e69ad Update Swedish localization
Close #4777
2018-09-02 17:14:20 +02:00
Don HO
3325da03a0 Fix a plugin installation problem
Add a new plugins loadding behaviour:
if it's not doLocalConf mode, then plugins can be loadded from "AppData\Local\Notepad++\plugins\", without presence of "allowAppDataPlugins.xml".
2018-08-19 18:04:16 +02:00
Don HO
f3c17e9886 Fix Plugin Admin installing plugins issues.
Fix Plugin Admin installing plugins bugs and check also wingup certificate before use it.
2018-08-12 15:21:21 +02:00
Don HO
e75cf910bd Add new brhaviour of checking Plugin List's certificate 2018-07-31 09:12:57 +02:00
Don HO
9aebe5baf1 Add a new file extension for cpp 2018-07-25 03:00:30 +02:00
Don HO
89fbbad94e Notepad++ 7.5.8 release 2018-07-23 02:45:12 +02:00
Rajendra Singh
14b5e161cc Fixed crash issue by checking & unchecking "Disable extension column" in preferences dialog
Fix #4682, close #4684
2018-07-22 20:31:03 +02:00
Rajendra Singh
1c60f3f93e Fix "Explorer Here" from "Folder as Workspace" problem if folder name contains comma
Close #4686, Fix #4249
2018-07-22 10:50:44 +02:00
Don HO
43b2344b23 Fix Folder as Workspace not updating regression
This regression is due to commit 6890e94952 (#4257)

Fix #4644, fix #4379
2018-07-22 02:42:28 +02:00
Silent
388e874bfc Fixed a crash when trying to launch a secondary instance with string commandline arguments
Fix #4621, close #4622
2018-07-20 03:03:53 +02:00
Don HO
eb4edb50ef Plugin Admin - in progress 2018-07-19 02:03:17 +02:00
Don Ho
97467eb802 Notepad++ 7.5.7 release 2018-06-30 16:54:33 +02:00
AngryGamer
85e3c53a21 Fix hanging problem while shutingdown and backup file is absent
Fix #4295, fix #4276, close #4611
2018-06-28 21:11:26 +02:00
Silent
6b5144d176 Fix format specifier warnings - /Wv:18 can now be removed
As a follow up to my previous pull request, this PR fixes the last remaining improper format specifiers. This allows to remove /Wv:18 compilation flag completely, since (presumably) the only reason it was added in the first place were those format specifier warnings, introduced in VS2015.

Effectively, all this PR does is applying fixes suggested by the compiler (included in those warnings).

Close #4604
2018-06-27 22:35:32 +02:00
Don HO
587d3494c7 Fix the compiling failure on x64 build 2018-06-27 02:15:55 +02:00
Don HO
ef13902206 Use corret name for length variable 2018-06-26 13:50:33 +02:00
Don HO
6326115662 Use automatic variable with static size instead of dynamical allocation 2018-06-25 01:01:00 +02:00
Silent
a9d203a60a Deprecate wstat/stat in favour of WinAPI GetFileAttributesEx - unifies code and behaviour between Windows versions
Fixes #4491, fixes #3969, fixes #2535, fixes #215, close #4541
2018-06-25 00:33:09 +02:00
Silent
9cb8fce854 Migrate timestamps from time_t to FILETIME and store them in UTC universally
Fixes #4491, #3969, #2535 and #215.
2018-06-25 00:32:46 +02:00
Silent
08eb29e3d6 Force cpp standard const char pointer on string literals
const-ified all string literals to suppress warnings on gcc and allow /Zc:strictStrings to be used with Visual Studio

Fix #4146, close #4150
2018-06-25 00:06:26 +02:00
vlakoff
06fb4dd99f Remove "from" which is not a reserved JavaScript keyword
Close #4410
2018-06-24 23:28:02 +02:00
Christophe Meriaux
b69c36b55f Make carret line always visible on click from Finder panel
Close #4518, fix #4510
2018-06-24 23:16:50 +02:00
Don HO
593cf451fb Clean up 2018-06-24 01:16:01 +02:00
WoodsCheney
bac637ddfa Fix Open File Dialog error for a long path
Fix #4345
2018-06-24 00:42:03 +02:00
SinghRajenM
a83fa30de6 Fixed the macro deletion bug
Fix the issue that deleting a Macro doesn't remove it from the Run Macro multiple times dialog until restart

Fix #4526, close #4532
2018-06-21 09:57:04 +02:00
Silent
1482420fcb Fixed pointer truncations reported after removing /Wv:18
Close #4544
2018-06-21 02:36:28 +02:00
Derek
0c55b381da Fix a bug where the document map highlights incorrectly when the view is scrolled past the end of the file.
Fix #4579, close #4580
2018-06-21 02:28:51 +02:00
Don HO
32c1427c12 Add run process sync method & Plugin Admin's operations
Make Updater run sync for removing & restoring plugin info from & to the
plugin lists while the Plugin Admin's operation of installation, update and removal.
2018-06-19 09:39:42 +02:00
Don HO
2b7cd05093 Restore the needed functions 2018-06-13 14:02:49 +02:00
Don HO
c94319e863 Enhance installed list in Plugin Admin 2018-06-13 04:15:21 +02:00
Don HO
c30c0de0fc Refactoring Plugin Admin codes 2018-06-12 03:20:37 +02:00
vlakoff
ab903c4554 Cleanup in context menu and Run entries
Close #4519
2018-05-26 00:00:09 +02:00
along
0a6b19fedc Fix toolbar display bug in big icon mode issue
Close #4509
2018-05-25 09:53:32 +02:00
Don HO
3a52ab1af1 Remove unused method 2018-05-07 21:11:22 +02:00
nrecker
e65b4c37bf Fix Sort Lines as Integers issue: use Natural Sort algorithm
This changes the line operations "Sort as Integers Ascending" and "Sort as Integers Descending" to sort by Natural Sort Order, in which consecutive numerals are considered as one character. This causes "2" < "10", just like in the old Integer sort, but also "foo 2" < "foo 10", which was not previously available functionality. In cases where every line is a single integer, Natural Sort functions exactly the same as Integer Sort; when every line begins with a single integer, it is a valid Integer Sort.

Close #4413, fix #2025
2018-05-06 13:25:10 +02:00
Don HO
454f92af4a Adapt new plugin file system structure for the future release. 2018-04-30 19:36:15 +02:00
Don HO
7cf5232056 Make new file system of plugin works on installation directory 2018-04-25 20:46:09 +02:00
SinghRajenM
6890e94952 Fixed a code in ReadDirectoryChangesPrivate.cpp
Close #4257
2018-04-21 14:51:57 +02:00
Christian Grasser
0f4b0ec9a4 Fix typo to make translation work.
correct typo STRT_REPLACE -> STR_REPLACE

Fix #4354, close #4391
2018-04-20 13:10:18 +02:00
SinghRajenM
e9c0ee4866 Fixed UDL export extension issue
Fix #4372, close #4377
2018-04-20 02:42:56 +02:00
Don HO
ce1ffd441d Update stylers.xml model 2018-04-13 18:22:57 +02:00
Don HO
3aaf083c1d Add unit tests for function list feature
go to notepad-plus-plus\PowerEditor\Test\FunctionList directory then
launch the following commands:
powershell ./unitTestLauncher.ps1
2018-04-13 12:46:03 +02:00
Don HO
985fa654b9 Fix Javascript not working regression in Function list since 2016
due to 2 commits:
5d438aa
fb189fa
2018-04-09 00:35:53 +02:00
Don HO
01cfe5d083 Rename label in functionlist output json 2018-04-04 01:14:11 +02:00
Don Ho
9733729bfb Notepad++ 7.5.6 release 2018-03-19 01:46:19 +01:00
d0vgan
58fa70b580 Fix file status detection issue under Windows XP (32-bit only)
Close #4226
2018-03-18 00:52:52 +01:00
Don HO
6c9a5a2afe Fix typos in translation entry string 2018-03-17 23:06:03 +01:00
Don HO
3332aa918b Add more funny quotes 2018-03-16 02:19:00 +01:00
Don HO
a3be39a3ad Quotes clean up 2018-03-13 21:16:45 +01:00
SinghRajenM
1e0b0b2cd9 Fix crash on styler dialog of User Defined Language dialog
Fixes #2646, fixes #4215, close #4279
2018-03-11 01:36:56 +01:00
GaryBloom
a724cc49a6 Function List enhancement: Highlight the current function based on cursor position
Closes #715, close #4113
2018-03-11 01:27:32 +01:00
Asaq
86aa5e6484 Fix GDI objects leak problem
Fix #1017, close #3896
2018-03-11 01:05:29 +01:00
Don HO
d9b9fb6046 Add a message from outer space 2018-03-10 12:22:02 +01:00
Don HO
5df6e9bbfe Ghost typing enhancement
1. Make ghost typing Unicode supported so any language can be displayed.
2. Ghost typing's speed (slow, rapid and spped of light) can be set.
3. Any supported programming language (syntax highligting) can be applied.
4. All above supports are accessible via command line arguments.
2018-03-10 11:30:55 +01:00
Don HO
f0e1ecdc72 Add ghost typing Unicode capacity 2018-03-07 02:17:26 +01:00
Don HO
d9f3cfd82b Remove the TODO to prevent from the useless modification 2018-03-04 22:13:53 +00:00