Skip to content

Adapt to N++ 7.6.x #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
chcg opened this issue Jan 11, 2019 · 5 comments
Closed

Adapt to N++ 7.6.x #20

chcg opened this issue Jan 11, 2019 · 5 comments

Comments

@chcg
Copy link
Contributor

chcg commented Jan 11, 2019

See https://notepad-plus-plus.org/community/topic/16871/please-remove-the-snippets-plugin-from-the-plugin-manager
nppsnippets is currently not taking the data from the changed plugin location introduced with N++ 7.6.x

@ffes
Copy link
Owner

ffes commented Jan 29, 2019

Most likely this functions need to be updated

https://github.com./ffes/nppsnippets/blob/master/DlgConsole.cpp#L269

@ffes
Copy link
Owner

ffes commented Jan 31, 2019

Do you think support for version < 7.6 should still work or should I just focus on the latest?

Note that as far as I can see now it only affects the installation process and where the plugin tries to find the initial template database. When you install manually or upgrade from a version < 7.6 to 7.6.x (apart from the location of the plugin itself) nothing has changes and it just works.

@chcg
Copy link
Contributor Author

chcg commented Feb 2, 2019

See https://notepad-plus-plus.org/news/notepad-7.6.3-released.html, the plugin dir is similar again to 7.5.9. Maybe it is already fine again with this switch back and just 7.6.0 -7.6.2 are broken.

@ffes
Copy link
Owner

ffes commented Feb 4, 2019

Not entirely. In the old situation the plugins where found in %PROGRAM_FILES%\Notepad++\plugins, now they are found in %PROGRAM_FILES%\Notepad++\plugins\%PLUGIN_NAME%.

At the moment (that was very useful in the pre 7.6 era) the additional files are installed in a subdirectory under the plugins directory named NppSnippets. With the extra subdirectory that got added in 7.6 the additional files are now installed in %PROGRAM_FILES%\Notepad++\plugins\%PLUGIN_NAME%\NppSnippets.

The NppSnippets plugin searches the template database (the database copied on first use of the plugin) in %NPPM_GETNPPDIRECTORY%\plugins\NppSnippets (see https://github.com./ffes/nppsnippets/blob/master/DlgConsole.cpp#L295). That is the same directory as where the .dll is found nowadays. So the plugin and release .zip need to be updated. The extra subdirectory needs to be removed from the zip and the code needs to use the new NPPM_GETPLUGINHOMEPATH message.

Note that NPPM_GETPLUGINHOMEPATH isn't mentioned on http://docs.notepad-plus-plus.org/index.php/Messages_And_Notifications, only in the release notes of 7.6.0.

@chcg
Copy link
Contributor Author

chcg commented Feb 4, 2019

Regarding http://docs.notepad-plus-plus.org/index.php/Messages_And_Notifications, see at the end:

This page was last modified on 14 February 2014, at 21:49.

So I guess there is much more of the info on this page outdated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants