#1995 Is there a fandoc syntax (colour) highligher for flux?

SlimerDude Mon 6 Aug 2012

Just wondering.

brian Mon 6 Aug 2012

no, not sure what we really could color code actually

SlimerDude Tue 4 Sep 2012

The following syntax-fandoc.fog adds a smattering of colour for those inclined:

using syntax
SyntaxRules {
  brackets = "[]"
  comments = ["  ", "##", "**", "==", "--"]
  blockCommentStart = "pre>"
  blockCommentEnd   = "<pre"
  blockCommentsNest = false
  strs = [
  SyntaxStr { delimiter = "`"; multiLine = true },
  ]
  keywords = null
}

brian Tue 4 Sep 2012

I tried that out and it doesn't look too bad. I had to change "**" to "***" to not have it trap on bold. But that doesn't work on beginning comments then too well. Plus it would be cool to actually show code sections - but that would require a custom parser.

SlimerDude Mon 10 Sep 2012

I've looked into customising the parser in the past, but it looks a tad involved and tricky. I wanted to add custom markup to integrate Concordion.

I've not tried yet, but it seemed easier to create a second parser that ran after the fandoc one, rather than try to integrate with the fandoc parser.

Login or Signup to reply.