bug-ncurses
[Top][All Lists]
Advanced

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

Re: Is there an API call as substitute to ESCDELAY environment variable


From: Marc Rechté
Subject: Re: Is there an API call as substitute to ESCDELAY environment variable ?
Date: Mon, 2 Mar 2020 14:40:11 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0



Le 02/03/2020 à 14:29, Pavel Stehule a écrit :


po 2. 3. 2020 v 13:34 odesílatel Marc Rechté <address@hidden <mailto:address@hidden>> napsal:



    Le 02/03/2020 à 12:54, Pavel Stehule a écrit :
     >
     >
     > po 2. 3. 2020 v 12:19 odesílatel Marc Rechté <address@hidden
    <mailto:address@hidden>
     > <mailto:address@hidden <mailto:address@hidden>>> napsal:
     >
     >     Hi,
     >
     >     I don't know where to post that question.
     >
     >     I need a non blocking version of getch, so I set
    nodelay(stdscr, TRUE)
     >
     >     However the standard delay for distinguishing "esc" key from
     >     "functions"
     >     keys pressed is too high IMO.
     >
     >     According to man page, timeout() is not the function to use
    for that
     >     purpose.
     >
     >     Is there an alternative to setting ESCDELAY environment
    variable before
     >     launching the program ?
     >
     >
     > for some not too old ncurses
     >
     > #ifdef NCURSES_EXT_FUNCS
     >
     >      set_escdelay(25);
     >
     > #endif
     >
     >
     >     Thanks
     >
    OK, why is man page (Routine Name Index) not showing this function ?


NAME
        curs_threads - curses thread support

SYNOPSIS
        #include <curses.h>

        typedef int (*NCURSES_WINDOW_CB)(WINDOW *, void *);
        typedef int (*NCURSES_SCREEN_CB)(SCREEN *, void *);
        int get_escdelay(void);
        int set_escdelay(int size);
        int set_tabsize(int size);
        int use_screen(SCREEN *scr, NCURSES_SCREEN_CB func, void *data);
        int use_window(WINDOW *win, NCURSES_WINDOW_CB func, void *data);

I see it. Probably it depends on age of your ncurses's library

Pavel

Thanks.

It is well documented in curs_threads.

The problem is that "man ncurses" does not list functions in curs_threads.

Check it out, I have the latest ncurses version.

So that's a documentation bug in /usr/share/man/man3/ncurses.3x.gz



reply via email to

[Prev in Thread] Current Thread [Next in Thread]