How do i Code and Syntax Highlight in articles in xwiki?

Hello!

We have just started using xwiki, haven’t change or done anything special to our installation. In our wiki articles we would like to be able to highlight code/syntaxes but are unable to do so, probably because lack of knowledge how to do this :slight_smile:

Our pagesyntax is xwiki 2.1 how do we correctly highlight code/syntaxes? We tried using test but that doesn’t work(works nicely here tho), pointers, tips?

Hi, you need to use the wiki editor (you need to be an advanced user to get it), see http://extensions.xwiki.org/xwiki/bin/view/Extension/Syntax%20Highlighting%20Application for more details.

Thanks

Aaah, thank you. Now i see :slight_smile: Is there any possibility to use inline code highlighting like this hey ho hey ho in xwiki as well?

@izeen,

I think you’re looking for the code macro. http://extensions.xwiki.org/xwiki/bin/view/Extension/Code%20Macro.

Have fun,
Ben

Hello!
How I can change Code Highlighting?

I want to change Theme from Iceberg to something Dark.
For example Theme “Darkly”

And I faced problem code higlighting. It use color: #19177C for some parts of code. This color fades on black background.

Please don’t hijack existing threads :slight_smile: Instead, if you have questions, consider starting a new thread.

EDIT: if you post a new thread, please mention your wiki markup content so that we know what macro you’re using.