Changes between Version 1 and Version 2 of TracCodeProcessorMacro
- Timestamp:
- Jul 26, 2009, 10:14:12 AM (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
TracCodeProcessorMacro
v1 v2 1 1 = Code Wiki Processor = 2 2 3 '''This is an external plugin. Please don't report any tickets here.''' See below for more information. 4 3 5 == Description == 6 This plugin provides a [wiki:WikiProcessors wiki processor] for code listing that uses file extensions for language detection rather than mimetypes. Normally you would - for [wiki:WikiProcessors#CodeHighlightingSupport more "exotic"] programming languages - have to specify the mimetype for a codelisting, like this: 4 7 5 - 8 {{{ 9 {{{ 10 #!text/css 11 div.lang-name-template { 12 margin: -1em 1.75em 1em 1.75em; 13 background: #F7F7F7; 14 text-align: right; 15 padding-right: 0.5em; 16 border-style: solid; 17 border-color: #D7D7D7; 18 border-width: 0 1px 1px 1px; 19 } 20 }}} 21 }}} 6 22 7 == Bugs/Feature Requests == 23 Since mimetypes are often hard to remember (is it `text/...` or `applicaton/...` or ...) and you have to dig to find the actual mimetype of a certain programing language this wiki processor addresses this problem. You only have to specify the ''file extension'' of the progamming language. To specify to code block above using this plugin simply write: 8 24 9 Existing bugs and feature requests for TracCodeProcessorMacro are 10 [report:9?COMPONENT=TracCodeProcessorMacro here]. 25 {{{ 26 {{{ 27 #!code(lang=css) 28 div.lang-name-template { 29 margin: -1em 1.75em 1em 1.75em; 30 background: #F7F7F7; 31 text-align: right; 32 padding-right: 0.5em; 33 border-style: solid; 34 border-color: #D7D7D7; 35 border-width: 0 1px 1px 1px; 36 } 37 }}} 38 }}} 11 39 12 If you have any issues, create a 13 [http://trac-hacks.org/newticket?component=TracCodeProcessorMacro&owner=manski new ticket]. 40 This results in: 14 41 15 == Download == 42 [[Image(screenshot.png)]] 16 43 17 Download the zipped source from [download:traccodeprocessormacro here].44 As a nice bonus the programming language is display in the lower right corner of the listing. This way a reader can easily identify the language the listing is written in. 18 45 19 == Source == 20 21 You can check out TracCodeProcessorMacro from [http://trac-hacks.org/svn/traccodeprocessormacro here] using Subversion, or [source:traccodeprocessormacro browse the source] with Trac. 22 23 == Example == 24 25 - 26 27 == Recent Changes == 28 29 [[ChangeLog(traccodeprocessormacro, 3)]] 46 == Source and Tickets == 47 You'll find all information about this ticket [https://svn.mayastudios.de/mtpp/wiki/Plugins/CodeProcessor here]. Please file only tickets there. 30 48 31 49 == Author/Contributors == 32 33 '''Author:''' [wiki:manski][[BR]]50 '''Author:''' [wiki:manski Sebastian Krysmanski] 51 [[BR]] 34 52 '''Contributors:'''