Re: some problems with do_*_ca_mode()



Hello, Bart!
You wrote to <mc-devel gnome org> on Fri, 25 Nov 2005 11:56:48 +1300 (NZDT):

BO>>> main() -> init_curses() -> [ SLsmg_init_smg() -> tt_init_video() (set
BO>>> to SLtt_init_video()) -> tt_write_string (Term_Init_Str); ]

BO> endwin() does that already as far as I can see.

BO> ncurses also automatically sends
BO> the relevant string automatically, in _nc_mvcur_init() (called via
BO> newterm() from initscr(), in the ncurses source code).

Yes, it does.
I can only add that ncurse's endwin() calls _nc_mvcur_wrap() with 
putp(exit_ca_mode) inside. So we do not need to manually operate with 
*_ca_mode capabilities neither under slang no under ncurses...

BO> I wonder what the purpose is of do_enter_ca_mode now. Maybe it is just
BO> a left-over, necessary for other (non-ncurses) curses libraries, or
BO> xterms with broken terminfo's.

Well, let's try to investigate it :)
As far as we can see in changelogs, it is old entry (since 1994).

Sat Dec 17 16:06:51 1994  Miguel de Icaza  <miguel sphinx>
        * terms.c: do_enter_ca_mode now enters putp's the enter_ca_mode to
        the screen.  Moved from main to avoid name space pollution, this
        should make the A/UX port work.

Wed Feb 15 00:46:33 1995  Dugan O. Porter  (dugan b011 eunet es)
        * terms.c (do_exit_ca_mode): New function; the counterpart of
        do_enter_ca_mode().  Called in main.c.
        * main.c (view_other_cmd): Now calls do_exit_ca_mode(), and it
        isn't disabled any more just because OTHER_CURSES is defined.

2001-09-15  Pavel Roskin  <proski gnu org>
        * ... Call do_exit_ca_mode() and do_enter_ca_mode() even with
        ncurses.

Pavel, do you remember - what for?

-- 
With best regards, Andrey V. Malyshev.
E-mail: amal krasn ru 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]