pg.ddx.io  pgsql-www@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jonathan S. Katz <jkatz@postgresql.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-www@lists.postgresql.org
Subject: Re: Website patch request: documentation style update
Date: Sat, 18 Apr 2020 15:01:27 -0400
Message-ID: <3f8560a6-9044-bdb8-6b3b-68842570db18@postgresql.org> (raw)
In-Reply-To: <9307.1587235619@sss.pgh.pa.us>
References: <31464.1587156281@sss.pgh.pa.us>
	<a8585a71-1326-949b-32c6-f786417b8eff@postgresql.org>
	<11946.1587171073@sss.pgh.pa.us>
	<887f49f7-42e0-5a80-9962-4a0a69daf7ec@postgresql.org>
	<9307.1587235619@sss.pgh.pa.us>

On 4/18/20 2:46 PM, Tom Lane wrote:
> "Jonathan S. Katz" <jkatz@postgresql.org> writes:
>> I went ahead and tweaked it a bit (attached) to give a little bit of
>> space between the lead line + the table edge (example screenshot
>> attached). I've attached the update patch. I tested in Chrome, FF,
>> Safari, and varied my window size.
> 
> Sounds good.  I have no particular allegiance to the settings I used.

Thanks. Pushed up[1].

>> I then started testing on my phone, and noticed that the font is smaller
>> in the tables than elsewhere. I believe this was done initially at first
>> to manage the old table design, so perhaps this is an opportunity to
>> bump the font up on it.
> 
> I'd noticed that the website style wants to render function signatures
> in a very cramped way, with less inter-word spacing than normal; is that
> another aspect of this?

I believe that's one of the trademarks of the monospace font family, but
we may be able to adjust it.

>  +1 for undoing it, at least in cells that are
> marked functableentry.

Great, I'll experiment and see what I can come up with.

I'm not sure how much more can be done in DocBook (and if need be I'll
opine again on the other thread) but I will note that the HTML that is
generated is a bit odd to deal with. For example (simplifying it a bit):

<td class="functableentry">
  <code class="function">enum_first</code> ( <code
class="type">anyenum</code> ) → <code class="returnvalue">anyenum</code>
  <br>
  Returns the first value of the input enum type.
  <br>
   <code class="literal">enum_first(null::rainbow)</code> → <code
class="returnvalue">red</code>
</td>

A few things to note:

1. The "(" seem to not be included in the "code" blocks. If they are all
together, that may help with some of the cramped/spacingness, as I can
uniformly apply rules.

2. The "<br>" in the "<td>" block is definitely an anti-pattern. The way
we were generating it before, with the multiple rowspan/colspan is "more
correct" for getting that formatting, and with the the different classes
we're applying, we could leverage that to remove the borders, etc. on
the web view. I don't know how that would take for the PDF view.

I do like the direction that this is heading, I think it's an
improvement since v1!

Thanks,

Jonathan


[1] https://www.postgresql.org/docs/devel/functions-enum.html

Attachments:

  signature.asc (application/pgp-signature, 832B) download

view thread (10+ messages)  latest in thread

Message-ID: <3f8560a6-9044-bdb8-6b3b-68842570db18@postgresql.org>
Permalink:  ../3f8560a6-9044-bdb8-6b3b-68842570db18@postgresql.org/
Also on:    postgresql.org/message-id/3f8560a6-9044-bdb8-6b3b-68842570db18@postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-www@postgresql.org
  Cc: jkatz@postgresql.org, tgl@sss.pgh.pa.us
  Subject: Re: Website patch request: documentation style update
  In-Reply-To: <3f8560a6-9044-bdb8-6b3b-68842570db18@postgresql.org>
  References: <31464.1587156281@sss.pgh.pa.us> <a8585a71-1326-949b-32c6-f786417b8eff@postgresql.org> <11946.1587171073@sss.pgh.pa.us> <887f49f7-42e0-5a80-9962-4a0a69daf7ec@postgresql.org> <9307.1587235619@sss.pgh.pa.us> <3f8560a6-9044-bdb8-6b3b-68842570db18@postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox