-
Notifications
You must be signed in to change notification settings - Fork 114
Wrong syntax highlighting when one line contains a single *
or _
#44
Comments
Looks like this is the same as #45 Closing my issue. |
Same problem when there is a single |
This appears to be fixed in v0.151. True? |
@Victorystick thanks for raising this - been bugging me for a while as well. Maybe it doesn’t bother people who write code in a bad C-style? |
I came across this issue when trying to use To solve this specific issue (this is a bad hack imo!) I have modified the existing local gfm.json file on line 40 to use the following regex:
I was going to do the same and submit a pull request, but as the main repo is actually in cson and I'm still learning coffee (and don't have an easy way to test) I haven't submitted that and instead created an updated fork ( https://github.com/PhillipHolmes/language-gfm/commit/3f91d731347f902b5e04a4c0eae492ac1aeca7cd ). As the syntax is slightly different and I'm not sure if I have escaped the quote or doublequote correctly within coffeescript - the line number changed to 39 and I'm guessing should look like this:
I know this isn't what most people are after (personally I don't have to care about |
+1 for fixing this, even if only for the I often write blog posts using Jekyll. If I put a {% include _toc.html %} at the top of a post the entire rest of the post becomes italic. Sadly, that mean this otherwise awesome package doesn't do much good unless I comment that line out with |
Yes, please fix this bug. It makes atom unusable for me. |
Hey there. I am the maintainer of of language-pfm, a package for pandoc flavored markdown which shares a lot of code with this package. I've spent a ridiculous amount of time trying to solve the bold / emphasis problematic for good. The grammar can either recognize inline styling like this beauty The first way actually works really good and produces almost no errors. __bold__
__this
is
bold__
__actually
not
bold__ bold bold__ The problem is that you cannot tell the grammar parser that an block environment is not allowed to contain new lines. So at the moment I only see two solutions.
Currently there is also a workaround I had not thought of, but was mentioned here: |
I meet the same problem in c code blocks and add espace charachter('') before each asterisk which is so ugly. |
No update on this issue... How can I help ? |
This comment has been minimized.
This comment has been minimized.
@kartsims's solution of switching to |
This also affects GitHub diffs. For example, the |
@Juni0rF's solution fixed this for me. I was having the same exact bug with Cheers! |
Sorry but that's hardly a solution...
…On Fri, 20 Apr. 2018, 11:18 pm jpasholk, ***@***.***> wrote:
@Juni0rF <https://github.com/Juni0rF>'s solution fixed this for me. I was
having the same exact bug with target="_ blank".
Cheers!
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#44 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ACB7XuyCVjtZ1d-GIxcYQ6fljcmUP5j9ks5tqfxOgaJpZM4Catzc>
.
|
I'm having the same issue. Would love to see this get fixed! |
Just came across this issue as well when I add a link with |
I came across the same problem using Atom as IDE and Jekyll with markdown and Kramdown. Unfortunately I've ran out of time to read and learn and solve, but in case it helps anyone i did discover that I could replace the underscore with the html code for underscore and (so far as I've tested) it renders perfectly in the final html and I no longer have the purple italics (I had the same view as @mischah 's example)
|
This comment has been minimized.
This comment has been minimized.
One of the most useful comments here (by @kartsims) has been marked "off-topic". 😕 |
This fixed the issue I was having with {:target="_blank"}, making all text italic before the target. |
If one wants to write a
*
as a normal char, not as a bold or italic start char, things will go wrong.Even,when there is no newline after the line contains the
*
When the
*
is the last char of one line, everything is ok...The text was updated successfully, but these errors were encountered: