Why does single line macro display content in viewmode?

36 views
Skip to first unread message

Mat

unread,
May 10, 2016, 10:14:09 AM5/10/16
to TiddlyWikiDev
Is it by design or is it a bug that a macro definition consisting of one line has the macro content displayed in viewmode whereas a macro consisting of multiple lines (or one line but with a linebreak after and possibly other non-macro content after) does not display anything in viewmode?

IMO it should better consistently not show, particularly as multiple single line definitions result in only the last one displaying, i.e

\define aaa() aaa

\define bbb() bbb

yields view

bbb

<:-)


Mat

unread,
May 10, 2016, 10:18:23 AM5/10/16
to TiddlyWikiDev
Ah, addition of possible interest: The background is that I made this little style definition

tag : $:/tags/Stylesheet

.tc-tagged-\%24\%3A\%2Ftags\%2FMacro .tc-tiddler-body:before {
content:"macro content"; height:1.5em; display:block; text-align:center; border:1px dashed crimson; padding: 0 5px; margin-bottom:2em;
}

...to have otherwise empty macro tiddlers show an indication of content. Of course, the tag itself might be considered enough but not in my particular context.

<:-)


Jeremy Ruston

unread,
May 10, 2016, 10:37:46 AM5/10/16
to tiddly...@googlegroups.com
Hi Mat

Macro definitions are never displayed in view mode. Perhaps your second example lacks its terminating line break, and therefore isn't being parsed as a macro definition?

Best wishes

--
You received this message because you are subscribed to the Google Groups "TiddlyWikiDev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywikide...@googlegroups.com.
To post to this group, send email to tiddly...@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywikidev.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywikidev/65614113-2d62-4dbc-9550-a3626d8f66d8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Mat

unread,
May 10, 2016, 11:22:40 AM5/10/16
to TiddlyWikiDev
Perhaps your second example lacks its terminating line break, and therefore isn't being parsed as a macro definition?

Hmpf, that's even embarassing... you're of course spot on!

Thanks Jeremy!

<:-)

Reply all
Reply to author
Forward
0 new messages