Last active
August 29, 2015 14:02
-
-
Save okayu3/9aa22fce7deb5aa4ab33 to your computer and use it in GitHub Desktop.
#xyzzy で Emmet/hayaku風のCSS専用強力補完
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ;;; -*- Mode: Lisp; Package: EDITOR -*- | |
| ;;; | |
| ;;; This file is not part of xyzzy. | |
| ;;; | |
| ;; $Id: zencss-minor-mode.l,v 0.006 2014/06/12 20:30:00 okayu3 Exp $ | |
| ;; | |
| ;; zencss-minor-mode.l | |
| ;;[[tips]] | |
| ;;* CSS強力補完を使おう!(zen-coding,Emmet/hayaku風) | |
| ;; | |
| ;; ** メニュー | |
| ;; #contents | |
| ;; | |
| ;; ** これは何? | |
| ;;CSS専用の強力補完機能を提供します。たとえば "w" を変換すると "width:" 、"fz"で "font-size:" 、"por" で "position: relative;" 。 | |
| ;;このように最短の略語で CSSのproperty(やvalue)を展開します。 | |
| ;;zen-coding の CSS版と考えてください。 | |
| ;;現在、Emmet、hayakuというライブラリが Emacs/SublimeText/TextMate などで使われていますが、これらに相当するものです。 | |
| ;;動作は似ていますが、何かに準拠しているわけではなく、オリジナルの実装です。 | |
| ;; | |
| ;; | |
| ;; ** ダウンロード | |
| ;; [zencss-minor-mode:https://gist.github.com/okayu3/9aa22fce7deb5aa4ab33] | |
| ;; ** インストール | |
| ;; + zencss-minor-mode.l を site-lisp に置いてください。 | |
| ;; + .xyzzy / sitelinit.l に、次の設定を行います。 | |
| ;; (add-hook 'ed::*css-mode-hook* | |
| ;; #'(lambda () | |
| ;; (require "zencss-minor-mode") | |
| ;; (ed::zencss-minor-mode) | |
| ;; )) | |
| ;; | |
| ;; ** 使い方 | |
| ;;CSS-mode で、任意の場所で | |
| ;;''por+fz16+m5+p5x15x5x0x!+lh1.5+bd1#c00so'' などと打って ''M-e'' を押下すると、 | |
| ;; position: relative; | |
| ;; font-size: 16px; | |
| ;; margin: 5px; | |
| ;; padding: 5px 15px 5px 0px !important; | |
| ;; line-height: 1.5em; | |
| ;; border: 1px #CC0000 solid; | |
| ;;などと展開されます。ほら簡単でしょ? | |
| ;; | |
| ;; ** 待て待て待て。なんだその呪文。 | |
| ;;+基本は、適当に略記して展開しよう、です。"padding" なら "pa" やら "p" で展開します。 | |
| ;;"position" は "po"で。山ほど細かいルールを作ってますが、入力したいpropertyを適当に | |
| ;;略してやってみて当たれば儲けもの、と思ってまずは使ってみてください。大抵当たると思います。 | |
| ;;+さらに、value をくっつけます。"po:r" とか "po-r" などと打てば、"position" にとることの可能な | |
| ;;valueの候補のなかから、rで始まるものを選んで展開します。この場合は "position:relative"。 | |
| ;;+さらにさらに、":"や"-" を省略できるかもしれません。"por" なら "position: relative;"、 | |
| ;;"poa" なら "position: absolute;"。"fb" なら "font-weight: bold;"、とかね。 | |
| ;;+続けて複数のpropetyを書きたい場合は、"+" または ";"を入力して引き続いて記載します。 | |
| ;;''m10+p10'' と ''m10;p10'' はほぼ同じ意味です。 | |
| ;;+単位については、''10p'' と打てば ''10%'' に変換。 | |
| ;;単位を省略した場合、整数値ならば(それが妥当なら)"px"、小数値ならば "em" をつけて展開します。 | |
| ;;+色については、"#X" と書けば "#XXXXXX" に、"#XY" と書けば "#XYXYXY"に、 "#XYZ" と書けば "#XXYYZZ"に | |
| ;;それぞれ展開します。 | |
| ;;+''!''をつければ '!important' が展開されます。 | |
| ;;+vendor prefix、つまり''-webkit-'' やら ''-moz-'' やらは最近使うことは少なくなりましたが、 | |
| ;;必要がありそうならば勝手につけて展開します。 | |
| ;; | |
| ;; ** リージョン、セレクションの扱い | |
| ;;+リージョン設定をした場合、カーソルと同じ行から始まっている場合はそのリージョン内の内容を元に展開します。 | |
| ;;+セレクションがある場合、セレクションの最初の行の内容を展開します。 | |
| ;;+カーソル位置より前に 「連続したスペース」または 「*」があった場合、その位置からカーソル位置までの内容を元に展開します。 | |
| ;;+その他の場合、行頭からカーソル位置以降最初の空白または行末までの内容を元に展開します。 | |
| ;; ** 今後の予定 | |
| ;;+snippet化 | |
| ;;+カーソル位置がvalueだったら、propertyを探して property/value の形で補完する。 | |
| ;;+comment機能 | |
| ;; | |
| ;; ** 変更履歴 | |
| ;;[2014/06/24] このドキュメントを書きました。 | |
| ;; | |
| ;; ** ライセンス | |
| ;;ご自身の責任にてお使い下さい。MIT ライセンスです。 | |
| ;;+補完の強弱について整理すること。単なるデフォルト値か、必然の展開値か、編集対象か、固定展開対象か。 | |
| ;; fi16 → font: italic 16px となるべきだが、font-style:16 となってしまう。 | |
| ;; "fi" → font-style:italic "16 → font-style:16 | |
| ;; "fi16" → "f" "i" "16" にならなくてはいけない。font: italic 16px | |
| ;; "f-i16" にすれば問題ないのだが。 | |
| (provide "zencss-minor-mode") | |
| (in-package "editor") | |
| (export '(*zencss-minor-mode-map* | |
| zencss-minor-mode)) | |
| ;; マイナーモードのOn・Offを管理するバッファローカルな変数を宣言 | |
| ;; (マイナーモードの状態は、バッファごとに管理する) | |
| (defvar-local *zencss-minor-mode* nil) | |
| ;; マイナーモード用のキーマップを保持する変数を宣言 | |
| ;; (defvar で宣言された変数は、グローバルなスペシャル変数になる) | |
| (defvar *zencss-minor-mode-map* nil) | |
| ;; 宣言した変数にキーマップをセットする (これはメジャーモードと同じ) | |
| ;; この処理は、1度だけ実行される | |
| (unless *zencss-minor-mode-map* | |
| (setq *zencss-minor-mode-map* (make-sparse-keymap)) | |
| (define-key *zencss-minor-mode-map* #\M-e 'zencss-insert) | |
| ) | |
| ;; マイナーモードの切り替えを行う関数 | |
| (defun zencss-minor-mode (&optional (arg nil sv)) | |
| (interactive "p") | |
| (toggle-mode '*zencss-minor-mode* arg sv) | |
| (update-mode-line t) | |
| (if *zencss-minor-mode* | |
| (set-minor-mode-map *zencss-minor-mode-map*) | |
| (unset-minor-mode-map *zencss-minor-mode-map*)) | |
| t) | |
| ;; マイナーモードを有効にした時の、モードライン表示の設定 | |
| (pushnew | |
| '(*zencss-minor-mode* . "Zen") *minor-mode-alist* :key #'car) | |
| (defvar *zencss-rule* nil) | |
| (unless *zencss-rule* | |
| ;;(unless (= 0 1) | |
| (setq *zencss-rule* (make-hash-table :test #'equalp)) | |
| (let ((dic | |
| '(("<common>" (("inherit") nil nil nil)) | |
| ("<dimension>" (("<length>" "<percentage>") nil nil nil)) | |
| ("<length>" ((".em" ".ex" ".vw" ".vh" ".vmin" ".vmax" ".ch" ".rem" ".px" ".cm" ".mm" ".in" ".pt" ".pc") nil nil nil)) | |
| ("<percentage>" ((".%") nil nil nil)) | |
| ("<angle>" ((".deg" ".grad" ".rad" ".turn") nil nil nil)) | |
| ("<time>" ((".s" ".ms") nil nil nil)) | |
| ("<url>" (("url()") nil nil nil)) | |
| ("<attr>" (("attr()") nil nil nil)) | |
| ("<image>" (("linear-gradient()" "repeating-linear-gradient()" "radial-gradient()" "repeating-radial-gradient()") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("<timing-function>" (("ease" "linear" "ease-in" "ease-out" "ease-in-out" "cubic-bezier()") nil nil nil)) | |
| ("position" (("static" "relative" "absolute" "fixed") nil nil nil)) | |
| ("top" (("auto" "<dimension>") nil "100%" nil)) | |
| ("right" (("auto" "<dimension>") nil "100%" nil)) | |
| ("bottom" (("auto" "<dimension>") nil "100%" nil)) | |
| ("left" (("auto" "<dimension>") nil "100%" nil)) | |
| ("z-index" (("auto" "<integer>") nil nil nil)) | |
| ("float" (("left" "right" "none") nil nil nil)) | |
| ("clear" (("none" "left" "right" "both") nil nil nil)) | |
| ("display" (("none" "block" "inline" "inline-block" "list-item" "table" "inline-table" "table-row-group" "table-header-group" "table-footer-group" "table-row" "table-cell" "table-column" "table-caption" "table-column-group" "run-in" "compact" "flex" "inline-flex") nil nil nil)) | |
| ("visibility" (("visible" "hidden" "collapse") nil nil nil)) | |
| ("overflow" (("visible" "hidden" "scroll" "auto") nil nil nil)) | |
| ("overflow-x" (("<overflow>") ("ms") nil nil)) | |
| ("overflow-y" (("<overflow>") ("ms") nil nil)) | |
| ("overflow-style" (("auto" "move" "marquee" "scrollbar" "panner") ("ms") nil nil)) | |
| ("clip" (("auto" "rect()") nil nil nil)) | |
| ("box-sizing" (("content-box" "border-box") ("webkit" "moz") nil nil)) | |
| ("-moz-box-sizing" (("<box-sizing>" "padding-box") nil nil nil)) | |
| ("flex-direction" (("row" "row-reverse" "column" "column-reverse") ("webkit" "ms") nil nil)) | |
| ("flex-wrap" (("nowrap" "wrap" "wrap-reverse") ("webkit" "ms") nil nil)) | |
| ("flex-flow" (("<flex-direction>" "<flex-wrap>") ("webkit" "ms") nil nil)) | |
| ("order" (("<integer>") ("webkit" "ms") nil nil)) | |
| ("flex-grow" (("<number>") ("webkit") nil nil)) | |
| ("flex-shrink" (("<number>") ("webkit") nil nil)) | |
| ("flex-basis" (("<width>") ("webkit") nil nil)) | |
| ("flex" (("none" "<flex-grow>" "<flex-shrink>" "<flex-basis>") ("webkit" "ms") nil nil)) | |
| ("justify-content" (("flex-start" "flex-end" "center" "space-between" "space-around") ("webkit") nil nil)) | |
| ("align-items" (("flex-start" "flex-end" "center" "baseline" "stretch") ("webkit") nil nil)) | |
| ("align-self" (("auto" "<align-items>") ("webkit") nil nil)) | |
| ("align-content" (("flex-start" "flex-end" "center" "space-between" "space-around" "stretch") ("webkit") nil nil)) | |
| ("pointer-events" (("none" "all") nil nil nil)) | |
| ("margin" (("auto" "<dimension>") nil nil nil)) | |
| ("margin-top" (("auto" "<dimension>") nil nil nil)) | |
| ("margin-right" (("auto" "<dimension>") nil nil nil)) | |
| ("margin-bottom" (("auto" "<dimension>") nil nil nil)) | |
| ("margin-left" (("auto" "<dimension>") nil nil nil)) | |
| ("padding" (("<dimension>") nil nil true)) | |
| ("padding-top" (("<dimension>") nil nil true)) | |
| ("padding-right" (("<dimension>") nil nil true)) | |
| ("padding-bottom" (("<dimension>") nil nil true)) | |
| ("padding-left" (("<dimension>") nil nil true)) | |
| ("width" (("auto" "<dimension>") nil "100%" true)) | |
| ("height" (("auto" "<dimension>") nil "100%" true)) | |
| ("min-width" (("auto" "<dimension>") nil "100%" true)) | |
| ("min-height" (("auto" "<dimension>") nil "100%" true)) | |
| ("max-height" (("none" "<dimension>") nil "100%" true)) | |
| ("max-width" (("none" "<dimension>") nil "100%" true)) | |
| ("outline-color" (("invert" "<color>") nil nil nil)) | |
| ("outline-style" (("<border-style>") nil nil nil)) | |
| ("outline-width" (("<border-width>") nil nil nil)) | |
| ("outline-offset" (("<length>") nil nil nil)) | |
| ("outline" (("<outline-color>" "<_outline-style>" "<outline-width>") nil nil nil)) | |
| ("border-collapse" (("collapse" "separate") nil nil nil)) | |
| ("border-spacing" (("<length>") nil nil nil)) | |
| ("border-color" (("<color>") nil nil nil)) | |
| ("border-top-color" (("<color>") nil nil nil)) | |
| ("border-right-color" (("<color>") nil nil nil)) | |
| ("border-bottom-color" (("<color>") nil nil nil)) | |
| ("border-left-color" (("<color>") nil nil nil)) | |
| ("border-style" (("none" "hidden" "dotted" "dashed" "solid" "double" "groove" "ridge" "inset" "outset") nil nil nil)) | |
| ("border-top-style" (("none" "hidden" "dotted" "dashed" "solid" "double" "groove" "ridge" "inset" "outset") nil nil nil)) | |
| ("border-right-style" (("none" "hidden" "dotted" "dashed" "solid" "double" "groove" "ridge" "inset" "outset") nil nil nil)) | |
| ("border-bottom-style" (("none" "hidden" "dotted" "dashed" "solid" "double" "groove" "ridge" "inset" "outset") nil nil nil)) | |
| ("border-left-style" (("none" "hidden" "dotted" "dashed" "solid" "double" "groove" "ridge" "inset" "outset") nil nil nil)) | |
| ("border-width" (("thin" "medium" "thick" "<length>") nil nil true)) | |
| ("border-top-width" (("thin" "medium" "thick" "<length>") nil nil true)) | |
| ("border-right-width" (("thin" "medium" "thick" "<length>") nil nil true)) | |
| ("border-bottom-width" (("thin" "medium" "thick" "<length>") nil nil true)) | |
| ("border-left-width" (("thin" "medium" "thick" "<length>") nil nil true)) | |
| ("border" (("<_border-style>" "<border-width>" "<border-color>") nil 1px solid nil)) | |
| ("border-top" (("<border-color>" "<_border-style>" "<border-width>") nil 1px solid nil)) | |
| ("border-right" (("<border-color>" "<_border-style>" "<border-width>") nil 1px solid nil)) | |
| ("border-bottom" (("<border-color>" "<_border-style>" "<border-width>") nil 1px solid nil)) | |
| ("border-left" (("<border-color>" "<_border-style>" "<border-width>") nil 1px solid nil)) | |
| ("border-radius" (("<length>") ("webkit" "moz") nil nil)) | |
| ("border-top-right-radius" (("<length>") ("webkit") nil nil)) | |
| ("border-top-left-radius" (("<length>") ("webkit") nil nil)) | |
| ("border-bottom-left-radius" (("<length>") ("webkit") nil nil)) | |
| ("border-bottom-right-radius" (("<length>") ("webkit") nil nil)) | |
| ("<border-image-source>" (("<url>" "none") ("webkit" "moz" "o") nil nil)) | |
| ("<border-image-slice>" (("<number>" "<percentage>" "fill") ("webkit" "moz" "o") nil nil)) | |
| ("<border-image-width>" (("<border-width>") ("webkit" "moz" "o") nil nil)) | |
| ("<border-image-outset>" (("<length>" "<number>") ("webkit" "moz" "o") nil nil)) | |
| ("<border-image-repeat>" (("stretch" "repeat" "round") ("webkit" "moz" "o") nil nil)) | |
| ("border-image" (("<border-image-source>" "<border-image-slice>" "<border-image-width>" "<border-image-outset>" "<border-image-repeat>") ("webkit" "moz" "o") nil nil)) | |
| ("border-fit" (("clip" "repeat" "scale" "stretch" "overwrite" "overflow" "space") ("webkit") nil nil)) | |
| ("background-attachment" (("scroll" "fixed" "local") nil nil nil)) | |
| ("background-color" (("<color>") nil nil nil)) | |
| ("background-image" (("<url>" "none" "<image>") nil nil nil)) | |
| ("background-position-x" (("left" "center" "right" "<dimension>") ("ms") nil nil)) | |
| ("background-position-y" (("top" "center" "bottom" "<dimension>") ("ms") nil nil)) | |
| ("background-position" (("<background-position-x>" "<background-position-y>") nil nil nil)) | |
| ("background-repeat" (("repeat" "repeat-x" "repeat-y" "no-repeat" "space" "round") nil nil nil)) | |
| ("background-clip" (("border-box" "padding-box" "content-box") ("o") nil nil)) | |
| ("background-origin" (("border-box" "padding-box" "content-box") ("webkit" "o") nil nil)) | |
| ("background-size" (("auto" "contain" "cover" "<dimension>") ("webkit" "o") nil nil)) | |
| ("background" (("none" "<_background-attachment>" "<background-color>" "<_background-position>" "<_background-repeat>" "<background-image>") nil nil nil)) | |
| ("box-decoration-break" (("slice" "clone") nil nil nil)) | |
| ("box-shadow" (("inset" "none" "<length>" "<color>") ("webkit") nil nil)) | |
| ("color" (("<color_values>") nil "#FFF" nil)) | |
| ("table-layout" (("auto" "fixed") nil nil nil)) | |
| ("caption-side" (("top" "bottom") nil nil nil)) | |
| ("empty-cells" (("show" "hide") nil nil nil)) | |
| ("list-style-image" (("none" "<url>") nil nil nil)) | |
| ("list-style-position" (("inside" "outside") nil nil nil)) | |
| ("list-style-type" (("disc" "circle" "square" "decimal" "decimal-leading-zero" "lower-roman" "upper-roman" "lower-greek" "lower-latin" "upper-latin" "armenian" "georgian" "lower-alpha" "upper-alpha" "none") nil nil nil)) | |
| ("list-style" (("<list-style-image>" "<list-style-position>" "<list-style-type>") nil nil nil)) | |
| ("quotes" (("none") nil nil nil)) | |
| ("content" (("normal" "none" "open-quote" "close-quote" "no-open-quote" "no-close-quote" "icon" "<attr>" "<string>" "<url>" "<counter>") nil "" nil)) | |
| ("counter-increment" (("none") nil nil nil)) | |
| ("counter-reset" (("none") nil nil nil)) | |
| ("vertical-align" (("sub" "super" "top" "text-top" "middle" "bottom" "text-bottom" "baseline" "<dimension>") nil nil nil)) | |
| ("text-align" (("left" "right" "center" "justify" "start" "end") nil nil nil)) | |
| ("text-align-last" (("<text-align>" "auto") ("ms") nil nil)) | |
| ("text-decoration" (("none" "underline" "overline" "line-through") nil nil nil)) | |
| ("text-emphasis-color" (("<color>") nil nil nil)) | |
| ("text-emphasis-style" (("none" "filled" "open" "dot" "circle" "double-circle" "triangle" "sesame") nil nil nil)) | |
| ("text-emphasis-position" (("above" "below" "right" "left") nil nil nil)) | |
| ("text-emphasis" (("<text-emphasis-style>" "<text-emphasis-position>" "<text-emphasis-color>") nil nil nil)) | |
| ("text-indent" (("<dimension>" "each-line" "hanging") nil nil nil)) | |
| ("text-justify" (("auto" "inter-word" "inter-ideograph" "inter-cluster" "distribute" "distribute-all-lines" "distribute-center-last" "kashida" "newspaper" "tibetan") ("ms") nil nil)) | |
| ("text-outline" (("none") nil nil nil)) | |
| ("text-transform" (("capitalize" "uppercase" "lowercase" "none" "fullwidth") nil nil nil)) | |
| ("text-wrap" (("none" "normal" "unrestricted" "avoid") nil nil nil)) | |
| ("text-overflow" (("ellipsis" "clip") ("ms") nil nil)) | |
| ("text-shadow" (("<length>" "none" "<color>") nil nil nil)) | |
| ("line-height" (("normal" "<number>" "<dimension>") nil nil true)) | |
| ("white-space" (("normal" "pre" "nowrap" "pre-wrap" "pre-line") nil nil nil)) | |
| ("word-spacing" (("normal" "<length>") nil nil nil)) | |
| ("word-wrap" (("normal" "break-word") ("ms") nil nil)) | |
| ("overflow-wrap" (("normal" "break-word" "hyphenate") nil nil nil)) | |
| ("word-break" (("normal" "keep-all" "break-all") ("ms") nil nil)) | |
| ("hyphens" (("none" "manual" "auto") ("webkit" "moz") nil nil)) | |
| ("letter-spacing" (("normal" "<length>") nil nil nil)) | |
| ("font-family" (("serif" "sans-serif" "cursive" "fantasy" "monospace" "<family-name>") nil nil nil)) | |
| ("font-size" (("larger" "smaller" "xx-small" "x-small" "small" "medium" "large" "x-large" "xx-large" "<dimension>") nil nil true)) | |
| ("font-style" (("normal" "italic" "oblique") nil nil nil)) | |
| ("font-variant" (("normal" "small-caps") nil nil nil)) | |
| ("font-variant-ligatures" (("none" "normal" "common-ligatures" "no-common-ligatures" "discretionary-ligatures" "no-discretionary-ligatures" "historical-ligatures" "no-historical-ligatures" "contextual" "no-contextual") nil nil nil)) | |
| ("font-feature-settings" (("normal" "<string>" "<integer>" "on" "off") nil nil nil)) | |
| ("font-weight" (("normal" "bold" "bolder" "lighter" "100" "200" "300" "400" "500" "600" "700" "800" "900") nil nil nil)) | |
| ("font-size-adjust" (("none") nil nil nil)) | |
| ("font-stretch" (("normal" "semi-expanded" "expanded" "extra-expanded" "ultra-expanded" "ultra-condensed" "extra-condensed" "condensed" "semi-condensed") nil nil nil)) | |
| ("font-kerning" (("none" "auto" "normal") nil nil nil)) | |
| ("font" (("<font_values>") nil nil nil)) | |
| ("font_values" (("<font-style>" "<font-variant>" "<font-weight>" "<font-size>" "line-height" "caption" "icon" "menu" "message-box" "small-caption" "status-bar" "initial") nil nil nil)) | |
| ("tab-size" (("<integer>") ("moz" "o") nil nil)) | |
| ("writing-mode" (("lr-tb" "rl-tb" "tb-rl" "bt-rl" "tb-lr" "bt-lr" "lr-bt" "rl-bt" "lr" "rl" "tb") ("moz" "o") nil nil)) | |
| ("opacity" (("<alphavalue>") nil nil nil)) | |
| ("interpolation-mode" (("bicubic" "nearest-neighbor") ("ms") nil nil)) | |
| ("resize" (("none" "both" "horizontal" "vertical") nil nil nil)) | |
| ("cursor" (("auto" "none" "alias" "all-scroll" "cell" "col-resize" "context-menu" "copy" "crosshair" "default" "e-resize" "ew-resize" "help" "move" "n-resize" "ne-resize" "nesw-resize" "no-drop" "not-allowed" "ns-resize" "nw-resize" "nwse-resize" "pointer" "progress" "row-resize" "s-resize" "se-resize" "sw-resize" "text" "vertical-text" "w-resize" "wait" "<url>") nil nil nil)) | |
| ("nav-index" (("auto") nil nil nil)) | |
| ("nav-up" (("auto") nil nil nil)) | |
| ("nav-right" (("auto") nil nil nil)) | |
| ("nav-down" (("auto") nil nil nil)) | |
| ("nav-left" (("auto") nil nil nil)) | |
| ("transition-delay" (("<time>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("transition-duration" (("<time>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("transition-property" (("none" "all" "<properties>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("transition-timing-function" (("<timing-function>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("transition" (("<transition-property>" "<transition-duration>" "<transition-delay>" "<transition-timing-function>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("transform" (("none" "matrix()" "matrix3d()" "perspective()" "rotate()" "rotateX()" "rotateY()" "rotateZ()" "scale()" "scaleX()" "scaleY()" "scaleZ()" "skew()" "skewX()" "skewY()" "translate()" "translateX()" "translateY()" "translateZ()" "translate3d()") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("transform-origin" (("top" "center" "bottom" "left" "center" "right" "<percentage>" "<length>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation-name" (("none" "<properties>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation-duration" (("<time>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation-delay" (("<time>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation-timing-function" (("<timing-function>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation-iteration-count" (("infinite" "<number>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation-direction" (("normal" "alternate") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation" (("<animation-name>" "<animation-duration>" "<animation-timing-function>" "<animation-delay>" "<animation-iteration-count>" "<animation-direction>") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("animation-play-state" (("running" "paused") ("webkit" "moz" "ms" "o") nil nil)) | |
| ("filter" (nil nil nil nil)) | |
| ("unicode-bidi" (("normal" "embed" "bidi-override") nil nil nil)) | |
| ("direction" (("ltr" "rtl") nil nil nil)) | |
| ("column-width" (("<length>" "auto") nil nil nil)) | |
| ("column-count" (("<integer>" "auto") nil nil nil)) | |
| ("columns" (("<columns-width>" "<columns-count>") ("webkit" "moz") nil nil)) | |
| ("column-gap" (("<length>" "normal") ("webkit" "moz") nil nil)) | |
| ("column-rule-color" (("<color>") ("webkit" "moz") nil nil)) | |
| ("column-rule-style" (("<border-style>") ("webkit" "moz") nil nil)) | |
| ("column-rule-width" (("<border-width>") ("webkit" "moz") nil nil)) | |
| ("column-rule" (("<column-rule-width>" "<column-rule-style>" "<column-rule-color>") ("webkit" "moz") nil nil)) | |
| ("break-before" (("auto" "always" "avoid" "left" "right" "page" "column" "avoid-page" "avoid-column") nil nil nil)) | |
| ("break-after" (("auto" "always" "avoid" "left" "right" "page" "column" "avoid-page" "avoid-column") nil nil nil)) | |
| ("break-inside" (("auto" "avoid" "avoid-page" "avoid-column") nil nil nil)) | |
| ("column-span" (("none" "all") nil nil nil)) | |
| ("column-fill" (("auto" "balance") nil nil nil)) | |
| ("orphans" (("<integer>") nil nil nil)) | |
| ("widows" (("<integer>") nil nil nil)) | |
| ("zoom" (("auto" "<integer>") nil nil nil)) | |
| ("behavior" (("none" "<url>") nil nil nil)) | |
| ("user-select" (("none" "text" "all") ("webkit" "moz" "ms") nil nil)) | |
| )) | |
| (dic2 | |
| '( | |
| ("animation-fill-mode" (("backwards" "both" "forwards") nil nil nil)) | |
| ("appearance" (("none") nil nil nil)) | |
| ("background-break" (("bounding-box" "each-box" "continuous") nil nil nil)) | |
| ("border-break" (("close") nil nil nil)) | |
| ("<border-image-property>" (("none" "continue") nil nil nil)) | |
| ("border-top-image" (("<border-image-property>") nil nil nil)) | |
| ("border-right-image" (("<border-image-property>") nil nil nil)) | |
| ("border-bottom-image" (("<border-image-property>") nil nil nil)) | |
| ("border-left-image" (("<border-image-property>") nil nil nil)) | |
| ("border-corner-image" (("<border-image-property>") nil nil nil)) | |
| ("border-top-left-image" (("<border-image-property>") nil nil nil)) | |
| ("border-top-right-image" (("<border-image-property>") nil nil nil)) | |
| ("border-bottom-left-image" (("<border-image-property>") nil nil nil)) | |
| ("border-bottom-right-image" (("<border-image-property>") nil nil nil)) | |
| ("border-length" (("auto") nil nil nil)) | |
| ("<color_values>" (("rgb(0, 0, 0)" "rgba(0, 0, 0, .5)" "aqua" "black" "blue" "fuchsia" "gray" "green" "lime" "maroon" "olive" "orange" "purple" "red" "silver" "white" "yellow") nil nil nil)) | |
| ("<counter>" (("counter()" "counters()") nil nil nil)) | |
| ("font-effect" (("none" "engrave" "emboss" "outline") nil nil nil)) | |
| ("font-emphasize-position" (("before" "after") nil nil nil)) | |
| ("font-emphasize-style" (("accent" "dot" "circle" "disc" "none") nil nil nil)) | |
| ("font-smooth" (("auto" "never" "always") nil nil nil)) | |
| ("orientation" (("landscape" "portrait") nil nil nil)) | |
| ("<page-break-property>" (("auto" "always" "left" "right") nil nil nil)) | |
| ("page-break-after" (("<page-break-property>") nil nil nil)) | |
| ("page-break-before" (("<page-break-property>") nil nil nil)) | |
| ("page-break-inside" (("auto" "avoid") nil nil nil)) | |
| ("text-height" (("auto" "font-size" "text-size" "max-size") nil nil nil)) | |
| ("text-replace" (("none") nil nil nil)) | |
| ("white-space-collapse" (("normal" "keep-all" "loose" "break-strict" "break-all") nil nil nil)) | |
| ;;追加分 | |
| ("animation-direction" (("alternate-reverse" "reverse") nil nil nil)) | |
| ("color" (("transparent") nil nil nil)) | |
| ("background-clip" (("no-clip") nil nil nil)) | |
| ("border-style" (("dot-dash" "dot-dot-dash" "wave") nil nil nil)) | |
| ("box-shadow" (("none") nil nil nil)) | |
| ("cursor" (("hand") nil nil nil)) | |
| ("display" (("ruby" "ruby-base" "ruby-base-group" "ruby-text" "ruby-text-group") nil nil nil)) | |
| ("text-emphasis-style" (("disc" "before" "after" "accent") nil nil nil)) | |
| ("text-wrap" (("suppress") nil nil nil)) | |
| ("user-select" (("none") nil nil nil)) | |
| ("word-break" (("loose" "break-strict") nil nil nil)) | |
| ("word-wrap" (("none" "unrestricted" "suppress") nil nil nil)) | |
| ("-webkit-font-smoothing" (("antialiased" "none" "subpixel-antialiased" "subpixel-antialiased") nil nil nil)) | |
| )) | |
| (tbl *zencss-rule*)) | |
| (dolist (one-rule dic) | |
| (let ((k (car one-rule)) | |
| (v (cadr one-rule))) | |
| (setf (gethash k tbl) v))) | |
| (dolist (one-rule dic2) | |
| (let* ((k (car one-rule)) | |
| (v (cadr one-rule)) | |
| (cand (gethash k tbl))) | |
| (if cand | |
| (setf (car cand) (append (car cand) (car v))) | |
| (setf (gethash k tbl) v)))) | |
| )) | |
| (defvar *zencss-valu-hints* nil) | |
| (unless *zencss-valu-hints* | |
| ;;(unless (= 0 1) | |
| (setq *zencss-valu-hints* (make-hash-table :test #'equalp)) | |
| (let ((tbl *zencss-valu-hints*) | |
| (dic | |
| '(("accent" "ac") | |
| ("alternate-reverse" "ar") | |
| ("always" "aw") | |
| ("always" "al") | |
| ("auto" "au") | |
| ("avoid" "av") | |
| ("baseline" "bl") | |
| ("bolder" "br") | |
| ("border-box" "bb") | |
| ("both" "bt") | |
| ("both" "bh") | |
| ("bounding-box" "bb") | |
| ("break-all" "ba") | |
| ("break-strict" "bs") | |
| ("close-quote" "cq") | |
| ("compact" "cp") | |
| ("contain" "ct") | |
| ("content-box" "cb") | |
| ("counter()" "c") | |
| ("counters()" "cs") | |
| ("cover" "cv") | |
| ("crosshair" "c") | |
| ("cubic-bezier()" "cb") | |
| ("dashed" "ds") | |
| ("decimal" "dc") | |
| ("decimal-leading-zero" "dclz") | |
| ("disc" "ds") | |
| ("dot" "dt") | |
| ("dot-dash" "dtds") | |
| ("dot-dot-dash" "dtdtds") | |
| ("dotted" "dt") | |
| ("double" "db") | |
| ("each-box" "eb") | |
| ("ease-in" "ei") | |
| ("ease-in-out" "eio") | |
| ("ease-out" "eo") | |
| ("emboss" "eb") | |
| ("engrave" "eg") | |
| ("extra-condensed" "ec") | |
| ("extra-expanded" "ee") | |
| ("hand" "ha") | |
| ("help" "he") | |
| ("inline-block" "ib") | |
| ("inline-table" "itb") | |
| ("inter-cluster" "ic") | |
| ("inter-ideograph" "ii") | |
| ("inter-word" "iw") | |
| ("lighter" "lr") | |
| ("list-item" "li") | |
| ("lower-roman" "lr") | |
| ("marquee" "mq") | |
| ("none" "n") | |
| ("no-clip" "nc") | |
| ("no-close-quote" "ncq") | |
| ("no-open-quote" "noq") | |
| ("none" "no") | |
| ("normal" "nm") | |
| ("nowrap" "nw") | |
| ("open-quote" "oq") | |
| ("overflow" "of") | |
| ("overwrite" "ow") | |
| ("padding-box" "pb") | |
| ("pre-line" "pl") | |
| ("pre-wrap" "pw") | |
| ("repeat-x" "x") | |
| ("repeat-y" "y") | |
| ("rgb(0, 0, 0)" "r") | |
| ("rgba(0, 0, 0, .5)" "ra") | |
| ("round" "rd") | |
| ("ruby" "rb") | |
| ("ruby-base" "rbb") | |
| ("ruby-base-group" "rbbg") | |
| ("ruby-text" "rbt") | |
| ("ruby-text-group" "rbtg") | |
| ("run-in" "ri") | |
| ("sans-serif" "ss") | |
| ("scale" "sc") | |
| ("scaleX()" "scx") | |
| ("scaleY()" "scy") | |
| ("skewX()" "skx") | |
| ("skewY()" "sky") | |
| ("semi-condensed" "sc") | |
| ("semi-expanded" "se") | |
| ("small-caps" "sc") | |
| ("space" "sp") | |
| ("stretch" "st") | |
| ("sub" "sub") | |
| ("subpixel-antialiased" "sa") | |
| ("super" "sup") | |
| ("table" "tb") | |
| ("table-caption" "tbcp") | |
| ("table-cell" "tbc") | |
| ("table-column" "tbcl") | |
| ("table-column-group" "tbclg") | |
| ("table-footer-group" "tbfg") | |
| ("table-header-group" "tbhg") | |
| ("table-row" "tbr") | |
| ("table-row-group" "tbrg") | |
| ("text-bottom" "tb") | |
| ("text-top" "tt") | |
| ("translateX()" "tx") | |
| ("translateY()" "ty") | |
| ("ultra-condensed" "uc") | |
| ("ultra-expanded" "ue") | |
| ("upper-roman" "ur")))) | |
| (dolist (one-elem dic) | |
| (let* ((k (car one-elem)) | |
| (v (cadr one-elem)) | |
| (cand (gethash k tbl))) | |
| (setf (gethash k tbl) | |
| (if cand (cons v cand) (cons v nil))))) | |
| )) | |
| (defvar *zencss-prop-abbrevs* nil) | |
| (unless *zencss-prop-abbrevs* | |
| ;;(unless (= 0 1) | |
| (setq *zencss-prop-abbrevs* (make-hash-table :test #'equalp)) | |
| (let ((zencss-dic-3letters-over | |
| '(("pos" ("position" "relative")) | |
| ("ovx" ("overflow-x" "hidden")) | |
| ("ovy" ("overflow-y" "hidden")) | |
| ("ovs" ("overflow-style" "scrollbar")) | |
| ("zoo" ("zoom" "1")) | |
| ("rsz" ("resize" "")) | |
| ("cur" ("cursor" "${pointer}")) | |
| ("bxz" ("box-sizing" "border-box")) | |
| ("maw" ("max-width" "")) | |
| ("mah" ("max-height" "")) | |
| ("miw" ("min-width" "")) | |
| ("mih" ("min-height" "")) | |
| ("fza" ("font-size-adjust" "")) | |
| ("fef" ("font-effect" "")) | |
| ("fem" ("font-emphasize" "")) | |
| ("femp" ("font-emphasize-position" "")) | |
| ("fems" ("font-emphasize-style" "")) | |
| ("ffj" ("font-family" "'Lucida Grande', 'Hiragino Kaku Gothic ProN', Meiryo, sans-serif")) | |
| ("fsm" ("font-smooth" "")) | |
| ("fst" ("font-stretch" "")) | |
| ("ta-lst" ("text-align-last" "")) | |
| ("lts" ("letter-spacing" "")) | |
| ("whs" ("white-space" "")) | |
| ("whsc" ("white-space-collapse" "")) | |
| ("wob" ("word-break" "")) | |
| ("wos" ("word-spacing" "")) | |
| ("wow" ("word-wrap" "")) | |
| ("bgc" ("background-color" "#fff")) | |
| ("bgi" ("background-image" "url(|)")) | |
| ("bgr" ("background-repeat" "")) | |
| ("bga" ("background-attachment" "")) | |
| ("bgpx" ("background-position-x" "")) | |
| ("bgpy" ("background-position-y" "")) | |
| ("bgbk" ("background-break" "")) | |
| ("bgcp" ("background-clip" "padding-box")) | |
| ("bgo" ("background-origin" "")) | |
| ("bgp" ("background-position" "0 0")) | |
| ("bgsz" ("background-size" "")) | |
| ("cnt" ("content" "'|'")) | |
| ("coi" ("counter-increment" "")) | |
| ("cor" ("counter-reset" "")) | |
| ("olo" ("outline-offset" "")) | |
| ("olw" ("outline-width" "")) | |
| ("ols" ("outline-style" "")) | |
| ("olc" ("outline-color" "#000")) | |
| ("tbl" ("table-layout" "")) | |
| ("cps" ("caption-side" "")) | |
| ("bdbk" ("border-break" "close")) | |
| ("bdcl" ("border-collapse" "")) | |
| ("bdc" ("border-color" "#000")) | |
| ("bdi" ("border-image" "url(|)")) | |
| ("bdti" ("border-top-image" "url(|)")) | |
| ("bdri" ("border-right-image" "url(|)")) | |
| ("bdbi" ("border-bottom-image" "url(|)")) | |
| ("bdli" ("border-left-image" "url(|)")) | |
| ("bdci" ("border-corner-image" "url(|)")) | |
| ("bdtli" ("border-top-left-image" "url(|)")) | |
| ("bdtri" ("border-top-right-image" "url(|)")) | |
| ("bdbri" ("border-bottom-right-image" "url(|)")) | |
| ("bdbli" ("border-bottom-left-image" "url(|)")) | |
| ("bdf" ("border-fit" "repeat")) | |
| ("bdlen" ("border-length" "")) | |
| ("bdsp" ("border-spacing" "")) | |
| ("bds" ("border-style" "")) | |
| ("bdw" ("border-width" "")) | |
| ("bdt" ("border-top" "")) | |
| ("bdtw" ("border-top-width" "")) | |
| ("bdts" ("border-top-style" "")) | |
| ("bdtc" ("border-top-color" "#000")) | |
| ("bdr" ("border-right" "")) | |
| ("bdrw" ("border-right-width" "")) | |
| ("bdrst" ("border-right-style" "")) | |
| ("bdrc" ("border-right-color" "#000")) | |
| ("bdb" ("border-bottom" "")) | |
| ("bdbw" ("border-bottom-width" "")) | |
| ("bdbs" ("border-bottom-style" "")) | |
| ("bdbc" ("border-bottom-color" "#000")) | |
| ("bdl" ("border-left" "")) | |
| ("bdlw" ("border-left-width" "")) | |
| ("bdls" ("border-left-style" "")) | |
| ("bdlc" ("border-left-color" "#000")) | |
| ("bdrs" ("border-radius" "")) | |
| ("bdtrrs" ("border-top-right-radius" "")) | |
| ("bdtlrs" ("border-top-left-radius" "")) | |
| ("bdbrrs" ("border-bottom-right-radius" "")) | |
| ("bdblrs" ("border-bottom-left-radius" "")) | |
| ("bxsh" ("box-shadow" "none")) | |
| ("lis" ("list-style" "")) | |
| ("lisp" ("list-style-position" "")) | |
| ("list" ("list-style-type" "")) | |
| ("lisi" ("list-style-image" "")) | |
| ("pgbb" ("page-break-before" "")) | |
| ("pgbi" ("page-break-inside" "")) | |
| ("pgba" ("page-break-after" "")) | |
| ("orp" ("orphans" "")) | |
| ("wid" ("widows" "")) | |
| ("anim" ("animation" "")) | |
| ("animdel" ("animation-delay" "time")) | |
| ("animdir" ("animation-direction" "normal")) | |
| ("animdur" ("animation-duration" "0s")) | |
| ("animfm" ("animation-fill-mode" "both")) | |
| ("animic" ("animation-iteration-count" "1")) | |
| ("animn" ("animation-name" "none")) | |
| ("animps" ("animation-play-state" "running")) | |
| ("animtf" ("animation-timing-function" "linear")) | |
| ("colm" ("columns" "")) | |
| ("colmc" ("column-count" "")) | |
| ("colmf" ("column-fill" "")) | |
| ("colmg" ("column-gap" "")) | |
| ("colmr" ("column-rule" "")) | |
| ("colmrc" ("column-rule-color" "")) | |
| ("colmrs" ("column-rule-style" "")) | |
| ("colmrw" ("column-rule-width" "")) | |
| ("colms" ("column-span" "")) | |
| ("colmw" ("column-width" "")) | |
| ("mar" ("max-resolution" "res")) | |
| ("mir" ("min-resolution" "res")) | |
| ("ori" ("orientation" "")) | |
| ("tal" ("text-align-last" "")) | |
| ("ta-lst" ("text-align-last" "")) | |
| ("tov" ("text-overflow" "${ellipsis}")) | |
| ("trf" ("transform" "")) | |
| ("trfo" ("transform-origin" "")) | |
| ("trfs" ("transform-style" "preserve-3d")) | |
| ("trs" ("transition" "")) | |
| ("trsde" ("transition-delay" "time")) | |
| ("trsdu" ("transition-duration" "time")) | |
| ("trsp" ("transition-property" "prop")) | |
| ("trstf" ("transition-timing-function" "tfunc")) | |
| ("tsh" ("text-shadow" "none")) | |
| ("wfsm" ("-webkit-font-smoothing" "${antialiased}")))) | |
| (zencss-dic-2letters | |
| '(("a" ("animation" "")) | |
| ("ab" ("bottom" "")) | |
| ("ac" ("text-emphasis" "accent")) | |
| ("ad" ("display" "")) | |
| ("af" ("font" "")) | |
| ("ah" ("max-height" "")) | |
| ("al" ("text-align-last" "")) | |
| ("am" ("margin" "")) | |
| ("ao" ("outline" "")) | |
| ;; ("ap" ("padding" "")) | |
| ("ap" ("appearance" "none")) | |
| ("aq" ("quotes" "")) | |
| ("ar" ("right" "")) | |
| ("at" ("top" "")) | |
| ("au" ("page-break-before" "auto")) | |
| ("av" ("page-break-inside" "avoid")) | |
| ("aw" ("max-width" "")) | |
| ("az" ("z-index" "")) | |
| ("b" ("bottom" "100%")) | |
| ("ba" ("bottom" "auto")) | |
| ("bb" ("border-bottom" "")) | |
| ("bc" ("border-color" "#000")) | |
| ("bd" ("border" "")) | |
| ("bf" ("border-fit" "")) | |
| ("bg" ("background" "")) | |
| ("bi" ("border-image" "url()")) | |
| ("bj" ("bottom" "")) | |
| ("bk" ("border-break" "")) | |
| ("bl" ("border-left" "")) | |
| ("bm" ("bottom" "")) | |
| ("bn" ("background" "none")) | |
| ; ("bo" ("background-origin" "")) | |
| ("bo" ("border" "")) | |
| ("bq" ("bottom" "")) | |
| ("br" ("border-right" "")) | |
| ("bs" ("border-style" "")) | |
| ("bt" ("border-top" "")) | |
| ("bu" ("bottom" "")) | |
| ("bv" ("background-size" "cover")) | |
| ("bw" ("border-width" "")) | |
| ("bx" ("box-sizing" "")) | |
| ("by" ("background-position-y" "")) | |
| ("bz" ("box-sizing" "")) | |
| ("c" ("color" "#FFF")) | |
| ("ca" ("clip" "auto")) | |
| ("cb" ("clear" "both")) | |
| ("cc" ("content" "counter()")) | |
| ("cd" ("cursor" "default")) | |
| ("ce" ("cursor" "help")) | |
| ("cf" ("color" "#000")) | |
| ("cg" ("color" "#000")) | |
| ("ch" ("cursor" "help")) | |
| ("ci" ("counter-increment" "")) | |
| ("cj" ("color" "#000")) | |
| ("ck" ("color" "#000")) | |
| ("cl" ("clear" "both")) | |
| ("cn" ("content" "")) | |
| ("co" ("counter-reset" "")) | |
| ("cp" ("clip" "")) | |
| ("cq" ("content" "open-quote")) | |
| ("cr" ("cursor" "")) | |
| ("cs" ("caption-side" "")) | |
| ("ct" ("content" "")) | |
| ("cu" ("cursor" "")) | |
| ("cv" ("color" "#000")) | |
| ("cw" ("color" "#000")) | |
| ("cx" ("color" "#000")) | |
| ("cy" ("color" "#000")) | |
| ("cz" ("color" "#000")) | |
| ("d" ("display" "")) | |
| ("da" ("display" "")) | |
| ("db" ("display" "block")) | |
| ("dc" ("display" "compact")) | |
| ("dd" ("display" "")) | |
| ("de" ("display" "")) | |
| ("df" ("display" "table-footer-group")) | |
| ("dg" ("display" "table-footer-group")) | |
| ("dh" ("display" "table-header-group")) | |
| ("di" ("display" "inline")) | |
| ("dj" ("display" "")) | |
| ("dk" ("display" "")) | |
| ("dl" ("display" "list-item")) | |
| ("dm" ("display" "")) | |
| ("dn" ("display" "none")) | |
| ("do" ("display" "")) | |
| ("dp" ("display" "compact")) | |
| ("dq" ("display" "")) | |
| ("dr" ("display" "ruby")) | |
| ("ds" ("display" "")) | |
| ("dt" ("display" "table")) | |
| ("du" ("display" "")) | |
| ("dv" ("display" "")) | |
| ("dw" ("display" "")) | |
| ("dx" ("display" "")) | |
| ("dy" ("display" "")) | |
| ("dz" ("display" "")) | |
| ("e" ("empty-cells" "")) | |
| ("ea" ("empty-cells" "")) | |
| ("eb" ("empty-cells" "")) | |
| ("ec" ("empty-cells" "")) | |
| ("ed" ("empty-cells" "")) | |
| ("ee" ("empty-cells" "")) | |
| ("ef" ("font-effect" "")) | |
| ("eg" ("empty-cells" "")) | |
| ("eh" ("empty-cells" "hide")) | |
| ("ei" ("empty-cells" "")) | |
| ("ej" ("empty-cells" "")) | |
| ("ek" ("empty-cells" "")) | |
| ("el" ("empty-cells" "")) | |
| ("em" ("font-emphasize" "")) | |
| ("eo" ("empty-cells" "")) | |
| ("ep" ("empty-cells" "")) | |
| ("eq" ("empty-cells" "")) | |
| ("er" ("empty-cells" "")) | |
| ("es" ("empty-cells" "show")) | |
| ("et" ("empty-cells" "")) | |
| ("eu" ("empty-cells" "")) | |
| ("ev" ("empty-cells" "")) | |
| ("ew" ("empty-cells" "")) | |
| ("ex" ("empty-cells" "")) | |
| ("ey" ("empty-cells" "")) | |
| ("ez" ("empty-cells" "")) | |
| ("f" ("font" "")) | |
| ("fa" ("font-size-adjust" "")) | |
| ("fb" ("font-weight" "bold")) | |
| ("fc" ("font-family" "cursive")) | |
| ("fd" ("font-emphasize-style" "dot")) | |
| ("fe" ("font-effect" "")) | |
| ("ff" ("font-family" "")) | |
| ("fg" ("font-effect" "engrave")) | |
| ("fh" ("font" "")) | |
| ("fi" ("font-style" "italic")) | |
| ("fj" ("font" "")) | |
| ("fk" ("font" "")) | |
| ("fl" ("float" "left")) | |
| ("fm" ("font-smooth" "")) | |
| ("fn" ("font-variant" "normal")) | |
| ("fo" ("font-style" "oblique")) | |
| ("fp" ("font-emphasize-position" "")) | |
| ("fq" ("font" "")) | |
| ("fr" ("float" "right")) | |
| ("fs" ("font-style" "")) | |
| ; ("fs" ("font-size" "")) | |
| ("ft" ("font-stretch" "")) | |
| ("fu" ("font-stretch" "ultra-condensed")) | |
| ("fv" ("font-variant" "")) | |
| ("fw" ("font-weight" "")) | |
| ("fx" ("font" "")) | |
| ("fy" ("font" "")) | |
| ("fz" ("font-size" "")) | |
| ("ga" ("background-attachment" "")) | |
| ("gb" ("background-break" "")) | |
| ("gc" ("background-color" "#fff")) | |
| ("gd" ("display" "")) | |
| ("gf" ("font" "")) | |
| ("gh" ("height" "")) | |
| ("gi" ("background-image" "url()")) | |
| ("gl" ("left" "")) | |
| ("gm" ("margin" "")) | |
| ("go" ("background-origin" "")) | |
| ("gq" ("quotes" "")) | |
| ("gr" ("background-repeat" "")) | |
| ("gt" ("top" "")) | |
| ("gv" ("visibility" "")) | |
| ("gw" ("width" "")) | |
| ("gz" ("background-size" "")) | |
| ("h" ("height" "100%")) | |
| ("ha" ("height" "auto")) | |
| ("hb" ("height" "")) | |
| ("hc" ("height" "")) | |
| ("hd" ("height" "")) | |
| ("he" ("height" "")) | |
| ("hf" ("height" "")) | |
| ("hg" ("height" "")) | |
| ("hh" ("height" "")) | |
| ("hi" ("height" "")) | |
| ("hj" ("height" "")) | |
| ("hk" ("height" "")) | |
| ("hl" ("height" "")) | |
| ("hm" ("height" "")) | |
| ("hn" ("height" "")) | |
| ("ho" ("height" "")) | |
| ("hp" ("height" "")) | |
| ("hq" ("height" "")) | |
| ("hr" ("height" "")) | |
| ("hs" ("height" "")) | |
| ("ht" ("height" "")) | |
| ("hu" ("height" "")) | |
| ("hv" ("height" "")) | |
| ("hw" ("height" "")) | |
| ("hx" ("height" "")) | |
| ("hy" ("hyphens" "")) | |
| ("hz" ("height" "")) | |
| ("i" ("-ms-interpolation-mode" "")) | |
| ("ib" ("display" "inline-block")) | |
| ("ic" ("text-justify" "inter-cluster")) | |
| ("id" ("widows" "")) | |
| ("if" ("font" "")) | |
| ("ih" ("min-height" "")) | |
| ("ii" ("text-justify" "inter-ideograph")) | |
| ("il" ("left" "")) | |
| ("im" ("margin" "")) | |
| ("io" ("outline" "")) | |
| ("ip" ("padding" "")) | |
| ("iq" ("quotes" "")) | |
| ("ir" ("right" "")) | |
| ("is" ("list-style" "")) | |
| ("it" ("display" "inline-table")) | |
| ("iv" ("visibility" "")) | |
| ("iw" ("min-width" "")) | |
| ("iz" ("z-index" "")) | |
| ("jb" ("bottom" "")) | |
| ("jc" ("color" "#000")) | |
| ("jd" ("display" "")) | |
| ("jf" ("font" "")) | |
| ("jh" ("height" "")) | |
| ("jl" ("left" "")) | |
| ("jm" ("margin" "")) | |
| ("jo" ("outline" "")) | |
| ("jp" ("padding" "")) | |
| ("jq" ("quotes" "")) | |
| ("jr" ("right" "")) | |
| ("jt" ("top" "")) | |
| ("jv" ("visibility" "")) | |
| ("jw" ("width" "")) | |
| ("jz" ("z-index" "")) | |
| ("kb" ("bottom" "")) | |
| ("kc" ("color" "#000")) | |
| ("kd" ("display" "")) | |
| ("kf" ("font" "")) | |
| ("kh" ("height" "")) | |
| ("kl" ("left" "")) | |
| ("km" ("margin" "")) | |
| ("ko" ("outline" "")) | |
| ("kp" ("padding" "")) | |
| ("kq" ("quotes" "")) | |
| ("kr" ("right" "")) | |
| ("kt" ("top" "")) | |
| ("kv" ("visibility" "")) | |
| ("kw" ("width" "")) | |
| ("kx" ("transform" "skewX(angle)")) | |
| ("ky" ("transform" "skewY(angle)")) | |
| ("kz" ("z-index" "")) | |
| ("l" ("left" "100%")) | |
| ("la" ("left" "auto")) | |
| ("lb" ("left" "")) | |
| ("lc" ("list-style-type" "circle")) | |
| ("ld" ("list-style-type" "disc")) | |
| ("le" ("left" "")) | |
| ("lf" ("left" "")) | |
| ("lg" ("left" "")) | |
| ("lh" ("line-height" "")) | |
| ("li" ("list-style" "")) | |
| ("lj" ("left" "")) | |
| ("lk" ("left" "")) | |
| ("ll" ("list-style-type" "lower-roman")) | |
| ("lm" ("left" "")) | |
| ("ln" ("list-style" "none")) | |
| ("lo" ("list-style-position" "outside")) | |
| ("lp" ("list-style-position" "")) | |
| ("lq" ("left" "")) | |
| ("lr" ("list-style-type" "lower-roman")) | |
| ("ls" ("letter-spacing" "")) | |
| ("lt" ("letter-spacing" "")) | |
| ("lu" ("list-style-type" "upper-roman")) | |
| ("lv" ("left" "")) | |
| ("lw" ("left" "")) | |
| ("lx" ("left" "")) | |
| ("ly" ("left" "")) | |
| ("lz" ("left" "")) | |
| ("m" ("margin" "")) | |
| ("ma" ("max-width" "")) | |
| ("mb" ("margin-bottom" "")) | |
| ("mc" ("margin" "")) | |
| ("md" ("margin" "")) | |
| ("me" ("margin" "")) | |
| ("mf" ("margin" "")) | |
| ("mg" ("margin" "")) | |
| ("mh" ("max-height" "")) | |
| ("mi" ("min-width" "")) | |
| ("mj" ("margin" "")) | |
| ("mk" ("margin" "")) | |
| ("ml" ("margin-left" "")) | |
| ("mm" ("margin" "")) | |
| ("mn" ("max-height" "none")) | |
| ("mo" ("margin" "")) | |
| ("mp" ("margin" "")) | |
| ("mq" ("margin" "")) | |
| ("mr" ("margin-right" "")) | |
| ("ms" ("margin" "")) | |
| ("mt" ("margin-top" "")) | |
| ("mu" ("margin" "")) | |
| ("mv" ("margin" "")) | |
| ("mw" ("max-width" "")) | |
| ("mx" ("margin" "")) | |
| ("my" ("margin" "")) | |
| ("mz" ("margin" "")) | |
| ("n" ("nav-down" "")) | |
| ("nb" ("bottom" "")) | |
| ("nc" ("content" "no-close-quote")) | |
| ("nd" ("display" "")) | |
| ("nf" ("font" "")) | |
| ("nh" ("height" "")) | |
| ("nl" ("left" "")) | |
| ("nm" ("word-wrap" "normal")) | |
| ("no" ("text-wrap" "none")) | |
| ("np" ("padding" "")) | |
| ("nq" ("quotes" "")) | |
| ("nr" ("right" "")) | |
| ("nt" ("top" "")) | |
| ("nv" ("visibility" "")) | |
| ("nw" ("white-space" "nowrap")) | |
| ("nz" ("z-index" "")) | |
| ("o" ("overflow" "")) | |
| ("oa" ("overflow" "auto")) | |
| ("ob" ("outline" "")) | |
| ("oc" ("outline-color" "#000")) | |
| ("od" ("outline" "")) | |
| ("of" ("outline" "")) | |
| ("og" ("outline" "")) | |
| ("oh" ("overflow" "hidden")) | |
| ("oi" ("outline-color" "invert")) | |
| ("oj" ("outline" "")) | |
| ("ok" ("outline" "")) | |
| ("ol" ("outline" "")) | |
| ("om" ("overflow-style" "move")) | |
| ("on" ("outline" "none")) | |
| ("oo" ("outline-offset" "")) | |
| ("op" ("opacity" "")) | |
| ("oq" ("overflow-style" "marquee")) | |
| ("or" ("orphans" "")) | |
| ("os" ("outline-style" "")) | |
| ("ot" ("outline" "")) | |
| ("ou" ("outline" "")) | |
| ("ov" ("overflow" "hidden")) | |
| ("ow" ("outline-width" "")) | |
| ("ox" ("overflow-x" "")) | |
| ("oy" ("overflow-y" "")) | |
| ("oz" ("outline" "")) | |
| ("p" ("padding" "")) | |
| ("pa" ("page-break-after" "")) | |
| ("pb" ("padding-bottom" "")) | |
| ("pc" ("padding" "")) | |
| ("pd" ("padding" "")) | |
| ("pe" ("padding" "")) | |
| ("pf" ("position" "fixed")) | |
| ("pg" ("page-break-before" "")) | |
| ("ph" ("padding" "")) | |
| ("pi" ("page-break-inside" "")) | |
| ("pj" ("padding" "")) | |
| ("pk" ("padding" "")) | |
| ("pl" ("padding-left" "")) | |
| ("pm" ("padding" "")) | |
| ("pn" ("padding" "")) | |
| ("po" ("position" "")) | |
| ("pp" ("padding" "")) | |
| ("pq" ("padding" "")) | |
| ("pr" ("padding-right" "")) | |
| ("ps" ("position" "")) | |
| ("pt" ("padding-top" "")) | |
| ("pu" ("page-break-after" "auto")) | |
| ("pv" ("page-break-inside" "avoid")) | |
| ("pw" ("padding" "")) | |
| ("px" ("padding" "")) | |
| ("py" ("padding" "")) | |
| ("pz" ("padding" "")) | |
| ("q" ("quotes" "")) | |
| ("qa" ("quotes" "")) | |
| ("qb" ("quotes" "")) | |
| ("qc" ("quotes" "")) | |
| ("qd" ("quotes" "")) | |
| ("qf" ("quotes" "")) | |
| ("qg" ("quotes" "")) | |
| ("qh" ("quotes" "")) | |
| ("qi" ("quotes" "")) | |
| ("qj" ("quotes" "")) | |
| ("qk" ("quotes" "")) | |
| ("ql" ("quotes" "")) | |
| ("qm" ("quotes" "")) | |
| ("qn" ("quotes" "none")) | |
| ("qo" ("quotes" "")) | |
| ("qp" ("quotes" "")) | |
| ("qq" ("quotes" "")) | |
| ("qs" ("quotes" "")) | |
| ("qt" ("quotes" "")) | |
| ("qv" ("quotes" "")) | |
| ("qw" ("quotes" "")) | |
| ("qx" ("quotes" "")) | |
| ("qy" ("quotes" "")) | |
| ("qz" ("quotes" "")) | |
| ("r" ("right" "100%")) | |
| ("ra" ("right" "auto")) | |
| ("rb" ("resize" "both")) | |
| ("rc" ("right" "")) | |
| ("rd" ("right" "")) | |
| ("re" ("right" "")) | |
| ("rf" ("right" "")) | |
| ("rg" ("right" "")) | |
| ("rh" ("resize" "horizontal")) | |
| ("ri" ("right" "")) | |
| ("rj" ("right" "")) | |
| ("rk" ("right" "")) | |
| ("rl" ("right" "")) | |
| ("rm" ("right" "")) | |
| ("rn" ("resize" "none")) | |
| ("ro" ("right" "")) | |
| ("rp" ("right" "")) | |
| ("rq" ("right" "")) | |
| ("rr" ("right" "")) | |
| ("rs" ("right" "")) | |
| ("rt" ("right" "")) | |
| ("ru" ("right" "")) | |
| ("rv" ("resize" "vertical")) | |
| ("rw" ("right" "")) | |
| ("rx" ("right" "")) | |
| ("ry" ("right" "")) | |
| ("rz" ("resize" "")) | |
| ("sb" ("bottom" "")) | |
| ("sc" ("white-space-collapse" "")) | |
| ("sd" ("transition-duration" "time")) | |
| ("sf" ("font" "")) | |
| ("si" ("list-style-image" "")) | |
| ("sk" ("transform" "skewX(angle)")) | |
| ("sl" ("left" "")) | |
| ("sm" ("font-smooth" "")) | |
| ("so" ("outline" "")) | |
| ("sp" ("transition-property" "prop")) | |
| ("sq" ("quotes" "")) | |
| ("sr" ("right" "")) | |
| ("ss" ("font-family" "sans-serif")) | |
| ("st" ("font-stretch" "")) | |
| ("su" ("vertical-align" "sub")) | |
| ("sv" ("visibility" "")) | |
| ("sw" ("width" "")) | |
| ("sz" ("z-index" "")) | |
| ("t" ("top" "")) | |
| ("ta" ("text-align" "left")) | |
| ("tb" ("table-layout" "")) | |
| ("tc" ("text-align" "center")) | |
| ("td" ("text-decoration" "none")) | |
| ("te" ("text-emphasis" "")) | |
| ("tf" ("transform" "")) | |
| ("tg" ("top" "")) | |
| ("th" ("text-height" "")) | |
| ("ti" ("text-indent" "")) | |
| ("tj" ("text-justify" "")) | |
| ("tk" ("text-justify" "kashida")) | |
| ("tl" ("text-align-last" "")) | |
| ("tm" ("text-height" "max-size")) | |
| ("tn" ("text-decoration" "none")) | |
| ("to" ("text-outline" "")) | |
| ("tp" ("transition-property" "prop")) | |
| ("tq" ("top" "")) | |
| ("tr" ("text-replace" "")) | |
| ("tt" ("text-transform" "uppercase")) | |
| ("tu" ("text-transform" "uppercase")) | |
| ("tv" ("top" "")) | |
| ("tw" ("text-wrap" "")) | |
| ("tx" ("transform" "translateX(x)")) | |
| ("ty" ("transform" "translateY(y)")) | |
| ("tz" ("top" "")) | |
| ("ub" ("vertical-align" "sub")) | |
| ("uc" ("font-stretch" "ultra-condensed")) | |
| ("ud" ("display" "")) | |
| ("ue" ("font-stretch" "ultra-expanded")) | |
| ("uf" ("font" "")) | |
| ("uh" ("height" "")) | |
| ("ul" ("left" "")) | |
| ("um" ("margin" "")) | |
| ("uo" ("outline" "")) | |
| ("up" ("vertical-align" "super")) | |
| ("uq" ("quotes" "")) | |
| ("ur" ("cursor" "")) | |
| ("us" ("user-select" "none")) | |
| ("ut" ("top" "")) | |
| ("uv" ("visibility" "")) | |
| ("uw" ("width" "")) | |
| ("uz" ("z-index" "")) | |
| ("v" ("visibility" "hidden")) | |
| ("va" ("vertical-align" "top")) | |
| ("vb" ("vertical-align" "bottom")) | |
| ("vc" ("visibility" "collapse")) | |
| ("vd" ("visibility" "")) | |
| ("ve" ("visibility" "")) | |
| ("vf" ("visibility" "")) | |
| ("vg" ("visibility" "")) | |
| ("vh" ("visibility" "hidden")) | |
| ("vi" ("visibility" "")) | |
| ("vj" ("visibility" "")) | |
| ("vk" ("visibility" "")) | |
| ("vl" ("vertical-align" "baseline")) | |
| ("vm" ("vertical-align" "middle")) | |
| ("vn" ("visibility" "")) | |
| ("vo" ("visibility" "")) | |
| ("vp" ("vertical-align" "super")) | |
| ("vq" ("visibility" "")) | |
| ("vr" ("visibility" "")) | |
| ("vs" ("vertical-align" "super")) | |
| ("vt" ("vertical-align" "top")) | |
| ("vu" ("vertical-align" "sub")) | |
| ("vv" ("visibility" "visible")) | |
| ("vw" ("visibility" "")) | |
| ("vx" ("visibility" "")) | |
| ("vy" ("visibility" "")) | |
| ("vz" ("visibility" "")) | |
| ("w" ("width" "")) | |
| ("wa" ("width" "auto")) | |
| ("wb" ("word-break" "")) | |
| ("wc" ("white-space-collapse" "")) | |
| ("wd" ("widows" "")) | |
| ("we" ("width" "")) | |
| ("wf" ("width" "")) | |
| ("wg" ("width" "")) | |
| ("wh" ("white-space" "")) | |
| ("wi" ("widows" "")) | |
| ("wj" ("width" "")) | |
| ("wk" ("word-break" "keep-all")) | |
| ("wl" ("word-break" "loose")) | |
| ("wm" ("word-wrap" "normal")) | |
| ("wn" ("white-space" "normal")) | |
| ("wo" ("word-break" "")) | |
| ("wp" ("white-space" "pre")) | |
| ("wq" ("width" "")) | |
| ("wr" ("width" "")) | |
| ("ws" ("word-spacing" "")) | |
| ("wt" ("width" "")) | |
| ("wu" ("word-wrap" "unrestricted")) | |
| ("wv" ("width" "")) | |
| ("ww" ("word-wrap" "")) | |
| ("wx" ("width" "")) | |
| ("wy" ("width" "")) | |
| ("wz" ("width" "")) | |
| ("xb" ("bottom" "")) | |
| ("xc" ("color" "#000")) | |
| ("xd" ("display" "")) | |
| ("xf" ("font" "")) | |
| ("xh" ("height" "")) | |
| ("xl" ("left" "")) | |
| ("xm" ("margin" "")) | |
| ("xo" ("outline" "")) | |
| ("xp" ("padding" "")) | |
| ("xq" ("quotes" "")) | |
| ("xr" ("right" "")) | |
| ("xt" ("top" "")) | |
| ("xv" ("visibility" "")) | |
| ("xw" ("width" "")) | |
| ("xz" ("box-sizing" "")) | |
| ("yb" ("bottom" "")) | |
| ("yc" ("color" "#000")) | |
| ("yd" ("display" "")) | |
| ("yf" ("font" "")) | |
| ("yh" ("height" "")) | |
| ("yl" ("left" "")) | |
| ("ym" ("margin" "")) | |
| ("yo" ("outline" "")) | |
| ("yp" ("padding" "")) | |
| ("yq" ("quotes" "")) | |
| ("yr" ("right" "")) | |
| ("yt" ("top" "")) | |
| ("yv" ("visibility" "")) | |
| ("yw" ("width" "")) | |
| ("yz" ("z-index" "")) | |
| ("z" ("z-index" "")) | |
| ("za" ("z-index" "auto")) | |
| ("zb" ("z-index" "")) | |
| ("zc" ("z-index" "")) | |
| ("zd" ("z-index" "")) | |
| ("ze" ("z-index" "")) | |
| ("zf" ("z-index" "")) | |
| ("zg" ("z-index" "")) | |
| ("zh" ("z-index" "")) | |
| ("zi" ("z-index" "")) | |
| ("zj" ("z-index" "")) | |
| ("zk" ("z-index" "")) | |
| ("zl" ("z-index" "")) | |
| ("zm" ("zoom" "1")) | |
| ("zn" ("z-index" "")) | |
| ("zo" ("zoom" "1")) | |
| ("zp" ("z-index" "")) | |
| ("zq" ("z-index" "")) | |
| ("zr" ("z-index" "")) | |
| ("zs" ("z-index" "")) | |
| ("zt" ("z-index" "")) | |
| ("zu" ("z-index" "")) | |
| ("zv" ("z-index" "")) | |
| ("zw" ("z-index" "")) | |
| ("zx" ("z-index" "")) | |
| ("zy" ("z-index" "")) | |
| ("zz" ("z-index" "")) | |
| ("@f" ("@font-face" "{font-family:|;src:url(|);}")) | |
| ("@i" ("@import" "url(|);")) | |
| ("@import" ("@import" "url(|);")) | |
| ("@m" ("@media" "screen {|}")) | |
| ("@media" ("@media" "screen {|}")) | |
| )) | |
| (tbl *zencss-prop-abbrevs*) | |
| ) | |
| (dolist (one-rule zencss-dic-3letters-over) | |
| (let ((k (car one-rule)) | |
| (v (cadr one-rule))) | |
| (setf (gethash k tbl) v))) | |
| (dolist (one-rule zencss-dic-2letters) | |
| (let ((k (car one-rule)) | |
| (v (cadr one-rule))) | |
| (setf (gethash k tbl) v))) | |
| )) | |
| (defvar *zencss-dic-test* | |
| '(("pos" "position:relative") | |
| ("pos:s" "position:static") | |
| ("pos:a" "position:absolute") | |
| ("pos:r" "position:relative") | |
| ("pos:f" "position:fixed") | |
| ("t" "top:|") | |
| ("t:a" "top:auto") | |
| ("r" "right:|") | |
| ("r:a" "right:auto") | |
| ("b" "bottom:|") | |
| ("b:a" "bottom:auto") | |
| ("l" "left:|") | |
| ("l:a" "left:auto") | |
| ("z" "z-index:|") | |
| ("z:a" "z-index:auto") | |
| ("fl" "float:left") | |
| ("fl:n" "float:none") | |
| ("fl:l" "float:left") | |
| ("fl:r" "float:right") | |
| ("cl" "clear:both") | |
| ("cl:n" "clear:none") | |
| ("cl:l" "clear:left") | |
| ("cl:r" "clear:right") | |
| ("cl:b" "clear:both") | |
| ("d" "display:block") | |
| ("d:n" "display:none") | |
| ("d:b" "display:block") | |
| ("d:i" "display:inline") | |
| ("d:ib" "display:inline-block") | |
| ("d:li" "display:list-item") | |
| ("d:ri" "display:run-in") | |
| ("d:cp" "display:compact") | |
| ("d:tb" "display:table") | |
| ("d:itb" "display:inline-table") | |
| ("d:tbcp" "display:table-caption") | |
| ("d:tbcl" "display:table-column") | |
| ("d:tbclg" "display:table-column-group") | |
| ("d:tbhg" "display:table-header-group") | |
| ("d:tbfg" "display:table-footer-group") | |
| ("d:tbr" "display:table-row") | |
| ("d:tbrg" "display:table-row-group") | |
| ("d:tbc" "display:table-cell") | |
| ("d:rb" "display:ruby") | |
| ("d:rbb" "display:ruby-base") | |
| ("d:rbbg" "display:ruby-base-group") | |
| ("d:rbt" "display:ruby-text") | |
| ("d:rbtg" "display:ruby-text-group") | |
| ("v" "visibility:hidden") | |
| ("v:v" "visibility:visible") | |
| ("v:h" "visibility:hidden") | |
| ("v:c" "visibility:collapse") | |
| ("ov" "overflow:hidden") | |
| ("ov:v" "overflow:visible") | |
| ("ov:h" "overflow:hidden") | |
| ("ov:s" "overflow:scroll") | |
| ("ov:a" "overflow:auto") | |
| ("ovx" "overflow-x:hidden") | |
| ("ovx:v" "overflow-x:visible") | |
| ("ovx:h" "overflow-x:hidden") | |
| ("ovx:s" "overflow-x:scroll") | |
| ("ovx:a" "overflow-x:auto") | |
| ("ovy" "overflow-y:hidden") | |
| ("ovy:v" "overflow-y:visible") | |
| ("ovy:h" "overflow-y:hidden") | |
| ("ovy:s" "overflow-y:scroll") | |
| ("ovy:a" "overflow-y:auto") | |
| ("ovs" "overflow-style:scrollbar") | |
| ("ovs:a" "overflow-style:auto") | |
| ("ovs:s" "overflow-style:scrollbar") | |
| ("ovs:p" "overflow-style:panner") | |
| ("ovs:m" "overflow-style:move") | |
| ("ovs:mq" "overflow-style:marquee") | |
| ("zoo" "zoom:1") | |
| ("zm" "zoom:1") | |
| ("cp" "clip:|") | |
| ("cp:a" "clip:auto") | |
| ("cp:r" "clip:rect(top right bottom left)") | |
| ("rsz" "resize:|") | |
| ("rsz:n" "resize:none") | |
| ("rsz:b" "resize:both") | |
| ("rsz:h" "resize:horizontal") | |
| ("rsz:v" "resize:vertical") | |
| ("cur" "cursor:${pointer}") | |
| ("cur:a" "cursor:auto") | |
| ("cur:d" "cursor:default") | |
| ("cur:c" "cursor:crosshair") | |
| ("cur:ha" "cursor:hand") | |
| ("cur:he" "cursor:help") | |
| ("cur:m" "cursor:move") | |
| ("cur:p" "cursor:pointer") | |
| ("cur:t" "cursor:text") | |
| ("m" "margin:|") | |
| ("m:a" "margin:auto") | |
| ("mt" "margin-top:|") | |
| ("mt:a" "margin-top:auto") | |
| ("mr" "margin-right:|") | |
| ("mr:a" "margin-right:auto") | |
| ("mb" "margin-bottom:|") | |
| ("mb:a" "margin-bottom:auto") | |
| ("ml" "margin-left:|") | |
| ("ml:a" "margin-left:auto") | |
| ("p" "padding:|") | |
| ("pt" "padding-top:|") | |
| ("pr" "padding-right:|") | |
| ("pb" "padding-bottom:|") | |
| ("pl" "padding-left:|") | |
| ("bxz" "box-sizing:border-box") | |
| ("bxz:cb" "box-sizing:content-box") | |
| ("bxz:bb" "box-sizing:border-box") | |
| ("bxsh" "box-shadow:inset hoff voff blur color") | |
| ("bxsh:r" "box-shadow:inset hoff voff blur spread rgb(0, 0, 0)") | |
| ("bxsh:ra" "box-shadow:inset h v blur spread rgba(0, 0, 0, .5)") | |
| ("bxsh:n" "box-shadow:none") | |
| ("w" "width:|") | |
| ("w:a" "width:auto") | |
| ("h" "height:|") | |
| ("h:a" "height:auto") | |
| ("maw" "max-width:|") | |
| ("maw:n" "max-width:none") | |
| ("mah" "max-height:|") | |
| ("mah:n" "max-height:none") | |
| ("miw" "min-width:|") | |
| ("mih" "min-height:|") | |
| ("f" "font:|") | |
| ("f+" "font:1em Arial,sans-serif") | |
| ("fw" "font-weight:|") | |
| ("fw:n" "font-weight:normal") | |
| ("fw:b" "font-weight:bold") | |
| ("fw:br" "font-weight:bolder") | |
| ("fw:lr" "font-weight:lighter") | |
| ("fs" "font-style:${italic}") | |
| ("fs:n" "font-style:normal") | |
| ("fs:i" "font-style:italic") | |
| ("fs:o" "font-style:oblique") | |
| ("fv" "font-variant:|") | |
| ("fv:n" "font-variant:normal") | |
| ("fv:sc" "font-variant:small-caps") | |
| ("fz" "font-size:|") | |
| ("fza" "font-size-adjust:|") | |
| ("fza:n" "font-size-adjust:none") | |
| ("ff" "font-family:|") | |
| ("ff:s" "font-family:serif") | |
| ("ff:ss" "font-family:sans-serif") | |
| ("ff:c" "font-family:cursive") | |
| ("ff:f" "font-family:fantasy") | |
| ("ff:m" "font-family:monospace") | |
| ("ff:a" "font-family: Arial, "Helvetica Neue", Helvetica, sans-serif") | |
| ("fef" "font-effect:|") | |
| ("fef:n" "font-effect:none") | |
| ("fef:eg" "font-effect:engrave") | |
| ("fef:eb" "font-effect:emboss") | |
| ("fef:o" "font-effect:outline") | |
| ("fem" "font-emphasize:|") | |
| ("femp" "font-emphasize-position:|") | |
| ("femp:b" "font-emphasize-position:before") | |
| ("femp:a" "font-emphasize-position:after") | |
| ("fems" "font-emphasize-style:|") | |
| ("fems:n" "font-emphasize-style:none") | |
| ("fems:ac" "font-emphasize-style:accent") | |
| ("fems:dt" "font-emphasize-style:dot") | |
| ("fems:c" "font-emphasize-style:circle") | |
| ("fems:ds" "font-emphasize-style:disc") | |
| ("fsm" "font-smooth:|") | |
| ("fsm:a" "font-smooth:auto") | |
| ("fsm:n" "font-smooth:never") | |
| ("fsm:aw" "font-smooth:always") | |
| ("fst" "font-stretch:|") | |
| ("fst:n" "font-stretch:normal") | |
| ("fst:uc" "font-stretch:ultra-condensed") | |
| ("fst:ec" "font-stretch:extra-condensed") | |
| ("fst:c" "font-stretch:condensed") | |
| ("fst:sc" "font-stretch:semi-condensed") | |
| ("fst:se" "font-stretch:semi-expanded") | |
| ("fst:e" "font-stretch:expanded") | |
| ("fst:ee" "font-stretch:extra-expanded") | |
| ("fst:ue" "font-stretch:ultra-expanded") | |
| ("va" "vertical-align:top") | |
| ("va:sup" "vertical-align:super") | |
| ("va:t" "vertical-align:top") | |
| ("va:tt" "vertical-align:text-top") | |
| ("va:m" "vertical-align:middle") | |
| ("va:bl" "vertical-align:baseline") | |
| ("va:b" "vertical-align:bottom") | |
| ("va:tb" "vertical-align:text-bottom") | |
| ("va:sub" "vertical-align:sub") | |
| ("ta" "text-align:left") | |
| ("ta:l" "text-align:left") | |
| ("ta:c" "text-align:center") | |
| ("ta:r" "text-align:right") | |
| ("ta:j" "text-align:justify") | |
| ("ta-lst" "text-align-last:|") | |
| ("tal:a" "text-align-last:auto") | |
| ("tal:l" "text-align-last:left") | |
| ("tal:c" "text-align-last:center") | |
| ("tal:r" "text-align-last:right") | |
| ("td" "text-decoration:none") | |
| ("td:n" "text-decoration:none") | |
| ("td:u" "text-decoration:underline") | |
| ("td:o" "text-decoration:overline") | |
| ("td:l" "text-decoration:line-through") | |
| ("te" "text-emphasis:|") | |
| ("te:n" "text-emphasis:none") | |
| ("te:ac" "text-emphasis:accent") | |
| ("te:dt" "text-emphasis:dot") | |
| ("te:c" "text-emphasis:circle") | |
| ("te:ds" "text-emphasis:disc") | |
| ("te:b" "text-emphasis:before") | |
| ("te:a" "text-emphasis:after") | |
| ("th" "text-height:|") | |
| ("th:a" "text-height:auto") | |
| ("th:f" "text-height:font-size") | |
| ("th:t" "text-height:text-size") | |
| ("th:m" "text-height:max-size") | |
| ("ti" "text-indent:|") | |
| ("ti:-" "text-indent:-9999px") | |
| ("tj" "text-justify:|") | |
| ("tj:a" "text-justify:auto") | |
| ("tj:iw" "text-justify:inter-word") | |
| ("tj:ii" "text-justify:inter-ideograph") | |
| ("tj:ic" "text-justify:inter-cluster") | |
| ("tj:d" "text-justify:distribute") | |
| ("tj:k" "text-justify:kashida") | |
| ("tj:t" "text-justify:tibetan") | |
| ("to" "text-outline:|") | |
| ("to+" "text-outline:0 0 #000") | |
| ("to:n" "text-outline:none") | |
| ("tr" "text-replace:|") | |
| ("tr:n" "text-replace:none") | |
| ("tt" "text-transform:uppercase") | |
| ("tt:n" "text-transform:none") | |
| ("tt:c" "text-transform:capitalize") | |
| ("tt:u" "text-transform:uppercase") | |
| ("tt:l" "text-transform:lowercase") | |
| ("tw" "text-wrap:|") | |
| ("tw:n" "text-wrap:normal") | |
| ("tw:no" "text-wrap:none") | |
| ("tw:u" "text-wrap:unrestricted") | |
| ("tw:s" "text-wrap:suppress") | |
| ("tsh" "text-shadow:hoff voff blur #000") | |
| ("tsh:r" "text-shadow:h v blur rgb(0, 0, 0)") | |
| ("tsh:ra" "text-shadow:h v blur rgba(0, 0, 0, .5)") | |
| ("tsh+" "text-shadow:0 0 0 #000") | |
| ("tsh:n" "text-shadow:none") | |
| ("lh" "line-height:|") | |
| ("lts" "letter-spacing:|") | |
| ("whs" "white-space:|") | |
| ("whs:n" "white-space:normal") | |
| ("whs:p" "white-space:pre") | |
| ("whs:nw" "white-space:nowrap") | |
| ("whs:pw" "white-space:pre-wrap") | |
| ("whs:pl" "white-space:pre-line") | |
| ("whsc" "white-space-collapse:|") | |
| ("whsc:n" "white-space-collapse:normal") | |
| ("whsc:k" "white-space-collapse:keep-all") | |
| ("whsc:l" "white-space-collapse:loose") | |
| ("whsc:bs" "white-space-collapse:break-strict") | |
| ("whsc:ba" "white-space-collapse:break-all") | |
| ("wob" "word-break:|") | |
| ("wob:n" "word-break:normal") | |
| ("wob:k" "word-break:keep-all") | |
| ("wob:l" "word-break:loose") | |
| ("wob:bs" "word-break:break-strict") | |
| ("wob:ba" "word-break:break-all") | |
| ("wos" "word-spacing:|") | |
| ("wow" "word-wrap:|") | |
| ("wow:nm" "word-wrap:normal") | |
| ("wow:n" "word-wrap:none") | |
| ("wow:u" "word-wrap:unrestricted") | |
| ("wow:s" "word-wrap:suppress") | |
| ("wow:b" "word-wrap:break-word") | |
| ("bg" "background:|") | |
| ("bg+" "background:#fff url(|) 0 0 no-repeat") | |
| ("bg:n" "background:none") | |
| ("bgc" "background-color:#fff") | |
| ("bgc:t" "background-color:transparent") | |
| ("bgi" "background-image:url(|)") | |
| ("bgi:n" "background-image:none") | |
| ("bgr" "background-repeat:|") | |
| ("bgr:n" "background-repeat:no-repeat") | |
| ("bgr:x" "background-repeat:repeat-x") | |
| ("bgr:y" "background-repeat:repeat-y") | |
| ("bgr:sp" "background-repeat:space") | |
| ("bgr:rd" "background-repeat:round") | |
| ("bga" "background-attachment:|") | |
| ("bga:f" "background-attachment:fixed") | |
| ("bga:s" "background-attachment:scroll") | |
| ("bgp" "background-position:0 0") | |
| ("bgpx" "background-position-x:|") | |
| ("bgpy" "background-position-y:|") | |
| ("bgbk" "background-break:|") | |
| ("bgbk:bb" "background-break:bounding-box") | |
| ("bgbk:eb" "background-break:each-box") | |
| ("bgbk:c" "background-break:continuous") | |
| ("bgcp" "background-clip:padding-box") | |
| ("bgcp:bb" "background-clip:border-box") | |
| ("bgcp:pb" "background-clip:padding-box") | |
| ("bgcp:cb" "background-clip:content-box") | |
| ("bgcp:nc" "background-clip:no-clip") | |
| ("bgo" "background-origin:|") | |
| ("bgo:pb" "background-origin:padding-box") | |
| ("bgo:bb" "background-origin:border-box") | |
| ("bgo:cb" "background-origin:content-box") | |
| ("bgsz" "background-size:|") | |
| ("bgsz:a" "background-size:auto") | |
| ("bgsz:ct" "background-size:contain") | |
| ("bgsz:cv" "background-size:cover") | |
| ("c" "color:#000") | |
| ("c:r" "color:rgb(0, 0, 0)") | |
| ("c:ra" "color:rgba(0, 0, 0, .5)") | |
| ("op" "opacity:|") | |
| ("cnt" "content:'|'") | |
| ("cnt:n" "content:normal") | |
| ("cnt:oq" "content:open-quote") | |
| ("cnt:noq" "content:no-open-quote") | |
| ("cnt:cq" "content:close-quote") | |
| ("cnt:ncq" "content:no-close-quote") | |
| ("cnt:a" "content:attr(|)") | |
| ("cnt:c" "content:counter(|)") | |
| ("cnt:cs" "content:counters(|)") | |
| ("ct" "content:|") | |
| ("ct:n" "content:normal") | |
| ("ct:oq" "content:open-quote") | |
| ("ct:noq" "content:no-open-quote") | |
| ("ct:cq" "content:close-quote") | |
| ("ct:ncq" "content:no-close-quote") | |
| ("ct:a" "content:attr(|)") | |
| ("ct:c" "content:counter(|)") | |
| ("ct:cs" "content:counters(|)") | |
| ("q" "quotes:|") | |
| ("q:n" "quotes:none") | |
| ("q:ru" "quotes:'\00AB' '\00BB' '\201E' '\201C'") | |
| ("q:en" "quotes:'\201C' '\201D' '\2018' '\2019'") | |
| ("coi" "counter-increment:|") | |
| ("cor" "counter-reset:|") | |
| ("ol" "outline:|") | |
| ("ol:n" "outline:none") | |
| ("olo" "outline-offset:|") | |
| ("olw" "outline-width:|") | |
| ("ols" "outline-style:|") | |
| ("olc" "outline-color:#000") | |
| ("olc:i" "outline-color:invert") | |
| ("tbl" "table-layout:|") | |
| ("tbl:a" "table-layout:auto") | |
| ("tbl:f" "table-layout:fixed") | |
| ("cps" "caption-side:|") | |
| ("cps:t" "caption-side:top") | |
| ("cps:b" "caption-side:bottom") | |
| ("ec" "empty-cells:|") | |
| ("ec:s" "empty-cells:show") | |
| ("ec:h" "empty-cells:hide") | |
| ("bd" "border:|") | |
| ("bd+" "border:1px solid #000") | |
| ("bd:n" "border:none") | |
| ("bdbk" "border-break:close") | |
| ("bdbk:c" "border-break:close") | |
| ("bdcl" "border-collapse:|") | |
| ("bdcl:c" "border-collapse:collapse") | |
| ("bdcl:s" "border-collapse:separate") | |
| ("bdc" "border-color:#000") | |
| ("bdc:t" "border-color:transparent") | |
| ("bdi" "border-image:url(|)") | |
| ("bdi:n" "border-image:none") | |
| ("bdti" "border-top-image:url(|)") | |
| ("bdti:n" "border-top-image:none") | |
| ("bdri" "border-right-image:url(|)") | |
| ("bdri:n" "border-right-image:none") | |
| ("bdbi" "border-bottom-image:url(|)") | |
| ("bdbi:n" "border-bottom-image:none") | |
| ("bdli" "border-left-image:url(|)") | |
| ("bdli:n" "border-left-image:none") | |
| ("bdci" "border-corner-image:url(|)") | |
| ("bdci:n" "border-corner-image:none") | |
| ("bdci:c" "border-corner-image:continue") | |
| ("bdtli" "border-top-left-image:url(|)") | |
| ("bdtli:n" "border-top-left-image:none") | |
| ("bdtli:c" "border-top-left-image:continue") | |
| ("bdtri" "border-top-right-image:url(|)") | |
| ("bdtri:n" "border-top-right-image:none") | |
| ("bdtri:c" "border-top-right-image:continue") | |
| ("bdbri" "border-bottom-right-image:url(|)") | |
| ("bdbri:n" "border-bottom-right-image:none") | |
| ("bdbri:c" "border-bottom-right-image:continue") | |
| ("bdbli" "border-bottom-left-image:url(|)") | |
| ("bdbli:n" "border-bottom-left-image:none") | |
| ("bdbli:c" "border-bottom-left-image:continue") | |
| ("bdf" "border-fit:repeat") | |
| ("bdf:c" "border-fit:clip") | |
| ("bdf:r" "border-fit:repeat") | |
| ("bdf:sc" "border-fit:scale") | |
| ("bdf:st" "border-fit:stretch") | |
| ("bdf:ow" "border-fit:overwrite") | |
| ("bdf:of" "border-fit:overflow") | |
| ("bdf:sp" "border-fit:space") | |
| ("bdlen" "border-length:|") | |
| ("bdlen:a" "border-length:auto") | |
| ("bdsp" "border-spacing:|") | |
| ("bds" "border-style:|") | |
| ("bds:n" "border-style:none") | |
| ("bds:h" "border-style:hidden") | |
| ("bds:dt" "border-style:dotted") | |
| ("bds:ds" "border-style:dashed") | |
| ("bds:s" "border-style:solid") | |
| ("bds:db" "border-style:double") | |
| ("bds:dtds" "border-style:dot-dash") | |
| ("bds:dtdtds" "border-style:dot-dot-dash") | |
| ("bds:w" "border-style:wave") | |
| ("bds:g" "border-style:groove") | |
| ("bds:r" "border-style:ridge") | |
| ("bds:i" "border-style:inset") | |
| ("bds:o" "border-style:outset") | |
| ("bdw" "border-width:|") | |
| ("bdt" "border-top:|") | |
| ("bt" "border-top:|") | |
| ("bdt+" "border-top:1px solid #000") | |
| ("bdt:n" "border-top:none") | |
| ("bdtw" "border-top-width:|") | |
| ("bdts" "border-top-style:|") | |
| ("bdts:n" "border-top-style:none") | |
| ("bdtc" "border-top-color:#000") | |
| ("bdtc:t" "border-top-color:transparent") | |
| ("bdr" "border-right:|") | |
| ("br" "border-right:|") | |
| ("bdr+" "border-right:1px solid #000") | |
| ("bdr:n" "border-right:none") | |
| ("bdrw" "border-right-width:|") | |
| ("bdrst" "border-right-style:|") | |
| ("bdrst:n" "border-right-style:none") | |
| ("bdrc" "border-right-color:#000") | |
| ("bdrc:t" "border-right-color:transparent") | |
| ("bdb" "border-bottom:|") | |
| ("bb" "border-bottom:|") | |
| ("bdb+" "border-bottom:1px solid #000") | |
| ("bdb:n" "border-bottom:none") | |
| ("bdbw" "border-bottom-width:|") | |
| ("bdbs" "border-bottom-style:|") | |
| ("bdbs:n" "border-bottom-style:none") | |
| ("bdbc" "border-bottom-color:#000") | |
| ("bdbc:t" "border-bottom-color:transparent") | |
| ("bdl" "border-left:|") | |
| ("bl" "border-left:|") | |
| ("bdl+" "border-left:1px solid #000") | |
| ("bdl:n" "border-left:none") | |
| ("bdlw" "border-left-width:|") | |
| ("bdls" "border-left-style:|") | |
| ("bdls:n" "border-left-style:none") | |
| ("bdlc" "border-left-color:#000") | |
| ("bdlc:t" "border-left-color:transparent") | |
| ("bdrs" "border-radius:|") | |
| ("bdtrrs" "border-top-right-radius:|") | |
| ("bdtlrs" "border-top-left-radius:|") | |
| ("bdbrrs" "border-bottom-right-radius:|") | |
| ("bdblrs" "border-bottom-left-radius:|") | |
| ("lis" "list-style:|") | |
| ("lis:n" "list-style:none") | |
| ("lisp" "list-style-position:|") | |
| ("lisp:i" "list-style-position:inside") | |
| ("lisp:o" "list-style-position:outside") | |
| ("list" "list-style-type:|") | |
| ("list:n" "list-style-type:none") | |
| ("list:d" "list-style-type:disc") | |
| ("list:c" "list-style-type:circle") | |
| ("list:s" "list-style-type:square") | |
| ("list:dc" "list-style-type:decimal") | |
| ("list:dclz" "list-style-type:decimal-leading-zero") | |
| ("list:lr" "list-style-type:lower-roman") | |
| ("list:ur" "list-style-type:upper-roman") | |
| ("lisi" "list-style-image:|") | |
| ("lisi:n" "list-style-image:none") | |
| ("pgbb" "page-break-before:|") | |
| ("pgbb:au" "page-break-before:auto") | |
| ("pgbb:al" "page-break-before:always") | |
| ("pgbb:l" "page-break-before:left") | |
| ("pgbb:r" "page-break-before:right") | |
| ("pgbi" "page-break-inside:|") | |
| ("pgbi:au" "page-break-inside:auto") | |
| ("pgbi:av" "page-break-inside:avoid") | |
| ("pgba" "page-break-after:|") | |
| ("pgba:au" "page-break-after:auto") | |
| ("pgba:al" "page-break-after:always") | |
| ("pgba:l" "page-break-after:left") | |
| ("pgba:r" "page-break-after:right") | |
| ("orp" "orphans:|") | |
| ("wid" "widows:|") | |
| ("!" "!important") | |
| ("@f" "@font-face {font-family:|;src:url(|);}") | |
| ("@f+" "@font-face {font-family: 'FontName';src: url('FileName.eot');src: url('FileName.eot?#iefix') format('embedded-opentype'),url('FileName.woff') format('woff'),url('FileName.ttf') format('truetype'),url('FileName.svg#FontName') format('svg');font-style: normal;font-weight: normal;}") | |
| ("@i" "@import url(|)") | |
| ("@import" "@import url(|)") | |
| ("@kf" "@-webkit-keyframes identifier {from {|}|to {|}}@-o-keyframes identifier {from {|}|to {|}}@-moz-keyframes identifier {from {|}|to {|}}@keyframes identifier {from {|}|to {|}}") | |
| ("@m" "@media screen {|}") | |
| ("@media" "@media screen {|}") | |
| ("anim" "animation:|") | |
| ("anim-" "animation:name duration timing-function delay iteration-count direction fill-mode") | |
| ("animdel" "animation-delay:time") | |
| ("animdir" "animation-direction:normal") | |
| ("animdir:a" "animation-direction:alternate") | |
| ("animdir:ar" "animation-direction:alternate-reverse") | |
| ("animdir:n" "animation-direction:normal") | |
| ("animdir:r" "animation-direction:reverse") | |
| ("animdur" "animation-duration:0s") | |
| ("animfm" "animation-fill-mode:both") | |
| ("animfm:b" "animation-fill-mode:backwards") | |
| ("animfm:bt" "animation-fill-mode:both") | |
| ("animfm:bh" "animation-fill-mode:both") | |
| ("animfm:f" "animation-fill-mode:forwards") | |
| ("animic" "animation-iteration-count:1") | |
| ("animic:i" "animation-iteration-count:infinite") | |
| ("animn" "animation-name:none") | |
| ("animps" "animation-play-state:running") | |
| ("animps:p" "animation-play-state:paused") | |
| ("animps:r" "animation-play-state:running") | |
| ("animtf" "animation-timing-function:linear") | |
| ("animtf:cb" "animation-timing-function:cubic-bezier(0.1, 0.7, 1.0, 0.1)") | |
| ("animtf:e" "animation-timing-function:ease") | |
| ("animtf:ei" "animation-timing-function:ease-in") | |
| ("animtf:eio" "animation-timing-function:ease-in-out") | |
| ("animtf:eo" "animation-timing-function:ease-out") | |
| ("animtf:l" "animation-timing-function:linear") | |
| ("ap" "appearance:${none}") | |
| ("bg:ie" "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='x.png',sizingMethod='crop')") | |
| ("cm" "/* |${child} */") | |
| ("colm" "columns:|") | |
| ("colmc" "column-count:|") | |
| ("colmf" "column-fill:|") | |
| ("colmg" "column-gap:|") | |
| ("colmr" "column-rule:|") | |
| ("colmrc" "column-rule-color:|") | |
| ("colmrs" "column-rule-style:|") | |
| ("colmrw" "column-rule-width:|") | |
| ("colms" "column-span:|") | |
| ("colmw" "column-width:|") | |
| ("mar" "max-resolution:res") | |
| ("mir" "min-resolution:res") | |
| ("op:ie" "filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=100)") | |
| ("op:ms" "-ms-filter:'progid:DXImageTransform.Microsoft.Alpha(Opacity=100)'") | |
| ("ori" "orientation:|") | |
| ("ori:l" "orientation:landscape") | |
| ("ori:p" "orientation:portrait") | |
| ("tov" "text-overflow:${ellipsis}") | |
| ("tov:c" "text-overflow:clip") | |
| ("tov:e" "text-overflow:ellipsis") | |
| ("trf" "transform:|") | |
| ("trf:r" "transform: rotate(|)") | |
| ("trf:sc" "transform: scale(|, |)") | |
| ("trf:scx" "transform: scaleX(|)") | |
| ("trf:scy" "transform: scaleY(|)") | |
| ("trf:skx" "transform: skewX(|)") | |
| ("trf:sky" "transform: skewY(|)") | |
| ("trf:t" "transform: translate(|, |)") | |
| ("trf:tx" "transform: translateX(|)") | |
| ("trf:ty" "transform: translateY(|)") | |
| ("trfo" "transform-origin:|") | |
| ("trfs" "transform-style:preserve-3d") | |
| ("trs" "transition:prop time") | |
| ("trsde" "transition-delay:time") | |
| ("trsdu" "transition-duration:time") | |
| ("trsp" "transition-property:prop") | |
| ("trstf" "transition-timing-function:tfunc") | |
| ("us" "user-select:${none}") | |
| ("wfsm" "-webkit-font-smoothing:${antialiased}") | |
| ("wfsm:a" "-webkit-font-smoothing:antialiased") | |
| ("wfsm:n" "-webkit-font-smoothing:none") | |
| ("wfsm:s" "-webkit-font-smoothing:subpixel-antialiased") | |
| ("wfsm:sa" "-webkit-font-smoothing:subpixel-antialiased"))) | |
| (defvar *zencss-favorites-standard* nil) | |
| (unless *zencss-favorites-standard* | |
| ;;(unless (= 0 1) | |
| (setq *zencss-favorites-standard* (make-hash-table :test #'equalp)) | |
| (let ((tbl *zencss-favorites-standard*) | |
| (dic | |
| '(("f+" "font:1em Arial,sans-serif") | |
| ("to+" "text-outline:0 0 #000") | |
| ("tsh+" "text-shadow:0 0 0 #000") | |
| ("bg+" "background:#fff url(|) 0 0 no-repeat") | |
| ("bd+" "border:1px solid #000") | |
| ("bdt+" "border-top:1px solid #000") | |
| ("bdr+" "border-right:1px solid #000") | |
| ("bdb+" "border-bottom:1px solid #000") | |
| ("bdl+" "border-left:1px solid #000") | |
| ("@f+" "@font-face {font-family: 'FontName';src: url('FileName.eot');src: url('FileName.eot?#iefix') format('embedded-opentype'),url('FileName.woff') format('woff'),url('FileName.ttf') format('truetype'),url('FileName.svg#FontName') format('svg');font-style: normal;font-weight: normal;}") | |
| ))) | |
| (dolist (one-elem dic) | |
| (let* ((k (car one-elem)) | |
| (v (cadr one-elem)) | |
| (cand (gethash k tbl))) | |
| (setf (gethash k tbl) | |
| (if cand (cons v cand) (cons v nil))))) | |
| )) | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;;; [css-expand] part of user-interface ;;; | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;;まず対象となる区間を取ります。 | |
| ;;1. selection領域がある場合、その最初の行の選択されている区間を対象区間とする。 | |
| ;;2. 同じ行で、カーソル位置より前にmarkがあれば、markからカーソル位置までが対象区間 | |
| ;;3. 同じ行で、カーソル位置より前に2つ以上のスペースがある場合、そこからカーソル位置までが対象区間 | |
| ;;4. 同じ行で、カーソル位置より前に"*" がある場合、そこからカーソル位置までが対象区間 | |
| ;;5. 1,2,3,4でない場合、行頭からカーソル位置までを対象区間とする。 | |
| ;;6. ただし、「カーソル位置まで」とあるのは、カーソル位置からうしろの空白または改行までを対象とすることを意味します。 | |
| (defun zencss-pick-previous-word () | |
| (interactive "*p") | |
| (let (ans | |
| posfrom | |
| posto | |
| (posnow (point))) | |
| ;;1. selection領域がある場合、その最初の行の選択されている区間を対象区間とする。 | |
| (when (= 2 (or (get-selection-type) 0)) | |
| (setf posfrom (min (selection-mark) (selection-point))) | |
| (setf posto (max (selection-mark) (selection-point))) | |
| (setf posto (min ((goto-char posfrom) (goto-eol) (point)) posto)) | |
| (setf ans (buffer-substring posfrom posto)) | |
| (goto-char posto) | |
| (return-from zencss-pick-previous-word (values ans 0)) | |
| ) | |
| (let* ((posbol (progn (goto-char posnow) (goto-bol) (point))) | |
| (poseol (progn (goto-char posnow) (goto-eol) (point))) | |
| (poslst (min (progn (goto-char posnow) (if (looking-at "[ \t ]") (match-beginning 0) poseol)) poseol))) | |
| ;;2. 同じ行で、カーソル位置より前にmarkがあれば、markからカーソル位置までが対象区間 | |
| (let ((mk (mark t))) | |
| (when (and mk (<= posbol mk ) (< mk posnow)) | |
| ;; (setf ans (buffer-substring mk poslst)) | |
| ;; (goto-char poslst) | |
| (setf ans (buffer-substring mk posnow)) | |
| (goto-char posnow) | |
| (return-from zencss-pick-previous-word (values ans 0)))) | |
| ;;3. 同じ行で、カーソル位置より前に2つ以上のスペースがある場合、そこからカーソル位置までが対象区間 | |
| ;;4. 同じ行で、カーソル位置より前に"*" がある場合、そこからカーソル位置までが対象区間 | |
| (let (offset | |
| (cand0 (progn (goto-char posnow) (if (scan-buffer " " :reverse t) (match-end 0) -1))) | |
| (cand1 (progn (goto-char posnow) (if (scan-buffer "*" :reverse t) (match-end 0) -1)))) | |
| (if (> cand0 cand1) | |
| (progn (setf posfrom cand0) (setf offset 2)) | |
| (progn (setf posfrom cand1) (setf offset 1))) | |
| (when (and (<= posbol posfrom) (<= posfrom posnow)) | |
| (setf ans (buffer-substring posfrom poslst)) | |
| (goto-char poslst) | |
| (return-from zencss-pick-previous-word (values ans offset)))) | |
| ;;5. 1,2,3,4でない場合、行頭からカーソル位置までを対象区間とする。 | |
| (setf ans (buffer-substring posbol poslst)) | |
| (goto-char poslst) | |
| (values ans 0)))) | |
| (defun zencss-insert () | |
| (interactive) | |
| (multiple-value-bind (input offset) (zencss-pick-previous-word) | |
| (setf input (string-left-trim " \t " input)) | |
| (let* (expanded-str | |
| (lst-expanded (zencss-expand input)) | |
| (loc (point))) | |
| (if lst-expanded | |
| (progn | |
| (setf expanded-str (zencss-string-join lst-expanded "\n\t")) | |
| (if (string-match ":" (car lst-expanded)) (setf expanded-str (concat "\t" expanded-str))) | |
| (backward-delete-char-untabify (+ (length input) offset)) | |
| (insert expanded-str)) | |
| (message "[ZEN] illegal format..."))))) | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;;; [css-expand] part of module-logic ;;; | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;;parserです。 | |
| ;;0.CSSは木構造ではないので、nodeのリストを返します。 | |
| ;;1.スペース" " が 値同士のセパレータか、プロパティの終了セパレータか2つの意味があることに注意。 | |
| ;;2.プロパティなしの 値のみの空ノードのpropertyとして"@"を使います。 | |
| (defun zencss-parser (lst-token) | |
| (let* ( | |
| pair | |
| (heritage "") | |
| (stat-prop 0) | |
| (stat-valu 1) | |
| (mode stat-prop) | |
| (lst-pair '()) | |
| ) | |
| (dolist (token lst-token) | |
| (cond ((or (equal ";" token) (equal "+" token)) | |
| (when pair | |
| (if (and (= mode stat-prop) | |
| (gethash (concat (aref pair 1) token) *zencss-favorites-standard*)) | |
| (setf (aref pair 1) (concat (aref pair 1) token)) | |
| (progn | |
| (push pair lst-pair) | |
| (setf pair nil) | |
| (setf mode stat-prop) | |
| )) | |
| )) | |
| ((equal "!" token) | |
| (if (not pair) (setf pair (zencss-item-new "ELEMENT" "@"))) | |
| (setf (aref pair 3) 1) | |
| (push pair lst-pair) | |
| (setf pair nil) | |
| (setf mode stat-prop)) | |
| ((or (equal ":" token) (equal "-" token)) | |
| (setf mode stat-valu)) | |
| ;; ((equal "-" token) | |
| ;; (cond | |
| ;; ((= mode stat-prop) | |
| ;; (setf mode stat-valu)) | |
| ;; ((= mode stat-valu) | |
| ;; (setf heritage (concat heritage token))))) | |
| ((and (equal " " token) (= mode stat-prop)) | |
| (setf mode stat-valu)) | |
| ((and (not (equal " " token)) (= mode stat-prop)) | |
| (if (zencss-is-vstart token) | |
| (progn | |
| (if (not pair) (setf pair (zencss-item-new "ELEMENT" "@"))) | |
| (setf mode stat-valu) | |
| (push token (aref pair 2)) | |
| ) | |
| (progn | |
| (if pair (push pair lst-pair)) | |
| (setf pair (zencss-item-new "ELEMENT" token))))) | |
| ((and (not (equal " " token)) (= mode stat-valu)) | |
| (when heritage | |
| (setf token (concat heritage token)) | |
| (setf heritage "")) | |
| (if pair (push token (aref pair 2)))) | |
| ) | |
| ) | |
| (if pair (push pair lst-pair)) | |
| (dolist (one lst-pair) | |
| (setf (aref one 2) (reverse (aref one 2)))) | |
| (reverse lst-pair) | |
| )) | |
| ;;構文木のノードを作成します。 | |
| ;;typ : ELEMENT | |
| (defun zencss-item-new (typ property) | |
| (let (ans | |
| (lst-value '()) | |
| (flg-important 0) | |
| ) | |
| (setf ans (make-array 4)) | |
| (setf (aref ans 0) typ) ;;type | |
| (setf (aref ans 1) property) ;;property | |
| (setf (aref ans 2) lst-value) ;;values | |
| (setf (aref ans 3) flg-important) ;;is important | |
| ans)) | |
| ;;lexer です。 | |
| ;;0. tokenのリストを返します。 | |
| ;;1. 値の羅列 "10e3p45" → "10e" "3p" "45" | |
| ;;2. 全体的にですが、pushして全体をreverseする、を行っています。 | |
| ;; 2-1. 並び順で混乱しない。 | |
| ;; 2-2. 局所的には mapを使うべきだが 使えないところがあるので 手順的に統一する。 | |
| (defun zencss-lexer (input) | |
| (let* (c | |
| (prev-is-vstart nil) | |
| (now-is-vstart nil) | |
| (color-mode nil) | |
| (token nil) | |
| (lst-token '())) | |
| (dotimes (i (length input)) | |
| (setf c (string (char input i))) | |
| (setf now-is-vstart (zencss-is-vstart c)) | |
| (if (zencss-is-specifier c) | |
| (progn | |
| (if (> (length token) 0) | |
| (progn | |
| (push token lst-token) | |
| (setf token nil))) | |
| (push c lst-token)) | |
| (progn | |
| (if (equal "#" c) (setf prev-is-vstart nil)) | |
| (if (and (not (equal "#" c)) color-mode) | |
| (setf now-is-vstart (not (zencss-is-vcolor c)))) | |
| (if (and (not prev-is-vstart) now-is-vstart) | |
| (progn | |
| (if (> (length token) 0) | |
| (push token lst-token)) | |
| (setf color-mode (equal "#" c)) | |
| (setf token c)) | |
| (setf token (concat token c)))) | |
| ) | |
| (setf prev-is-vstart now-is-vstart) | |
| ) | |
| (if (and token (length token)) | |
| (push token lst-token)) | |
| (if (length lst-token) | |
| (setf lst-token (reverse lst-token))) | |
| ;;"-"の処理をここでまとめて行う。次のtokenが ^[.0-9] の場合は次にくっつけて自分は":"扱いにする. | |
| (dotimes (i (- (length lst-token) 1)) | |
| (let ((tnow (nth i lst-token)) | |
| (tnxt (nth (+ i 1) lst-token))) | |
| (when (and (equal "-" tnow) | |
| (string-match "^[.0-9]" tnxt)) | |
| (setf (nth (+ i 1) lst-token) (concat tnow tnxt)) | |
| (setf (nth i lst-token) ":") | |
| ) | |
| )) | |
| (return-from zencss-lexer lst-token))) | |
| ;;区切り文字判定 | |
| (defun zencss-is-specifier (c) | |
| (and (= 1 (length c)) | |
| (string-match "[-:;!+ ]" c))) | |
| ;;数値、色値を判定 | |
| (defun zencss-is-vstart (c) | |
| (string-match "^[0-9.#]" c)) | |
| ;;色値判定 | |
| (defun zencss-is-vcolor (c) | |
| (string-match "^[0-9A-Fa-f]" c)) | |
| ;;zencss 展開本体 | |
| (defun zencss-expand (input) | |
| (interactive) | |
| (let* ((cand "") | |
| (wk-imp "") | |
| (ans '()) | |
| (lst-token (zencss-lexer input)) | |
| (lst-pair (zencss-parser lst-token)) | |
| (tbl *zencss-prop-abbrevs*) | |
| ) | |
| (dolist (onepair lst-pair) | |
| (setf cand (gethash (aref onepair 1) *zencss-favorites-standard*)) | |
| (if cand | |
| (push (concat (car cand) (if (equal #\@ (char (car cand) 0)) "" ";")) ans) | |
| (let* (v | |
| rule | |
| (prop (zencss-determine-prop (aref onepair 1) onepair)) | |
| (lst-values (aref onepair 2)) | |
| (abbelem (gethash prop tbl)) | |
| ) | |
| (if abbelem | |
| (progn | |
| (setf prop (car abbelem)) | |
| (setf cand (cadr abbelem)))) | |
| (setf v (zencss-solve-value prop lst-values cand)) | |
| (if (= 1 (aref onepair 3)) (setf v (concat v " !important"))) | |
| (if (equal prop "@") | |
| (push v ans) | |
| (if (equal #\@ (char prop 0)) | |
| (push (concat prop " " v) ans) | |
| (progn | |
| (push (concat prop ": " v ";") ans) | |
| (setf rule (gethash prop *zencss-rule*)) | |
| (if (and rule (cadr rule)) | |
| (dolist (vendor (cadr rule)) | |
| (push (concat "-" vendor "-" prop ": " v ";") ans)))))) | |
| )) | |
| ) | |
| (reverse ans) | |
| )) | |
| ;;1つのプロパティ を CSS文法から候補を探して決定します。 | |
| ;; "ovh (ov:hの省略形)" や "poa (po:aの省略形)" など、値と一体化したプロパティ表現に対応します。 | |
| (defun zencss-determine-prop (prop onepair) | |
| ;; poa → po:a に変換するのが最初の目標。■ | |
| ;; [todo] pa → (page-break-after:nil) か (position:absolute) か選べるようにするのが最終目標。 | |
| (let ((wk-prop prop)) | |
| (while (> (length wk-prop) 1) | |
| (let ((rule (or (gethash wk-prop *zencss-rule*) | |
| (gethash wk-prop *zencss-prop-abbrevs*)))) | |
| (if rule | |
| (progn | |
| (setf (aref onepair 1) wk-prop) | |
| (setf (aref onepair 2) | |
| (push (substring prop (length wk-prop)) (aref onepair 2))) | |
| (return-from zencss-determine-prop wk-prop)) | |
| (setf wk-prop (substring wk-prop 0 (- (length wk-prop) 1)))) | |
| ) | |
| ) | |
| prop | |
| )) | |
| ;;値リストを解釈して空白でつないで返します。 | |
| (defun zencss-solve-value (prop lst-values cand) | |
| (if (not lst-values) | |
| (return-from zencss-solve-value cand)) | |
| (let ((ans '()) | |
| (rule (gethash prop *zencss-rule*))) | |
| (dolist (one lst-values) | |
| (cond | |
| ((< (length one) 1)) | |
| ((equal #\# (char one 0)) | |
| (push (zencss-solve-color-value one) ans)) | |
| ((string-match "^[-]*[.0-9]+$" one) | |
| (push (zencss-add-unit prop one) ans)) | |
| ((string-match "^[-]*[.0-9]" one) | |
| (push (zencss-solve-unit one) ans)) | |
| (rule | |
| (push (zencss-determine-value prop one) ans)) | |
| (t | |
| (push one ans) | |
| ) | |
| )) | |
| (if (> (length ans) 0) | |
| (zencss-string-join (reverse ans) " ") | |
| cand) | |
| )) | |
| ;;1つの値 を CSS文法から候補を探して決定します。 | |
| (defun zencss-determine-value (prop one) | |
| ;; 候補一覧の作成■ | |
| ;; 最初は前方一致のみ■ | |
| ;; [todo] | |
| ;;;; ib → inline-block | |
| ;;;; itb → inline-table のようなことができるようにしたい。 | |
| ;;;; →なかなか難しいので、emmetの変換を辞書扱いしましょう。 | |
| ;;;; 1. inline-table → itb 、など逆引き辞書を作っておいて、 | |
| ;;;; 2. 候補一覧のときに、abbreb一覧を作成すると。 | |
| (let ((lst-abb '()) | |
| (lst-cand (zencss-rule-expansion prop))) | |
| (dolist (cand lst-cand) | |
| (let ((hint-lst (gethash cand *zencss-valu-hints*))) | |
| (when hint-lst | |
| (dolist (hint hint-lst) | |
| ;; (princ (concat prop " " hint " " one " " cand "\n")) | |
| (if (equalp hint one) | |
| (return-from zencss-determine-value cand)))))) | |
| (dolist (cand lst-cand) | |
| ;; (princ (concat one cand "\n")) | |
| (if (string-match (concat "^" one) cand) | |
| (return-from zencss-determine-value cand)) | |
| ) | |
| (dolist (cand lst-cand) | |
| (let ((hint-lst (gethash cand *zencss-valu-hints*))) | |
| (when hint-lst | |
| (dolist (hint hint-lst) | |
| (if (string-match (concat "^" hint) one) | |
| (return-from zencss-determine-value cand)))))) | |
| ) | |
| one | |
| ) | |
| ;; 編集距離であいまい検索を試みようとした跡 | |
| ;; (defun zencss-levenshtein-distance (str1 str2) | |
| ;; (let ((n (length str1)) | |
| ;; (m (length str2))) | |
| ;; ;; Check trivial cases | |
| ;; (cond ((= 0 n) (return-from levenshtein-distance m)) | |
| ;; ((= 0 m) (return-from levenshtein-distance n))) | |
| ;; (let ((col (make-array (1+ m) :element-type 'integer)) | |
| ;; (prev-col (make-array (1+ m) :element-type 'integer))) | |
| ;; ;; We need to store only two columns---the current one that | |
| ;; ;; is being built and the previous one | |
| ;; (dotimes (i (1+ m)) | |
| ;; (setf (svref prev-col i) i)) | |
| ;; ;; Loop across all chars of each string | |
| ;; (dotimes (i n) | |
| ;; (setf (svref col 0) (1+ i)) | |
| ;; (dotimes (j m) | |
| ;; (setf (svref col (1+ j)) | |
| ;; (min (1+ (svref col j)) | |
| ;; (1+ (svref prev-col (1+ j))) | |
| ;; (+ (svref prev-col j) | |
| ;; (if (char-equal (schar str1 i) (schar str2 j)) 0 1))))) | |
| ;; (rotatef col prev-col)) | |
| ;; (svref prev-col m)))) | |
| ;; CSS文法で値域を展開します。 | |
| (defun zencss-rule-expansion (prop) | |
| (let ((ans '()) | |
| (rule (gethash prop *zencss-rule*))) | |
| (if rule | |
| (reverse (zencss-rule-expansion-ite (car rule) ans)) | |
| ans))) | |
| ;; CSS文法で値域を展開します。処理の本体です。 | |
| (defun zencss-rule-expansion-ite (lst-v ans) | |
| (if (not lst-v) ans | |
| (let (wk | |
| neu-rule | |
| (one (car lst-v))) | |
| (cond | |
| ((string-match "^<[_]*\\(.+\\)>$" one) | |
| (setf wk (match-string 1)) | |
| (setf neu-rule (or (gethash wk *zencss-rule*) | |
| (gethash (concat "<" wk ">") *zencss-rule*))) | |
| (zencss-rule-expansion-ite (cdr lst-v) | |
| (append (zencss-rule-expansion-ite (car neu-rule) '()) ans))) | |
| (t | |
| (zencss-rule-expansion-ite (cdr lst-v) (push one ans)))) | |
| ))) | |
| ;; joinです。 | |
| (defun zencss-string-join (lst sep) | |
| (cond ((null (car lst)) | |
| "") | |
| ((null (cdr lst)) | |
| (car lst)) | |
| (t | |
| (concat (car lst) sep (zencss-string-join (cdr lst) sep))))) | |
| ;;色値 の展開。Emmetと同じ動きです。 | |
| ;; #c → #CCCCCC | |
| ;; #1a → #1A1A1A | |
| ;; #3f9 → #33FF99 | |
| (defun zencss-solve-color-value (one) | |
| (let (wk ans) | |
| (if (equal #\# (char one 0)) | |
| (cond | |
| ((string-match "^#[0-9abcdefABCDEF]\\{6\\}$" one) | |
| (setf ans (string-upcase one))) | |
| ((string-match "^#\\([0-9abcdefABCDEF]\\{3\\}\\)$" one) | |
| (setf wk (string-upcase (match-string 1))) | |
| (setf ans (concat "#" (string (char wk 0)) (string (char wk 0)) (string (char wk 1)) (string (char wk 1)) (string (char wk 2)) (string (char wk 2))))) | |
| ((string-match "^#\\([0-9abcdefABCDEF]\\{2\\}\\)$" one) | |
| (setf wk (string-upcase (match-string 1))) | |
| (setf ans (concat "#" wk wk wk))) | |
| ((string-match "^#\\([0-9abcdefABCDEF]\\{1\\}\\)$" one) | |
| (setf wk (string-upcase (match-string 1))) | |
| (setf ans (concat "#" wk wk wk wk wk wk))) | |
| (t | |
| (setf ans one))) | |
| (setf ans one)) | |
| ans)) | |
| ;;数値の時に、自動的に単位を付与する | |
| ;;prop → expansion して、 | |
| ;;".px" 、".em" が含まれるかを調べる。 | |
| ;;整数ならば "px" を付与、 小数ならば "em"を付与 | |
| (defun zencss-add-unit (prop one) | |
| (let ((ans one) | |
| (lst-cand (zencss-rule-expansion prop)) | |
| (is-int (not (string-match "\\." one)))) | |
| (cond | |
| ((and is-int (find ".px" lst-cand :test #'equal)) | |
| (setf ans (concat one "px"))) | |
| ((and (not is-int) (find ".em" lst-cand :test #'equal)) | |
| (setf ans (concat one "em"))) | |
| ) | |
| ans | |
| )) | |
| ;;数値+単位 の時の 単位展開 | |
| ;;Emmet では "x" は "ex" に展開されますが、"px" にしました。 | |
| ;;[hint]"rem" は "いつ使ってもいいem" なのでオススメです。(但しIE9以降 CSS3) | |
| (defun zencss-solve-unit (one) | |
| (let (wk ans) | |
| (if (string-match "^[-.0-9]" one) | |
| (cond | |
| ((string-match "^\\([-.0-9]+\\)p$" one) | |
| (setf wk (match-string 1)) | |
| (setf ans (concat wk "%"))) | |
| ((string-match "^\\([-.0-9]+\\)e$" one) | |
| (setf wk (match-string 1)) | |
| (setf ans (concat wk "em"))) | |
| ((string-match "^\\([-.0-9]+\\)x$" one) | |
| (setf wk (match-string 1)) | |
| (setf ans (concat wk "px"))) | |
| ((string-match "^\\([-.0-9]+\\)r$" one) | |
| (setf wk (match-string 1)) | |
| (setf ans (concat wk "rem"))) | |
| (t | |
| (setf ans one))) | |
| (setf ans one)) | |
| ans)) | |
| (defun zencss-test () | |
| (let ((tests-simple *zencss-dic-test*) | |
| (success 0) | |
| (failed 0)) | |
| (dolist (onetest tests-simple) | |
| (let* ((ans (substitute-string (car (zencss-expand (car onetest))) "[ \t;\\|,\\$\\{\\}]" "")) | |
| (result (equal ans (substitute-string (cadr onetest) "[ \t;\\|,\\$\\{\\}]" "")))) | |
| (when (not result) (princ (concat "FAILED:" (car onetest) " " (cadr onetest) " " ans "\n"))) | |
| (if result | |
| (setf success (+ 1 success)) | |
| (setf failed (+ 1 failed))))) | |
| (list success failed))) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment