DokuWikiで情報発信

個人での情報発信や社内での情報共有に便利なDokuWikiを紹介するサイトです。

ユーザ用ツール

サイト用ツール


サイドバー

目次

DokuWikiを理解

DokuWikiの構築

よく確認するページ

· 最終更新: 2020/08/29 by oreda admin



「プラグイン」に戻る
DokuWikiおすすめプラグイン一覧。まとめ

Dokuwikiプラグイン : Code Prettifier Pluginでcodeのデザインを変更

概要

<code></code>で囲んだ時のデザインを変更できます。


設定


デザイン

(略)/dokuwiki/lib/plugins/codeprettify/code-prettify/styles/****.css

選択できるCSS

  • desert.css
  • doxy.css
  • sons-of-obsidian.css
  • sunburst.css

https://cdn.rawgit.com/google/code-prettify/master/styles/index.html

標準

sunburst.css

sons-of-obsidian.css

desert.css

doxy.css

sunburst.cssを元に修正してみた

/* Pretty printing styles. Used with prettify.js. */
/* Vim sunburst theme by David Leibovic */

pre .str, code .str { color: #65B042; } /* string  - green */
pre .kwd, code .kwd { color: #E28964; } /* keyword - dark pink */
pre .com, code .com { color: #AEAEAE; } /* comment - gray */
pre .typ, code .typ { color: #89bdff; } /* type - light blue */
pre .lit, code .lit { color: #66ccff; } /* literal - blue */
pre .pun, code .pun { color: #f5f5f5; } /* punctuation - white */
pre .pln, code .pln { color: #d3d3d3; } /* 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 */

pre.prettyprint, code.prettyprint {
        background-color: #333333;
        border-radius: 0px;
}

pre.prettyprint {
        //width: 98%;
        margin: 1em auto;
        padding: 1em;
        white-space: pre;
        line-height: 18px;
}


/* Specify class=linenums on a pre to get line numbering */
ol.linenums { margin-top: 0; margin-bottom: 0; color: #AEAEAE; } /* 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 { }

@media print {
  pre .str, code .str { color: #060; }
  pre .kwd, code .kwd { color: #006; font-weight: bold; }
  pre .com, code .com { color: #600; }
  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; }
}





「プラグイン」に戻る




· 最終更新: 2020/08/29 by oreda admin

ページ用ツール