summaryrefslogtreecommitdiffstats
path: root/emacsconf-subed.el
diff options
context:
space:
mode:
authorEmacsConf <emacsconf-org@gnu.org>2025-11-27 14:37:57 -0500
committerEmacsConf <emacsconf-org@gnu.org>2025-11-27 14:37:57 -0500
commit68c95568c9241b15d553a0fa04e5632a7eea195c (patch)
tree5124cac2b0658635a49cacce7fc7e83413bb6fd0 /emacsconf-subed.el
parentc1cc853ccc154818cf68549284c6d48b391bb9b7 (diff)
parentac24ad231fabe040777e2c390b7c231366d19682 (diff)
downloademacsconf-el-68c95568c9241b15d553a0fa04e5632a7eea195c.tar.xz
emacsconf-el-68c95568c9241b15d553a0fa04e5632a7eea195c.zip
Merge branch 'main' of git.emacsconf.org:pub/emacsconf-el
Diffstat (limited to '')
-rw-r--r--emacsconf-subed.el21
1 files changed, 14 insertions, 7 deletions
diff --git a/emacsconf-subed.el b/emacsconf-subed.el
index fafdf38..422aec3 100644
--- a/emacsconf-subed.el
+++ b/emacsconf-subed.el
@@ -147,13 +147,11 @@ TYPE can be 'end if you want the match end instead of the beginning."
(let ((new-filename (concat (file-name-sans-extension (buffer-file-name)) "--chapters.vtt"))
(subtitles (subed-subtitle-list))
(subed-auto-play-media nil))
- (when (or (not (file-exists-p new-filename))
- (yes-or-no-p (format "%s exists. Overwrite? " new-filename)))
- (subed-create-file
- new-filename
- (emacsconf-subed-list-chapter-markers-based-on-comments
- subtitles)
- t))))
+ (subed-create-file
+ new-filename
+ (emacsconf-subed-list-chapter-markers-based-on-comments
+ subtitles)
+ t)))
(defun emacsconf-subed-list-chapter-markers-based-on-comments (subtitles)
"Make a list of subtitles based on which SUBTITLES have comments."
@@ -431,5 +429,14 @@ Create it if necessary."
map)
t))
+(defun emacsconf-subed-insert-question-heading-from-other-window ()
+ (interactive)
+ (insert
+ (with-selected-window
+ (other-window)
+ (replace-regexp-in-string
+ "^- +" "NOTE "
+ (buffer-substring (line-beginning-position) (line-end-position))))
+ "\n\n"))
(provide 'emacsconf-subed)
;;; emacsconf-subed.el ends here