From ce07094014be6cfdba4d1b6ad335d21ca7856486 Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Mon, 20 Jan 2025 10:09:03 -0400 Subject: st4: hsmusic: cmd+b for bold this implementation from panacea --- apps/Sublime Text 4/Packages/User/HSMusic Editing.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'apps/Sublime Text 4/Packages/User/HSMusic Editing.py') diff --git a/apps/Sublime Text 4/Packages/User/HSMusic Editing.py b/apps/Sublime Text 4/Packages/User/HSMusic Editing.py index 232ecd3..6daa032 100644 --- a/apps/Sublime Text 4/Packages/User/HSMusic Editing.py +++ b/apps/Sublime Text 4/Packages/User/HSMusic Editing.py @@ -241,6 +241,13 @@ class EnterExitWikiTagCommand(_CursorAdaptiveCommand): else: return ('wrap', '[[', ']]', 'left') +class WrapTextBoldCommand(_CursorAdaptiveCommand): + def handle_region(self, region): + if region.a == region.b: + return ('insert', 'right', '', 4) + else: + return ('wrap', '', '', 'right') + class ExitWikiTagCommand(_CursorAdaptiveCommand): def handle_region(self, region): rest_of_tag = _match_rest_of_tag_in_progress(self.view, region) -- cgit 1.3.0-6-gf8a5