Skip to content

Commit 7189a41

Browse files
authored
Merge pull request #124 from shriprem/patch-2
Create GotoLineCol_Barebones.py
2 parents 77f24ab + 10a4389 commit 7189a41

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
curLine = editor.lineFromPosition(editor.getCurrentPos())
2+
3+
line = int( notepad.prompt('Line Number:', 'Navigate to a line and character position', str(curLine + 1) ))
4+
pos = int( notepad.prompt('Character Position:', 'Navigate to a line and character position', str( editor.getCurrentPos() - editor.positionFromLine(curLine) + 1 ) ))
5+
6+
editor.gotoPos(editor.positionFromLine(line - 1) + pos - 1)

0 commit comments

Comments
 (0)