andriusvelykis / reflow-maven-skin

Reflow is an Apache Maven site skin built on Bootstrap. It allows various structural and stylistic customizations to create a modern-looking Maven-generated website.
http://andriusvelykis.github.io/reflow-maven-skin/
Apache License 2.0
132 stars 54 forks source link

Syntax highlighting doesn't work as intended. #11

Closed rlubke closed 11 years ago

rlubke commented 11 years ago

Looking at the resulting html in the highlight.js examples, the css class of the code blocks are based on the language name.

However, it appears that the doxia markdown conversion sets the class for all of these code blocks to "source".

Syntax highlighting looks okay for simple languages such as xml, but when you try java, it's all wonky.

It's easy to reproduce: Just update index.md of the reflow-skin site, add a code block in markdown with a hint of java. The result won't match what is expected on the example site.

I'm looking through the velocity tools now to see if I can work around this by replacing the "source" selector as I see it, but I'm not sure that a) it's possible (still reading) and b) how to tell Velocity to use whatever I create to process the result (need to read more about velocity).

If you have ideas on how I can easily work around this, please let me know.

rlubke commented 11 years ago

May be invalid after looking at the doxia sources. Closing for now.

rlubke commented 11 years ago

For reference in case anyone hits this: https://jira.codehaus.org/browse/DOXIA-488

andriusvelykis commented 11 years ago

Thanks for researching this. I did hope that the "automatic language detection" of highlight.js would help with the inability of explicitly indicating the language at the moment.

I guess we will just have to wait for the fix above.

rlubke commented 11 years ago

Well, even with the fix, it doesn't work as one would think.

For example, if I set the highlight theme to solarized_dark, the background of the pre block doesn't match the example on the highlight.js themes page.

Based on some digging with FF's developer tools, it appeared that the css definitions from bootstrap were interfering. Maybe something to investigate?

Andrius Velykis mailto:notifications@github.com May 1, 2013 2:50 PM

Thanks for researching this. I did hope that the "automatic language detection" of /highlight.js/ would help with the inability of explicitly indicating the language at the moment.

I guess we will just have to wait for the fix above.

— Reply to this email directly or view it on GitHub https://github.com/andriusvelykis/reflow-maven-skin/issues/11#issuecomment-17308814.

cchantep commented 10 years ago

Here is proposal for doxia md using jygments for highlighting: http://jira.codehaus.org/browse/DOXIA-507