【发布时间】:2018-08-05 14:28:34
【问题描述】:
这是宏,由于某种原因,它不起作用:
[
{ "command": "split_selection_into_lines" },
{ "command": "move_to", args: {"to": "hardeol"} },
{ "command": "move_to", args: {"to": "hardbol", "extend": true} },
]
我可以通过插件做同样的事情,但我不喜欢在这里使用它:
import sublime_plugin
class SplitIntoLinesReverseCommand(sublime_plugin.TextCommand):
def run(self, edit):
self.view.run_command("split_selection_into_lines")
self.view.run_command("move_to", {"to": "hardeol"})
self.view.run_command("move_to", {"to": "hardbol", "extend": True})
为什么宏不起作用?
【问题讨论】:
标签: macros sublimetext3 sublimetext2 sublimetext sublime-text-plugin