#include <tads.h>

/*
 * An XTads test game.
 * Focus is on HTML markup handling in text banner vs grid banner.
 */

main(args)
{
	local b0 = nil;
	local b1;
	local b2;
	local txt = 'Text banner: Normal <b>bold</b> normal <i>italics <b>italics bold</b> italics</i> normal\nLine2?<br>Line3?';
    
    "A banner test game for XTads.";

    //------------

    "\bb1 - text banner below and 50% of main area:";
    b1 = bannerCreate(b0, BannerFirst, nil, BannerTypeText, BannerAlignBottom,
                       50, BannerSizePercent,
                       BannerStyleBorder);
    bannerSetTextColor(b1, ColorYellow, ColorTransparent);
    inputKey();

	 bannerSay(b1, txt);
    inputKey();
    
    bannerDelete(b1);
    inputKey();

    "\bb2 - grid banner below and 50% of main area:";
    b2 = bannerCreate(b0, BannerFirst, nil, BannerTypeTextGrid, BannerAlignBottom,
                       50, BannerSizePercent,
                       BannerStyleBorder);
    bannerSetTextColor(b2, ColorYellow, ColorTransparent);
    inputKey();

	 bannerSay(b2, txt);
    inputKey();

    
    //------------
    
    "\bPress another key to exit...\n";
    inputKey();
}
