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

Unmatched bracket breaks line wrapping #148

Closed
evmar opened this issue Jul 4, 2016 · 3 comments
Closed

Unmatched bracket breaks line wrapping #148

evmar opened this issue Jul 4, 2016 · 3 comments
Labels

Comments

@evmar
Copy link

evmar commented Jul 4, 2016

;; Version: 2.1
;; Package-Version: 20160629.459

Input:

foo bar
foo bar
foo bar
foo bar
foo bar
foo bar
[
foo bar
foo bar
foo bar

foo bar
foo bar
foo bar
foo bar

Set a fill column:
M-x set-variable RET fill-column RET 72 RET

Then hit M-q while the cursor is in the first block. You'll see that the [ causes odd wrapping, and also that the subsequent block cannot be wrapped.

Using backticks around the [ doesn't help either. I couldn't find any workaround. This came up in a place where I was discussing ANSI escapes, which are text sequences that look like \e[34m.

@evmar
Copy link
Author

evmar commented Jul 4, 2016

Possible workaround: use [ in place of the bracket.

Edit: nope, [ in a code block doesn't become a [.

@jrblevin
Copy link
Owner

jrblevin commented Jul 5, 2016

Thanks for reporting this. I've confirmed it. It would seem to be related to some of the variables that control filling behavior, to avoid breaking lines in the middle of an inline link, but I'll have to look into it further.

@jrblevin jrblevin added the bug label Aug 26, 2016
@jrblevin
Copy link
Owner

I can't reproduce this anymore. In fact, I think this was fixed a while ago by 3f11a4a, which was in response to #161. The problem was that markdown-mode mistakenly thought the point was inside an link, due to the unclosed square bracket, but I fixed that. Please reopen this issue if this didn't fix the problem.

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