Метод | Описание | |
---|---|---|
Append ( string text ) : void |
Appends text to the end of the document without affecting the selection.
|
|
CancelAutoCompletion ( ) : void |
Cancels any active auto-completion.
|
|
Clear ( ) : void |
Deletes the selected text.
|
|
ClearAll ( ) : void |
Clears all text out of the document.
|
|
Copy ( ) : void |
Copies the selected text to the clipboard.
|
|
Copy ( |
Copies the specified text range into the clipboard.
|
|
Copy ( |
Copies the specified text range into the clipboard.
|
|
Copy ( string text ) : void |
Copies the provided string into the clipboard.
|
|
CopyAllowLine ( ) : void |
Copies the selected text to the clipboard. If no text is selected, the current line is copied instead.
|
|
Cut ( ) : void |
Cuts the selected text to the clipboard.
|
|
DockWindow ( IWin32Window window, string title, DockWindowAlignment alignment, int id ) : IDockWindow |
Creates a docked window. This window will not be restored the next time Notepad++ starts. The plugin must recreate the window during the 'Ready' event, if it wishes to have the window visible again. Notepad++ will use the ID to remember the state for this docked window between sessions. If another docked window with the same ID had been opened previously with a different alignment, or the user had dragged the window to another side of the screen, then the docked window will appear in the previous location rather than the one specified here. |
|
FindColumn ( int line, int column ) : |
Gets the position that corresponds to a line and column.
|
|
FocusEditor ( ) : void |
Sets the focus to the current editor window.
|
|
GetActiveFileIndex ( EditorView view ) : int |
Gets the current document index in the specified view.
|
|
GetDockWindow ( int id ) : IDockWindow |
Gets the dock window object for the specified ID.
|
|
GetFileNames ( EditorView view ) : IEnumerable |
Gets a list of open file names in the specified view. To get a list of all open file names in both views, you can use the 'FileNames' property. |
|
GetLanguageName ( int langId ) : string |
Gets the name of a language, given the ID.
|
|
GetLineEndPos ( int line ) : |
Gets the ending position of the specified line, before any line-end characters.
|
|
GetLineLength ( int line ) : int |
Gets the length of the specified line (excluding line-end characters).
|
|
GetLineStartPos ( int line ) : |
Gets the starting position of the specified line.
|
|
GetLineText ( int line ) : string |
Gets the text for the specified line.
|
|
GetLineText ( int line, bool includeLineEndChars ) : string |
Gets the text for the specified line, optionally including line-end characters.
|
|
GetText ( |
Gets the text for the specified range.
|
|
GetText ( |
Gets the text for the specified range.
|
|
GetWordEndPos ( |
Gets the position at the end of the current word.
|
|
GetWordStartPos ( |
Gets the position at the start of the current word.
|
|
GoTo ( |
Goes to the specified position and ensures it is visible.
|
|
GoToLine ( int line ) : void |
Goes to the specified line and ensures it is visible.
|
|
Insert ( string text ) : void |
Inserts text over the current selection. The caret is placed after the inserted text and scrolled into view.
|
|
LaunchFindInFiles ( string dir, string filters ) : void |
Launches the 'Find in Files' dialog.
|
|
MenuCommand ( MenuCommand command ) : void |
Triggers a menu item command.
|
|
MenuCommand ( int commandId ) : void |
Triggers a menu item command.
|
|
MoveCaretInsideView ( ) : void |
If the caret is outside the current view, it is moved to the nearest visible line. Any selection is lost.
|
|
MoveSelectedLinesDown ( ) : void |
Moves the selected lines down one line, shifting the line below the selection.
|
|
MoveSelectedLinesUp ( ) : void |
Moves the selected lines up one line, shifting the line above the selection.
|
|
OpenFile ( string fileName ) : bool |
Opens a new file. If the file is already open, it will be made active.
|
|
Paste ( ) : void |
Pastes the clipboard text over the selection.
|
|
PointToPos ( Point pt ) : |
Finds the position closest to a point on the screen.
|
|
PointToPosClose ( Point pt, |
Finds the position closest to a point on the screen.
|
|
PosToPoint ( |
Returns the x and y display location of the position.
|
|
RefreshCustomLexers ( ) : void |
Refreshes the word-styles and folding on documents that use a custom lexer provided via NppSharp. This function is useful if your lexers providing highlighting that can change, and need to be refreshed at certain events. |
|
ReloadFile ( bool withAlert ) : void |
Reloads the current file.
|
|
ReloadFile ( string fileName, bool withAlert ) : void |
Reloads a file given the file name. If the file is not already open, then this has no effect.
|
|
SaveAllFiles ( ) : bool |
Saves all open documents.
|
|
SaveFile ( ) : bool |
Saves the current document.
|
|
SaveFileAs ( string fileName ) : bool |
Saves the current document to another file name.
|
|
SaveFileCopyAs ( string fileName ) : bool |
Saves a copy of the current document to another file name.
|
|
SelectAll ( ) : void |
Selects all text in the document. (The caret is not scrolled into view)
|
|
SetActiveFileIndex ( EditorView view, int index ) : void |
Switches to the file in the specified view.
|
|
SetEmptySelection ( |
Removes the selection and sets the caret at pos. (The caret is not scrolled into view)
|
|
SetSelection ( |
Sets the selection range. (The caret is scrolled into view)
|
|
ShowAutoCompletion ( int lengthEntered, IEnumerable |
Shows the AutoCompletion list.
|
|
ShowAutoCompletion ( int lengthEntered, IEnumerable |
Shows the AutoCompletion list.
|
|
ShowError ( |
Displays an error message caused by an exception.
|
|
ShowError ( |
Displays an error message caused by an exception, with additional text.
|
|
ShowError ( string message ) : void |
Displays an error message.
|
|
SwitchToFile ( string fileName ) : bool |
Switches to a file given the file name.
|
Метод | Описание | |
---|---|---|
OnLoad ( ) : void |
Called after the object has been created and initialized, but before the Notepad++ Ready notification.
|
Метод | Описание | |
---|---|---|
InitEvents ( ) : void | ||
OnCharAdded ( object sender, |
||
OnDoubleClick ( object sender, |
||
OnFileActivated ( object sender, FileEventArgs e ) : void | ||
OnFileClosed ( object sender, FileEventArgs e ) : void | ||
OnFileClosing ( object sender, FileEventArgs e ) : void | ||
OnFileLoadFailed ( object sender, |
||
OnFileLoading ( object sender, |
||
OnFileOpened ( object sender, FileEventArgs e ) : void | ||
OnFileOpening ( object sender, FileEventArgs e ) : void | ||
OnFileOrderChanged ( object sender, FileEventArgs e ) : void | ||
OnFileSaved ( object sender, FileEventArgs e ) : void | ||
OnFileSaving ( object sender, FileEventArgs e ) : void | ||
OnLanguageChanged ( object sender, |
||
OnModification ( object sender, |
||
OnReady ( object sender, |
||
OnShutdown ( object sender, |
||
OnStyleUpdate ( object sender, FileEventArgs e ) : void |
public Append ( string text ) : void | ||
text | string | The text to be appended. |
Результат | void |
public Copy ( |
||
start | The starting position. | |
end | The ending position (exclusive). | |
Результат | void |
public Copy ( |
||
start | The starting position. | |
numChars | int | The number of characters to be copied. |
Результат | void |
public Copy ( string text ) : void | ||
text | string | The text to be placed into to the clipboard. |
Результат | void |
public DockWindow ( IWin32Window window, string title, DockWindowAlignment alignment, int id ) : IDockWindow | ||
window | IWin32Window | The form window that is to be docked. |
title | string | The window title. |
alignment | DockWindowAlignment | Window alignment, or floating. |
id | int | An identifier for this docked window. /// The ID must be greater than zero. |
Результат | IDockWindow |
public FindColumn ( int line, int column ) : |
||
line | int | The one-based line number. |
column | int | The one-based column number. |
Результат |
public GetActiveFileIndex ( EditorView view ) : int | ||
view | EditorView | The view in which the active file index will be retrieved. |
Результат | int |
public GetDockWindow ( int id ) : IDockWindow | ||
id | int | The ID number for the dock window object. |
Результат | IDockWindow |
public GetFileNames ( EditorView view ) : IEnumerable |
||
view | EditorView | The editor view to retrieve the list of open file names. |
Результат | IEnumerable |
public GetLanguageName ( int langId ) : string | ||
langId | int | The language ID. |
Результат | string |
public GetLineEndPos ( int line ) : |
||
line | int | The one-based line number. |
Результат |
public GetLineLength ( int line ) : int | ||
line | int | The one-based line number. |
Результат | int |
public GetLineStartPos ( int line ) : |
||
line | int | The one-based line number. |
Результат |
public GetLineText ( int line ) : string | ||
line | int | The one-based line number. |
Результат | string |
public GetLineText ( int line, bool includeLineEndChars ) : string | ||
line | int | The one-based line number. |
includeLineEndChars | bool | If true, the returned string will contain the line-end characters. |
Результат | string |
public GetText ( |
||
start | The starting position. | |
end | The ending position (exclusive). | |
Результат | string |
public GetText ( |
||
start | The starting position. | |
numChars | int | The number of characters to retrieve. |
Результат | string |
public GetWordEndPos ( |
||
pos | The starting position. | |
onlyWordChars | bool | If true, only word characters will be jumped. /// If false, all characters will be jumped. |
Результат |
public GetWordStartPos ( |
||
pos | The starting position. | |
onlyWordChars | bool | If true, only word characters will be jumped. /// If false, all characters will be jumped. |
Результат |
public GoTo ( |
||
pos | The position to go to. | |
Результат | void |
public GoToLine ( int line ) : void | ||
line | int | The line to go to. |
Результат | void |
public Insert ( string text ) : void | ||
text | string | The text to be inserted. |
Результат | void |
public LaunchFindInFiles ( string dir, string filters ) : void | ||
dir | string | The directory to be searched. |
filters | string | The file filters to be searched. |
Результат | void |
public MenuCommand ( MenuCommand command ) : void | ||
command | MenuCommand | The ID of the command to be triggered. |
Результат | void |
public MenuCommand ( int commandId ) : void | ||
commandId | int | The ID of the command to be triggered. |
Результат | void |
public OpenFile ( string fileName ) : bool | ||
fileName | string | The pathname of the file to be opened. |
Результат | bool |
public PointToPos ( Point pt ) : |
||
pt | Point | The client coordinates of the point to test. |
Результат |
public PointToPosClose ( Point pt, |
||
pt | Point | The client coordinates of the point to test. |
location | An out parameter to receive the found location. | |
Результат | bool |
public PosToPoint ( |
||
pos | The position to find. | |
Результат | Point |
public ReloadFile ( bool withAlert ) : void | ||
withAlert | bool | If true, Notepad++ will show an alert box to confirm. |
Результат | void |
public ReloadFile ( string fileName, bool withAlert ) : void | ||
fileName | string | The pathname of the file to be reloaded. |
withAlert | bool | If true, Notepad++ will show an alert box to confirm. |
Результат | void |
public SaveFileAs ( string fileName ) : bool | ||
fileName | string | The pathname of the file to be written. |
Результат | bool |
public SaveFileCopyAs ( string fileName ) : bool | ||
fileName | string | The pathname of the file to be written. |
Результат | bool |
public SetActiveFileIndex ( EditorView view, int index ) : void | ||
view | EditorView | The view in which the file is to be switched. |
index | int | Zero-based index of the view to switch to. |
Результат | void |
public SetEmptySelection ( |
||
pos | The new start/end position for the selection. | |
Результат | void |
public SetSelection ( |
||
anchorPos | The selection anchor position. | |
currentPos | The selection current position. | |
Результат | void |
public ShowAutoCompletion ( int lengthEntered, IEnumerable |
||
lengthEntered | int | The number of characters already entered by the user. |
list | IEnumerable |
The list of words. |
Результат | void |
public ShowAutoCompletion ( int lengthEntered, IEnumerable |
||
lengthEntered | int | The number of characters already entered by the user. |
list | IEnumerable |
The list of words. |
ignoreCase | bool | Ignore case? |
Результат | void |
public ShowError ( |
||
ex | The exception that caused the error. | |
Результат | void |
public ShowError ( |
||
ex | The exception that caused the error (will be displayed in details tab). | |
message | string | Additional text to be displayed in message tab. |
Результат | void |
public ShowError ( string message ) : void | ||
message | string | The message to be displayed. |
Результат | void |
public SwitchToFile ( string fileName ) : bool | ||
fileName | string | The pathname of the file to be brought current. |
Результат | bool |