Previous Page | Next Page

TEMPLATE Procedure: Creating Markup Language Tagsets

Example 6: Using Different Styles for Events


PROC TEMPLATE features:

DEFINE EVENT statement:

PUT statement

TRIGGER statement

Event attribute:

STYLE= attribute



Program Description

This example uses different styles for events.


Program

 Note about code
define event Gnote;
           start:
               put '<div>';
               trigger align;
               put '>';
               put '<table>';
               put '<tr>' nl;
           finish:
               put '</tr>' nl;
               put '</table>' nl;
               put '</div>';
       end;

       define event GBanner;
           put '' nl;
           trigger pre_post;
           put '' nl;
       end;

       define event GNContent;
           put '';
           trigger pre_post start;
           put VALUE;
           trigger pre_post finish;
           put '';
       end;

       define event noteBanner;
           style=NoteBanner;
           trigger GBanner;
       end;

       define event NoteContent;
           style=NoteContent;
           trigger GNContent;
       end;

       define event note;
           trigger Gnote start;
           trigger noteBanner;
           trigger noteContent;
           trigger Gnote finish;
       end;

       define event WarnBanner;
           style=WarnBanner;
           trigger GBanner;
       end;

       define event WarnContent;
           style=WarnContent;
           trigger GNContent;
       end;

       define event Warning;
           trigger Gnote start;
           trigger WarnBanner;
           trigger WarnContent;
           trigger Gnote finish;
       end;
 

Previous Page | Next Page | Top of Page