[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: styling flexibility for definitions

From: Gavin Smith
Subject: Re: styling flexibility for definitions
Date: Wed, 3 Feb 2021 18:51:15 +0000

On Sat, Nov 7, 2020 at 11:24 PM Per Bothner <per@bothner.com> wrote:
> I checked in some css tweaks for the DomTerm manual to make use
> of the latest makeinfo changes.
> If you're concerned that '<span class="category-suffix">: </span>'
> is verbose I can look into using JavaScript to remove the colon.
> (If you're fine with the currently-checked-in code I won't bother.)
> One more issue related to definitions is the name itself.
> The makeinfo output emphasizes the name with <strong>, but that
> is not very semantic.  In my manual I use the color purple for these names:
> https://www.gnu.org/software/kawa/Paths.html
> I can certainly use a style rule like:
> dl.def > dt strong { color: purple }
> However, it seems adding a class would be cleaner.  Perhaps <strong 
> class="name">?
> Personally, I would also add a class="synopsis" to the <dt> element.
> Neither of these changes are critical for my needs, and could anyway be added 
> later,
> but I think they're worth considering.

I have made a change in this area, so there is an extra <span> element
around the rest of the definition line.

@deffn Method bar (water, bread, cheese)
One Two Three
@end deffn

Current output:

<dl class="def">
<dt id="index-bar"><span class="category">Method:
</span><span><strong>bar</strong> <em>(water, bread, cheese)</em><a
href='#index-bar' class='copiable-anchor'> &para;</a></span></dt>
<dd><p>One two three

You may have to change your CSS to adapt to this.

I made this change (along with change to other CSS) to make the
pilcrow sign only appear when you put the mouse over the text of the
definition line, not anywhere in the space to the right. (This
behaviour annoyed me when I was reading HTML documentation generated
by other systems.)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]