Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add code source highlight capabilities #16

Closed
Jenselme opened this issue Apr 22, 2014 · 3 comments
Closed

Add code source highlight capabilities #16

Jenselme opened this issue Apr 22, 2014 · 3 comments

Comments

@Jenselme
Copy link
Contributor

Hi,

Is it possible to add source highlighting possibilities with pygment? Possibly with the same syntax as here: http://hatta-wiki.org/Markup2#preformat

{{{#!c
/* "Hello World" written in C */
#include <stdio.h>
int main(int argc, char[]* argv)
{ printf("Hello World\n"); return 0; }
} }}

Regards,

@jedie
Copy link
Owner

jedie commented Apr 25, 2014

This is possible to use pygments via macro and i use it in PyLucid, see:

https://github.com/jedie/PyLucid/blob/master/pylucid_project/apps/pylucid/markup/PyLucid_creole_macros.py

http://www.pylucid.org/permalink/309/highlight-source-code#creole-markup-macro

But IMHO not in the syntax you wrote, Without code changes.

@Jenselme
Copy link
Contributor Author

Thanks for your answer. It works perfectly with macros as you suggested.

@jedie
Copy link
Owner

jedie commented Apr 28, 2014

Think it would be a good idea to add a pygments example macro: #17

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants