57
50

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Jupyter のテーマを変える

Posted at

Jupyter便利ですね。
Jupyter Notebookを自分仕様に:背景,アイコンの変更を見て、確かに背景の色とか変えたいなと思いました。でもCSSを自分でいじったりするのは面倒なので、お手軽にできる方法はないかと探してみました。

jupyter-themesを使えば簡単にできそうです。

インストール

% pip install jupyterthemes

使い方

% jt -h
usage: jt [-h] [-l] [-t THEME] [-f MONOFONT] [-fs MONOSIZE] [-nf NBFONT]
          [-nfs NBFONTSIZE] [-tf TCFONT] [-tfs TCFONTSIZE] [-m MARGINS]
          [-cursw CURSORWIDTH] [-cursc CURSORCOLOR] [-cellw CELLWIDTH]
          [-lineh LINEHEIGHT] [-alt] [-vim] [-T] [-N] [-r]

optional arguments:
  -h, --help            show this help message and exit
  -l, --list            list available themes
  -t THEME, --theme THEME
                        theme name to install
  -f MONOFONT, --monofont MONOFONT
                        monospace code font
  -fs MONOSIZE, --monosize MONOSIZE
                        code font-size
  -nf NBFONT, --nbfont NBFONT
                        notebook font
  -nfs NBFONTSIZE, --nbfontsize NBFONTSIZE
                        notebook fontsize
  -tf TCFONT, --tcfont TCFONT
                        txtcell font
  -tfs TCFONTSIZE, --tcfontsize TCFONTSIZE
                        txtcell fontsize
  -m MARGINS, --margins MARGINS
                        fix margins of main intro page
  -cursw CURSORWIDTH, --cursorwidth CURSORWIDTH
                        set cursorwidth (px)
  -cursc CURSORCOLOR, --cursorcolor CURSORCOLOR
                        cursor color (r, b, g, p)
  -cellw CELLWIDTH, --cellwidth CELLWIDTH
                        set cell width (px)
  -lineh LINEHEIGHT, --lineheight LINEHEIGHT
                        code/text line-height (%)
  -alt, --altlayout     alt markdown layout
  -vim, --vimext        toggle styles for vim
  -T, --toolbar         make toolbar visible
  -N, --nbname          nb name/logo visible
  -r, --reset           reset to default theme

利用可能なテーマ

% jt -l
Available Themes: 
   chesterish
   grade3
   oceans16
   onedork

テーマをインストール

% jt -t onedork
You are using Python 3.5
only versions 2.7, 3.3, 3.4 support custom settings
Installing onedork theme with default settings

Python 3.5だと使えない機能があるみたいですが、とりあえず色が変わったので、しばらくこれで使ってみようと思います。

2016-09-20_10-52-25.png

57
50
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
57
50

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?