[TW5] How do (should) I start a new line in a Tiddler?

3,084 views
Skip to first unread message

Gerald Strickland

unread,
Dec 14, 2013, 7:11:31 AM12/14/13
to tiddl...@googlegroups.com
First off, thank you Jeremy Ruston and to all of those involved with TiddlyWiki. I started using TWC a few months ago and it completely satisfied the way I like to keep my notes and document whatever I happen to be working on. Simply incredible. Then early this month, while looking for ways to tweak the look of my TWC, I came across TW5 and was blown away!

The question is exactly what's written on the subject line. In TWC, when writing a tiddler, I can hit the enter key and start a new line. In TW5, I can only (afaik) achieve this either by creating a bullet or numbered list. There are cases where I would not want a bullet or numbered list and just simply create a new line. The way I'm doing this now is by typing in <br> in front of each line. Is there another way of doing this? Not that big of a deal if there isn't, just curious. I understand hitting "Enter" twice moves you down to a new line, but I'd prefer if I didn't have that much space between my lines.

I could always experiment using a text expander software or something like that to speed up the <br> inputs. OR I could make it easy on myself and just get used to numbered lists and bullets.

jb

unread,
Dec 14, 2013, 11:50:42 PM12/14/13
to tiddl...@googlegroups.com
Me too. I am a long time TWC user (several yrs.) without really understand all the underlying code. I have been able to mimic others and use some or Eric's awesome plugins. I am having a really hard time warming up to all of the extra spacing in TW5. If only we could get a theme that have a more 'classic' look.
Awesome job Jeremy!

Jeremy Ruston

unread,
Dec 15, 2013, 9:16:58 AM12/15/13
to TiddlyWiki
I've just added support for hard line breaks using triple-double quotes:

"""
The linebreak at the end
of this line
will be preserved
"""

The new feature will be released with 5.0.2 shortly

Best wishes

Jeremy



--
You received this message because you are subscribed to the Google Groups "TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/groups/opt_out.



--
Jeremy Ruston
mailto:jeremy...@gmail.com

Gerald Strickland

unread,
Dec 16, 2013, 3:53:48 AM12/16/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
I upgraded to 5.0.3 and it works like a charm! Definitely faster than typing in <br>, excellent! Thank you!

By the way, this is the first time I tried upgrading TW5. I like the drag/drop idea of doing it. Very easy.

Jeremy Ruston

unread,
Dec 16, 2013, 3:59:23 AM12/16/13
to Gerald Strickland, TiddlyWiki
Hi Gerald

On Mon, Dec 16, 2013 at 8:53 AM, Gerald Strickland <mr.str...@inbox.com> wrote:
I upgraded to 5.0.3 and it works like a charm! Definitely faster than typing in <br>, excellent! Thank you!

By the way, this is the first time I tried upgrading TW5. I like the drag/drop idea of doing it. Very easy.

Great, glad it's working out,

Best wishes

Jeremy

Mat

unread,
Dec 17, 2013, 4:17:49 AM12/17/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
Various editors allow you to press Shift+Enter for hard line breaks. I think this would be a nice(-r) solution, if possible.

But actually, if I understand it right there is now

<<< and > for block quotes (btw, I'm always unsure if it's <<< or >>>) (with resevations for googlegroup messing up this here)
```` for monospace
""" for hard line breaks
double enter for paragraphs
and maybe more.

...am I alone in thinking that this is a bit much? It doesn't feel coherent. Even CSS would be more intuitive and generic ; ie {{block{ ... {{mono{ ...etc. So how about this idea, using the single and familiar > as a markup indicator

>block
here's the
block text
>block

>mono
10 write "Hello"
20 goto 10;
>mono

>linebreaks
poetry for
the people
>linebreaks

etc

Maybe that repetitive bottom command is not necessary, i.e instead of bottom >mono just a single > to show end.

Could even be with optional commands for even easier use, ie all these for the same result: >mono or >code or >m or >c

I think this is a LOT easier to learn (and there's already a LOT of other stuff to learn in order to use TW). I think we should strive for as few, as genereic and as coherent commands as possible.

<:-)

Vincent Yeh

unread,
Dec 17, 2013, 10:58:32 PM12/17/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
Mat,

I'd like to +1 (and like) the idea of "as few, as generic and as coherent as possible". :-)

Have fun!
Vincent

PMario

unread,
Dec 18, 2013, 9:28:40 AM12/18/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
On Tuesday, December 17, 2013 10:17:49 AM UTC+1, Mat wrote:
```` for monospace

``` ... only 3 of them


 
...am I alone in thinking that this is a bit much? It doesn't feel coherent. Even CSS would be more intuitive and generic ; ie {{block{ ... {{mono{ ...etc. So how about this idea, using the single and familiar > as a markup indicator

>block
here's the
block text
>block

hmmm ... nice idea, but imo you'll run into several problems if you want to implement it.
I'm just naming a view.

a) There is no difference between the "start" and the "end" tag. So what if, you need to nest them
eg:

>block

>block
here's the
block text
>block
>block

You'll need to implement a new syntax for your "nested tags" and your "end" tag ... which introduces more complexity.

b) IMO typing ``` is much easier than >block >mono ... I'm lazy ... its just less characters to type
```
mono text
```

>mono
mono text
>mono

imo the ">mono" tags interfere with the text in edit mode.

c) there may be some text eg: > linebreaks that should not indicate a """ block, but start a single line quote with the text "linebreak" ...
I did use a space to create a difference between ">linebreak" and "> linebreak" ... As you can see, it is quite errorprone

...

So imo at the end there will be much more complexity and much more to type :)

have fun!
mario

Andrew Harrison

unread,
Dec 18, 2013, 9:36:21 AM12/18/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
I still don't know why my responses to this group don't show up for days, even weeks. That aside, I think markup is only useful for keeping the size of the file small. Triple letters is a bit much, and I wish it were double characters for everything. <br> was 4 and I have it times 1000, so """ is 3 X 1000 = 3000. Sooo, thank you 1000 times Jeremy. I wish it could be 2000 times.




Sent from my Samsung Epic™ 4G Touch

Vincent Yeh <qmo....@gmail.com> wrote:
Mat,

I'd like to +1 (and like) the idea of "as few, as generic and as coherent as possible". :-)

Have fun!
Vincent

On Tuesday, December 17, 2013 5:17:49 PM UTC+8, Mat wrote:
Various editors allow you to press Shift+Enter for hard line breaks. I think this would be a nice(-r) solution, if possible.

But actually, if I understand it right there is now

<<< and > for block quotes (btw, I'm always unsure if it's <<< or >>>) (with resevations for googlegroup messing up this here)
```` for monospace
""" for hard line breaks
double enter for paragraphs
and maybe more.

...am I alone in thinking that this is a bit much? It doesn't feel coherent. Even CSS would be more intuitive and generic ; ie {{block{ ... {{mono{ ...etc. So how about this idea, using the single and familiar > as a markup indicator

>block
here's the
block text
>block

Mat

unread,
Dec 20, 2013, 4:56:58 AM12/20/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
On Wednesday, December 18, 2013 3:28:40 PM UTC+1, PMario wrote:

a) There is no difference between the "start" and the "end" tag. So what if, you need to nest them

You have a point - but is it my lack of imagination or is this relevant to anything else other than block? I'm not sure what nested monospace or linebreaks mean. Regardless, one could perhaps use the intuitive and established practice of repeating the command as is done in e.g bullet list levels. Perhaps

>block
mary had a
>>block (or >block>block )
little
>>
lamb
>


b) IMO typing ``` is much easier  [...and...]  the ">mono" tags interfere with the text in edit mode.

I agree with the "interfere" aspect (altho only a minor problem) but while ```, """, <<<  etc may look aesthetic my point is that these are magic commands and that they are too many that have to be learnt individually. How can we make these  many formatting commands (or whatever these commands are called) more coherent?


c) there may be some text eg: > linebreaks that should not indicate a """ block, but start a single line quote with the text "linebreak" ...
I did use a space to create a difference between ">linebreak" and "> linebreak" ... As you can see, it is quite errorprone
 
LOL, maybe someone wants to type """ also! I think the number of times people write >linebreak literally are quite few. That said, I do just realize that the > sign is sometimes used in emails to indicate copied text. However, > is just an example of course. Could be | , ~ ... 


So imo at the end there will be much more complexity and much more to type :)

Well, complexity can bring simplicity and this is my very aim. Maybe we can come up with something quick and easy to remember? One running concern I have with TW is that I think we loose potential users because of quirks like these. The threshold to get into TW is unfortunately a bit high and these commands used from the very beginning are probably particularly important in this respect (as opposed to the later thresholds where you're forced to dabble with js and stuff.)


However, this makes me wonder if it is possible with alternative syntax for these features? Both """ and something else. Maybe difficult to implement, I have no idea, but it would probably appeal to different people and thus increase the appeal of TW. I will raise this question on the dev board instead and hope to continue the discussion there.

Always thought provoking and valuable thoughts from you Mario.

<:-)



Julie

unread,
Dec 20, 2013, 8:23:05 AM12/20/13
to tiddl...@googlegroups.com
Maybe "linebreak" or other full English words are clearer for you, but it may not be for all people whose native langage is different. The interface of TiddlyWiki could be translated (as it has been for TWC, and for Chinese TW5) for non English-speaking people, but it may be more difficult to translate all the markup used. In this regard, symbols seem better.

If you are not pleased with the wikiText for TW5, maybe can you look at the MarkDown one, which is supported by TW5 thanks to a plugin (see http://tiddlywiki.com/markdowndemo.html) ?

Stephan Hradek

unread,
Dec 20, 2013, 9:34:19 AM12/20/13
to tiddl...@googlegroups.com
Besides the already introduced """ for literal linebreaks, what do think about the idea of being able to dynamically define, on tiddler-level a character to use for a linebreak?

I have, at the moment, no idea whether or not this will work, but similar to the \rules pragma we already have, we could create another like:

\pragma linebreak #

Which would then mean that any "#" character at the end of a line would mean to take this linebreak literally and remove the hash.

This is just a stupid idea, but maybe you like it?

Jeremy Ruston

unread,
Dec 20, 2013, 9:39:07 AM12/20/13
to TiddlyWiki
It could also perhaps be done by switching in and out parse rules. The current paragraph parsing could be moved into a rule called "paragraphs" and the alternative newline-causes-<BR> rule called "linebreaks". The latter rule would be off by default. Then one would switch with:

\rules +linebreaks -paragraphs

(albeit with a newly invented syntax).

Best wishes

Jeremy.
 

--
You received this message because you are subscribed to the Google Groups "TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/groups/opt_out.

Stephan Hradek

unread,
Dec 20, 2013, 11:11:15 AM12/20/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
Nice idea, Jeremy, but I'd like to be able to have:

\rules +linebreaks +paragraphs

be possible as well, meaning that this:

i want the
best
of both worlds

that would really be
GREAT

would render something like this;

<p>
i want the
<br/>
best
<br/>
of both worlds
</p>
<p>
that would really be
<br/>
GREAT
</p>


Michael Herrmann

unread,
Dec 20, 2013, 5:12:22 PM12/20/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
I would like Jeremy's proposal 

     \rules +linebreaks -paragraphs

very much, if the scope could be widened to the whole TW also.

Stephan Hradek

unread,
Dec 23, 2013, 9:28:57 AM12/23/13
to tiddl...@googlegroups.com, jeremy...@gmail.com
Hi Jeremy!

While I was creating a new documentation today for work, I again came to the point, where I really wanted a linebreak in a list. Using <br> is okay for me, but still there is the problem that those lines will get pretty long. I'm not allowed to enter a real linebreak as the list will then be closed.

So I came back to this idea and I'm wondering whether or not the following, very generic approach could be implemented. I'm more than willing zo do that, but I think I need to be shown to my starting place.

So this is the idea:

Similar to the \define pragma, I'd like to have a tiddler specific pragma defining some "pre-processor" search and replace terms. As an example:

\replace /#\n/<br>/

This should replace any "#" followed by an line-end with a <br>. So there wouldn't be any additional rendering included. It would be a pure pre-processing. As a result, this:

# line item 1
# line item 2#
continuation of line item
2
# line item 3

Would be seen by the TW render process as

# line item 1
# line item 2<br>continuation of line item 2
# line item 3

and rendered as such.

Maybe it's a too stupid or too complex idea?

Jeremy Ruston

unread,
Dec 23, 2013, 10:32:01 AM12/23/13
to Stephan Hradek, TiddlyWiki
Hi Stephan

I think there's an easier approach to this particular problem: a new parse rule could match /#\n/ and emit a <br> element. In earlier discussions the backslash has been floated for this purpose, which I think I might prefer.

Best wishes

Jeremy.

Stephan Hradek

unread,
Dec 23, 2013, 11:32:56 AM12/23/13
to tiddl...@googlegroups.com, Stephan Hradek, jeremy...@gmail.com
My idea was to make this configurable. It would also allow other replacements like:

\replace /\(\(/<span class="myButton">/
\replace /
\)\)/<\/span>/

This preprocessing would surround any "((buttontext))" with some html stuff which a CSS would render in a button-like way.


Jeremy Ruston

unread,
Dec 23, 2013, 1:18:14 PM12/23/13
to Stephan Hradek, TiddlyWiki
Another way of thinking about this feature would be as the ability to define a regexp that invokes a macro, passing the captured groups as parameters. It would be an interesting half-way house between our present textual macros and writing a fully-fledged javascript parser rule module.

Best wishes

Jeremy
 
Reply all
Reply to author
Forward
0 new messages