tech-userlevel archive

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

Re: terminfo implementation

In article <>,
Roy Marples  <> wrote:
>Here's a new snapshot.
>It should now implement all documented ncurses terminfo capabilities.
>The tic(1) implementation is a lot faster than before and is 3 times 
>quicker than ncurses tic :)
>Both tic(1) and infocmp(1) now sport the -x flag to control acceptance 
>of non standard capabilities. If you have tried a previous snapshot, 
>you'll need to rebuild your databases.
>In addition to the standard cap_long_name macros to access a cap quickly 
>on cur_term, we have t_cap_long_name macros to access a cap quickly on 
>any TERMINAL struct which would make any merge with our curses library a 
>little less painless.
>It also has a termcap compatibility layer and is source and binary 
>compatible with our current libtermcap provided that NO NetBSD 
>extensions have been used. Only ul(1) and curses(3) use this in the tree 
>according to my grep search. Whilst curses(3) does have an excuse to use 
>them (see prior discussions for why) ul(1) does not so I'm pretty sure 
>we can just drop them.
>On the whole, most people are generally positive about this.
>I've taken on board some comments by Joerg and changed some code 
>accordingly, but more eyes would be better.

        - there are more baud rates defined on NetBSD.
        - the arrays of constants should be sorted so the index functions
          can use binary search instead of of linear.
        - use errx(3) in the exit case so that the program name gets printed.
        - what frees tp->_extras?
        - sort arrays and use binary search.
        - to support multiple terminals outc should be passed a second
          void * argument that can be used from the application to determine
          the terminal context. ie. the signature for ti_puts should be
          int ti_puts(const TERMINAL *term, const char *str, int affcnt, 
              int (*outc)(int, void *), void *arg)


Home | Main Index | Thread Index | Old Index