Support colored footnote marker & calls
Hey,
I'm having issues to set the colour of footnote markers/calls.
This doesn't work:
.footnote::footnote-call {
content: counter(footnote, decimal) " ";
color: green;
vertical-align: super;
font-size: 0.8em;
}
.footnote::footnote-marker {
content: counter(footnote, lower-roman);
font-size: 14pt;
color: red;
display: inline-block;
width: 2em;
padding-right: 1em;
text-align: right;
}
You can find a full example here, with comparisons to other printcss engines.
Best anghenfil
Hi!
Thanks for the report.
It looks like there are 2 different problems:
.footnote::footnote-calland.footnote::footnote-markerdon’t match the elements, but::footnote-calland::footnote-markerdo. We have to check the specification to find exactly what’s supposed to work.- The color is not applied to the footnote marker. Maybe that’s related to the way we handle markers.
We’ll check that in depth and get back as soon as we understand what’s going on here.
.footnote::footnote-calland.footnote::footnote-markerdon’t match the elements, but::footnote-calland::footnote-markerdo. We have to check the specification to find exactly what’s supposed to work.
There’s nothing in the specification about that. As it seems to work with other renderers, we can assume that it’s the way it should work.
There’s nothing in the specification about that. As it seems to work with other renderers, we can assume that it’s the way it should work.
I’m not sure about that. Should the pseudo-element be p::footnote-marker or .footnote::footnote-marker? The second selector makes more sense to me, but it has an important consequence: the style of the marker inherits from the style of the footnote, and I’m not sure that this is what we want.
Even if that’s discutable, let’s go this way.
- The color is not applied to the footnote marker. Maybe that’s related to the way we handle markers.
That was just a bug for footnote markers.