Skip to content

Latest commit

 

History

History
104 lines (60 loc) · 3.45 KB

README.ja.md

File metadata and controls

104 lines (60 loc) · 3.45 KB

Textbringer

LatestVer Gem Version ubuntu windows macos

TextbringerはRubyで実装されたEmacsライクなテキストエディタです。 Lispの代りにRubyで拡張することができます。

スクリーンショット

Screenshot

デモ

インストール

$ gem install textbringer

マルチバイト文字を使用するためにはncurseswが必要です。 Textbringerが依存するcurses.gemをインストールする前に、ncurseswをインストールしておいてください。

$ sudo apt-get install libncursesw5-dev
$ gem install curses

使い方

$ txtb

Ctrl-x Ctrl-c で終了できます。 

多くのコマンドとキーバインディングはEmacsに似ています。

キーバインディングを確認するには、 F1 b または Alt+x describe_bindings RET とタイプしてください。

設定

メタキー

端末エミュレータでメタキーを使用するためには、以下のような設定が必要です。

xterm

~/.Xresourcesに以下の行を追加してください。

XTerm*metaSendsEscape: true

mlterm

~/.mlterm/mainに以下の行を追加してください。

mod_meta_key = alt
mod_meta_mode = esc

東アジアの曖昧な文字幅

曖昧な文字を全角扱いするには、以下の設定を~/.textbringer.rbに記述してください。

CONFIG[:east_asian_ambiguous_width] = 2

ncurseswはwcwidth(3)を使用するため、LD_PRELOADハックやlocale charmapの修正が必要かもしれません。

xterm、 mlterm、screenにはそれぞれ独自の設定項目があります。

xterm

~/.Xresourcesに以下の設定を追加してください。

xterm*utf8: 1
xterm*locale: true
xterm*cjkWidth: true

mlterm

~/.mlterm/mainに以下の設定を追加してください。

col_size_of_width_a = 2

screen

~/.screenrcに以下の設定を追加してください。

cjkwidth on

プラグイン

ライセンス

MIT Licenseの下でオープンソースとして利用可能です。