Tinderbox Forum

Disable Smart Dashes


(Dirk Kalmbach) #1

Hi all,
I often copy text from tinderbox to other code editors and find it annoying that two dashes “–” will be replaced to one dash “-” (so called “smart dashes”). I know I can change this in Edit/Substitutions for every note.
But is there any possibility to disable Smart Dashes for all notes in advance?


(Ralph Alvy) #2

I don’t have that enabled in any Note. Not sure why I don’t and you do.


(Dirk Kalmbach) #3

Interesting! In my case, it’s always enabled when I open a new TBX.


(Mark Anderson) #4

See this on Smart Dashes which summarises the behaviour and how you can control it.


(Dirk Kalmbach) #5

Thanks, Mark. I wasn’t aware of the Attribute $SmartQuotes which indeed disables also the smart dashes.
So my only work-around would be to work with prototypes in which I set $SmartQuotes = False!?
Or is there a possibility to change the attribute value for the whole TBX document?


(Mark Anderson) #6

Yes. As with any System Attribute (except read-only ones) you can set a custom default at Document level using the System tab of the Document Inspector. However, with a few attributes that have preference-based settings, you can’t edit here…

Document%20Inspector%3A%20untitled%202019-03-04%2009-20-52

… but instead you need to do this via the Document Settings (i.e. the document’s preferences). In this case you want Edit menu -> Document Settings (Cmd+8) and then the Text and then set the ‘Smart Quotes’ control:

Preferences%202019-03-04%2009-32-24

The default setting is ‘ticked’ which seeds the doc-level $SmartQuotes default value of true. Untick the box to get your desired false setting whereby Smart Quotes and Smart Dashes are disabled for all notes. For any notes where you’ve set $SmartQuotes locally you may want to re-enable inheritance.

If the inheritance aspect of attribute values is confusing, see my article on how inheritance works in Tinderbox.