In message <cceb8bf558.DaveMeUK@BeagleBoard-xM>
David Higton <dave(a)davehigton.me.uk> wrote:
In message <866b6af458.harriet(a)bazleyfamily.co.uk>
Harriet Bazley <lists(a)bazleyfamily.co.uk> wrote:
> Netsurf doesn't seem to support HTML of the form
> <OL>
> <li type="i" value=5>
> </OL>
> but always defaults to a sequential numerical list, whatever type/value
> the source specifies - are we all supposed to be styling list entries
> with CSS nowadays?
I've been having a look around some parts of the source (with which I am
nowhere even beginning to be familiar) and docs. AFAICS (which is not very
far!) the parser is in place to pick this stuff up. There also seem to be
tests in place to check parsing.
Some experiments indicate that it isn't rendered to screen like it should
be, though. CSS seems to work no better than HTML. Ordered lists in upper
case Roman and lower case alpha both come out as Arabic numerals.
In the source files, take a look in
netsurf.content.handlers.html.box_construct.c around line 400. (This is
for the 3.10 source; I haven't looked to see if it's moved in the current
version.) You'll see that cases CSS_LIST_STYLE_TYPE_DECIMAL,
CSS_LIST_STYLE_TYPE_LOWER_ALPHA, CSS_LIST_STYLE_TYPE_LOWER_ROMAN,
CSS_LIST_STYLE_TYPE_UPPER_ALPHA, CSS_LIST_STYLE_TYPE_UPPER_ROMAN and
default all use the same block of code. The marker itself is generated
in the last few lines of the block.
It ought to be not too difficult to generate code to handle the alpha
and Roman-numbered cases.
David