[comp.sys.atari.st] clearing the screen

m204help@cca.UUCP (03/10/87)

I'm writing a program using the MEGAMAX C system and my program is going
to spit out lines of output to the screen. My problem is that I want to
clear the screen (exit the desktop), have my program display its' information,
then return to the desktop.
How do I do this ??? I realize I can spit out a bunch a blank lines, but I 
would like to be a little more elegant about things. I have read in my
MEGAMAX documentation the stuff on the AES and opening windows etc. ,,
is this what I need to do ? 
Does one have to open a window to clear the desktop ? Is there an escape
sequence I can pump out of my program ? 
I know that there is probably a simple answer to this question, but
I'M CONFUSED. 
Your help is greatly appreciated,
keith hedger

sansom@trwrb.UUCP (03/12/87)

In article <13873@cca.CCA.COM> m204help@cca.CCA.COM (Keith Hedger) writes:
>Does one have to open a window to clear the desktop ? Is there an escape
>sequence I can pump out of my program ? 

I believe that all *.TOS programs will clear the screen for you.  If this
isn't so with Megamax, then you can clear the screen using the vt52 escape
sequence ESC-E (that's Cconws("\033E") in Atari-ese ;-).

-Rich

-- 
  //////////////////////////////////////\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
 /// Richard E. Sansom                    TRW Electronics & Defense Sector \\\
 \\\ {decvax,ucbvax,ihnp4}!trwrb!sansom   Redondo Beach, CA                ///
  \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\/////////////////////////////////////

braner@batcomputer.UUCP (03/12/87)

[]

You can clear the _whole_ screen and put the _text_ cursor at top left by:

	printf("\033E");   (or Cconws("\033E"))

That is one of the VT52 escapes.  See page 242 in the Abacus "ST Internals"
for more details.

- Moshe Braner

leavens@atari.UUCP (03/14/87)

in article <13873@cca.CCA.COM>, m204help@cca.CCA.COM (Keith Hedger) says:
> 
> 
> I'm writing a program using the MEGAMAX C system and my program is going
> to spit out lines of output to the screen. My problem is that I want to
> clear the screen (exit the desktop), have my program display its' information,
> then return to the desktop.
> How do I do this ???

  Open a window.
  Write a filled rectangle of color white to the dimensions of the window.
  (This effectively blanks the window by painting the whole screen white).
  DO your stuff.
  CLose the window.
  Delete the window handle.
  Exit.

--alex @ Atari

BIX:alexl.            GEnie: ALEXLEAVENS      AtariCorp: 408-745-2006

"How can you be in two places at once when you're not anywhere at all."