Disobeying typografic correction


I was working with some code examples. In the maxOS preference I have enabled typographic quotes (I use »…« instead of “…”). Unfortunately this setting is not helpful when editing action code in Tinderbox – as it will interfere and make it impossible to write with syntactically correct quotes.

Is there a way to have Tinderbox behave better and not REPLACE quotes with the ones preferred in the system seintgs? I tried a programs like Visual Studio Code, that do not have the probkem…

Yes! Just disable “Smart Quotes” for notes where typographic quotes are not appropriate. Doing so also sets $SmartQuotes to false, so the setting will be restored when you edit this note in the future.

Note that $SmartQuotes is inheritable, so (for example) if your code notes inherit from a prototype, turning off $SmartQuotes in the prototype will make it easy to set this automatically in new code notes.

Use of $SmartQuotes has already been explained but note that Tinderbox is primarily a note taking tool and not a coding IDE, unlike Visual Code, so the default, of fixing quote to (locale observant) typographic conventions makes a sensible norm. Bear in mind many people use Tinderbox with little or no use of code, so one default can’t fit all uses.

In addition check out the builtin prototypes ‘Code’ and ‘Action’. Code is intended for when a note has general code, e.g. HTML, JavaScript, CSS, etc. For notes holding action code, the Action prototype adds the affordance of the code colouring that you see in the Inspector for queries/rules/stamps, etc.

So code support is there, but you need to remember that if you’re going to code in notes you want to set them up for code beforehand.