Timeline for How to use `syn` in regex match?
Current License: CC BY-SA 4.0
9 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Mar 2, 2023 at 20:00 | vote | accept | PedroSantana | ||
Mar 2, 2023 at 19:20 | answer | added | Vivian De Smedt | timeline score: 0 | |
Mar 2, 2023 at 18:16 | comment | added | PedroSantana |
Yeah I tried but unfortunately it seems the syntax cannot be used in the way I'm thinking. I'll look into the more well known markdown plugins like vimwiki, wiki.vim and vim-markdown. Let's see how it goes haha.But anyway, thank you for your help!
|
|
Mar 2, 2023 at 18:00 | comment | added | Vivian De Smedt |
You can use match but may be you could also use the result of syntax and catch the part of the text that is assigned to the highlighting group.
|
|
Mar 2, 2023 at 17:48 | comment | added | PedroSantana |
But instead of using the match() in vimscript, I was wondering if it was possible to use a similar method to the one I mentioned, using syn , start and end for example.
|
|
Mar 2, 2023 at 17:47 | comment | added | PedroSantana |
Hi! Sorry for not being more clear, I want to match and return the string of a given pattern, in this case a link, exactly the one you mentioned, similar to vimwiki , so when I press Enter, I can match this string.
|
|
Mar 2, 2023 at 17:21 | comment | added | Vivian De Smedt |
Welcome to Vim :-) I'm not sure I understand what you want to achieve or maybe I'm misled by the use of the syntax feature. The syntax feature is used for colorization but I understand that you would like to map <CR> to an action that would apply to a markdown link (like in vimwiki)
|
|
S Mar 2, 2023 at 17:12 | review | First questions | |||
Mar 2, 2023 at 17:18 | |||||
S Mar 2, 2023 at 17:12 | history | asked | PedroSantana | CC BY-SA 4.0 |