[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/subed 166988c 041/389: Special subtitle separator when mov
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/subed 166988c 041/389: Special subtitle separator when moving to end of subtitle |
Date: |
Fri, 3 Dec 2021 10:59:53 -0500 (EST) |
branch: elpa/subed
commit 166988c3f4739b621b8484d81ef12613bc26ae84
Author: Random User <rndusr@posteo.de>
Commit: Random User <rndusr@posteo.de>
Special subtitle separator when moving to end of subtitle
---
subed/subed-srt.el | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/subed/subed-srt.el b/subed/subed-srt.el
index b5a812c..01adbcf 100644
--- a/subed/subed-srt.el
+++ b/subed/subed-srt.el
@@ -209,8 +209,11 @@ Return point or nil if point unless point did not change."
(save-match-data
(let ((orig-point (point)))
(subed-srt-move-to-subtitle-text sub-id)
- ;; Look for next separator or end of buffer
- (let ((regex (concat "\\(" subed-srt--regexp-separator
"[0-9]+\n\\|\\([[:blank:]]*\n*\\)\\'\\)")))
+ ;; Look for next separator or end of buffer. We can't use
+ ;; `subed-srt--regexp-separator' here because if subtitle text is empty,
+ ;; it may be the only empty line in the separator, i.e. there's only one
+ ;; "\n".
+ (let ((regex (concat
"\\([[:blank:]]*\n+[0-9]+\n\\|\\([[:blank:]]*\n*\\)\\'\\)")))
(when (re-search-forward regex nil t)
(goto-char (match-beginning 0))))
(unless (= (point) orig-point)
- [nongnu] elpa/subed 03cd2bf 097/389: Wrap msecs-to-timestamp in save-match-data, (continued)
- [nongnu] elpa/subed 03cd2bf 097/389: Wrap msecs-to-timestamp in save-match-data, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 4960c74 098/389: Make timestamp parsing more robust, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 9b95137 104/389: Test subed--for-each-subtitle more thoroughly, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed ec03689 105/389: Fix subed--for-each-subtitle, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed a7cbce6 107/389: Test subed-move-subtitle-forward/backward more thoroughly, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 5da6d79 112/389: Add "pause with key" to features, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 868d05c 114/389: Adjust some variable descriptions, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 6cf5df4 036/389: Remove annoying minibuffer messages, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 3927690 037/389: Some rewording, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 62d5d3d 038/389: Use (unless ...) instead of (when (not ...)), ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 166988c 041/389: Special subtitle separator when moving to end of subtitle,
ELPA Syncer <=
- [nongnu] elpa/subed e471802 046/389: Adjust test description, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 727275d 043/389: subed-srt-sanitize: Wrap function body in atomic-change-group, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed a30a4b1 054/389: subed-srt-regenerate-ids: Don't change buffer unless it's necessary, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 5fd2009 055/389: subed-mpv: Handle invalid JSON, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed c865969 058/389: Toggle subed-mode when `subed-mode' is called, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 65bfba6 057/389: When enabling debugging, expect the debug window to exist, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed dc60c27 060/389: subed-srt--subtitle-id-at-msecs: Try to ignore invalid time stamps, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 0781285 061/389: Make mpv RPC socket and client buffer unique per buffer, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 2f86a8e 030/389: Add function: subed-srt--subtitle-text, ELPA Syncer, 2021/12/03
- [nongnu] elpa/subed 17f3ae5 034/389: Add/fix tests for srt parsing changes, ELPA Syncer, 2021/12/03