Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inline math: empty spaces in virtual preview #69

Open
SamHindson opened this issue Sep 19, 2023 · 2 comments
Open

Inline math: empty spaces in virtual preview #69

SamHindson opened this issue Sep 19, 2023 · 2 comments

Comments

@SamHindson
Copy link

SamHindson commented Sep 19, 2023

Hello! This plugin looks really useful for my purposes. However, whenever I add inline LaTeX to any document (enclosed within $ .. $) and call enable_virt, I am faced with empty spaces after the LaTeX code which shifts the rest of the text to the right of the screen. EDIT: (Or, rather, the text following the math is not shifted back, and the concealed TeX still seems to occupy as much space as it does before it is concealed away.)

Before enabling virt:
20230919_10h09m13s_grim

After enabling virt:
20230919_10h08m57s_grim

The plugin setup here is quite minimal --- only nabla and treesitter are installed.

Is this intended behaviour, or is it just not how nabla works? I've tried to follow the provided documentation but I'm getting a bit stuck. The first screenshot on the main page seems to suggest this is possible: the spacing of the text after "2\pi" seems to be normal, and as one might expect from e.g. VimTeX's concealment feature.

Thank you for your hard work!

@max397574
Copy link
Contributor

I'm quite sure this is a neovim limitation since we had quite similar issues in neorg and couldn't fix them

@Beastwick18
Copy link
Contributor

I've opened a PR #70 that should fix this. These changes are applied on my fork Beastwick18/nabla.nvim if you want to use that in the meantime. Also let me know if there are issues regarding the PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants