: border-css, ( border -- )
"border: 1px solid #" % hex-color, "; " % ;
+: (padding-css,) ( horizontal vertical -- )
+ 2dup = [
+ drop "padding: " % # "px; " %
+ ] [
+ "padding: " % # "px " % # "px; " %
+ ] if ;
+
: padding-css, ( padding -- )
- first2 "padding: " % # "px " % # "px; " % ;
+ first2 (padding-css,) ;
CONSTANT: pre-css "white-space: pre; font-family: monospace;"
end-sub-stream format-html-div ;
: border-spacing-css, ( pair -- )
- first2 max 2 /i "padding: " % # "px; " % ;
+ first2 [ 2 /i ] bi@ (padding-css,) ;
: table-style ( style -- str )
{