[comp.unix.aix] curses

wdn@math.ufl.edu (William Dean Norris II) (06/06/91)

We are trying to port from SysV 3.2.3 and 4.0.2 to AIX 3.1 on a
IBM RISC System/6000/x (RIOS) and having a few problems. :-)

The major problem has been trying to port some of our programs which
use curses, it seems that IBM used curses from SysV 2.x.  Attributes
do not function on other than HFT terminals.  We have been told that
they are *NOT* going to upgrade because they would have to buy all of 
the Un*x source from A*&* and that the cost was prohibitive.  :-}

Is there a curses library which is compatible with SysV 3.x (and up)
what we really need is the addch() function, I really don't want to
have to write it.

Thanx.

--
William Dean Norris II				People always say "I know what
University of Florida				I like" when they mean "I like
                                                what I know".
wdn@beach.cis.ufl.edu	                                 	- G. Artman

tli@Morgan.COM ( IBM) (06/06/91)

addch is a macro in curses.h. The macro uses waddch() which exist in the
/lib/libcurses.a

===============================================================
Thomas Y. Li                 Email: tli@nycvmic4.vnet.ibm.com
IBM Corporation                     tli%nycvmic4@vnet.ibm.com
33 Maiden Lane  10th Floor          tli@morgan.com
New York, NY  10038
(212) 493-2516 T/L 340       VNET:  tli at nycvmic4

jsalter@ibmpa.awdpa.ibm.com (06/07/91)

In article <WDN.91Jun5180238@bebop.math.ufl.edu> wdn@math.ufl.edu (William Dean Norris II) writes:
>Is there a curses library which is compatible with SysV 3.x (and up)
>what we really need is the addch() function, I really don't want to
>have to write it.

According to the include files <cur01.h> and <curses.h> it says that
addch() is a macro and is defined as waddch(stdscr,ch).  Is this what you
need?  By the way, I mention this is the /usr/lpp/bos/bsdport document.

>William Dean Norris II				People always say "I know what
>wdn@beach.cis.ufl.edu	                                 	- G. Artman

jim/jsalter  IBM PSP, Palo Alto  T465/(415)855-4427  VNET: JSALTER at AUSVMQ
Internet: jsalter@slo.awdpa.ibm.com         UUCP: ..!uunet!ibmsupt!jsalter 
"IBM part #23521, aka Lt. Commander Data"    The stuff above is on my own.

wdn@reef.cis.ufl.edu (William Dean Norris II) (06/08/91)

In article <1991Jun6.202337.27453@ibmpa.awdpa.ibm.com> you write:
>In article <WDN.91Jun5180238@bebop.math.ufl.edu> wdn@math.ufl.edu (William Dean Norris II) writes:
>>Is there a curses library which is compatible with SysV 3.x (and up)
>>what we really need is the addch() function, I really don't want to
>>have to write it.
>
>According to the include files <cur01.h> and <curses.h> it says that
>addch() is a macro and is defined as waddch(stdscr,ch).  Is this what you
>need?  By the way, I mention this is the /usr/lpp/bos/bsdport document.

What I was attempting to say is that wattrset () in the
curses library *doesn't* work, allegedly it works on HFTs.  The only
attribute which works is standout mode.  Blinking, underline, bold,
etc... do *not* work.  The include file calls these attributes,
A_STANDOUT, A_UNDERLINE, A_REVERSE, A_BLINK, A_DIM, A_BOLD, A_ALTCHARSET.

Actually the code we need is refresh ().  Addch() (or waddch () if you
perfer) seems to set the flags in the proper (at least I hope) arrays,
but refresh () (wrefresh () if you perfer) is what sends the escape
sequences to the terminal, (I think).

Low level curses routines not working is making it almost impossible
for us to port to the RISC System/6000.  We don't want to have to try
and write wrefresh (), or a new curses library for our software.

>
>>William Dean Norris II

>jim/jsalter  IBM PSP, Palo Alto  T465/(415)855-4427  VNET: JSALTER at AUSVMQ
>Internet: jsalter@slo.awdpa.ibm.com         UUCP: ..!uunet!ibmsupt!jsalter 
>"IBM part #23521, aka Lt. Commander Data"    The stuff above is on my own.

BTW, who owns the trademark on RS/6000?

Also how do you make the RISC System/6000/520 remember it's uname, after
you set it (with uname -S) and do a uname it shows correctly,
but after you shut it down it returns to it's default name (AIX).

-- 
-----
William Dean Norris II		"Darling it's better down
University of Florida		 where it's wetter..."
wdn@cis.ufl.edu				Sebastian in "A Little Mermaid"

wdn@reef.cis.ufl.edu (William Dean Norris II) (06/08/91)

In article <3473@s5.Morgan.COM> tli@Morgan.COM ( IBM) writes:
>addch is a macro in curses.h. The macro uses waddch() which exist in the
>/lib/libcurses.a
>

Obviously my original posting was misinterpreted.

I do appreciate you trying to help, but the problem is *not*
forgetting to #include a file.  It is deep within the curses
code.  Almost none of the attributes work (only standout works).

My follow-up to the previous response, has more details, I don't
have the time or patience to type them back in.
 
>===============================================================
>Thomas Y. Li                 Email: tli@nycvmic4.vnet.ibm.com
>IBM Corporation                     tli%nycvmic4@vnet.ibm.com
>(212) 493-2516 T/L 340       VNET:  tli at nycvmic4

-- 
-----
William Dean Norris II		"Darling it's better down
University of Florida		 where it's wetter..."
wdn@cis.ufl.edu				Sebastian in "A Little Mermaid"

wdn@reef.cis.ufl.edu (William Dean Norris II) (06/08/91)

>>>>> On 7 Jun 91 17:12:45 GMT, wdn@reef.cis.ufl.edu (William Dean Norris II) said:

Dean> In article <1991Jun6.202337.27453@ibmpa.awdpa.ibm.com> you write:
>In article <WDN.91Jun5180238@bebop.math.ufl.edu> wdn@math.ufl.edu (William Dean Norris II) writes:

Dean> What I was attempting to say is that wattrset () in the
Dean> curses library *doesn't* work, allegedly it works on HFTs.  The only
Dean> attribute which works is standout mode.  Blinking, underline, bold,
Dean> etc... do *not* work.  The include file calls these attributes,
Dean> A_STANDOUT, A_UNDERLINE, A_REVERSE, A_BLINK, A_DIM, A_BOLD, A_ALTCHARSET.

>jim/jsalter  IBM PSP, Palo Alto  T465/(415)855-4427  VNET: JSALTER at AUSVMQ

Dean> William Dean Norris II		"Darling it's better down
Dean> wdn@cis.ufl.edu				Sebastian in "A Little Mermaid"


Well our question was answered through eMail, by
ejsiebe@chgvmic1.vnet.ibm.com he suggested that we compile with
-DNLS and it worked.  He (I am assuming the sex of the individual)
said that this was a work-around and thought that there was a patch
available to fix this bug, but I'm glad that we have something. :-)

Now if we can only get *real* boxes around our windows. :)

Tech Support -4
Net 1

--
-----
William Dean Norris II		"Darling it's better down
University of Florida		 where it's wetter..."
wdn@cis.ufl.edu				Sebastian in "A Little Mermaid"

rbraun@spdcc.COM (Rich Braun) (06/11/91)

This thread has me a little nervous, because I'm in the midst of
developing a curses application which has to run on the RS/6000.  (I've
not yet tested it under AIX.)  The first thing I noticed about curses
under AIX is that it lacks color support.

Is IBM planning on upgrading to the color curses supported by SCO et al?
When?

-rich