Skip to content
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

Add NPPN_NATIVELANGCHANGED & NPPM_GETNATIVELANGFILENAME #697

Merged
merged 1 commit into from
Sep 11, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions content/docs/plugin-communication.md
Original file line number Diff line number Diff line change
Expand Up @@ -1207,6 +1207,23 @@ MAX_PATH is suggested to use.*

---

#### [2140] **NPPM_GETNATIVELANGFILENAME**
*Get the Current native language file name string. Use it after getting NPPN_READY notification to find out which native language is used.*
Users should call it with nativeLangFileName as NULL to get the required number of char (not including the terminating nul character), allocate language file name string buffer with the return value + 1, then call it again to get the current native language file name string.*

**Parameters**:

*wParam [in]*
: size_t strLen, which is "language file name string" buffer length

*lParam [out]*
: TCHAR * nativeLangFileName, language file name string receives all copied native language file name string

**Return value**:
: Returns the number of char copied/to copy

---

#### [2031] **NPPM_GETNBOPENFILES**
*Retrieves the number of files currently open*

Expand Down Expand Up @@ -2553,6 +2570,20 @@ The general layout of the following notifications look like this

---

#### [1031] **NPPN_NATIVELANGCHANGED**
*To notify plugins that the current native language is just changed to another one.*

// Use NPPM_GETNATIVELANGFILENAME to get current native language file name.
// Use NPPM_GETMENUHANDLE(NPPPLUGINMENU, 0) to get submenu "Plugins" handle (HMENU)

**Fields:**

code: NPPN_NATIVELANGCHANGED
hwndFrom: hwndNpp
idFrom: 0 // reserved for the future use; must be zero from v8.6.5

---

#### [1016] **NPPN_READONLYCHANGED**
*To notify plugins that current document changed the read-only status*

Expand Down