Posts

File Encoding

file and character encoding/decoding in emacs How to open a file with specific coding system? Open it normally, then Alt + x revert-buffer-with-coding-system , then type a coding system. Press Tab to list possible ones.     Reference http://ergoemacs.org/emacs/emacs_encoding_decoding_faq.html

Display Chinese Characters in LaTex

document classes:   ctexart (article), ctexrep (report) and ctexbook (book) Example: \ documentclass { ctexart }   \setCJKmainfont { SimSun.ttf } \setCJKsansfont { SimHei.ttf } \setCJKmonofont { SimFang.ttf }   \begin { document }   \ tableofcontents   \begin { abstract } 这是在文件的开头的介绍文字.本文的主要话题的简短说明. \end { abstract }   \ section { 前言 } 在该第一部分中的一些额外的元素可以被添加。巴贝尔包将采取的翻译服务.   \ section { 关于数学部分 } 在本节中的一些数学会使用数学模型含中文字符显示。   這是一個傳統的中國文字   \end { document } Reference  https://www.sharelatex.com/learn/Chinese

Basics

Change Fonts Permanently On Windows Emacs 23 Use the menu: Options > Set Default Font … Options > Save Options This saves the font to .emacs. Optionally, you can add some code to init.el directly: (set-face-attribute 'default nil :font "Andale Mono-12") or this, which works quite well for Emacs on Windows: (set-face-attribute 'default nil :family "Consolas" :height 110)