[pmwiki-users] Re: PMWiki Bug? leading Tabs
Patrick R. Michaud
pmichaud at pobox.com
Tue Mar 15 17:12:03 CST 2005
On Tue, Mar 15, 2005 at 05:49:13PM -0500, Ryan Varick wrote:
> Well, I would like to change the behavior to only trigger on two
> leading spaces but I can't find where pmWiki is formatting things
> (stdmarkup maybe)? I think the default behavior is fine, I just want
> to override it locally. Suggestions?
It's in stdmarkup.php. If you want to change it so that two leading
spaces result in preformatted text, add the following in config.php:
DisableMarkup('^ ');
Markup('^ ', 'block', '/^ /', '<:pre,1>');
If you want it so that *exactly* two leading spaces result in
preformatted text (i.e., three spaces is not preformatted), then use
DisableMarkup('^ ');
Markup('^ ', 'block', '/^ \\S/', '<:pre,1>');
Using two leading spaces to mean "preformatted text" sounds like a
useful rule that covers most of the existing cases -- and it would
eliminate the "bug" that Christian often complains about where a single
leading space causes a line to become preformatted. Maybe we can
adopt this or something like it in general?
Pm
> On Tue, 15 Mar 2005 16:43:47 -0600, Patrick R. Michaud
> <pmichaud at pobox.com> wrote:
> > On Tue, Mar 15, 2005 at 11:21:59PM +0100, chr at home.se wrote:
> > > On Tue, 15 Mar 2005, Sivakatirswami wrote:
> > >
> > > > Invariably posts of copy from an email application which contain a tab
> > > > character as the the first char of a line cause PMWiki not to wrap
> > > > lines. I have tested both under Gemini and PMWiki.org's own sand box...
> > > > exactly the same behavior>
> > >
> > > This is actually a known bug (I've reported it twice :-)
> >
> > It's not a "bug". Lines that begin with whitespace are preformatted
> > text -- this is by design. Tabs are whitespace.
> >
> > If anything, you simply want it to do something different than it
> > currently does. If we can figure out what that "something different"
> > should be (in a way that makes sense with various other requirements),
> > then we can change it.
> >
> > Pm
> > _______________________________________________
> > pmwiki-users mailing list
> > pmwiki-users at pmichaud.com
> > http://pmichaud.com/mailman/listinfo/pmwiki-users
> >
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://pmichaud.com/mailman/listinfo/pmwiki-users
More information about the pmwiki-users
mailing list