OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Subject: DOCBOOK: Re: Looking for a tag analogous to HTML's <code>

----- Original Message -----
From: "Norman Walsh" <ndw@nwalsh.com>

> The grab-bag for this is probably <literal>. What sort of statements do
> want to put inline?

Various expressions, such as properties qualified by object, method calls,
Examples (implemented using <literal role="code">):

  <para>To free up resources, use
  <literal role="code"><variable>Session</variable
  >.<methodname>Abandon</methodname>()</literal> when ... </para>

  <para>To suggest a filename, use <literal role="code"
  <literal>'attachment; filename=export.csv'</literal>);</literal>
  ... </para>

  <para>Simple conversion can be acheived via
  <literal role="code">while(<>) { s/--/&mdash;/go }</literal>
  ... </para>

Basically, one-liners and member references that require connecting syntax,
like ".", ":", "::", or "->" (which, in practical terms, I would also like
to be rendered in a monospace font when styled).
These are really too small enough to be rendered as blocks (which would also
break up the flow unnecessarily), which rules out <programlisting>.

It looks like the above examples will validate for now, but I would still
like to occasionally include the markup for the different components,
so I am a little worried by the "Future Changes" in the docs that
suggest severe constraints to the <literal> tag in later versions.

> | I am tempted to use xreflabel; would this be abusive?

> Definitely. Abusing role is probably a better bet.

Hmm... OK.

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Powered by eList eXpress LLC