示例#1
0
    def show_abbreviations(self):
        abbrevs = [
            '{0} --> {1}'.format(item['trigger'], item['contents'])
            for item in abbrev.Store().get_all()
        ]

        self.view.window().show_quick_panel(
            abbrevs,
            None,  # Simply show the list.
            flags=sublime.MONOSPACE_FONT)
示例#2
0
    def run(self, edit, short):
        if not short:
            return

        abbrev.Store().erase(short)
示例#3
0
    def run(self, edit, short=None, full=None):
        if not (short and full):
            self.show_abbreviations()
            return

        abbrev.Store().set(short, full)