[pmwiki-users] numbered list questions

David Spitzley dspitzle at wash.k12.mi.us
Tue Mar 15 10:00:23 CST 2005


>>> "Patrick R. Michaud" <pmichaud at pobox.com> 03/15/05 10:36 AM >>>
On Tue, Mar 15, 2005 at 10:03:20AM -0500, David Spitzley wrote:
> Why not allow "capping" of list entries with a closing # symbol? 
> 
> #First entry in the list#
> #Second entry in the list, which is
> very, very, very, very, very, very,
> very, very, very long#
> 
> Obviously, you'll need to leave the "capping" # optional for
backward
> compatibility, but I think defaulting to the current block-handling
> behavior in the absence of capping would be reasonably
straightforward
> ("ok, I've got a new line starting with a #, and the next # I see
also
> starts a line, so I'll use the old blocking rules up through that
point"
> vs "ok, I've got a new line starting with a #, and the next # I see
is
> not at the start of a new line, so I'll treat everything in-between
as a
> block").  I suppose nested lists could complicate things somewhat,
> though.

Yes, and it's not at all an obvious markup, and it requires a fair 
amount of "lookahead" on the part of PmWiki to see if there are any
later lines that have the capping #.  PmWiki currently works by
processing
"the current line" without looking ahead to see what may be coming
(I'm not likely to change this model).

And what do we do with:

    # First entry in the list
    # Second entry in the list
    with more text
    and still more text.

    And a paragraph.  Lorem ipsum dolor sit amet, consectetuer 
    adipiscing elit. Donec metus magna, lobortis nec, auctor sit amet.

    * Here's a bullet list thrown in for fun.

    And this line has a "capping" #

*Now* what do we do?  ;-)  Is the bullet list considered part of the 
second item in the numbered list?

And the presence of capping #'s later in the text just a "spooky
action
at a distance" sort of feeling to them -- i.e., it's not at all
obvious
to someone looking at the "Lorem ipsum" paragraph above that it's
part of the numbered list.
----------------------------

On the flip side, what option does a writer have now if they wanted all
that material to be part of the one list item?    Is it even possible to
tag all of that so it will be processed as a single entry in the initial
list?  I realize there may just be unavoidable practical limits for
parsing this stuff, but if "spooky action at a distance" (amusing
reference, by the way) is a plausible method of achieving that
functionality, it comes down to a question of whether the problem is
sufficiently important to warrant resorting to that solution.  You're
driving this bus, so that's obviously your decision.

For what it's worth, I wouldn't have any objection to the "leading
space" approach, but it seems a little too tricky to implement.  Maybe a
"leading underscore" approach, instead?

#Here's the first list item, which
_extends to a second line, and even
_#a third line which starts
__a nested numbered list
_#that contains multiple entries.
Once the underscores end, the list entry ends.
#And now a new list begins


David



More information about the pmwiki-users mailing list