Microsoft Small Basic

Program Listing:
Embed this in your website
gw = GraphicsWindow.Width
gh = GraphicsWindow.Height

GraphicsWindow.BackgroundColor = "AntiqueWhite"
GraphicsWindow.BrushColor = "MediumAquamarine"
GraphicsWindow.FillRectangle(0,gh/2, gw,gh/2)

GraphicsWindow.BrushColor = "Black"
mltb = Controls.AddMultiLineTextBox(0,gh/2)
Controls.SetSize(mltb, gw,gh/2)
Shapes.SetOpacity(mltb, 80)

GraphicsWindow.FontName = "Calligraphic"
GraphicsWindow.FontItalic = "True"
GraphicsWindow.FontSize = 18
GraphicsWindow.FontBold = "False"

Controls.TextTyped = OnTextTyped


Sub OnTextTyped
  If Controls.LastTypedTextBox = mltb Then
    '' Avoid overwrite eg. after BS, CursorLeft, ...
    GraphicsWindow.BrushColor = GraphicsWindow.BackgroundColor
    GraphicsWindow.FillRectangle(0,0, gw,gh/2)
    GraphicsWindow.BrushColor = "Black"

    input = Controls.GetTextBoxText(mltb)
    GraphicsWindow.DrawBoundText(0,0, gw,input)
  EndIf
EndSub
Copyright (c) Microsoft Corporation. All rights reserved.