joeyuping / quick_latex_obsidian

MIT License
327 stars 21 forks source link

cursor not working properly #57

Closed julianmueller closed 2 years ago

julianmueller commented 2 years ago

Hi, in latest update of the shorthands there are these two tips:

Tip2: Use "#cursor" within snippet to set the cursor position after replacement Tip3: Use "#tab" within snippet for cases of multiple parameters. e.g. bi:\binom{#cursor}{#tab}, after keying bi and spacebar, the shorthand will expand into \binom{|}{#tab} with cursor in the first brackets. After keying the values in first brackets, press tab to jump to the #tab location to continue typing.

But this does not work properly. I used the example bi:\binom{#cursor}{#tab} but the autocomplete made \binom{#{#tab}. Id same goes for this example: cs:\cos(#cursor); -> \cos(#.

Still a great plugin tho!

joeyuping commented 2 years ago

Hi !

Thank you! However, I am not so sure whether it was version difference or... as I am unable to replicate the situation as you mentioned.... Does the problem still persist?

julianmueller commented 2 years ago

Hi, i just updated to the latest version of your plugin, and unfortunately, the bug still exists for me. I disabled all other plugins and styles and tried with only one shorthand command in config file, but no luck. I also tried turning off all other settings for your plugin.

eg with the suggestion from #58, i get ([SPACE] means the keystroke):

vmat:\begin{vmatrix}#cursor\end{vmatrix}; $$\vmat[SPACE]$$ -> $$\begin{vmatrix}#end{vmatrix}$$

I dont know why this happens.

joeyuping commented 2 years ago

oh!!

I found the issue! Please try v2.3.6