fancy-splash: tighten up width="*" removal

width="*" should be preceded by whitepace, which should be preserved.
This commit is contained in:
TEC 2022-11-09 01:01:06 +08:00
parent d02bd0454f
commit af3ef40806
Signed by: tec
SSH Key Fingerprint: SHA256:eobz41Mnm0/iYWBvWThftS0ElEs1ftBr6jamutnXc/A
1 changed files with 2 additions and 2 deletions

View File

@ -2295,8 +2295,8 @@ and the current theme."
(progn
(replace-match (format "height=\"%s\"" height) t t)
(goto-char (point-min))
(when (re-search-forward "width=\"[\\.0-9]+\"[ \t\n]*" nil t)
(replace-match "")))
(when (re-search-forward "\\([ \t\n]\\)width=\"[\\.0-9]+\"[ \t\n]*" nil t)
(replace-match "\\1")))
(warn "Warning! fancy splash template: neither $height nor height=100 not found in %s" template)))
(dolist (substitution fancy-splash-template-colours)
(goto-char (point-min))