I just noticed that extensive tiddler content (i.e. large chunks of
text) is not exactly easy on the eyes.
Playing around with the font settings (font-size, line-height) didn't
really help a lot.
Then I realized the problem was paragraphs; apparently, the wikifier
doesn't use P elements, but simply adds BRs.
This means that I can't define a bottom-margin for paragraphs, but will
have to manually insert a blank line.
However, that blank line is simply too much (roughly speaking, 1em
instead of the 0.2em margin I was aiming for) - not to mention the issue
of separating content from layout).
I realize that this is probably a complex issue with the wikifier, so I
assume the problem is not gonna be solved anytime soon!?
Has anyone encountered this issue before - and if so, how did you solve
it (short of having to manually insert P tags, which in turn would
require Eric's HTMLFormattingPlugin)?
-- F.
To insert a non-matched <p> singleton, you don't need a plugin... the
TW core supports embedding of "pure" HTML syntax directly into your
tiddler content, simple by surrounding it with <html>...</html>
blah blah blah <html><p></html> blah blah blah
However, to get the full benefit of paragraph formatting, you would
want to use the properly-matched <p>...</p> block definition
surrounding your wiki-syntax content, in which case, you *would* need
to use the HTMLFormattingPlugin, since the content in between the
<p>...</p> would need additional "wikify()" processing to be rendered.
<html>
<p>
blah blah blah
etc.
blah blah blah foo.
</p>
</html>
Unfortunately, even with the plugin, bracketing your paragraphs with
<p>...</p> can be a bit of a tedious nuisance. Nonetheless, if you
are resigned to do that editing work to get your document to look just
right, you can still avoid using any HTML entirely by use a custom CSS
class wrapper instead:
First, in your [[StyleSheet]], write:
.paragraph { display:block; margin-top:.2em; margin-bottom:.2em; }
Then, in your tiddler content, you can write:
{{paragraph{
This is the first paragraph, blah blah blah...
etc.
...blah blah foo.}}}
{{paragraph{
This is the second paragraph, blah blah blah...
etc.
...blah blah foo.}}}
HTH,
-e
Eric Shulman
TiddlyTools / ELS Design Studios
Exactly; in a way, having to use extra markup for such basic things also
defeats the purpose of having wiki markup at all.
> you can still avoid using any HTML entirely by use a custom CSS
> class wrapper instead
I hadn't thought of that; it's a good idea.
Unfortunately, the {{class{...}}} markup is even more tedious to use
than <p>...</p> (though the basic issue is having to remember using a
wrapper at all).
Just out of curiosity, am I the only one who thinks this is a big issue?
(I rarely used TiddlyWiki for large chunks of text before - mainly short
snippets, lists and code - but now that I've expanded the scope, this
issue feels like a serious nuisance.)*
-- F.
* I guess I don't have to mention it, but just for the record: I do
acknowledge how difficult it is to get this right, and I still admire JR
and the Dev Crew for their achievements with my favorite wiki engine!
Looks like it's on the plan for version 2.3. If you were highly
motivated, you could work on a formatter for generating proper <p>
tags, and let the core team know about it. I'm sure they'd appreciate
the work..
;Daniel
--
Daniel Baird
http://tiddlyspot.com (free, effortless TiddlyWiki hosting)
http://danielbaird.com (TiddlyW;nks! :: Whiteboard Koala :: Blog ::
Things That Suck)
That's sooner than I had hoped (theoretically, 2.3 is due in about three
months... )[1].
> If you were highly motivated, you could work on a formatter for
> generating proper <p> tags, and let the core team know about it.
I am in fact highly motivated, but I'm afraid most of TiddlyWiki's code
is far beyond my humble capabilites.
I've already tried fiddling with the formatter/wikifier for fixing
nested lists (ticket #302)[2], as well as for headings (see [twdev],
"ignoring blank lines around headings")[3] - but to no avail...
-- F.
[1] http://www.tiddlywiki.org/roadmap
[2] http://www.tiddlywiki.org/ticket/302
[3] http://groups.google.com/group/TiddlyWikiDev/t/c61b072d5ed227b1
Yeah it's a big step in complexity from the current system.. the
current thing just sees a line break and outputs a <br> tag. To make
proper paragraphs, it would have to start a paragraph by skipping
forwards through the wiki markup, looking for a line break that wasn't
part of other markup (like the end of a heading etc). Once it finds
the right blank line, it needs to wikify all the content it skipped
over, and wrap the output in <p> </p>.
The hardest bit is that when it's skipping through looking for where
to put the end tag, it needs to allow for other nested paragraphs, as
well as paragraphs nested inside blocks, table cells and the like.
I think we should start a paragraph tag bounty, so we can buy Martin
and Jeremy something nice when paragraphs start working:
http://www.winedancer.com/index.html?lang=en-uk&target=p1548.html
Wotcha think?
;D
Hehe, that's a nice idea.
Though I guess they'd prefer us donating directly via PayPal
(http://tiddlywiki.com/#Donations) rather than waiting until, someday,
we can come up with 750 quid for "perishable goods"... ;)
-- F.
You're really very kind, and quite right this is a bit of a humdinger.
Martin's implementations of the Mediawiki and Socialtext formatters do
handle <P> tags correctly thouugh (although I believe there are still
some issues in certain edge cases). So I think we're in good shape to
solve this; the problem when we do will no doubt be backwards
compatibility....
Cheers
Jeremy
>
>
> -- F.
>
> >
>
--
Jeremy Ruston
mailto:jer...@osmosoft.com
http://www.tiddlywiki.com
name: "lineBreak",match: "\\n|<br ?/?>",handler: function(w){createTiddlyElement(w.output,"br");}
createTiddlyElement(w.output,"br");
createTiddlyElement(w.output,"hr");
.viewer hr{border-style:none;padding-bottom:0.25em;color:#fff;background-color:transparent;}
.hrule hr{border-bottom:1px solid red;padding-bottom:0.25em; }
{{hrule{
----
}}}
ul, ol, blockquote{margin-top:0;}