Re: ncurses getch & unicode (was: decoding keyboard input when using curses)

2009-08-21 Thread Thomas Dickey
On Fri, 21 Aug 2009, Iñigo Serna wrote: 2009/8/21 Thomas Dickey : On Aug 20, 6:12 pm, Iñigo Serna wrote:     c = win.getch() You're using "getch", not "get_wch" (Python's ncurses binding may/may not have the latter). curses getch returns 8-bit values, get

Re: ncurses getch & unicode (was: decoding keyboard input when using curses)

2009-08-21 Thread Thomas Dickey
On Aug 20, 6:12 pm, Iñigo Serna wrote: > Hi again, > > 2009/8/20 Iñigo Serna > > I have the same problem mentioned > > inhttp://groups.google.com/group/comp.lang.python/browse_thread/thread/...some > > months ago. > > > Python 2.6 program which usesncursesmodule in a terminal configured to use

Re: web page text extractor

2007-07-22 Thread Thomas Dickey
Miki <[EMAIL PROTECTED]> wrote: > (You can find lynx at http://lynx.browser.org/) not exactly - The current version of lynx is 2.8.6 It's available at http://lynx.isc.org/lynx2.8.6/ 2.8.7 Development & patches: http://lynx.isc.org/current/index.html -- Thomas E. Dickey http://i

Re: Curses and resizing windows

2007-02-28 Thread Thomas Dickey
Nick ! <[EMAIL PROTECTED]> wrote: > http://web.cs.mun.ca/~rod/ncurses/ncurses.html#xterm says "The ncurses > library does not catch [the SIGWINCH aka resizing] signal, because it > cannot in general know how you want the screen re-painted". First, is > this really true? When I make my xterms small

Re: python+ncurses: I can't display accents

2007-01-27 Thread Thomas Dickey
Fabrice DELENTE <[EMAIL PROTECTED]> wrote: > My system is Linux, and the distribution is Slackware 10.1. > I have > /lib/libncurses.so.5.4 > /lib/libncursesw.so.5.4 > so I even have the wide-chars version available. Any hint on the python > configuration? I didn't find any function that would al

Re: python+ncurses: I can't display accents

2007-01-26 Thread Thomas Dickey
Neil Cerutti <[EMAIL PROTECTED]> wrote: > I don't really expect it to work, but if anything will, that is > it. Curses supports only ASCII and a some special symbol codes > defined by curses. un - no. Curses supports whatever the flavor of curses you have does. Often that's the 8-bit flavor of n

Re: curses problem reading cursor keys

2006-10-11 Thread Thomas Dickey
Simon Morgan <[EMAIL PROTECTED]> wrote: > I'd also appreciate any pointers to good tutorials on curses, I've read > the one by awk and esr but found it rather brief and lacking in detail. esr only contributed his name - awk wrote the rest. (When I asked why, he only said it sounded like a good id

Re: need all python dialog equivalent

2006-06-22 Thread Thomas Dickey
Eric S. Johansson <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: >> dialog binary is 110 KB. Won't it fit ? > missing library. I have ncurses and newt and dialog seems to require > something called ncursesw. I've been trying to find the Python newt "seems to require" if you're install

Re: Need pixie dust for building Python 2.4 curses module on Solaris 8

2006-06-07 Thread Thomas Dickey
[EMAIL PROTECTED] wrote: > I'm having no success building the curses module on Solaris 8 (yes, I know > it's ancient - advancing the state-of-the-art is not yet an option) for > Python 2.4. Sun provides an apparently ancient version of curses in > /usr/lib, so I downloaded and installed ncurses 5

Re: ANN: Urwid 0.9.0 - Console UI library

2006-02-23 Thread Thomas Dickey
Ian Ward <[EMAIL PROTECTED]> wrote: > - New raw_display module that handles console display without relying > on external libraries. This module was written as a work around > for the lack of UTF-8 support in the standard version of ncurses. The "standard version" of ncurses has support

Re: Replacing curses

2006-02-09 Thread Thomas Dickey
Ian Ward <[EMAIL PROTECTED]> wrote: > I'm going to look at the Mined text editor for some terminal behavior mined_2000 (there's more than one program named mined, and the other doesn't do UTF-8). > detection code. Mined is able to produce good UTF-8 output on a variety > of terminals, and it li

Re: Replacing curses

2006-02-08 Thread Thomas Dickey
Ian Ward <[EMAIL PROTECTED]> wrote: > Thomas Dickey wrote: >> hmm - I've read Urwid, and most of the comments I've read in that regard >> reflect problems in Urwid. Perhaps it's time for you to do a little >> analysis. >> >> (looking for

Re: Replacing curses

2006-02-08 Thread Thomas Dickey
Ian Ward <[EMAIL PROTECTED]> wrote: > Grant Edwards wrote: >> Depending on what you're tring to do, slang might be an option, > I've looked at newt and snack, but all I really need is: > - a way to position the cursor at (0,0) > - a way to hide and show the cursor > - a way to detect when the term

Re: Replacing curses

2006-02-08 Thread Thomas Dickey
Grant Edwards <[EMAIL PROTECTED]> wrote: > Depending on what you're tring to do, slang might be an option, perhaps not - he's trying to use UTF-8. I haven't seen any plausible comment that indicates John Davis is interested in updating newt to work with slang2 (though of course he's welcome to s

Re: Problem with curses and UTF-8

2006-02-08 Thread Thomas Dickey
Ian Ward <[EMAIL PROTECTED]> wrote: > Martin v. Löwis wrote: >> If that was Python's configure: don't do that. Instead, hack setup.py >> to make it change the compiler/linker settings, or even edit the >> compiler/linker line manually at first. > Ok, that compiled. same here - though it was not

Re: Problem with curses and UTF-8

2006-02-08 Thread Thomas Dickey
"Martin v. Löwis" <[EMAIL PROTECTED]> wrote: >> I'll test it if someone would dumb down "link with ncursesw instead of >> ncurses" a little for me. >> >> I tried: >> ./configure --with-libs="ncursesw5" >> >> and it failed saying: >> checking size of wchar_t... configure: error: cannot compute siz

Re: Replacing curses

2006-02-08 Thread Thomas Dickey
Ian Ward <[EMAIL PROTECTED]> wrote: > I've had to work around many curses issues while developing Urwid (a hmm - I've read Urwid, and most of the comments I've read in that regard reflect problems in Urwid. Perhaps it's time for you to do a little analysis. (looking forward to bug reports, rat

Re: Problem with curses and UTF-8

2006-02-08 Thread Thomas Dickey
"Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > Ian Ward wrote: >> Any Ideas? > I think there is one or more ncurses bugs somewhere. indeed. It might be nice to report them rather than jawing about it. > The ncurses documentation suggests that you should link with > ncurses_w instead of linking

Re: Is the Python binding for ncurses unicode capable?

2006-01-20 Thread Thomas Dickey
"Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > Thomas Dickey wrote: >>>ncurses expects byte strings (although I'm uncertain as to what >>>impact multi-byte encodings have in ncurses). >> >> >> It depends on whether python's curses

Re: Is the Python binding for ncurses unicode capable?

2006-01-19 Thread Thomas Dickey
"Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > ncurses expects byte strings (although I'm uncertain as to what > impact multi-byte encodings have in ncurses). It depends on whether python's curses binding is linked with the wide-character flavor (ncursesw) or the normal one. If it's linked with

Re: Python and curses

2005-12-16 Thread Thomas Dickey
linuxfreak <[EMAIL PROTECTED]> wrote: > Was wanting to write a text based application in python seems > curses module is the way to go... anyone knows of any good tutorials > apart from the one written by esr It wasn't written by esr. He only has his name on it, did none of the work. -- Tho

Re: Converting HTML to ASCII

2005-02-27 Thread Thomas Dickey
Grant Edwards <[EMAIL PROTECTED]> wrote: > First, make it work. Then make it work right. Then worry > about how fast it is. > "Premature optimization..." That could be - but then again, most of the comments I've seen for that particular issue are for rather old releases. >> It seems to use a