List Arkiverade meddelande #31

Från: "Steven Levine" <> Meddelandehuvud
Oavkodat meddelande
Ämne: Re: [GNU Ports] Terminal width?
Datum: Sat, 14 May 2022 23:00:01 -0700
Till: "GNU Ports for eCS Mailing List" <>

In <>, on 05/14/22
   at 06:52 PM, "Dave Yeo" <> said:

Hi Dave,

>void _scrsize (int *dst);

And for reference the actual source at


>Does this code make sense?

You have the right idea, but what you have written is probably going to

>int term_width(int fd)
>         int dst[1];
>         void _scrsize (int *dst);
>                  return dst[0];

What you want is:

int term_width(int fd)
         int dst[2];
         void _scrsize (dst);       /* Get columns and rows */
                  return dst[0];    /* Return columns */

For your needs, _srcsize is better than using VioGetMode directly because
it deals with the 16-bit code issues.


"Steven Levine" <>  Warp/DIY/BlueLion etc.

Prenumerera: Sändning, Uppsamling, Index.
Stoppa prenumeration
Meddelande till ListMaster