[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Using ncurses only for terminfo (no I/O)
From: |
Thomas Dickey |
Subject: |
Re: Using ncurses only for terminfo (no I/O) |
Date: |
Sat, 16 Jan 2021 11:39:31 -0500 |
User-agent: |
Mutt/1.10.1 (2018-07-13) |
On Sat, Jan 16, 2021 at 02:16:51AM -0000, Grant Edwards wrote:
> On 2021-01-16, Thomas Dickey <dickey@his.com> wrote:
> > On Fri, Jan 15, 2021 at 11:22:33PM -0000, Grant Edwards wrote:
> >> I've recently been working with ncurses from Python, and would like to
> >> use ncurses only for terminfo purposes. I can call tigetstr() and then
> >> tparm() if needed, and write the result using Python's normal output
> >> stream. Everything works as expected using urxvt, but what sort of
> >> failure modes I should be expecting because I'm not using tputs() or
> >> putp() as specified in the man page?
> >
> > man ncurses:
> >
> > NCURSES_NO_PADDING
> > Most of the terminal descriptions in the terminfo database are
> > written
> > for real "hardware" terminals.
>
> Thanks!
>
> So i infer that the lack of inserted padding is the only problem with
> "skipping" tputs/putp and writing to the file descriptor?
If the capability has padding, it's tputs that does the trimming.
(writing directly to the file descriptor runs the risk of leaving the
markers in the output--not something you'd find usable).
--
Thomas E. Dickey <dickey@invisible-island.net>
https://invisible-island.net
ftp://ftp.invisible-island.net
signature.asc
Description: PGP signature
- Using ncurses only for terminfo (no I/O), Grant Edwards, 2021/01/15
- Re: Using ncurses only for terminfo (no I/O), Thomas Dickey, 2021/01/15
- Re: Using ncurses only for terminfo (no I/O), Timothy Allen, 2021/01/15
- Re: Using ncurses only for terminfo (no I/O), Nicholas Marriott, 2021/01/18
- Re: Using ncurses only for terminfo (no I/O), Grant Edwards, 2021/01/18
- Re: Using ncurses only for terminfo (no I/O), Thomas Dickey, 2021/01/18
- Re: Using ncurses only for terminfo (no I/O), Nicholas Marriott, 2021/01/19
- Re: Using ncurses only for terminfo (no I/O), Nicholas Marriott, 2021/01/19
- Re: Using ncurses only for terminfo (no I/O), Thomas Dickey, 2021/01/19
- Re: Using ncurses only for terminfo (no I/O), Grant Edwards, 2021/01/19
- Re: Using ncurses only for terminfo (no I/O), Thomas Dickey, 2021/01/21