mirror of
https://github.com/SpartanJ/eepp.git
synced 2026-05-31 02:26:29 +03:00
ecode: Added textDocument/rename support ("Rename Symbol Under Cursor").
This commit is contained in:
@@ -36,6 +36,8 @@ class EE_API SyntaxHighlighter {
|
||||
|
||||
std::string getTokenTypeAt( const TextPosition& pos );
|
||||
|
||||
SyntaxTokenPosition getTokenPositionAt( const TextPosition& pos );
|
||||
|
||||
protected:
|
||||
TextDocument* mDoc;
|
||||
std::map<size_t, TokenizedLine> mLines;
|
||||
|
||||
@@ -18,6 +18,12 @@ struct EE_API SyntaxToken {
|
||||
size_t len{ 0 };
|
||||
};
|
||||
|
||||
struct EE_API SyntaxTokenPosition {
|
||||
std::string type;
|
||||
Int64 pos{ 0 };
|
||||
size_t len{ 0 };
|
||||
};
|
||||
|
||||
struct EE_API SyntaxTokenComplete {
|
||||
std::string type;
|
||||
std::string text;
|
||||
|
||||
@@ -547,6 +547,14 @@ class EE_API TextDocument {
|
||||
|
||||
SyntaxHighlighter* getHighlighter() const;
|
||||
|
||||
TextRange getWordRangeInPosition( const TextPosition& pos );
|
||||
|
||||
TextRange getWordRangeInPosition();
|
||||
|
||||
String getWordInPosition( const TextPosition& pos );
|
||||
|
||||
String getWordInPosition();
|
||||
|
||||
protected:
|
||||
friend class UndoStack;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user