#519 Problem with markdown lexer

Filetypes (68)

Lines of code in a block should not be interpreted (http://daringfireball.net/projects/markdown/syntax#precode)

function foo_bar

"_bar" is colorized

"_bar" should not ne colorized

Tested with geany 0.20 (revision 5095)


  • Joseph Reagle

    Joseph Reagle - 2012-04-11

    This bug could be better specified. Basically, the matching of the underscore "_" character for emphasis or strong is too promiscuous. It finds underscores in URLs (or in the original report, variable names) and think they are markup. I would limit underscore matches to non-alphanumeric boundaries.

  • Joseph Reagle

    Joseph Reagle - 2012-04-11

    I've read up a little on syntax highlighting in geany, and it looks like this would be a scintella lexer issue, perhaps the bug should be moved upstream?

  • Lex Trotman

    Lex Trotman - 2012-09-13
    • assigned_to: nobody --> codebrainz
  • Anonymous - 2012-09-13

    You're right it's a Scintilla issue and would need to be fixed in Scintilla's LexMarkdown.cxx file. If you happen to get motivated to fix it (and all the other issues in it :) or if you report it to Scintilla's bug tracker, it would be great if you could follow up here with a link for others to find.

  • Colomban Wendling

    I don't see the bug in Geany 1.22. Actually the Markdown lexer (now?) checks whether "_" is preceded by a whitespace character and only changes states if it is.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks