editor.getCursor()可以得到光标或选区末尾所对应的EditorPosition对象 editor.getCursor(“from”)可以得到选区开始或光标所对应的EditorPosition对象 editor.getCursor(“to”)可以得到光标或选区末尾所对应的EditorPosition对象