[net.micro.amiga] More columns and lines from Amiga BASIC

bruceb@amiga.UUCP (Bruce Barrett) (01/16/86)

We've gotten several requestes for how to access more than the 
typical 77.5 x 23.5 charcter window display from Amiga BASIC.
The following 2 lines will do it.
  WINDOW 2,"",,0
  WINDOW OUTPUT 2
A program example demostrates (read remarks for more info):
Good luck!,  Bruce Barrett
REM ----------------- Cut Here ---------
REM --- Creating a borderless window for 79x24.5 output ----
REM --- Quickly hacked together by Bruce Barrett
REM --- Placed in the public domain.  If you can
REM --- get someone to pay for this go ahead.

DEFINT a-Z 

' This is the good part!  The rest just proves it.  
' Note: Name ="", no gadgets selected to take up border space
  WINDOW 2,"",,0

' Select new window for "standard output"  
  WINDOW OUTPUT 2

' Set the REAL window width so wrap works
  WIDTH 79
  LOCATE 11,1 ' Start in the midle of the screen

' print 79 characters (tens digit)
  FOR i = 1 TO 79
    PRINT CHR$((INT(i/10) MOD 10) + ASC("0"));
    NEXT

' print 85 characters (ones digit) to cause wrap.
  FOR i = 1 TO 85
    PRINT CHR$((i MOD 10) + ASC("0"));
    NEXT

' print 25 lines (well, 24.5) vertically  
  FOR i = 1 TO 25
    LOCATE i,11
    PRINT USING "##";i;
    NEXT

' pause to let the user see what we did.
LOCATE 18,20 : INPUT "Press <Return> to end ",a$
WINDOW CLOSE  2
END
     
REM ---------- Cut Here ------------