Tinderbox Forum

Force Plaintext if Prototype of note is Markdown?

Is it possible to force the editor to function in a plaintext mode, where maybe a fixed width type face is used and all styles are ignored when copy/paste occurs?

I find myself reformatting notes to standardize size, color, typeface regularly if I am pulling an action item from an email for example.

When pasting, use Paste And Match Style.

Yeah, that is what I am doing now, will commit to muscle memory; just was curious if there was something on the horizon that would disable the “rich text” editor when using Markdown prototype for example.

I very much doubt this.

Can’t test right now, however something @eastgate mentioned some time ago in another thread might work. Try to use this code

in the note’s $Edict.

(If it doesn’t work we could try to add a short delay at the beginning of the Edict, I think).

When you’re done with adding new text you could remove or disable the Edict.

FWIW, action code doesn’t have a ‘wait’ mechanism (though AppleScript does).

I tested:

$MyString=$Text; $Text=$MyString;

And it works. Result is no styling but $Text font and size are as per document defaults.

Here is my test doc: plaintext.tbx (136.4 KB)

The TBX has one stamp applied to 2 copies of the ‘test text’ note that contains styled text. The test using a prototype is for if you want $Text with a monospace font with no smart quotes.

†. Normally, we’re trying to make things go faster. :slight_smile:

1 Like

Yes, I had runCommand in mind.

Yep, just tested too. Quite nice.

@devnull if you don’t want to be precise when copying you could add this at the beginning of the Edict:


This way you don’t have to take care of exact copying or adding linebreaks afterwards and always get exactly two linebreks between each pasted part.

Thanks for the help all, this is a great workaround!

1 Like