[Pmwiki-users] Idea for extension of special list syntax
chr@home.se
chr
Fri Jan 21 06:17:06 CST 2005
On Fri, 21 Jan 2005, Neil Herber wrote:
> At 2005-01-21 01:05 PM +0100, chr at home.se is rumored to have said:
> > I added an example of
> >this problem as snippet 2... would you mind looking (again:-) to see if
> >the page still makes sense?
> >
> > > http://www.pmwiki.com/wiki/Test/SyntaxForLongListItems as well as here.
>
> It makes sense to me now. (Now that I see one slash instead of the two I
> imagined.) I added an extra point under the first snippet.
>
> Going back to a question I had earlier, can this not be solved by having
> the list markup look for a trailing blank line before finishing the list?
> It does that for paragraphs ...
I've added this to the page. Basically the problem is that we then
couldn't do something like this:
* Add this line of code to your config.php
if($i > 0) $i = $i-1; // Iterate...
* Or ask the users to do something else.
This hopefully also explains why the horizontal alignment is needed to
differentiate this case from:
* Add this line of code to your config.php
A piece of text that should be "swallowed" by the 1st item
* Or ask the users to do something else.
However, your comment was very useful because it gave me two insights...
1. We are in principle already using 'horizontal alignment' to say that
the next line should be included in the current 'element'.
2. This method of using 'horizontal alignment' could be used for more
than just list items...
To explain n:o 1. Consider the following example:
Here is a paragraph.
These lines are also included in the paragraph,
and we could motivate it by saying that they have
the same horizontal alignment as the first line...
There are of course alternative motivations for why the following lines
are included in the paragraph. (For instance, no blank line or other kind
of element in between).
As for n:o 2, I realized that it'd be convenient to be able to also write:
* An item
* Another item with a long text
that continues on the next line
-> Here is an indented paragraph, that
also is a bit long and uses indentation,
or horizontal alignment to make these
lines become a part of the paragraph.
--> An example of a twice-indented
paragraph spread over several lines
of source
if($i > 0) $i = $i + 1; // Code markup, diff. indentation
Normal text paragraph, starting at alignment zero.
These lines are also included in the paragraph since they
also start with alignment zero.
So maybe this thing about using indentatino/horizontal alignment to
indicate that the following line should be included into the element can
be extended to more kinds of element than just list items?
/Christian
--
Christian Ridderstr?m, +46-8-768 39 44 http://www.md.kth.se/~chr
More information about the pmwiki-users
mailing list