Annotation of Amaya/amaya/HTMLTT.T, revision 1.7
1.1 cvs 1: TRANSLATION HTML;
2:
3: LINELENGTH 78;
4:
5: COUNTERS
6: ItemCounter : Rank of List_Item;
1.5 cvs 7: AnchorCounter : Set 1 on BODY Add 1 on Anchor;
8:
1.3 cvs 9: CONST
1.5 cvs 10: TmpFileName = 'test';
1.3 cvs 11: TmpFileExt = '.tmp';
12: TmpFileDir = '/tmp/';
1.5 cvs 13: DoubleQuote = '"';
1.3 cvs 14:
15: VAR
1.5 cvs 16: OUT_AnchorCounter : Value(AnchorCounter);
1.3 cvs 17: TmpFile : TmpFileDir TmpFileName TmpFileExt;
1.1 cvs 18:
19: RULES
20:
21: HTML : BEGIN
1.5 cvs 22: Create '\12' After;
1.1 cvs 23: END;
24:
25: HEAD: BEGIN
1.5 cvs 26: Create in TmpFile '\12' After;
1.1 cvs 27: END;
28:
29: Document_URL:
30: BEGIN
1.5 cvs 31: Create In TmpFile 'The URL of the document is: ';
1.3 cvs 32: Create Attributes;
1.5 cvs 33: Create In TmpFile '\12' After;
34: {Waiting for a change of HTML.S}
35: Remove;
1.1 cvs 36: END;
37:
38: TITLE: BEGIN
1.5 cvs 39: Create '\12\12' After;
1.1 cvs 40: END;
41:
42: ISINDEX: BEGIN
43: Remove;
44: END;
45:
46: BASE: BEGIN
1.5 cvs 47: Create IN TmpFile 'The base of the document is: ';
48: Create Attributes;
49: Create IN TmpFile '\12' After;
1.1 cvs 50: END;
51:
52: Styles:BEGIN
1.7 ! cvs 53: Remove;
1.1 cvs 54: END;
55:
56: StyleRule:
57: BEGIN
1.7 ! cvs 58: Remove;
1.1 cvs 59: END;
60:
61: SCRIPT: BEGIN
1.7 ! cvs 62: Remove;
1.1 cvs 63: END;
64:
65: META: BEGIN
66: Remove;
67: END;
68:
69: LINK: BEGIN
70: Remove;
71: END;
72:
1.5 cvs 73:
1.1 cvs 74: BODY: BEGIN
1.4 cvs 75: Indent +3;
76: Indent -3 After;
1.3 cvs 77: Create '\12\12' After;
78: Create '-------------------------\12' After;
1.5 cvs 79: Create 'List of References\12\12' After;
80: Include '/tmp/test.tmp' After;
1.1 cvs 81: END;
82:
83: H1: BEGIN
1.4 cvs 84: Indent -3;
1.7 ! cvs 85: if not within Preformatted Create '\12';
1.4 cvs 86: Indent +3 After;
1.7 ! cvs 87: if not within Preformatted Create '\12\12' After;
1.1 cvs 88: END;
89:
90: H2: BEGIN
1.7 ! cvs 91: if not within Preformatted Create '\12';
! 92: if not within Preformatted Create '\12\12' After;
1.1 cvs 93: END;
94:
95: H3: BEGIN
1.4 cvs 96: Indent +3;
1.7 ! cvs 97: if not within Preformatted Create '\12';
1.4 cvs 98: Indent -3 After;
1.7 ! cvs 99: if not within Preformatted Create '\12\12' After;
1.1 cvs 100: END;
101:
102: H4: BEGIN
1.4 cvs 103: Indent +6;
1.7 ! cvs 104: if not within Preformatted Create '\12';
1.4 cvs 105: Indent -6 After;
1.7 ! cvs 106: if not within Preformatted Create '\12\12' After;
1.1 cvs 107: END;
108:
109: H5: BEGIN
1.4 cvs 110: Indent +9;
1.7 ! cvs 111: if not within Preformatted Create '\12';
1.4 cvs 112: Indent -9 After;
1.7 ! cvs 113: if not within Preformatted Create '\12\12' After;
1.1 cvs 114: END;
115:
116: H6: BEGIN
1.4 cvs 117: Indent +12;
1.7 ! cvs 118: if not within Preformatted Create '\12';
1.4 cvs 119: Indent -12 After;
1.7 ! cvs 120: if not within Preformatted Create '\12\12' After;
1.1 cvs 121: END;
122:
123: BaseFont:
124: BEGIN
125: Remove;
126: END;
127:
128: BR: BEGIN
1.3 cvs 129: Create '\12';
1.1 cvs 130: Remove;
131: END;
1.5 cvs 132:
1.1 cvs 133: Italic_text:
134: BEGIN
135: END;
136: Bold_text:
137: BEGIN
138: END;
139: Teletype_text:
140: BEGIN
141: END;
142: Underlined_text:
143: BEGIN
144: END;
145: Struck_text:
146: BEGIN
147: END;
148: Big_text:
149: BEGIN
150: END;
151: Small_text:
152: BEGIN
153: END;
154: Subscript:
155: BEGIN
156: END;
157: Superscript:
158: BEGIN
159: END;
160:
161: Emphasis:
162: BEGIN
163: END;
164: Strong:
165: BEGIN
166: END;
167: Def:
168: BEGIN
169: END;
170: Code:
171: BEGIN
172: END;
173: Sample:
174: BEGIN
175: END;
176: Keyboard:
177: BEGIN
178: END;
179: Variable:
180: BEGIN
181: END;
182: Cite:
183: BEGIN
1.5 cvs 184: Create DoubleQuote;
185: Create DoubleQuote After;
1.1 cvs 186: END;
187:
188: Font_: BEGIN
1.3 cvs 189: Remove;
1.1 cvs 190: END;
191:
192: Applet: BEGIN
1.5 cvs 193: Create Attributes;
194: Remove;
195: Create '\12' After;
1.1 cvs 196: END;
197:
198: Parameter: BEGIN
199: Remove;
200: END;
201:
202: #ifdef COUGAR
1.5 cvs 203: Object: BEGIN
204: Create Attributes;
205: Remove;
1.3 cvs 206: Create '\12' After;
1.1 cvs 207: END;
208: #endif
209: Paragraph: BEGIN
1.5 cvs 210: Create '\12';
211: Create '\12' After;
1.1 cvs 212: END;
213:
214: Pseudo_paragraph: BEGIN
1.7 ! cvs 215: If NOT within Paragraph AND NOT within Pseudo_paragraph
! 216: Create '\12\12' After;
1.1 cvs 217: END;
218:
219: TEXT_UNIT: BEGIN
220: IF *Style\240 and not Within HEAD
221: BEGIN
1.7 ! cvs 222: Remove;
1.1 cvs 223: END;
224: IF *Class and not Within HEAD
225: BEGIN
1.7 ! cvs 226: Remove;
1.1 cvs 227: END;
228: IF Within Text_Area
229: Remove;
230: IF Within Text_Input
231: Remove;
1.7 ! cvs 232: IF Within HEAD
! 233: Remove;
! 234: IF Within STYLE
! 235: Remove;
1.1 cvs 236: END;
237:
238: Definition_List: BEGIN
1.3 cvs 239: Create '\12';
1.5 cvs 240: Indent +3;
241: Indent -3 After;
1.1 cvs 242: END;
243:
244: Term: BEGIN
1.5 cvs 245: Create '\12' After;
1.1 cvs 246: END;
247:
248: Definition: BEGIN
249: Indent +5;
250: Indent -5 After;
251: END;
252:
253: Unnumbered_List: BEGIN
1.7 ! cvs 254: Create '\12';
! 255: Indent +3;
1.5 cvs 256: Indent -3 After;
1.1 cvs 257: END;
258:
259: Numbered_List: BEGIN
1.7 ! cvs 260: Create '\12';
! 261: Indent +3;
1.5 cvs 262: Indent -3 After;
1.1 cvs 263: END;
264:
265: Address: BEGIN
1.5 cvs 266: Create Attributes;
1.3 cvs 267: Create '\12' After;
1.1 cvs 268: END;
269:
270: Menu: BEGIN
1.5 cvs 271: Create '\12';
1.7 ! cvs 272: Indent +3;
! 273: Indent -3 After;
1.1 cvs 274: END;
275:
276: Directory: BEGIN
1.5 cvs 277: Create '\12';
1.7 ! cvs 278: Indent +3;
! 279: Indent -3 After;
1.1 cvs 280: END;
281:
282: List_Item: BEGIN
283: Create Attributes;
284: Indent +3;
1.7 ! cvs 285: Indent -3 after;
1.1 cvs 286: END;
287:
288: Preformatted: BEGIN
289: NoLineBreak;
1.5 cvs 290: Create Attributes;
1.3 cvs 291: Create '\12' After;
1.1 cvs 292: END;
293:
294: Horizontal_Rule: BEGIN
1.7 ! cvs 295: If NOT within Paragraph AND NOT within Pseudo_paragraph
! 296: Create '\12';
1.5 cvs 297: Create '-----------------------------\12';
298: Remove;
1.1 cvs 299: END;
300:
301: Form: BEGIN
1.6 cvs 302: Create '\12';
303: Create '\12' After;
1.1 cvs 304: END;
305:
306: Option_Menu: BEGIN
1.6 cvs 307: Remove;
1.1 cvs 308: END;
309:
310: Option: BEGIN
1.6 cvs 311: Remove;
1.1 cvs 312: END;
313:
314: Toggle_Menu: BEGIN
1.6 cvs 315: Remove;
1.1 cvs 316: END;
317:
318: Toggle_Item: BEGIN
1.6 cvs 319: Remove;
1.1 cvs 320: END;
321:
322: Radio_Menu: BEGIN
1.6 cvs 323: Remove;
1.1 cvs 324: END;
325:
326: Radio_Item: BEGIN
1.6 cvs 327: Remove;
1.1 cvs 328: END;
329:
330: Text_Input_Line: BEGIN
1.6 cvs 331: Remove;
1.1 cvs 332: END;
333:
334: Command_Line: BEGIN
1.6 cvs 335: Remove;
1.1 cvs 336: END;
337:
338: Text_Area: BEGIN
1.6 cvs 339: Remove;
1.1 cvs 340: END;
341:
342: Checkbox_Input: BEGIN
343: Remove;
344: END;
345:
346: Radio_Input: BEGIN
347: Remove;
348: END;
349:
350: Text_Input: BEGIN
351: Remove;
352: END;
353:
354: Hidden_Input: BEGIN
355: Remove;
356: END;
357:
358: Password_Input: BEGIN
359: Remove;
360: END;
361:
362: File_Input: BEGIN
363: Remove;
364: END;
365:
366: Reset_Input: BEGIN
367: Remove;
368: END;
369:
370: Submit_Input: BEGIN
1.5 cvs 371: Remove;
1.1 cvs 372: END;
373:
374: Block_Quote: BEGIN
1.3 cvs 375: Create '\12';
376: Indent +5;
377: Indent -5 After;
378: Create '\12' After;
1.1 cvs 379: END;
380:
381: PICTURE_UNIT: BEGIN
382: #ifdef COUGAR
383: if Immediately within Object
384: Remove;
385: if NOT Immediately within Object BEGIN
1.5 cvs 386: Create Attributes;
387: END;
388: if NOT within Paragraph AND NOT Immediately within Object BEGIN
1.1 cvs 389: END;
390: #else
391: Create Attributes;
392: #endif
393: END;
394:
395: Anchor: BEGIN
1.5 cvs 396: Create IN TmpFile '[';
397: Create IN TmpFile OUT_AnchorCounter;
398: Create IN TmpFile '] ';
399: Create Attributes;
1.3 cvs 400: Create IN TmpFile '\12' After;
1.5 cvs 401: #ifdef ANCHOR_PREFIX
402: Create '[' ;
403: Create OUT_AnchorCounter;
404: Create ']';
405: #else
1.4 cvs 406: Create '[' After;
407: Create OUT_AnchorCounter After;
408: Create ']' After;
1.5 cvs 409: #endif
1.1 cvs 410: END;
411:
412: MAP:
413: BEGIN
1.3 cvs 414: Remove;
1.1 cvs 415: END;
416:
417: AREA:
418: BEGIN
419: Remove;
420: END;
421:
422: { ---- Tables ---- }
423:
424: Table:
425: BEGIN
1.5 cvs 426: Create '\12';
427: Indent +3;
1.1 cvs 428: Create Attributes;
1.5 cvs 429: Indent -3 After;
430: Create '\12' After;
1.1 cvs 431: END;
432:
433: CAPTION:
434: BEGIN
1.5 cvs 435: Indent -3;
436: Indent +3 After;
437: Create '\12' after;
1.1 cvs 438: END;
439:
440: Table_head:
441: Remove;
442:
443: #ifdef COUGAR
444: thead:
445: BEGIN
1.5 cvs 446: Create '<thead';
447: Create Attributes;
448: Create '>\12';
449: Create '</thead>\12' after;
1.1 cvs 450: END;
451:
452: tfoot:
453: BEGIN
1.5 cvs 454: Create '<tfoot';
455: Create Attributes;
456: Create '>\12';
457: Create '</tfoot>\12' after;
1.1 cvs 458: END;
459: tbody:
460: BEGIN
461: END;
462: #endif
463:
464: Table_body:
465: Get tfoot;
466:
467: Table_row:
468: BEGIN
469: END;
470:
471: Data_cell:
472: BEGIN
1.3 cvs 473: Create '\12' After;
1.1 cvs 474: END;
475:
476: Heading_cell:
477: BEGIN
1.5 cvs 478: Create '\12' After;
1.1 cvs 479: END;
480:
481: Table_foot:
482: BEGIN
483: Remove;
484: END;
485:
486: Division: BEGIN
1.7 ! cvs 487: Create '\12';
1.1 cvs 488: END;
489:
490: Center: BEGIN
1.7 ! cvs 491: Create '\12';
! 492:
1.1 cvs 493: END;
494:
495: Invalid_element:
496: BEGIN
1.5 cvs 497: if Error_type = BadPosition
498: Remove;
499: if not Error_type = BadPosition
500: BEGIN
501: NoTranslation;
502: Create Content;
503: Remove;
504: Create Attributes;
505: Create '>';
506: END;
1.1 cvs 507: END;
508:
509: Comment\240: BEGIN
1.4 cvs 510: Remove;
1.1 cvs 511: END;
512:
513: Comment_line: BEGIN
1.4 cvs 514: Remove;
1.1 cvs 515: END;
516:
517: ATTRIBUTES
518:
519: http_equiv: BEGIN
1.7 ! cvs 520: Remove;
1.1 cvs 521: END;
522:
523: meta_name: BEGIN
1.7 ! cvs 524: Remove;
1.1 cvs 525: END;
526:
527: meta_content: BEGIN
1.7 ! cvs 528: Remove;
1.1 cvs 529: END;
530:
531: REL: BEGIN
1.7 ! cvs 532: Remove;
1.1 cvs 533: END;
534:
535: REV: BEGIN
1.7 ! cvs 536: Remove;
1.1 cvs 537: END;
538:
539: HREF_ :
540: BEGIN
1.6 cvs 541: If NOT Within LINK
542: Create IN TmpFile HREF_;
1.1 cvs 543: END;
544:
545: background_ :
546: BEGIN
547: END;
548:
549: BackgroundColor :
550: BEGIN
551: END;
552:
553: TextColor :
554: BEGIN
555: END;
556:
557: LinkColor :
558: BEGIN
559: END;
560:
561: VisitedLinkColor :
562: BEGIN
563: END;
564:
565: ActiveLinkColor :
566: BEGIN
567: END;
568:
569: BaseFontSize:
570: BEGIN
571: END;
572:
573: Font_size :
1.5 cvs 574: BEGIN
1.1 cvs 575: END;
576:
577: color :
578: BEGIN
579: END;
580:
581: Clear = Left_:
582: BEGIN
583: END;
584:
1.7 ! cvs 585: Clear = Right_:
1.1 cvs 586: BEGIN
587: END;
588: Clear = All_:
589: BEGIN
590: END;
591: Clear = None:
592: BEGIN
593: END;
594:
595: Align = left_:
596: BEGIN
597: END;
598: Align = center_:
599: BEGIN
600: END;
601: Align = right_:
602: BEGIN
603: END;
604:
605: NoShade:
1.5 cvs 606: BEGIN
1.1 cvs 607: END;
608:
609: Size_: BEGIN
610: END;
611:
612: Width__: BEGIN
613: END;
614:
615: codebase: BEGIN
616: END;
617:
618: code: BEGIN
619: END;
620:
621: applet_name: BEGIN
622: END;
623:
624: Param_name: BEGIN
625: END;
626:
627: Param_value: BEGIN
628: END;
629: #ifdef COUGAR
630: classid: BEGIN
631: END;
632:
633: data: BEGIN
634: END;
635:
636: Object_type: BEGIN
637: END;
638:
639: codetype: BEGIN
640: END;
641: #endif
642: Title : BEGIN
643: NoTranslation;
644: END;
645:
646: Class: BEGIN
1.7 ! cvs 647: Remove;
1.1 cvs 648: END;
649:
650: Style\240: BEGIN
1.7 ! cvs 651: Remove;
1.1 cvs 652: END;
653:
654: COMPACT: BEGIN
655: END;
656:
657: IntItemStyle = disc:
658: Create '* ';
659: IntItemStyle = square :
660: Create '+ ';
661: IntItemStyle = circle :
662: Create 'o ';
663: IntItemStyle = Arabic_ :
664: Create (Value(ItemCounter, Arabic) '. ');
665: IntItemStyle = LowerAlpha :
666: Create (Value(ItemCounter, Lowercase) '. ');
667: IntItemStyle = UpperAlpha :
668: Create (Value(ItemCounter, Uppercase) '. ');
669: IntItemStyle = LowerRoman :
670: Create (Value(ItemCounter, LRoman) '. ');
671: IntItemStyle = UpperRoman :
672: Create (Value(ItemCounter, URoman) '. ');
673:
674: Start: BEGIN
675: END;
676:
677: ItemValue: BEGIN
678: END;
679:
680: WidthElement: BEGIN
681: END;
682:
683: Script_URL: BEGIN
684: END;
685:
686: METHOD=Post_:
1.5 cvs 687: BEGIN
688: END;
1.1 cvs 689:
690: METHOD=Get_:
1.5 cvs 691: BEGIN
692: END;
1.1 cvs 693:
694: ENCTYPE: BEGIN
695: END;
696:
697: NAME: BEGIN
698: END;
699:
700: Multiple:
1.5 cvs 701: BEGIN
702: END;
1.1 cvs 703:
704: MenuSize: BEGIN
705: END;
706:
707: Selected:
708: Create ' selected';
709:
710: Value_: BEGIN
711: END;
712:
713: Rows: BEGIN
714: END;
715:
716: Columns: BEGIN
717: END;
718:
719: Checked = Yes_:
720: Create ' checked';
721:
722: Area_Size: BEGIN
723: END;
724:
725: MaxLength: BEGIN
726: END;
727:
728: SRC: BEGIN
1.3 cvs 729: Remove;
1.1 cvs 730: END;
731:
732: ALT: BEGIN
1.3 cvs 733: Create '[';
1.1 cvs 734: Create ALT;
1.3 cvs 735: Create ']' After;
1.1 cvs 736: END;
737:
738: Alignment = Top_:
1.5 cvs 739: BEGIN
740: END;
1.1 cvs 741: Alignment = Middle_:
1.5 cvs 742: BEGIN
743: END;
1.1 cvs 744: Alignment = Bottom_:
1.5 cvs 745: BEGIN
746: END;
1.1 cvs 747: Alignment = Left_:
1.5 cvs 748: BEGIN
749: END;
1.1 cvs 750: Alignment = Right_:
1.5 cvs 751: BEGIN
752: END;
1.1 cvs 753:
754: Height_: BEGIN
755: END;
756:
757: Width_: BEGIN
758: END;
759:
760: Img_border: BEGIN
761: END;
762:
763: hspace: BEGIN
764: END;
765:
766: vspace: BEGIN
767: END;
768:
769: ISMAP:
1.5 cvs 770: BEGIN
771: END;
1.1 cvs 772:
773: USEMAP: BEGIN
774: END;
775:
776: nohref:
1.5 cvs 777: BEGIN
778: END;
1.1 cvs 779:
780: shape = rectangle:
1.5 cvs 781: BEGIN
782: END;
1.1 cvs 783: shape = circle:
1.5 cvs 784: BEGIN
785: END;
1.1 cvs 786: shape = polygon:
1.5 cvs 787: BEGIN
788: END;
1.1 cvs 789:
790: coords: BEGIN
791: END;
792:
793: Border: BEGIN
794: END;
795:
796: Table_align = Align_left:
1.5 cvs 797: BEGIN
798: END;
1.1 cvs 799: Table_align = Center_:
1.5 cvs 800: BEGIN
801: END;
1.1 cvs 802: Table_align = Align_right:
1.5 cvs 803: BEGIN
804: END;
1.1 cvs 805: cellspacing: BEGIN
806: END;
807:
1.5 cvs 808: cellpadding:
809: BEGIN
1.1 cvs 810: END;
811:
812: Position = Position_top:
1.5 cvs 813: BEGIN
814: END;
1.1 cvs 815: Position = Position_bottom:
1.5 cvs 816: BEGIN
817: END;
1.1 cvs 818:
819: Row_align = Row_left:
1.5 cvs 820: BEGIN
821: END;
1.1 cvs 822: Row_align = Row_center:
1.5 cvs 823: BEGIN
824: END;
1.1 cvs 825: Row_align = Row_right:
1.5 cvs 826: BEGIN
827: END;
1.1 cvs 828: Row_valign = Row_top:
1.5 cvs 829: BEGIN
830: END;
1.1 cvs 831: Row_valign = Row_middle:
1.5 cvs 832: BEGIN
833: END;
1.1 cvs 834: Row_valign = Row_bottom:
1.5 cvs 835: BEGIN
836: END;
1.1 cvs 837:
838: colspan: BEGIN
839: END;
840:
841: rowspan: BEGIN
842: END;
843:
844: Cell_align = Cell_left:
1.5 cvs 845: BEGIN
846: END;
1.1 cvs 847: Cell_align = Cell_center:
1.5 cvs 848: BEGIN
849: END;
1.1 cvs 850: Cell_align = Cell_right:
1.5 cvs 851: BEGIN
852: END;
1.1 cvs 853:
854: Cell_valign = Cell_top:
1.5 cvs 855: BEGIN
856: END;
1.1 cvs 857: Cell_valign = Cell_middle:
1.5 cvs 858: BEGIN
859: END;
1.1 cvs 860: Cell_valign = Cell_bottom:
1.5 cvs 861: BEGIN
862: END;
1.1 cvs 863:
864: Cell_width: BEGIN
865: END;
866:
867: Cell_height: BEGIN
868: END;
869:
870: Word_wrap = No_wrap:
1.5 cvs 871: BEGIN
872: END;
1.1 cvs 873:
874: Invalid_attribute:
1.5 cvs 875: BEGIN
876: END;
877:
878: TextTRANSLATE
879: BEGIN
880: '\240' -> ' '; { }
881: '\267' -> '-'; { · }
882: '\212' -> '\12'; { &CTLrc; }
883: END;
1.1 cvs 884:
885: GraphTRANSLATE
886: BEGIN
887: 'c' -> 'circle';
888: 'Q' -> 'circle';
889: 'R' -> 'rect';
890: 'C' -> 'rect';
891: ' ' -> 'rect';
892: 'P' -> 'rect';
893: 'p' -> 'polygon';
894: 'B' -> 'polygon';
895: END;
896:
897: END
1.3 cvs 898:
Webmaster