Hello again CMSimple!
I'm still having issue with code highlighting (view the topic), but now it's a bit different. I replaced tiny with fckeditor, and I'd like to use the PBCKCode plugin which looks great. Unfortunately I couldn't make it work, I think I missed something. Because my 0 skill in web, I can't figure out the reason.
I added the plugin in /plugins/ckeditor/plugins directory, then modified config.js from ckeditor as requested for the plugin installation... but the icon does not appear
Could someone test if this plugin works, and the steps to do so please?
Cya
syntax highlighter - the comeback :)
Re: syntax highlighter - the comeback :)
Hello again pmolik,
the fine PBCKCode plugin requires CKEditor 4, but the latest version of CKEditor4CMSimple uses still CKEditor 3.x. Holger is working on the integration of CKEditor 4 to CMSimple_XH, but I don't know when a first version will be released (there were quite some changes from CKEditor 3 to 4).
So probably the best solution for now is to use Syntaxhighlighter_XH, despite it's an alpha version. At least you may test it. Of course, any feedback is welcome.
Christoph
the fine PBCKCode plugin requires CKEditor 4, but the latest version of CKEditor4CMSimple uses still CKEditor 3.x. Holger is working on the integration of CKEditor 4 to CMSimple_XH, but I don't know when a first version will be released (there were quite some changes from CKEditor 3 to 4).
So probably the best solution for now is to use Syntaxhighlighter_XH, despite it's an alpha version. At least you may test it. Of course, any feedback is welcome.
Christoph
Christoph M. Becker – Plugins for CMSimple_XH
[solved]Re: syntax highlighter - the comeback :)
Ho dear cmb! nice to see you again,
Thanks for the plugin, actually it's pretty good (much better than geshi hand crafted solution!), so I will adopt it for the moment. The only drawback is that (it seems to me) the 'tab' key can't be used to tabulate the code, but I don't know if there is any solution for that actually... and it's a minor problem anyway.
I set the topic as "solved", because this solution is good enough!
Bye
Thanks for the plugin, actually it's pretty good (much better than geshi hand crafted solution!), so I will adopt it for the moment. The only drawback is that (it seems to me) the 'tab' key can't be used to tabulate the code, but I don't know if there is any solution for that actually... and it's a minor problem anyway.
I set the topic as "solved", because this solution is good enough!
Bye
Re: syntax highlighter - the comeback :)
That's always a bit of a problem with simple textareas. The tab character defaults to jump to the next element, which can have the focus, in a browser. One can catch that with JavaScript, and insert the tab character, but this is not handled by the undo functionality (CTRL+z).pmolik wrote:The only drawback is that (it seems to me) the 'tab' key can't be used to tabulate the code, but I don't know if there is any solution for that actually
You may consider to actually write the code in an external editor, and just copy&paste it in the textarea. This way tabs will be preserved (at least for the tinyMCE plugin; I have not checked the CKeditor plugin). Syntaxhighlighter defaults to 4 spaces for a tab, which is configurable, but that's not (yet?) implemented for Syntaxhighlighter_XH.
PS: If JavaScript is disabled in the visitors browser, a tab will be rendered as 8 spaces usually. So it might be better to avoid tab characters at all.
PPS: If I'm not mistaken the value of the class attribute, which is needed for the SyntaxHighlighter, is invalid HTML 4.01 (that's not reported by the W3C validator, though). It may be valid HTML5 however.
Last edited by cmb on Thu Apr 25, 2013 2:08 pm, edited 1 time in total.
Reason: added PSs
Reason: added PSs
Christoph M. Becker – Plugins for CMSimple_XH