Suppress blank lines (crlf) in rendered tiddler content

54 views
Skip to first unread message

Craig in Calgary

unread,
Dec 31, 2009, 1:25:52 PM12/31/09
to TiddlyWiki
Recently I read somewhere in the TiddlyWiki community of a way
(plugin, transclusion, macro, script) to suppress extra blank lines in
rendered tiddler content. For example, to make editing a tiddler more
human-readable I place one extra return (CRLF) or several extra
returns (CRLFs) before and after headings, after bullet lists, etc. I
also use TiddlySnip to grab HTML content that often has lots of white
space (whitespace) in the source code. In both scenarios, the rendered
content displays all the extra linefeed (linefeeds). What's a
TiddlyWikker (two k's so it doesn't rhyme with biker) [noun; a person
who peruses, uses, abuses, and confuses TiddlyWikis] to do?

For those curious about my strange parentheticals above, I've spent
over an hour pouring over the TiddlyWiki and TiddlyWikiDev Google
Groups searching on "suppress", "blank", "crlf" without finding the
post I'm certain exists which answers my question. By embedding every
keyword I could think of in *this* post, I hope to make it easier for
the next TiddlyWikiSeeker [noun; a person looking for an answer to a
question about TiddlyWiki to the point of obsession].

Take care, my TiddlyWikiFriends [noun; people who share a common bond
and passion about all things TiddlyWiki],

Craig

Mike

unread,
Dec 31, 2009, 1:42:02 PM12/31/09
to TiddlyWiki

PMario

unread,
Jan 1, 2010, 10:40:05 AM1/1/10
to TiddlyWiki
Hi Craig,

Mike mentioned my post "LineBreakHack for headings and paragraphs" [1]
already. Hope it can help. But it won't do anything with HTML content,
that may come from TiddlySnip or somewhere else. HTML content is
parsed seperately.

It also may not work/interfere with additional plugins, if they use
there own parsing mechanism.

On Dec 31 2009, 7:25 pm, Craig in Calgary <craig.prich...@gmail.com>
wrote:
=== snip


> For those curious about my strange parentheticals above, I've spent
> over an hour pouring over the TiddlyWiki and TiddlyWikiDev Google
> Groups searching on "suppress", "blank", "crlf" without finding the
> post I'm certain exists which answers my question. By embedding every
> keyword I could think of in *this* post, I hope to make it easier for

And I thought I used them already.
remove whitespace, line-break, linebreak, <br>, paragraphs, heading,
editmode .. :))

regards Mario
[1] http://a-pm-experimental.tiddlyspot.com/#LineBreakHack

Craig in Calgary

unread,
Jan 1, 2010, 3:25:27 PM1/1/10
to TiddlyWiki
YES!!! My search was fruitless because I didn't think of "linebreak",
"white space", or "<br>".

Thank you very much for helping me.

Craig

Craig in Calgary

unread,
Jan 1, 2010, 3:30:54 PM1/1/10
to TiddlyWiki
For <html></html> tiddler content, place <hide linebreaks> anywhere
between the html tags and the rendered contents will have much less
wasted white space.

Don't ask where I found this 'cuz I don't know and I'm still kicking
myself for not finding it before creating this thread.

Craig

Eric Shulman

unread,
Jan 1, 2010, 3:41:46 PM1/1/10
to TiddlyWiki
> For <html></html> tiddler content, place <hide linebreaks> anywhere
> between the html tags and the rendered contents will have much less
> wasted white space.

"<hide linebreaks>" is a special added syntax provided by
http://www.TiddlyTools.com/#HTMLFormattingPlugin

enjoy,
-e


PMario

unread,
Jan 1, 2010, 7:17:34 PM1/1/10
to TiddlyWiki
Hi,
I have enhanced the hack a little bit.

Now it changes the behaviour of
*linebreaks
*headings
*all list types
*blockquots
*linequots

Especially numbered lists will be interesting for some people.
#one

#two

will be
1. one
2. two

regards Mario

[1] http://a-pm-experimental.tiddlyspot.com/#LineBreakHack
[2] http://a-pm-experimental.tiddlyspot.com/#LineBreakHackOld

Reply all
Reply to author
Forward
0 new messages