Re: [vim/vim] Concealed text causes vim to wrap before window width (#260)

179 views
Skip to first unread message

Anmol Sethi

unread,
Jan 2, 2017, 5:20:28 PM1/2/17
to vim/vim, Subscribed

What about when concealcursor=nvic? Then it should only wrap on what is visible.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub

Anmol Sethi

unread,
Jan 2, 2017, 5:23:12 PM1/2/17
to vim/vim, Subscribed

Also, horizontal scrolling doesn't scroll on only visible text.

Bart

unread,
Jan 2, 2017, 7:55:40 PM1/2/17
to vim/vim, Subscribed

@nhooyr It should, but it's not the case.

Anmol Sethi

unread,
Jan 2, 2017, 8:04:13 PM1/2/17
to vim/vim, Subscribed

@louwers in the original post, the person has concealcursor=nvic set though?

Bart

unread,
Jan 3, 2017, 8:43:35 AM1/3/17
to vim/vim, Subscribed

@nhooyr Yes, so for that setting it's incorrect that it would create a wobbling effect or that it would be slow. However, there's still the issue of it being a lot of work to implement.

Are you working on a patch? Personally I think it would be worth it, because without correct wrapping the conceal feature has little use, at least to me.

Antonio Ospite

unread,
Jul 18, 2017, 11:08:51 AM7/18/17
to vim/vim, Subscribed

And as mentioned by @brammool in https://groups.google.com/forum/#!topic/vim_dev/ZQTXsL4Tdyg on lines where there is some concealed text, positioning the cursor with the mouse also fails.

As aside effect of these bugs the AnsiEsc plugin which uses conceal to hide the ANSI escape sequences is not that useful either.

Henré Botha

unread,
Jan 16, 2020, 4:52:30 AM1/16/20
to vim/vim, Subscribed

I know this is wontfix, but I would like to add my 2c that it be reconsidered. My use case: I write notes in markdown syntax, using this plugin for syntax highlighting. The plugin helpfully defines conceals for URL patterns (like [this](https://github.com/vim/vim/issues/260)).

I'd like my notes to remain reasonably readable. With long URLs, it becomes a challenge. The "correct" answer here is set conceallevel > 0; however, due to also using set wrap, this completely breaks the flow of reading. I may as well not use conceal at all.

The behaviour I think anyone would expect is that wrapping happens based on visible characters only.

If we can map out what all needs to be done to implement this change, I'd be willing to help.


You are receiving this because you are subscribed to this thread.

Reply to this email directly, view it on GitHub, or unsubscribe.

ihadgraft

unread,
May 23, 2020, 9:35:18 AM5/23/20
to vim/vim, Subscribed

For pages that contain reference information or a solution (most of my cases) I do this:

  • Create a new page in vimwiki
  • On the new page, I paste relevant content from the URL, add a summary, metadata, annotations, the source URL, and whatever else is useful

A quick way I've come up with to get nicely-formatted, easily "yankable" content from a URL is to use Pandoc and pipe the output right into vim:

$ pandoc -o - -t markdown ${SOME_URL} | vim - 

Creating my own page is a bit more up-front work but has a couple of nice advantages:

  • The reference / solution itself is searchable in the wiki
  • I often don't have to deal with a browser on repeat visits if I've done a good job capturing the critical information.
  • Links in the wiki are far easier to deal with

If there are cases where this solution wouldn't work or would be annoying, I might use a URL shortener. But I'm finding that most things I need to link to directly every time are site home pages or maybe one level deep, so they aren't causing issues to begin with.

Kefei Lu

unread,
Aug 25, 2021, 2:23:57 AM8/25/21
to vim/vim, Subscribed

I know this is wontfix, but I would like to add my 2c that it be reconsidered. My use case: I write notes in markdown syntax, using this plugin for syntax highlighting. The plugin helpfully defines conceals for URL patterns (like [this](https://github.com/vim/vim/issues/260)).

I'd like my notes to remain reasonably readable. With long URLs, it becomes a challenge. The "correct" answer here is set conceallevel > 0; however, due to also using set wrap, this completely breaks the flow of reading. I may as well not use conceal at all.

The behaviour I think anyone would expect is that wrapping happens based on visible characters only.

If we can map out what all needs to be done to implement this change, I'd be willing to help.

I want to make the same point as this comment, but mainly using the below screenshots to give an idea:

image

image


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Triage notifications on the go with GitHub Mobile for iOS or Android.

mtwebb

unread,
Jan 4, 2022, 4:32:26 PM1/4/22
to vim/vim, Subscribed

+1 to this. The visual example above is great, and there are many other use cases this would enable (hide footnotes, or notes to self in long prose work, hide commented out code).


Reply to this email directly, view it on GitHub.


Triage notifications on the go with GitHub Mobile for iOS or Android.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/1005185645@github.com>

Dan Murphy

unread,
Sep 10, 2022, 3:52:11 PM9/10/22
to vim/vim, Subscribed

Another vote for fixing this issue. I love Vim and use it for almost everything, but I still find myself using Emacs for Markdown and Org files. The ability to conceal links and still have properly wrapped lines is a huge advantage; I almost never need to bother with a separate viewer application.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/1242795888@github.com>

Hunter Wapman

unread,
Jan 3, 2023, 10:53:29 PM1/3/23
to vim/vim, Subscribed

Adding a vote for a fix to this issue — seems clear to me this isn't desirable behavior.


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/1370458942@github.com>

flechtwerkflechtwerk

unread,
Feb 10, 2023, 1:42:54 PM2/10/23
to vim/vim, Subscribed

I'd also love this to be reconsidered. I use comments in Markdown a lot and would like to conceal them, but it truly messes up my lines.


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/1426197372@github.com>

WhiteBlackGoose

unread,
Mar 9, 2023, 5:59:31 AM3/9/23
to vim/vim, Subscribed

Bump


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/1461805666@github.com>

Yee Cheng Chin

unread,
Mar 13, 2023, 9:13:30 AM3/13/23
to vim/vim, Subscribed

Just something random I have been dealing with: conceal also affects hard tab character positioning. In fact, if you read Vim documentation, it makes liberal uses of hard tabs and the alignment of the docs assume that conceal characters still count towards the hard tabs (in fact vimhelp.org only recently fixed this issue to make the online documentation look correct alignment-wise c4rlo/vimhelp#23). So if we fix this this probably need to be a toggleable option unless we fix up all the docs (and not sure if others rely on this as well).


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/1466122602@github.com>

qadzek

unread,
Dec 2, 2024, 3:54:11 AM12/2/24
to vim/vim, Subscribed

If you're looking to conceal links, especially long URLs, consider using reference links such as [Vim][3] instead of inline links like [Vim](https://www.vim.org).

I created a plugin that automatically converts your inline links to reference-style. This ensures that concealing works well, even when you use :set wrap.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/2510922847@github.com>

Mostafa Touny

unread,
Sep 6, 2025, 3:13:23 PMSep 6
to vim/vim, Subscribed
mostafatouny left a comment (vim/vim#260)

I hope the community fixes this someday.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/260/3263065890@github.com>

Reply all
Reply to author
Forward
0 new messages