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
Allow multiple characters surround #15
Comments
This would also be useful for Mediawiki: ''italic'', '''bold''' And of course Markdown: bold |
I guess it'd be possible, though I'm not too keen on implementing it. In the past, I've just created one-offs for those, e.g.:
|
I'm resurrecting this because I have a question about your philosophy on this and a specific question regarding multiple characters. I am wondering why |
All surroundings are invoked as a single character. |
I think the majority of use cases for this would be covered by allowing a prefix for the surround plugin; |
That seems like a reasonable solution. Today, the count for the operator is unused. You can still supply a count for the motion (e.g. |
How about using Currently you can use That isn't very useful, since |
That strikes me as being a hack; then you wouldn't be able to do multiple |
What do you mean "multiple surrounds of alphanumeric characters"? |
This proposal fails to allow surrounding with the characters "tt", since On Thu, Nov 26, 2015 at 6:07 PM, Håken Lid notifications@github.com wrote:
|
I know it's a bit of a hack, but for anyone else trying to figure this out, you can use
Gets the job done. |
Since the solutions in this thread involved a lot of keypresses, I started the Vim Markup Assistant plugin, which toggles single words in Markdown to italic or bold. Thereby, I lose the flexibility of vim-surround, but I gain simplicity. Examples here. |
with vim-repeat, an alternative is: |
Just adding a possible use-case: Jinja2 has this kind of stuff:
and it's common to put a space between those and the contents. So I'd love to do something like this:
|
I came across this issue while looking for a way to do
This seems to work fine as long as the characters on one side are identical to the ones on the other (so no
but at that point I might as well just do it manually. My main issue is how to make these, or at least the Markdown bold |
Glad I wasn't the only one wanting this! (This was part of why I liked using Asciidoc vs Markdown.) If this changes, please let me know! Use your plugin all the time! |
If I'm not mistaken this is addressed in PR #226 from 2017 that has not been merged yet. |
For anyone finding this thread later... it's kind of a hack but the best solution I've found is to just press |
I'm trying to resurrect this thread... I have these in my vimrc... I'd like to be able to surround words with two or more characters to have "bold" in markdown.
|
That doesn't seem to work for me... 🤔 |
oh, I'm not sure if I wrote that before or after using |
Hi,
I'd like to use your plugin for editing Trac wiki pages. In this language sections have more than one = level, for instance:
= Section1 =
== Section2 ==
=== Section3 ===
would it be possible to specify a number before the character to wrap? For instance if I want to convert a text into Section3 header it will be something like cs<text_selection>3=
Thank you
The text was updated successfully, but these errors were encountered: