Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Merge pull request #198 from zanata/fix-codemirror3-commits
Browse files Browse the repository at this point in the history
fix style for visible space and new line
  • Loading branch information
seanf committed Sep 24, 2013
2 parents 6f83d98 + 4760809 commit b7f74cf
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 218 deletions.
Expand Up @@ -60,7 +60,7 @@ private void highlight()
Element preElement = getElement().getFirstChildElement();
Highlighting.syntaxHighlight(Strings.nullToEmpty(plainText), preElement);
preElement.addClassName("cm-s-default");
String styled = preElement.getInnerHTML().replaceAll("<br>", "<span class='newline'></span><br>");
String styled = preElement.getInnerHTML().replaceAll("\\n", "<span class='newline'></span>\n");
preElement.setInnerHTML(styled);
}

Expand Down
Expand Up @@ -10,8 +10,8 @@
<link rel="stylesheet" href="images/fontello/css/fontello.css" />
<link rel="stylesheet" href="../stylesheet/menu.css" />

<script src="codemirror-compressed-old.js" type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="codemirror-old.css"/>
<script src="codemirror-compressed.js" type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="codemirror.css"/>

<script src="diff_match_patch/javascript/diff_match_patch.js" type="text/javascript"></script>

Expand Down

This file was deleted.

This file was deleted.

Expand Up @@ -259,3 +259,39 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #f22;}
visibility: hidden;
}
}

/* show visible tab */
.cm-tab:after {
content: "\21e5";
display: inline-block;
width: 1em;
position: relative;
overflow: visible;
color: #aaa;
}

/* visible space */
.cm-space
{
border-bottom: #dcecf7 solid 2px;
}

/* visible line break*/
.CodeMirror-code .CodeMirror-cursor:after
{
content: '';
}
.CodeMirror-code pre:after
{
content: '\00b6';
color: #aaaaaa;
}
.CodeMirror-code div:last-child pre:after {
content: '';
}

/* for highlighting label (runs code mirror runmode) */
.newline:after {
content: '\00b6';
color: #aaaaaa;
}

0 comments on commit b7f74cf

Please sign in to comment.