diff --git a/source/Ox.UI/js/Code/Ox.SourceViewer.js b/source/Ox.UI/js/Code/Ox.SourceViewer.js index e7acf5ad..dc499717 100644 --- a/source/Ox.UI/js/Code/Ox.SourceViewer.js +++ b/source/Ox.UI/js/Code/Ox.SourceViewer.js @@ -60,7 +60,7 @@ Ox.SourceViewer = function(options, self) { .appendTo(self.$table), $comment = $('') .addClass('OxComment OxSerif') - .html(trim(section.comment)) + .html(quote(trim(section.comment))) .appendTo($section), $code = $('') .addClass('OxCode') @@ -74,6 +74,10 @@ Ox.SourceViewer = function(options, self) { }); }); + function quote(str) { + return str.replace(/\s`(.*?)`/g, ' $1') + } + function trim(str) { // removes leading or trailing empty line return str.replace(/^\s*\n/, '').replace(/\n\s*$/, '');