[Top][All Lists]

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

Re: lynx-dev lynx.cfg entry order

From: pAb-032871
Subject: Re: lynx-dev lynx.cfg entry order
Date: Tue, 23 May 2000 05:14:46 -0700

In "Re: lynx-dev lynx.cfg entry order"
[23/May/2000 Tue 02:30:13]
Vlad Harchev wrote:

>   The order of options in lynx.cfg is non-signtificant for majority of them
> (of course, if you have two options of the same name in lynx.cfg, the last one
> will win).

Thank you.  That line about duplicate entries is also a relief
to me.  With all the cutting and pasting I'll *have* to run a
search for duplicates, but knowing it won't crash under conflicting
entries helps.

>   As for learning it by beginners, have you seen htmlized documentation on
> settings in lynx.cfg (it has TOCs by alphabet and by category)? You can view
> the old version online at 

Yes, but I'll have to look again more closely.  Great stuff. 
Luckily, I started with a 70 k, v2.7.1 cfg so it's a little easier
[okay, a LOT easier].

What I'm actually doing is remapping ".cfg" to text/html and rewriting
lynx.cfg *itself* as an HTML document.  This isn't too hard, but
now I have three very different audiences in mind:

1)-The first is Lynx itself.  This documet still has to function
   as a configuration reference as Lynx starts up, with "#" as
   a leading character in comments.
2)-The second is whoever reads it in the browser as rendered HTML
   [this might actually be considered two readers: one of them
   being Lynx interpreting the source text].
3)-And the third [or fourth] is the human reader now editing
   the document as plaintext in their chosen editor.

The rest could be more than anyone wants to know, but here it
is.  Might be useful if anyone else wants to do a similar project:

>From lynx.cfg:

#<title>lynx.cfg [remapped/edited to HTML].</title><a name=top>
#</a> <a href="docs/lynxcfg_idx.html">Go to Indexed Reference</a>
# #<hr><h1>-=&lt;{} #
#                       lynx.cfg file.
# {}&gt;=-</h1><hr><pre>
# The default placement for this file is:
#                               /usr/local/lib/lynx.cfg (Unix)
#                               or Lynx_Dir:lynx.cfg (VMS)
#                               or in the same folder with the
#                               MacLynx application (MacOS)

Rendered as:

     # # Go to Indexed Reference # #

                     -=<{} # # # lynx.cfg file. # # # {}>=-

# The default placement for this file is:

Short entries are left in PRE, like this one:

#       This line ensures that MacLynx treats lynx.cfg as an
#       HTML document instead of plaintext. Don't change this
#       line unless you're willing to rewrite the whole file.

With longer entries. . .  Here's a chunk from my notes:

Trimmed lynx.cfg down to just under 32k, so it can be edited in
SimpleText [SimpleText on a Mac is roughly similar to Pico on
UNIX; a plain, universal text editor].  UNIX/VMS-only entries were
removed, and the suffix-mapping section was replaced by an external
mime.types file [except one entry.  See above].

Since it was hacked-down so drastically, the unmodified original
will be included under the name "lynx.cfg.TMPL".  The added ".tmpl"
suffix should also ensure it's displayed as plaintext instead of
[wrongly] as HTML.

Writing it so the tags don't interfere with reading it as plaintext
was tricky, but it turned out not-so-bad.  Used tabs to add whitespace
between the text and tags, and resorted to some illegal tag attributes
to hide the "#" characters at the beginning of each line, like this:

[Intentional long-line, with apologies.  See below.]

 . . . A sample of some helpful text concerning the configuration of Lynx 
through its cfg file.         <p
#> Another paragraph of notes. . .

Fairly unobtrusive, and MacLynx ignores the illegal attributes
gracefully.  HTML <!-- comments --> would satisfy the purist,
but would also raise the file-size above 32k, and get in the way
when you're trying to read the thing in a text editor.

A note concerning long-lines:

[this one HAS been wrapped.]

[...]   </pre
#> If you're working on this in BBEdit or something, AND you already
know what you're doing, try disabling soft-wrap to ''flatten''
and minimize these help notes.  <h1>
#               Do NOT hard-wrap this copy of lynx.cfg

Couldn't resist the irony in that.


; To UNSUBSCRIBE: Send "unsubscribe lynx-dev" to address@hidden

reply via email to

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