Pygmentizer
Component ID
1097460
Component name
Pygmentizer
Component type
module
Maintenance status
Development status
Component security advisory coverage
covered
Downloads
1333
Component created
Component changed
Component body
This module provides an input filter which does source code syntax highlighting by using Pygments.
With this module you will have 20 color styles and 55 languages / metalanguages!
Prerequisite
You need a working Pygments on your host.
Try
sudo apt-get install python-setuptools
easy_install Pygments
Or see how to install Pygments.
Installation
- Enable this module.
- Download PHPygments and put it in sites/all/libraries. Ensure directory name keeps named "PHPygments"
- Go to admin/config/content/formats page, configure the text format in which you want to enable Pygmentizer and select the filter.
- At bottom of configuration page switch to settings tab of Pygmentizer.
Usage
Just Put your code inside [LANGUAGE] [/LANGUAGE] token!
eg:
[javascript]
/**
* Drag and drop table rows with field manipulation.
*/
Drupal.behaviors.tableDrag = {
attach: function (context, settings) {
//......
}
};
[/javascript]
See README.txt for more information.
