Added style for code highlighting

This commit is contained in:
2019-02-14 20:26:52 +01:00
parent cf6dc48b23
commit 5e553ebea1

View File

@@ -167,6 +167,95 @@ header h1 a span.first {color: black;}
border-right: 1px solid #555555;
}
/* pre/code highlighted theme - taken from wombat256grf vim colorscheme */
.highlight { background-color: #242424; }
.highlight .c { color: #99968b; font-style: italic} /* Comment */
.highlight .err { color: #dddddd} /* Error */
.highlight .g { color: #dddddd } /* Generic */
.highlight .k { color: #87afff } /* Keyword */
.highlight .l { color: #dddddd } /* Literal */
.highlight .n { color: #dddddd } /* Name */
.highlight .o { color: #dddddd } /* Operator */
.highlight .x { color: #dddddd } /* Other */
.highlight .p { color: #dddddd } /* Punctuation */
.highlight .cm { color: #99968b; font-style: italic} /* Comment.Multiline */
.highlight .cp { color: #e5786d } /* Comment.Preproc */
.highlight .c1 { color: #99968b; font-style: italic} /* Comment.Single */
.highlight .cs { color: #99968b; font-style: italic} /* Comment.Special */
.highlight .gd { color: #dddddd } /* Generic.Deleted */
.highlight .ge { color: #dddddd } /* Generic.Emph */
.highlight .gr { color: #dddddd } /* Generic.Error */
.highlight .gh { color: #f6f3e8; font-weight: bold} /* Generic.Heading */
.highlight .gi { color: #dddddd } /* Generic.Inserted */
.highlight .go { color: #888888 } /* Generic.Output */
.highlight .gp { color: #dddddd } /* Generic.Prompt */
.highlight .gs { color: #dddddd } /* Generic.Strong */
.highlight .gu { color: #f6f3e8; font-weight: bold} /* Generic.Subheading */
.highlight .gt { color: #dddddd } /* Generic.Traceback */
.highlight .kc { color: #87afff } /* Keyword.Constant */
.highlight .kd { color: #87afff } /* Keyword.Declaration */
.highlight .kn { color: #87afff } /* Keyword.Namespace */
.highlight .kp { color: #87afff } /* Keyword.Pseudo */
.highlight .kr { color: #87afff } /* Keyword.Reserved */
.highlight .kt { color: #caeb82 } /* Keyword.Type */
.highlight .ld { color: #dddddd } /* Literal.Date */
.highlight .m { color: #e5786d } /* Literal.Number */
.highlight .s { color: #95e454; font-style: italic} /* Literal.String */
.highlight .na { color: #caeb82 } /* Name.Attribute */
.highlight .nb { color: #dddddd } /* Name.Builtin */
.highlight .nc { color: #dddddd } /* Name.Class */
.highlight .no { color: #e5786d } /* Name.Constant */
.highlight .nd { color: #dddddd } /* Name.Decorator */
.highlight .ni { color: #ffdead } /* Name.Entity */
.highlight .ne { color: #dddddd } /* Name.Exception */
.highlight .nf { color: #caeb82 } /* Name.Function */
.highlight .nl { color: #dddddd } /* Name.Label */
.highlight .nn { color: #dddddd } /* Name.Namespace */
.highlight .nx { color: #dddddd } /* Name.Other */
.highlight .py { color: #dddddd } /* Name.Property */
.highlight .nt { color: #87afff } /* Name.Tag */
.highlight .nv { color: #caeb82 } /* Name.Variable */
.highlight .ow { color: #dddddd } /* Operator.Word */
.highlight .w { color: #dddddd } /* Text.Whitespace */
.highlight .mf { color: #e5786d } /* Literal.Number.Float */
.highlight .mh { color: #e5786d } /* Literal.Number.Hex */
.highlight .mi { color: #e5786d } /* Literal.Number.Integer */
.highlight .mo { color: #e5786d } /* Literal.Number.Oct */
.highlight .sb { color: #95e454; font-style: italic } /* Literal.String.Backtick */
.highlight .sc { color: #95e454; font-style: italic } /* Literal.String.Char */
.highlight .sd { color: #95e454; font-style: italic } /* Literal.String.Doc */
.highlight .s2 { color: #95e454; font-style: italic } /* Literal.String.Double */
.highlight .se { color: #95e454; font-style: italic } /* Literal.String.Escape */
.highlight .sh { color: #95e454; font-style: italic } /* Literal.String.Heredoc */
.highlight .si { color: #95e454; font-style: italic } /* Literal.String.Interpol */
.highlight .sx { color: #95e454; font-style: italic } /* Literal.String.Other */
.highlight .sr { color: #95e454; font-style: italic } /* Literal.String.Regex */
.highlight .s1 { color: #95e454; font-style: italic } /* Literal.String.Single */
.highlight .ss { color: #95e454; font-style: italic } /* Literal.String.Symbol */
.highlight .bp { color: #dddddd } /* Name.Builtin.Pseudo */
.highlight .vc { color: #caeb82 } /* Name.Variable.Class */
.highlight .vg { color: #caeb82 } /* Name.Variable.Global */
.highlight .vi { color: #caeb82 } /* Name.Variable.Instance */
.highlight .il { color: #e5786d } /* Literal.Number.Integer.Long */
.gutter{
background-color: black;
color: #857b6f;
}
.post > .highlight .lineno {
display:inline-block;
padding: 0 5px;
border-right:1px solid #ccc;
}
.post > .highlight pre code {
display: block;
white-space: pre;
overflow-x: auto;
word-wrap: normal;
}
/* main content */
article {
padding: 1em;
@@ -333,6 +422,11 @@ article {
nav.menu li#themes {background-image: url(/img/prefs_themes.png);}
nav.menu li#links {background-image: url(/img/prefs_links.png);}
.highlight {
padding: 0;
margin: 0;
}
}
/* very small - usually mobile phone screens */