joeyuping / quick_latex_obsidian

MIT License
327 stars 21 forks source link

Bug: Tabout and general tab not working for equations on list elements #84

Closed StrangeGirlMurph closed 1 year ago

StrangeGirlMurph commented 1 year ago

!!! Start reading here !!!

I would love to be able to tab or enter out of equations. Always reaching for the arrow key at the end of an equation is super slow. I never use tab in an equations. I think it would be the best option.

Sadly I don't know how obsidian plugins work yet and don't really know your code base... I would just make a PR if I knew. But it shouldn't be that hard to implement for you. Obsidian-latex-suite has this feature already implemented. Their tabout:

  • Pressing Tab while the cursor is at the end of an equation will move the cursor outside the $ symbols.
  • Otherwise, pressing Tab will advance the cursor to the next closing bracket: ), ], }, >, or |.

https://github.com/artisticat1/obsidian-latex-suite#tabout

Here is their source code:

StrangeGirlMurph commented 1 year ago

On another note: Thank you for your incredible plugin! I really appreciate your work :)

StrangeGirlMurph commented 1 year ago

Nevermind... This is already implemented.

StrangeGirlMurph commented 1 year ago

Now I understood that I found a bug ^^ The tabout doesn't work when the equation is an item of a list (bullet or numbered).

Example: + Let $a' \in G$

StrangeGirlMurph commented 1 year ago

Tab in general doesn't work on list items. That's also the reason that shorthands like bi:\binom{#cursor}{#tab}; also doesn't work

joeyuping commented 1 year ago

Hi! @StrangeGirlMurph

My deepest apology for the really late reply... Thank you for bringing this up! Though, while I tested the tabout for equation in list item, it does work fine. Does this problem still exist on your end?

StrangeGirlMurph commented 1 year ago

Oh don't worry. I actually switched to the latex suite plugin now (and have actually been working on it). You're right! The bug disappeared :) Those are my favorite bugs! Thank you :)