diff options
author | garret <garret@airmail.cc> | 2022-07-28 18:46:26 +0100 |
---|---|---|
committer | garret <garret@airmail.cc> | 2022-07-28 18:46:26 +0100 |
commit | 7876e626d73b8010ed63a2423c354f2412f318be (patch) | |
tree | 37f0b078d48d949c27cee2997d8f4b4c915e2a93 | |
parent | 1b2340131b4c58b210842977554f2eae7223454a (diff) | |
download | aegisub-scripts-7876e626d73b8010ed63a2423c354f2412f318be.tar.gz aegisub-scripts-7876e626d73b8010ed63a2423c354f2412f318be.tar.bz2 aegisub-scripts-7876e626d73b8010ed63a2423c354f2412f318be.zip |
useless script
i have discovered that i actually do have an em-dash key
-rw-r--r-- | macros/em-dash.lua | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/macros/em-dash.lua b/macros/em-dash.lua deleted file mode 100644 index 99d22df..0000000 --- a/macros/em-dash.lua +++ /dev/null @@ -1,27 +0,0 @@ -script_name = "Em-dash" -script_description = "I do not have an em-dash key on my keyboard" -script_author = "garret" -script_version = "2021-04-05" -em = "—" -function append(sub, sel) - for si, li in ipairs(sel) do - local line = sub[li] - line.text = line.text..em - sub[li] = line - end - aegisub.set_undo_point(script_name) -end - -function replace(sub, sel) - for si, li in ipairs(sel) do - local line = sub[li] - local text = sub[li].text - text = text:gsub("%-%-",em) - line.text=text - sub[li] = line - end - aegisub.set_undo_point(script_name) -end - -aegisub.register_macro(script_name.."/Append", "Appends an Em-dash to the selected line(s)", append) -aegisub.register_macro(script_name.."/Replace", "Replaces -- with "..em, replace) |