RFR: JDK-8186466: Fix accessibility and other minor issues in java.base

Jonathan Gibbons jonathan.gibbons at oracle.com
Sat Aug 19 21:19:04 UTC 2017

On 8/19/17 11:55 AM, Martin Buchholz wrote:
> I don't know how hard it would be to make the header rows in 
> BlockingDeque presented like the ones in e.g. Deque.
> Deque uses striped thead, which gets the #DDD background from the 
> stylesheet.  And having <thead>s is probably itself an accessibility 
> feature.
Actually, thead and tbody have no direct significance for accessibility. 
They provide a semantic differentiation of the content, and provide a 
hook for different styling, as you have seen for "striped". Also note, 
although you can have many <tbody>, you can only have at most one 
<thead>, and at most one <tfoot>.
> table.striped > thead {
>     background-color: #DDD;
>     border: 1px solid black;
> }
> we could brute force the same background color or try to convert these 
> to striped tables (but you probably tried that).

The only way to make the first table in BlockingDeque use striped tables 
would be to split the table in two, and change the First/Last Element 
headers into table captions.  If you want the overhead of brute-forcing 
the color on each row, we can do that, but ideally, we should be trying 
to move inline styles out of the HTML (and into stylesheets), not 
increasing the use of inline styles (despite all appearances to the 
contrary in this overall changeset!)

There's a bunch of work going on in javadoc related to stylesheets. See 
the open issues list here:
If that link gets mangled by the mail system, the underlying query is
"project = jdk and Subcomponent="javadoc(tool)" and labels in 
(stylesheet) and resolution is empty"

I think BlockingDeque is a good reason and test case for better support 
for table styles. Maybe it's better to address the javadoc support for 
custom styles, rather than work around the lack of it.

-- Jon

More information about the core-libs-dev mailing list