div-tag ( str style -- str' )


Vocabulary
io.streams.farkup.private

Inputs
stran object
stylean object


Outputs
str'an object


Definition


: div-tag ( str style -- str' )
{
[
font-name of "monospace" =
[ "\n\n" "\n" replace "[{" "}]" surround ] when
]
[
font-size of {
{ [ dup not ] [ drop ] }
{ [ dup 18 >= ] [ drop "= " " =" surround ] }
{ [ dup 16 >= ] [ drop "== " " ==" surround ] }
{
[ dup 14 >= ]
[ drop "=== " " ===" surround ]
}
[ drop ]
} cond
]
} cleave ;