(www-format-encode-string): Format &(o-|G-|g2-|R-)HD-TK-dddddddd;
authorMORIOKA Tomohiko <tomo.git@chise.org>
Mon, 7 Dec 2020 00:36:28 +0000 (09:36 +0900)
committerMORIOKA Tomohiko <tomo.git@chise.org>
Mon, 14 Dec 2020 16:22:21 +0000 (01:22 +0900)
cwiki-common.el

index 8e235d1..291a138 100644 (file)
@@ -991,6 +991,18 @@ style=\"vertical-align:middle\">"
             t 'literal))
 
          (goto-char (point-min))
+         (while (re-search-forward "&\\(o-\\|G-\\|g2-\\|R-\\)?HD-TK-\\([0-9]+\\);" nil t)
+           (setq code (string-to-int (match-string 2)))
+           (replace-match
+            (format "<img alt=\"HD-KS%06d\" src=\"%s/IVD/HanyoDenshi/TK%08d.png\"
+style=\"vertical-align:middle\">"
+                    code
+                    chise-wiki-bitmap-glyphs-url
+                    code
+                    www-format-char-img-style)
+            t 'literal))
+
+         (goto-char (point-min))
          (while (re-search-forward "&G\\([01]\\)-\\([0-9A-F][0-9A-F][0-9A-F][0-9A-F]\\);" nil t)
            (setq plane (string-to-int (match-string 1))
                  code (string-to-int (match-string 2) 16))