From 0fb89ceb06d8484591f0855aa5480430393a936b Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Sat, 29 Jun 2013 13:14:46 +0100 Subject: [PATCH] Trailing space adding added Load extra JS file, setup class and turn option on --- editor.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/editor.php b/editor.php index 4b9a56b..44acbae 100644 --- a/editor.php +++ b/editor.php @@ -15,6 +15,7 @@ modes: clike, coffeescript, css, htmlmixed, javascript, less, markdown, php, pyt utils: closetag, xml-fold, brace-fold, show-hint, javascript-hint, html-hint, searchcursor, match-highlighter //--> + ";} +.cm-trailingspace { + background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAACCAYAAAB/qH1jAAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3QUXCToH00Y1UgAAACFJREFUCNdjPMDBUc/AwNDAAAFMTAwMDA0OP34wQgX/AQBYgwYEx4f9lQAAAABJRU5ErkJggg==); + background-position: bottom left; + background-repeat: repeat-x; + } .lint-error {font-family: arial; font-size: 80%; background: #ccc; color: #b00; padding: 3px 5px} .lint-error-icon {background: #b00; color: #fff; font-weight: bold; border-radius: 50%; padding: 0 3px; margin-right: 5px} .CodeMirror-foldmarker {font-family: arial; line-height: .3; color: #b00; cursor: pointer; @@ -170,6 +176,7 @@ function createNewCMInstance(num) { electricChars: false, autoCloseTags: true, highlightSelectionMatches: true, + showTrailingSpace: true, keyMap: "ICEcoder", onKeyEvent: function(thisCM, e) { top.ICEcoder.redoChangedContent(e);