728x90
728x170
주피터 노트북을 다크모드로 변경하기
들어가며
- 아나콘다 프롬프트에 간단한 명령을 함으로써 주피터 노트북을 다크 모드(Dark Mode)로 변경할 수 있다.
방법
① 아나콘다 프롬프트(Anaconda Prompt) 실행

② 명령어 입력
- 다음의 명령을 입력하여 주피터 노트북의 테마가 담긴 패키지를 설치해준다.
> pip install jupyterthemes
Collecting jupyterthemes Downloading jupyterthemes-0.20.0-py2.py3-none-any.whl (7.0 MB) |████████████████████████████████| 7.0 MB 1.1 MB/s Collecting lesscpy>=0.11.2 Downloading lesscpy-0.15.0-py2.py3-none-any.whl (46 kB) |████████████████████████████████| 46 kB 1.2 MB/s ...
③ 주피터 노트북 테마 종류 확인
- jt -l 명령을 입력하면, 적용할 수 있는 주피터 노트북의 테마를 확인할 수 있다.
> jt -l
Available Themes: chesterish grade3 gruvboxd gruvboxl monokai oceans16 onedork solarizedd solarizedl
④ 다크 모드 테마 적용
- 다음과 같이 jt -t "테마명" 명령을 입력하여 다크 모드 테마를 주피터 노트북에 적용시켜준다.
> jt -t chesterish
⑤ 결과 확인
- 주피터 노트북에 다크 모드가 적용된 것을 확인할 수 있다.

참고
옵션 확인하기
- jt --help 명령을 입력하면 사용할 수 있는 옵션을 확인할 수 있다.
> jt --help
usage: jt [-h] [-l] [-t THEME] [-f MONOFONT] [-fs MONOSIZE] [-nf NBFONT] [-nfs NBFONTSIZE] [-tf TCFONT] [-tfs TCFONTSIZE] [-dfs DFFONTSIZE] [-ofs OUTFONTSIZE] [-mathfs MATHFONTSIZE] [-m MARGINS] [-cursw CURSORWIDTH] [-cursc CURSORCOLOR] [-cellw CELLWIDTH] [-lineh LINEHEIGHT] [-altp] [-altmd] [-altout] [-P] [-T] [-N] [-kl] [-vim] [-r] [-dfonts] 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 -dfs DFFONTSIZE, --dffontsize DFFONTSIZE pandas dataframe fontsize -ofs OUTFONTSIZE, --outfontsize OUTFONTSIZE output area fontsize -mathfs MATHFONTSIZE, --mathfontsize MATHFONTSIZE mathjax fontsize (in %) -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 or %) -lineh LINEHEIGHT, --lineheight LINEHEIGHT code/text line-height (%) -altp, --altprompt alt input prompt style -altmd, --altmarkdown alt markdown cell style -altout, --altoutput set output bg color to notebook bg -P, --hideprompt hide cell input prompt -T, --toolbar make toolbar visible -N, --nbname nb name/logo visible -kl, --kernellogo kernel logo visible -vim, --vimext toggle styles for vim -r, --reset reset to default theme -dfonts, --defaultfonts force fonts to browser default
기본(Default) 테마로 복원하기
> jt -r
728x90
그리드형(광고전용)
'Programming > Python' 카테고리의 다른 글
[Python] 파이썬에서 외부 모듈 등록 방법 (sys.path.append, PYTHONPATH) (0) | 2023.04.11 |
---|---|
[Python] 윈도우 프로그래밍(Window Programming) (0) | 2022.06.05 |
[Python] 파이썬을 이용하여 함수 그래프 그리기 (NumPy, matplotlib.pyplot) (0) | 2022.04.12 |
[Python] 튜플(Tuple) (0) | 2022.03.19 |
[Python] 문자열 (0) | 2022.03.19 |
[Python] 세트(Set) (0) | 2022.03.19 |
[Python] 딕셔너리(Dictionary) (0) | 2022.03.19 |
[Python] 리스트(List) (0) | 2022.03.19 |