// Text of project TabsNStyles written on 11/25/95 at 5:03 PM
// Beginning of file TabsNStyles.t

// Before Script for "baseView"
// Copyright 1993-1995 Apple Computer, Inc. All rights reserved.


baseView :=
    {title: "TabsNStyles",
     viewBounds: {top: 0, left: 0, right: 240, bottom: 336},
     viewSetupFormScript:
       func()
       begin
       	local b := GetAppParams();
       	constant kMaxWidth := 240;
       	constant kMaxHeight := 336;
       	
       	// prepare for different size screens
       	viewBounds := RelBounds(b.appAreaLeft, b.appAreaTop,
       			Min(b.appAreaWidth, kMaxWidth),
       			Min(b.appAreaHeight, kMaxHeight) );
       end,
     debug: "baseView",
     _proto: @157
    };

title2 :=
    {text: "Styled Text Example:",
     viewBounds: {left: 10, top: 50, right: 173, bottom: 67},
     debug: "title2",
     _proto: @218
    };
AddStepForm(baseView, title2);



theText :=
    {viewFlags: 3,
     viewFormat: 134427729,
     viewLineSpacing: 18,
     viewFont: userFont12,
     viewBounds: {left: 17, top: 73, right: 228, bottom: 184},
     text:
       "This is the story of a brave rat that tried to cross the street and forgot that the way people drive is not to exactly look at the ground closely while driving 80 mph..."
     ,
     styles:
       [
       	// set the style of the first two lines (56 chars) to bold geneva
       	56, {family: ROM_genevafont, face: 1, size: 12},
           
       	// set the style of the second two lines (62 chars) to plain geneva
       	62, {family: ROM_genevafont, face: 0, size: 12},
           
       	// finally set the last two lines to italic geneva
       	70, {family: ROM_genevafont, face: 2, size: 12}
       ],
     tabs: [40, 80, 120,160],
     debug: "theText",
     viewClass: 81
    };
AddStepForm(baseView, theText);



_view000 :=
    {text: "Tab Example:",
     viewBounds: {left: 10, top: 218, right: 130, bottom: 234},
     _proto: @218
    };
AddStepForm(baseView, _view000);



theText2 :=
    {viewFlags: 1,
     viewFormat: 12625,
     viewLineSpacing: 20,
     viewFont: ROM_fontsystem10bold,
     viewBounds: {left: 11, top: 235, right: 233, bottom: 281},
     tabs: [30, 60, 90, 120, 150, 180],
     text:
       "0\t1\t2\t3\t4\t5\t" &             // use the backslash-t method for tabs
       "6	7	8	9	10	11	12	13	14	15"     // or put tabs directly in the code
       ,
     debug: "theText2",
     viewClass: 81
    };
AddStepForm(baseView, theText2);




constant |layout_TabsNStyles.t| := baseView;
// End of file TabsNStyles.t



