Xbasic

MODE

Syntax

MODE Argument

Arguments

Argument

Defines the mode to use. The options are: "GRAPHICS" and "TEXT"

Description

Opens a split window that lets you play around with graphics in the Interactive window. This is an older command that was useful for desktop applications. With newer applications you might want to consider using SVG.

Discussion

Alpha Anywhere has a very powerful set of Xbasic commands that allow you to create bitmaps. You can experiment with these commands in the Interactive window by executing the MODE GRAPHICS command. This will turn the top half of the Interactive window into a bitmap where you can see the results of executing graphics commands.

Example

Try this in the Interactive window.

mode graphics

set_brush("blue") 
fill_rect(0,0,2,2) 
set_font("Arial,15,b","Red") 
text("Hello World",.5,.5) 
bitmap("$a5_open",.5,.7) 
set_brush("Cyan") 
fill_oval(.2,.9,.5,.5)

mode text

Limitations

Interactive Window Only

See Also