libwebsockets/lib/misc/css-prop-constants.txt
Andy Green 63d2f844db lhp: Lightweight HTML Parser
Introduce a very lightweight html5 + css2.1+ stateful stream parser, along
the same lines as the lws json and cbor ones.

This is interesting primarily because of just how low-resource it is for
modest css + html, it uses an lwsac to hold the entirity of the css in
memory at once but the html is parsed in chunks without any need to keep
previous chunks around (chunks may be as small as 1 byte).

A user callback receives element entry and exit callbacks with payload and
all attributes parsed out, CSS related to the active element stack is
parsed to provide a list of active css attributes, which takes heap for the
duration of the parsing.

In effect this provides rich information about the html and css state to
the callback, which has the job of producing the layout in a user-defined
way.

As such, there is no DOM in memory at one time, there is only a stack of
active elements like <html><body><div>xxx with their associated attributes
(like class).  So as it is, it does not support DOM modification such as
JS changing elements after parsing, although elements with interesting IDs
could be kept around by the callback.  There is a corresponding tiny and
relatively flat heap usage regardless of html size.

Default CSS is specified as recommended in the CSS 2.1 standard.

Inline <style></style> elements are supported, but not pre-html5 style= in
element attributes, since these are incompatible with strict CSP.

What the attributes should mean on your system, eg, font-size, font-family
etc is left for the user callback to decide, along with how to lay out the
items using the CSS attributes, and render them.

Fixed point 32.32 constants are used (fraction expressed at parts in 100M)
instead of floating point.

If you have presentation needs, even on a constrained display on a
constrained microcontroller, this makes it feasible to use standardized
markup and styling instead of roll your own.
2022-05-04 08:43:26 +01:00

125 lines
1.1 KiB
Plaintext

above
absolute
always
armenian
auto
avoid
baseline
behind
below
bidi-override
blink
block
bold
bolder
both
bottom
capitalize
caption
center
circle
close-quote
code
collapse
continuous
crosshair
decimal-leading-zero
decimal
digits
disc
embed
e-resize
fixed
georgian
help
hidden
hide
high
higher
icon
inherit
inline
inline-block
inline-table
invert
italic
justify
left
lighter
line-through
list-item
low
lower
lower-alpha
lowercase
lower-greek
lower-latin
lower-roman
ltr
menu
message-box
middle
mix
move
ne-resize
no-close-quote
none
no-open-quote
no-repeat
normal
nowrap
n-resize
nw-resize
oblique
once
open-quote
outside
overline
pointer
pre
pre-line
pre-wrap
progress
relative
repeat
repeat-x
repeat-y
right
rtl
scroll
separate
se-resize
show
silent
small-caps
small-caption
spell-out
square
s-resize
static
status-bar
sub
super
sw-resize
table
table-caption
table-cell
table-column
table-column-group
table-footer-group
table-header-group
table-row
table-row-group
text-bottom
text-top
text
top
transparent
underline
upper-alpha
uppercase
upper-latin
upper-roman
visible
wait
w-resize