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

Syntax highlight problem in inline block when variable name contains underline #150

Closed
yanlinlin82 opened this issue Jan 7, 2015 · 7 comments
Labels

Comments

@yanlinlin82
Copy link

Underline in variable name should not be treated as "emphasis". For example:

Show a value: **`r a_b`**
@jalvesaq
Copy link

jalvesaq commented Jan 8, 2015

Thanks for reporting the bug, but the region starting with ** is defined by syntax/markdown.vim and I don't know how to fix the issue in syntax/rmd.vim.

@yanlinlin82
Copy link
Author

Intuitively thinking, syntax/markdown.vim should know nothing about the code chunks. That should probably be the reason of wrongly "emphasis". Will changing render order help to solve the problem?

@jalvesaq
Copy link

jalvesaq commented Jan 9, 2015

I've tried to include markdown syntax at the end of syntax/rmd.vim, but the result was the same.

@yanlinlin82
Copy link
Author

I guess this should be an issue of syntax/markdown.vim rather than syntax/rmd.vim, since two lines in the following code snippet behave differently in vim highlight:

This is a test code chunk: `r a_b`.

This is another _test code chunk: `r a_b`_.

@yanlinlin82
Copy link
Author

I found there have been issues about this problem, but unfortunately no any correct solution yet.

tpope/vim-markdown#16
tpope/vim-markdown#37
tpope/vim-markdown#27

@jalvesaq
Copy link

jalvesaq commented Jan 9, 2015

I guess that the solution (if any exists) might be in the use of the contains option in Markdown, but I also have tried to add/remove some contains to/from syntax/markdown.vim and couldn't find a solution.

@jalvesaq jalvesaq changed the title Syntex highlight problem in inline block when variable name contains underline Syntax highlight problem in inline block when variable name contains underline Feb 21, 2015
@jalvesaq jalvesaq added the Bug label Apr 6, 2015
@jalvesaq
Copy link

jalvesaq commented Apr 8, 2015

I deleted from the Vim-R-plugin the files that are already distributed as official Vim runtime files. Now, there is a new repository with these files: https://github.com/jalvesaq/R-Vim-runtime

Since the official runtime files are no longer in this repository, I'm closing this bug. This bug is already described in the Known bugs section of the README.md, and new bugs should be reported in the new repository.

@jalvesaq jalvesaq closed this as completed Apr 8, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants