Tag read-onlyĮditor: SearchAnchor() - Sets the current caret position to be the search anchor. Returns the length of the replacement text including any change caused by processing the \d patterns. Looks for \d where d is between 1 and 9 and replaces these with the strings matched in the last search operation which were surrounded by \( and \). Position editor: ReplaceTargetRE(string text) - Replace the target text with the argument text after \d processing. Position editor: ReplaceTargetMinimal(string text) - Replace the target text with the argument text but ignore prefix and suffix that are the same as current. Returns the length of the replacement text. Position editor: ReplaceTarget(string text) - Replace the target text with the argument text. Returns start of found range or -1 for failure in which case target is not moved. Position editor: SearchInTarget(string text) - Search for a counted string in the target and set the target to the found range. SearchFlags - Set the search flags used by SearchInTarget. TargetEndVirtualSpace - Sets the virtual space of the target endĮditor: SetTargetRange(position start, position end) - Sets both the start and end of the target in one call.Įditor: TargetFromSelection() - Make the target range start and end be the same as the selection range start and end.Įditor: TargetWholeDocument() - Sets the target to the whole document. TargetEnd - Sets the position that ends the target which is used for updating the document without affecting the scroll position. TargetStartVirtualSpace - Sets the virtual space of the target start TargetStart - Sets the position that starts the target which is used for updating the document without affecting the scroll position. Set to -1 and the string will be measured to the first nul. On error return 0.Įditor: SetLengthForEncode(position bytes) - Set the length of the utf8 argument for calling EncodedFromUTF8. Return the length of the result in bytes. String editor: EncodedFromUTF8(string utf8) - Translates a UTF8 string into the document encoding. String editor: TargetAsUTF8() - Returns the target converted to UTF8. Int editor: AllocateExtendedStyles(int numberStyles) - Allocate some extended (>255) style numbers and return the start of the range StyleIndexAt read-onlyĮditor: ReleaseAllExtendedStyles() - Release all extended (>255) style numbers AllocateLines write-only - Enlarge the number of lines allocated.Įditor: AddText(string text) - Add text to the document at current position.Įditor: AppendText(string text) - Append a string to the end of the document without changing the selection.Įditor: InsertText(position pos, string text) - Insert string at a position.Įditor: ChangeInsertion(string text) - Change the text that is being inserted in response to SC_MOD_INSERTCHECKĮditor: ClearAll() - Delete all text in the document.Įditor: DeleteRange(position start, position lengthDelete) - Delete a range of text in the document.Įditor: ClearDocumentStyle() - Set all style bytes to 0, remove all folding information. ReadOnly - Set to read only or read write.Įditor: Allocate(position bytes) - Enlarge the document to a particular size of text bytes. Returns the length of the line.Įditor: ReplaceSel(string text) - Replace the selected text with the argument text.īool editor. String editor: GetLine(line line) - Retrieve the contents of a line. Result is NUL-terminated.Įditor: SetText(string text) - Replace the contents of the document with the argument text.Įditor: SetSavePoint() - Remember the current position in the undo history as the position at which the document was saved. String editor: GetText() - Retrieve all the text in the document. Passed back to Scintilla or to an extension written in C. It is difficult to use this type from Lua but its possible it could be On 32-bit systems the maximum value is 2,147,483,647 but on 64-bit systems larger values are possible. The 'position' and 'line' types are integer types that represent positions and line numbers in the document. Properties are both readable and writeable by default and are otherwise marked "read-only" or "write-only". In Lua methods are called with the ':' operator and properties accessed with the '.' operator. All of the same featuresĪre available for the output pane by substituting 'output' for 'editor'. The API is presented here as it is called from Lua for the edit pane. SciTE Lua scripting of edit and output panes using Scintilla APIīoth the edit and output panes are Scintilla controls and can be scripted using Scintilla's API.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |