From 3a0cf976cc33ddc25fa4d8e74a2d6ea3585ac2e6 Mon Sep 17 00:00:00 2001
From: Kai Moritz
Date: Tue, 16 Sep 2014 13:14:54 +0200
Subject: [PATCH] =?utf8?q?Prettyprint-Style=20=C3=BCberarbeitet?=
MIME-Version: 1.0
Content-Type: text/plain; charset=utf8
Content-Transfer-Encoding: 8bit
---
src/main/webapp/less/base/prettify.less | 102 +++++--------------
src/main/webapp/less/print.less | 1 +
src/main/webapp/less/print/prettify.less | 11 ++
src/main/webapp/thymeleaf/projects/typo.html | 3 +-
4 files changed, 40 insertions(+), 77 deletions(-)
create mode 100644 src/main/webapp/less/print/prettify.less
diff --git a/src/main/webapp/less/base/prettify.less b/src/main/webapp/less/base/prettify.less
index 198f281a..b25145d4 100644
--- a/src/main/webapp/less/base/prettify.less
+++ b/src/main/webapp/less/base/prettify.less
@@ -1,87 +1,39 @@
/* Pretty printing styles. Used with prettify.js. */
+/* Vim sunburst theme by David Leibovic */
-/* SPAN elements with the classes below are added by prettyprint. */
-.pln { color: #000 } /* plain text */
+pre .str, code .str { color: #65B042; } /* string - green */
+pre .kwd, code .kwd { color: #E28964; } /* keyword - dark pink */
+pre .com, code .com { color: #AEAEAE; font-style: italic; } /* comment - gray */
+pre .typ, code .typ { color: #89bdff; } /* type - light blue */
+pre .lit, code .lit { color: #3387CC; } /* literal - blue */
+pre .pun, code .pun { color: #fff; } /* punctuation - white */
+pre .pln, code .pln { color: #fff; } /* plaintext - white */
+pre .tag, code .tag { color: #89bdff; } /* html/xml tag - light blue */
+pre .atn, code .atn { color: #bdb76b; } /* html/xml attribute name - khaki */
+pre .atv, code .atv { color: #65B042; } /* html/xml attribute value - green */
+pre .dec, code .dec { color: #3387CC; } /* decimal - blue */
-@media screen {
- .str { color: #080 } /* string content */
- .kwd { color: #008 } /* a keyword */
- .com { color: #800 } /* a comment */
- .typ { color: #606 } /* a type name */
- .lit { color: #066 } /* a literal value */
- /* punctuation, lisp open bracket, lisp close bracket */
- .pun, .opn, .clo { color: #660 }
- .tag { color: #008 } /* a markup tag name */
- .atn { color: #606 } /* a markup attribute name */
- .atv { color: #080 } /* a markup attribute value */
- .dec, .var { color: #606 } /* a declaration; a variable name */
- .fun { color: red } /* a function name */
+pre.prettyprint, code.prettyprint {
+ background-color: #000;
+ overflow-x: scroll;
}
-/* Use higher contrast and text-weight for printable form. */
-@media print, projection {
- .str { color: #060 }
- .kwd { color: #006; font-weight: bold }
- .com { color: #600; font-style: italic }
- .typ { color: #404; font-weight: bold }
- .lit { color: #044 }
- .pun, .opn, .clo { color: #440 }
- .tag { color: #006; font-weight: bold }
- .atn { color: #404 }
- .atv { color: #060 }
+pre.prettyprint {
+ width: 95%;
+ margin: 1em auto;
+ padding: 1em;
+ white-space: pre;
}
-/* Put a border around prettyprinted code snippets. */
-pre.prettyprint { padding: 2px; border: 1px solid #888 }
/* Specify class=linenums on a pre to get line numbering */
-ol.linenums { margin-top: 0; margin-bottom: 0 } /* IE indents via margin-left */
-li.L0,
-li.L1,
-li.L2,
-li.L3,
-li.L5,
-li.L6,
-li.L7,
-li.L8 { list-style-type: none }
-/* Alternate shading for lines */
-li.L1,
-li.L3,
-li.L5,
-li.L7,
-li.L9 { background: #eee }
+ol.linenums {
+ margin-top: 0;
+ margin-bottom: 0;
+ color: #AEAEAE;
+} /* IE indents via margin-left */
-/* Anpassungen an das Juplo-Branding */
-
-ol.linenums
-{
- margin: auto;
- padding: 0 0 0 3em;
-}
-li.L0,
-li.L1,
-li.L2,
-li.L3,
-li.L4,
-li.L5,
-li.L6,
-li.L7,
-li.L8,
-li.L9
-{
- padding: 0;
-}
-pre.prettyprint
-{
- border-color: @dunkel;
- overflow-x: scroll;
-}
-/* Alternate shading for lines */
-li.L1,
-li.L3,
-li.L5,
-li.L7,
-li.L9
+li.L0, li.L1, li.L2, li.L3, li.L4, li.L5, li.L6, li.L7, li.L8, li.L9
{
- background: @sehrhell
+ list-style-type: decimal;
}
diff --git a/src/main/webapp/less/print.less b/src/main/webapp/less/print.less
index 8322842a..8d87aa48 100644
--- a/src/main/webapp/less/print.less
+++ b/src/main/webapp/less/print.less
@@ -27,3 +27,4 @@
@import 'print/typo.less';
@import 'print/layout.less';
@import 'print/head.less';
+@import 'print/prettify.less';
diff --git a/src/main/webapp/less/print/prettify.less b/src/main/webapp/less/print/prettify.less
new file mode 100644
index 00000000..0ed8c472
--- /dev/null
+++ b/src/main/webapp/less/print/prettify.less
@@ -0,0 +1,11 @@
+/* Pretty printing styles. Used with prettify.js. */
+pre .str, code .str { color: #060; }
+pre .kwd, code .kwd { color: #006; font-weight: bold; }
+pre .com, code .com { color: #600; font-style: italic; }
+pre .typ, code .typ { color: #404; font-weight: bold; }
+pre .lit, code .lit { color: #044; }
+pre .pun, code .pun { color: #440; }
+pre .pln, code .pln { color: #000; }
+pre .tag, code .tag { color: #006; font-weight: bold; }
+pre .atn, code .atn { color: #404; }
+pre .atv, code .atv { color: #060; }
diff --git a/src/main/webapp/thymeleaf/projects/typo.html b/src/main/webapp/thymeleaf/projects/typo.html
index 5f74ae3f..77c14f07 100644
--- a/src/main/webapp/thymeleaf/projects/typo.html
+++ b/src/main/webapp/thymeleaf/projects/typo.html
@@ -100,8 +100,7 @@
google-code-prettify for automatic
syntax highlighting.
-
-<plugin>
+ <plugin>
<groupId>ro.isdc.wro4j</groupId>
<artifactId>wro4j-maven-plugin</artifactId>
<version>${wro4j.version}</version>
--
2.20.1