Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] sup and ncursesw
@ 2009-06-10 17:50 Jörg-Hendrik Bach
  2009-06-12 20:03 ` William Morgan
  0 siblings, 1 reply; 6+ messages in thread
From: Jörg-Hendrik Bach @ 2009-06-10 17:50 UTC (permalink / raw)


Hi all,

I recently installed sup 0.8 and find I am having problems with umlauts and
accented characters. There is a patch for the ncurses-0.9.1 gem on the sup
wiki ("utf8-issues") which allows the characters to be displayed correctly,
but after applying the patch I can't enter proper text. Hitting 'c' for
compose works, but entering '123' for subject ends in a subject line such
as:

Subject: P<85>??P<85>???C"      ?C"

(it's a different set of confused characters each time)
Similar when searching for messages using '\' or 'L'.

I am on ubuntu 9.04 with libncursesw5{,-dev} version 5.7+20090207, sup 0.8.
Any hints?

cheers,
- J?rg-Hendrik
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090610/aa0a2b51/attachment.html>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [sup-talk] sup and ncursesw
  2009-06-10 17:50 [sup-talk] sup and ncursesw Jörg-Hendrik Bach
@ 2009-06-12 20:03 ` William Morgan
  2009-06-13 14:17   ` Jörg-Hendrik Bach
  0 siblings, 1 reply; 6+ messages in thread
From: William Morgan @ 2009-06-12 20:03 UTC (permalink / raw)


Hi J?rg-Hendrik,

Reformatted excerpts from J?rg-Hendrik Bach's message of 2009-06-10:
> I recently installed sup 0.8 and find I am having problems with
> umlauts and accented characters. There is a patch for the
> ncurses-0.9.1 gem on the sup wiki ("utf8-issues") which allows the
> characters to be displayed correctly, but after applying the patch I
> can't enter proper text.

What is your environment's character set? (Should be the first line of
output logged by Sup.) What is your terminal emulator? Do other widechar
ncurses programs work? And what's the behavior without the patch to
ncurses.so?
-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [sup-talk] sup and ncursesw
  2009-06-12 20:03 ` William Morgan
@ 2009-06-13 14:17   ` Jörg-Hendrik Bach
  2009-06-15 14:04     ` William Morgan
  0 siblings, 1 reply; 6+ messages in thread
From: Jörg-Hendrik Bach @ 2009-06-13 14:17 UTC (permalink / raw)


2009/6/12 William Morgan <wmorgan-sup at masanjin.net>

>
> What is your environment's character set? (Should be the first line of
> output logged by Sup.) What is your terminal emulator? And what's the
> behavior without the patch to ncurses.so?


After playing around a bit i think the behaviour might be related to a
problem with locale.
I reinstalled ruby, rubygems, ncurses and sup. No patch to ncurses this
time. Using gnome-terminal or xterm with "TERM=xterm" now lets umlauts etc
look like, e.g. "JM-CM-6rg-Hendrik"). The reported character set is "utf8".
The same happens when using urxvt with TERM=rxvt-unicode.

However, calling sup like this:
$ LC_ALL=en_GB.iso-8859-15 sup

results in different behaviour in the two emulators: xterm looks OK when
viewing the inbox, but inserts boxed question marks in thread-view.
rxvt-unicode displays everything correctly, but drops the last character of
a line when a non-ASCII element is somewhere in the line. In both variants
sup reports the character set correctly as iso-8859-15.
So I guess I could simply work in urxvt and that's OK, then.

Do other widechar ncurses programs work?


The only other ncurses-based program I am aware of using is midnight
commander, and it seems to be working fine. But I don't know whether it uses
the widechar variant.

cheers,
- J?rg-Hendrik
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090613/c8c73902/attachment.html>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [sup-talk] sup and ncursesw
  2009-06-13 14:17   ` Jörg-Hendrik Bach
@ 2009-06-15 14:04     ` William Morgan
  2009-06-17 16:14       ` William Morgan
  0 siblings, 1 reply; 6+ messages in thread
From: William Morgan @ 2009-06-15 14:04 UTC (permalink / raw)


Reformatted excerpts from J?rg-Hendrik Bach's message of 2009-06-13:
> After playing around a bit i think the behaviour might be related to a
> problem with locale.

Yeah, this stuff is all tricky to get working right. I recommend first
trying to get to the point where you can cat and less files with funny
characters in them, and then introduce something like Sup. (And that's
typically the point where you see the difference between ncurses.so with
and without the patch.)

> Using gnome-terminal or xterm with "TERM=xterm" now lets umlauts etc
> look like, e.g. "JM-CM-6rg-Hendrik"). The reported character set is
> "utf8".

Probably the umlauts themselves aren't in utf8. I have had success with
gnome-terminal and TERM=xterm, so I bet you can get this combo to work.
Try changing your locale from utf8 to en_GB.iso-8859-15 here (if you're
using Ubuntu, you can edit /etc/default/locale an re-log in, then
`locale` to check.)
-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [sup-talk] sup and ncursesw
  2009-06-15 14:04     ` William Morgan
@ 2009-06-17 16:14       ` William Morgan
  2009-06-18  9:26         ` Jörg-Hendrik Bach
  0 siblings, 1 reply; 6+ messages in thread
From: William Morgan @ 2009-06-17 16:14 UTC (permalink / raw)


Reformatted excerpts from William Morgan's message of 2009-06-15:
> (And that's typically the point where you see the difference between
> ncurses.so with and without the patch.)

BTW, it looks like the patch will not be necessary if we manage to move
to 1.9.1:

  http://redmine.ruby-lang.org/issues/show/975
-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [sup-talk] sup and ncursesw
  2009-06-17 16:14       ` William Morgan
@ 2009-06-18  9:26         ` Jörg-Hendrik Bach
  0 siblings, 0 replies; 6+ messages in thread
From: Jörg-Hendrik Bach @ 2009-06-18  9:26 UTC (permalink / raw)


2009/6/17 William Morgan <wmorgan-sup at masanjin.net>:
> Reformatted excerpts from William Morgan's message of 2009-06-15:
>> (And that's typically the point where you see the difference between
>> ncurses.so with and without the patch.)
>
> BTW, it looks like the patch will not be necessary if we manage to move
> to 1.9.1:

The patch actually works for me now, and probably had been working all
the time. Whatever was screwed, after I manually redrew the screen
_twice_ after the strange chars appeared, it was all fine.
thanks for the help,
- JH


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2009-06-18  9:26 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-10 17:50 [sup-talk] sup and ncursesw Jörg-Hendrik Bach
2009-06-12 20:03 ` William Morgan
2009-06-13 14:17   ` Jörg-Hendrik Bach
2009-06-15 14:04     ` William Morgan
2009-06-17 16:14       ` William Morgan
2009-06-18  9:26         ` Jörg-Hendrik Bach

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox