yatex
diff yatexadd.el @ 627:f294195d0d3f
Add details add-in, which fills <summary>.
| author | HIROSE Yuuji <yuuji@gentei.org> |
|---|---|
| date | Tue, 11 Aug 2026 20:43:46 +0900 |
| parents | aa395d5e3bf8 |
| children |
line diff
1.1 --- a/yatexadd.el Thu Jul 23 22:55:51 2026 +0900 1.2 +++ b/yatexadd.el Tue Aug 11 20:43:46 2026 +0900 1.3 @@ -1,12 +1,15 @@ 1.4 -;;; yatexadd.el --- YaTeX add-in functions -*- coding: sjis -*- 1.5 -;;; (c)1991-2022 by HIROSE Yuuji.[yuuji@yatex.org] 1.6 -;;; Last modified Thu Jul 23 22:53:51 2026 on firestorm 1.7 +;;; yatexadd.el --- YaTeX add-in functions -*- coding: sjis; lexical-binding: nil -*- 1.8 +;;; (c)1991-2026 by HIROSE Yuuji.[yuuji@yatex.org] 1.9 +;;; Last modified Sat Aug 1 12:55:44 2026 on firestorm 1.10 ;;; $Id$ 1.11 1.12 ;;; Code: 1.13 ;;; 1.14 ;;Sample functions for LaTeX environment. 1.15 ;;; 1.16 +(and (fboundp 'eval-when-compile) 1.17 + (eval-when-compile (require 'yatex))) 1.18 + 1.19 (defvar YaTeX:tabular-default-rule 1.20 "@{\\vrule width 1pt\\ }c|c|c@{\\ \\vrule width 1pt}" 1.21 "*Your favorite default rule format.") 1.22 @@ -2030,8 +2033,7 @@ 1.23 (setq str (YaTeX-read-string-or-skip "Grayscale values(0.0 - 1.0): ")) 1.24 (if (<= (string-to-number str) 1) 1.25 str 1.26 - (message "%s may be an error. Values from 0.0 to 1.0 are acceptable") 1.27 - str)) 1.28 + (message "%s may be an error. Values from 0.0 to 1.0 are acceptable" str))) 1.29 ((equal model "named") 1.30 (YaTeX::color-completing-read (concat type " color"))) 1.31 )))) 1.32 @@ -2143,9 +2145,11 @@ 1.33 (string< "" info) 1.34 (setq bb (format "bb=%s" info))) 1.35 (setq info (yahtml-get-image-info imgfilepath)) 1.36 - (car info) ;if has width value 1.37 - (car (cdr info)) ;if has height value 1.38 - (setq bb (format "bb=%d %d %d %d" 0 0 (car info) (car (cdr info))))) 1.39 + (and 1.40 + (car info) ;if has width value 1.41 + (car (cdr info)) ;if has height value 1.42 + (setq bb (format "bb=%d %d %d %d" 1.43 + 0 0 (car info) (car (cdr info)))))) 1.44 (save-excursion 1.45 (cond 1.46 ((and (save-excursion
