comp.lang.ada
 help / color / mirror / Atom feed
From: Juergen Pfeifer <juergen.pfeifer@gmx.net>
Subject: Re: modifying color of "Ada.Text_IO.Put"
Date: Fri, 22 Dec 2000 00:44:27 +0100
Date: 2000-12-22T00:44:27+01:00	[thread overview]
Message-ID: <3A4295DB.B8E1AD55@gmx.net> (raw)
In-Reply-To: 3A425FFC.3831ACE2@gmx.net

>   in C and other programming languages it's simply possible to change
> the background and foreground color of text plotted on screen. But GNAT
> doesn't seem to offer procedures to handle that.
> 
Pardon me, but can you give me the C-language statement that sets the
color of a charactor on the screen? I'm doing C for 20 years and never
heard about that feature of the language;-) But perhaps you mean that
for C or other languages their exist conveniant libraries to do that.

> Moving the cursor may work with "Set_Col" and "Set_Line", but i need
> routines to change color as well!
> 
> Could anyone remember a small, simple easy-to-use package (OS
> independent) or should it even be possible by using standard GNAT
> packages?
> 
IMHO even in C you hardly find a library that does that kind of
thing in an OS independent way. On most UNIXes and similar OS
you'll find a library called curses (or ncurses on free OSes) which
deals with screen manipulation in a terminal independent way.
If you look into the sources of ncurses
(ftp://ftp.gnu.org/pub/gnu/ncurses)
you'll find there a quite complete Ada95 binding for this library.
Modern curses implementations (lile ncurses) support also colors.
The Ada95 binding for ncurses as BSD style license, so you are
quite free to use it for whatever you want.

Jürgen



  parent reply	other threads:[~2000-12-21 23:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-12-21 19:54 modifying color of "Ada.Text_IO.Put" Stefan Kombrink
2000-12-21 21:58 ` Adrian Knoth
2000-12-21 23:44 ` Juergen Pfeifer [this message]
2000-12-21 23:57 ` Ted Dennison
2000-12-22  0:01 ` Marin David Condic
2000-12-22 11:26 ` Lutz Donnerhacke
2000-12-22 12:33 ` Thank you very much Stefan Kombrink
2000-12-22 13:16   ` Marin David Condic
2000-12-22 20:21     ` Juergen Pfeifer
2000-12-23  0:51   ` Ted Dennison
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox