Mercurial > hgrepos > hgweb.cgi > yatex
comparison yahtml.el @ 598:ebe2b7a66b9d draft dev
Add input type="range" completion
author | HIROSE Yuuji <yuuji@gentei.org> |
---|---|
date | Sun, 16 Oct 2022 20:56:35 +0859 |
parents | 722004cc4375 |
children | 38a414d755c1 |
comparison
equal
deleted
inserted
replaced
597:722004cc4375 | 598:ebe2b7a66b9d |
---|---|
1479 (let ((alg (yahtml-read-parameter "align"))) | 1479 (let ((alg (yahtml-read-parameter "align"))) |
1480 (yahtml-make-optional-argument "align" alg)))) | 1480 (yahtml-make-optional-argument "align" alg)))) |
1481 | 1481 |
1482 (defvar yahtml-input-types | 1482 (defvar yahtml-input-types |
1483 '(("text") ("password") ("checkbox") ("radio") ("submit") | 1483 '(("text") ("password") ("checkbox") ("radio") ("submit") |
1484 ("reset") ("image") ("hidden") ("file"))) | 1484 ("reset") ("image") ("hidden") ("file") |
1485 ("date") ("time") ("datetime-local") ("week") ("number") ("tel") | |
1486 ("range") ("color"))) | |
1485 | 1487 |
1486 (defun yahtml:input () | 1488 (defun yahtml:input () |
1487 "Add-in function for `input' form" | 1489 "Add-in function for `input' form" |
1488 (let ((size "") name type value id (maxlength "") | 1490 (let ((size "") name type value id (maxlength "") |
1489 (l yahtml-prefer-upcase-attributes)) | 1491 (l yahtml-prefer-upcase-attributes)) |
1500 (if l "NAME" "name") "=\"" name "\"" | 1502 (if l "NAME" "name") "=\"" name "\"" |
1501 (yahtml-make-optional-argument "type" type) | 1503 (yahtml-make-optional-argument "type" type) |
1502 (yahtml-make-optional-argument "value" value) | 1504 (yahtml-make-optional-argument "value" value) |
1503 (yahtml-make-optional-argument "id" id) | 1505 (yahtml-make-optional-argument "id" id) |
1504 (yahtml-make-optional-argument "size" size) | 1506 (yahtml-make-optional-argument "size" size) |
1507 (if (string-match "range" type) | |
1508 (concat (yahtml-make-optional-argument | |
1509 "min" (YaTeX-read-string-or-skip "min: ")) | |
1510 (yahtml-make-optional-argument | |
1511 "max" (YaTeX-read-string-or-skip "max: ")) | |
1512 (yahtml-make-optional-argument | |
1513 "step" (YaTeX-read-string-or-skip "step: ")))) | |
1505 (yahtml-make-optional-argument "maxlength" maxlength)))) | 1514 (yahtml-make-optional-argument "maxlength" maxlength)))) |
1506 | 1515 |
1507 (defun yahtml:datalist () | 1516 (defun yahtml:datalist () |
1508 "Add-in function for `datalist' form" | 1517 "Add-in function for `datalist' form" |
1509 (setq yahtml-last-typeface-cmd "option") | 1518 (setq yahtml-last-typeface-cmd "option") |