Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
472 views
in Technique[技术] by (71.8m points)

开发vscode插件,怎么实现选中编辑中某个变量呢?

比例想编辑中let name = 'Tom'中的name选中飘红,应该咋做呢?
网上只查到这个代码~~

let decorationType = vscode.window.createTextEditorDecorationType({
            outline: '#00FF00 dotted'
        });
        let editor = vscode.window.activeTextEditor;
        editor.setDecorations(decorationType, [new vscode.Range(5, 1, 1, 4)]);

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
等待大神解答

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...