This is the mail archive of the docbook@lists.oasis-open.org mailing list for the DocBook project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Block element for user input


On Wed, Feb 16, 2000 at 08:06:59PM +0200, Gershon Leib Joseph wrote:
> Consider the following sample:
> 
> <step>
>   <para>Change directory to the <filename>/tmp</filename> directory:</para>
>   <para># <userinput>cd /tmp</userinput></para>
> </step>

   <step>
     <para>Change directory to the <filename>/tmp</filename> directory:</para>

     <screen><prompt>#</prompt> <userinput>cd /</userinput></screen>
   </step>

To see what that looks like when converted to HTML, take a look at 
http://www.FreeBSD.org/handbook/

>   <userinput prompt='root'>cd /tmp</userinput>
>
> - Less markup (obvious advantages ;-)  )

Use an editor that helps.

> - Use attribute to set shell prompt. Legal values could include DOS, root
> and normal (for Unix) and perhaps others too for other operating systems.

Better idea.  Create a customisation layer of the DTD, and create some 
prompt.foo entities.  Two good ones we use on the FreeBSD Doc. Project are

    &prompt.root;         (becomes '<prompt>#</prompt>')
    &promtt.user;         (becomes '<prompt>%</prompt>')

For a DTD customisation that does this, and more, look at

    http://www.FreeBSD.org/cgi/cvsweb.cgi/doc/share/sgml/freebsd.dtd

Hope that helps,

N
-- 
    If you want to imagine the future, imagine a tennis shoe stamping
    on a penguin's face forever.
        --- with apologies to George Orwell


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]