joeyuping / quick_latex_obsidian

MIT License
326 stars 21 forks source link

Add option to automatically convert '*' to '\cdot' or '\times' #122

Open Mafrans opened 9 months ago

Mafrans commented 9 months ago

Many standards for multiplication use the center dot (\cdot) or cross (\times) for multiplication of scalars, I suggest there should be an option to automatically convert the asterisk symbol (often used as a multiplication symbol) into one of these options, similar to how '/' automatically converts to \frac.

joeyuping commented 9 months ago

Hi!!

The functionality can be achieved using the custom shorthand function of the plugin, by going to the plugin settings page, scroll to the last item, following the syntax as described in the description.

joeyuping commented 9 months ago

for the multiplication conversion, try adding the following to the custom shortcut setting:

*:::\cdot;

Mafrans commented 9 months ago

The custom shorthand works when a space is before/after the symbol but typing f.e a*b will not result in a \cdot b, perhaps this is intended functionality, but it does make quick latex slightly less quick.

asellingson28 commented 2 months ago

I would agree this should be an option in the custom quick latex settings.