Subject: Re: GVim and UTF-8 Cyrillic
To: NetBSD Users <netbsd-users@netbsd.org>
From: Christian Biere <christianbiere@gmx.de>
List: netbsd-users
Date: 12/27/2006 16:43:06
Stefan 'Kaishakunin' Schumacher wrote:
> Also sprach Pavel Cahyna (pavel@netbsd.org)
> > On Wed, Dec 27, 2006 at 01:30:53PM +0100, Stefan 'Kaishakunin' Schumacher wrote:
> > > I'm writing some LaTeX documents whith mixed German and Russian,
> > > therefor I use UTF-8 encoding. 
> > > 
> > > Everything works fine, except the fact that Gvim isn't displaying the
> > > russian parts correct. All I see are strange characters instead of
> > > cyrillic. 
> > > 
> > > After googeling I only found hints to set the locale, but this seems
> > > to work on Linux only. So how can I configure Gvim to show the
> > > cyrillic characters?
> > 
> > What toolkit does you GVim use? It can be compiled to use Xaw or GTK2, at
> > least.
> 
> It's vim with GTK, (VIM - Vi IMproved 6.4 Normal version with GTK GUI)

The old Gtk+ 1.2 needs explicit configuration for UTF-8. Install 
fonts/efont-unicode from pkgsrc and put the following into your ~/.gtkrc:

style "user-font"
{
	fontset="-efont-*-medium-r-normal--12-*-*-*-*-*-iso10646-*"
}
widget_class "*" style "user-font"

And use an UTF-8 locale. Older NetBSD versions had only en_US.UTF-8. Run
locale -a to see which locales are available.

-- 
Christian