With scripts for irssi it's possible to get most of the comforts of a GUI client, such as nick coloring (nickcolor.pl) and spell checking (spellcheck.pl).
I had some problems getting nordic characters to work, but the solution was to switch everything to utf-8:
- The terminal
- In gnome terminal menu, Terminal->Set character encoding->UTF-8
- The remote environment
- Add
export LANG en_GB.UTF-8to the end of ~/.bashrc - The screen session when starting irssi
screen -SU irc irssi(creates a screen instance named 'irc' using UTF-8 that runs irssi)- In irssi
/set term_type utf-8
The spellcheck.pl script didn't work with UTF-8 out of the box either, aspell needs the --encoding=UTF-8 parameter passed to it to work with non-english characters.
To install spellcheck.pl for irssi with utf support:
- Log in to the machine you run irssi on
- Install aspell:
- sudo apt-get install aspell libtext-aspell-perl aspell-en aspell-de aspell-fi # and so on for the languages that you want spell check dictionaries installed for
- cd ~/.irssi/scripts # if the scripts directory doesn't exists, create it
- wget http://scripts.irssi.org/scripts/spellcheck.pl #downloads the original spellcheck.pl
- Edit spellcheck.pl and find the line
$speller{$_[0]}->set_option('sug-mode', 'fast') or return undef;
- Add a new line after it and save:
$speller{$_[0]}->set_option('encoding', 'utf-8') or return undef;
- In irssi, write /script load spellcheck.pl
- You can specify what language spellchecking should be used in different channels by typing /set spellcheck_languages NetworkName/#channelName/TwoLetterLanguageCode in irssi. Default seems to be english.
Aspeller seems to be a bit more user friendly spellchecker, as it doesn't spam the window with spelling suggestions, just highlights the misspelled words. Unfortunately it doesn't allow specifying channel specific languages. There's also spell.pl.
0 comments :: Configuring irssi with UTF-8 and spell checking
Post a Comment