Fossil SCM

nowiki tag limitations

Open

59da623c1120685… · opened 11 years, 10 months ago

Type
Code_Defect
Priority
Low
Severity
Cosmetic
Resolution
Open
Subsystem
Created
May 30, 2014 2:51 a.m.

The nowiki tag does not seem to work if it is the first line in a file.

Moreover, multiple nowiki tags don't seem to work properly. For example, in the following WIKI+HTML, the first table is fine, but in the second the


tag, Option" ends up with

tag in it which causes an the header to be very tall.

BTW: fossil is great.

Regards, Peter


Some

OptionDescription
AB

More

OptionDescription
AB


Some

OptionDescription
AB
More

Option

Description
AB
--------------------

Comments (5)

anonymous 11 years, 10 months ago

The nowiki tag does not seem to work if it is the first line in a file.

Moreover, multiple nowiki tags don't seem to work properly. For example, in the following WIKI+HTML, the first table is fine, but in the second the


tag, Option" ends up with

tag in it which causes an the header to be very tall.

BTW: fossil is great.

Regards, Peter


Some

OptionDescription
AB

More

OptionDescription
AB


Some

OptionDescription
AB
More

Option

Description
AB
--------------------
stephan 11 years, 10 months ago

NOWIKI does not block normal HTML Tags, only wiki-specific markup (braces and such).

i'll take a look at the no-effect-on-the-first-line bit this weekend (sounds like an off-by-one, but it might just be a misunderstanding of what nowiki is supposed to do). i use multiple NOWIKI tags in pages very often with no problems.

peter 11 years, 10 months ago

Thanks for the quick response.

To clarify the 2nd problem: NOWIKI is not blocking HTML tags, but rather inserting a

tag in the .

Perhaps I misunderstand it's intent, but I thought NOWIKI was designed to not do any wiki processing on a block.

There is no problem using multiple NOWIKI for simple cases. But there is with text nested between other tags.

For most content, inserting

tags would not be a problem. But with tables, a

in the causes the height to double.

stephan 11 years, 10 months ago

Hi, thanks for the feedback!

i cannot reproduce a problem with NOWIKI on the first line. The problem regarding the P flag i am going to justify with the following semi-lame explanation: NOWIKI is not really intended to enclose whole block-level structures such as tables, and doing so may cause unwanted side-effects in conjunction with block-level constructs which the parser takes a substantial interest in. i do not have a definitive list of which tags that might be, but i know (e.g.) that PRE inside NOWIKI works fine, while you have demonstrated that a TABLE block (or the TH inside it) is apparently not side-effect-free (in that it generates a spurious P tag).

Here is an example of a page which uses multiple NOWIKI PRE /PRE /NOWIKI blocks without any problems:

[http://fossil.wanderinghorse.net/repos/libfossil/index.cgi/artifact/582cf57813cf8864a636f686d84b29839764cd65]

i'll leave this open for the time being, as the spurious P "really shouldn't" be generated, but any changes to the wiki parser, in particular for edge cases, are not likely to get much priority.

Peter 11 years, 10 months ago

Ok. Not really looking for problems to be fixed, though. Mostly I opened the bug for the benefit of future fossil wiki users experiencing similar problems

The language in the documentation could perhaps be softened, to wit:

The tag disables all wiki formatting rules through the matching element

Irregardless, I've found another problem with NOWIKI (below) which (maybe) sheds some light on the first bug. Essentially, it turns out a missing tag for a label is causing the parser go get confused. The wiki does not recognize the self closing tag (which is fair) but instead reads forward to the other end tag.

Regards, and hope this helps.


START

A1
B2
C3

END.


START

A1
B2 C3 END. -----------------------------------------

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button