multi-page_20graphics
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
multi-page_20graphics [2018/03/31 13:19] – external edit 127.0.0.1 | multi-page_20graphics [2024/01/05 00:21] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
=====Multi-page graphics===== | =====Multi-page graphics===== | ||
- | //by Richard Russell, November 2007//\\ \\ Some dialects of BASIC provide the ability to have multiple //pages// of graphics, whereby you can draw text and/or graphics into each //page// and then switch ' | + | //by Richard Russell, November 2007//\\ \\ Some dialects of BASIC provide the ability to have multiple //pages// of graphics, whereby you can draw text and/or graphics into each //page// and then switch ' |
+ | |||
+ | <code bb4w> | ||
ON CLOSE PROCpage(-1) : QUIT | ON CLOSE PROCpage(-1) : QUIT | ||
ON ERROR PROCpage(-1) : SYS " | ON ERROR PROCpage(-1) : SYS " | ||
- | Of course you may need to perform other ' | + | </ |
+ | |||
+ | Of course you may need to perform other ' | ||
+ | |||
+ | <code bb4w> | ||
FOR Page% = 0 TO 15 | FOR Page% = 0 TO 15 | ||
PROCpage(Page%) | PROCpage(Page%) | ||
Line 10: | Line 16: | ||
PRINT "This is page "; | PRINT "This is page "; | ||
NEXT | NEXT | ||
- | As it stands the **PROCpage** routine doesn' | + | </ |
+ | |||
+ | As it stands the **PROCpage** routine doesn' | ||
+ | |||
+ | <code bb4w> | ||
REPEAT | REPEAT | ||
K% = INKEY(10) | K% = INKEY(10) | ||
Line 21: | Line 31: | ||
ENDCASE | ENDCASE | ||
UNTIL FALSE | UNTIL FALSE | ||
- | This code also allows you to write text into each page, to demonstrate that they are truly independent. Note that **page 0**, which is the normal default screen, cannot be selected using this code. The page currently being // | + | </ |
+ | |||
+ | This code also allows you to write text into each page, to demonstrate that they are truly independent. Note that **page 0**, which is the normal default screen, cannot be selected using this code. The page currently being // | ||
+ | |||
+ | <code bb4w> | ||
DEF PROCpage(Page%) | DEF PROCpage(Page%) | ||
PRIVATE hdc%() | PRIVATE hdc%() | ||
Line 56: | Line 70: | ||
SYS " | SYS " | ||
ENDPROC | ENDPROC | ||
+ | </ |
multi-page_20graphics.1522502369.txt.gz · Last modified: 2024/01/05 00:17 (external edit)