Zettelkasten Forum


Use of *x* vs. _x_ for italics

I’m still on the trial, but I very much like The Archive as a substitute for NVAlt.
One thing: in Preferences there is an option to choose between *x* and _x_ for italics, which is great. I would find it useful if this choice not only affected what happens when I type cmd-I, but also how text is rendered. Thus if I pick _x_ for italics in Preferences, typing *hello* should not be rendered in italics.
This would be useful for me as I use asterisks for other things than italics.
Thomas

Comments

  • edited March 2018

    A personal opinion:

    As a general rule, markdown renders both single asterisks and underscores in the same way. I don't think it would be a very practical idea to have a customised markdown, as 1. that would not play well with other applications (i.e. marked 2, typora, etc) and 2. it would defeat the idea of format agnosticism (because if this happened, then you'd be stuck to an app to render markdown in the way you want).

    That said, I have experimented with both things and have the impression that using underscores for italics is more readable. I suspect, for instance, that is the reason why Ulysses uses the underscores by default. Let me give an example:

    **bold** ***italicbold*** vs **bold** **_italicbold_**

    In my opinion, the second is more human readable, even though both will be rendered in the same way by the machine. It's also easier to find and replace or use regex (if you're into that sort of thing) if things are kept differentiated.

  • Yeah, breaking with the core Markdown convention of how italics are rendered is not a good idea. I won't change that.

    But I'm curious: what do you want to do with the asterisks instead, @Thomas?

    Author at Zettelkasten.de • https://christiantietze.de/

  • Would that really be breaking the conventions? I would just think of it as a way to allow the user to customise how the text is rendered. Markdown-asterisk aficionados could still use their asterisks if they wanted. In Marked 2 I use a custom pre-processor to replace all instances of * with \*, which works. But anyway, thanks for your comments!
    In historical linguistics we use asterisks for reconstructed forms. For instance, English mouse, German Maus and Danish mus descend from Proto-Germanic *mūs. The Proto-Germanic word is not actually attested, but reconstructed on the basis of its daughter languages, and that is shown by the asterisk.
    All best,
    Thomas

Sign In or Register to comment.