home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / SourceCode / MiscKit1.7.1 / MiscKit / Examples / AutoDoc / lib / perl5 / Autodoc / DumpDocs.pm next >
Encoding:
Perl POD Document  |  1995-11-02  |  17.5 KB  |  764 lines

  1. package Autodoc::DumpDocs;
  2.  
  3. ###############################################################################
  4. ###############################################################################
  5. ##
  6. ##    Written by Adam Swift (c) 1995 by Friday Software and Consulting
  7. ##                           All rights reserved.
  8. ##
  9. ##      This notice may not be removed from this source code.
  10. ##
  11. ##    This program is included in the MiscKit by permission from the author
  12. ##    and its use is governed by the MiscKit license, found in the file
  13. ##    "LICENSE.rtf" in the MiscKit distribution.  Please refer to that file
  14. ##    for a list of all applicable permissions and restrictions.
  15. ##
  16. ##    Because AutoDoc is licensed free of charge, there is no warranty 
  17. ##    for the program.  Copyright holder, Friday Software and Consulting, 
  18. ##    is providing this program "as is" and this program is distributed in 
  19. ##    the hope that it will be useful, but WITHOUT ANY WARRANTY; without 
  20. ##    even the implied warranty of MERCHANTABILITY or FITNESS FOR A 
  21. ##    PARTICULAR PURPOSE.
  22. ##
  23. ###############################################################################
  24. ###############################################################################
  25.  
  26. require 5.000;
  27. require "flush.pl";
  28.  
  29. ##########################
  30. # load required packages #
  31. ##########################
  32. use Exporter;
  33. use Autodoc::GenerateRTF;
  34. use Autodoc::LogDebug;
  35. use Autodoc::ReadSource;
  36.  
  37. @ISA      = qw(Exporter);
  38. @EXPORT   = qw(dump_documentation
  39.                set_copyrightowner
  40.                copyrightowner
  41.                set_usetimestamp
  42.                usetimestamp
  43.                doc_bold_words
  44.                doc_italic_words
  45.               );
  46.  
  47. $module_version = '$Revision: 1.3 $';
  48. $module_version =~ s!(\$\w+: | \$)!!g;
  49. $module_id        = '$Id: DumpDocs.pm,v 1.3 1995/10/20 22:16:25 aswift Exp $';
  50. $module_id      =~ s!(\$\w+: | \$)!!g;
  51. $module_name    = $module_id;
  52. $module_name    =~ s!^([^\,]+).*$!$1!;
  53.  
  54. ############################################################################
  55. # Purpose: Module that encapsulates the creation of documentation from the
  56. #          source code parsed with autodoc.
  57. #
  58. # HISTORY: START
  59. # $Log: DumpDocs.pm,v $
  60. # Revision 1.3  1995/10/20  22:16:25  aswift
  61. # Added DevMan style changes Log support
  62. #
  63. #
  64. # HISTORY: END
  65. ############################################################################
  66. #
  67. # GLOBAL VARIABLES THAT AFFECT DOCUMENTATION DUMP
  68. #
  69. #  $format_italicwords  The array of words to italicize in &format_paragraph
  70. #  $dump_rtf            If the documentation should produce RTF formatted docs.
  71. #
  72. #############################################################################
  73.  
  74.  
  75. #############################################################################
  76. #
  77. # NAME:       module_version
  78. #
  79. # ACTION:     returns the version number of this module
  80. #
  81. # RETURN:     the module version
  82. #
  83. #############################################################################
  84. sub module_version
  85. {
  86.     return $module_version;
  87. }
  88.  
  89. sub module_versionstamp
  90. {
  91.     return "$module_name (rev-$module_version)";
  92. }
  93.  
  94. #############################################################################
  95. #
  96. # Module variable access 
  97. #
  98. #############################################################################
  99. sub set_copyrightowner
  100. {
  101.     $copyrightowner = $_[0];
  102. }
  103.  
  104. sub copyrightowner
  105. {
  106.     return $copyrightowner 
  107.       if (defined($copyrightowner));
  108.     return "";
  109. }
  110.  
  111. sub set_usetimestamp
  112. {
  113.     $usetimestamp = $_[0];
  114. }
  115.  
  116. sub usetimestamp
  117. {
  118.     return $usetimestamp 
  119.       if (defined($usetimestamp)); 
  120.     return 0;
  121. }
  122.  
  123. sub doc_italic_words
  124.   {
  125.     return @format_italicwords
  126.       if (defined (@format_italicwords));
  127.     return ();
  128.   }
  129.  
  130. sub doc_bold_words
  131.   {
  132.     return ("self", "nil", "super", "id", "NULL");
  133.   }
  134.  
  135.  
  136. ###############################################################################
  137. #
  138. # DOCUMENTATION DUMPING TO OBJECT RTF FILE
  139. #
  140. #    Use the information scanned into the global object variables to create
  141. #  a Rich Text Formatted documentation file, in the directory specified by
  142. #  $dest_dir.
  143. #
  144.  
  145. #
  146. # Locate and write the documentation file for the object passed as the one
  147. # argument to this subroutine. 
  148. #
  149. sub dump_documentation
  150.   {
  151.     local ($obj_root, $obj_r, $opt_silent) = @_;
  152.     
  153.     $dump_rtf = 1;
  154.     
  155.     dblog (0, "Writing documentation for:\t$obj_root");
  156.     dblog (1, "Writing documentation to file: $obj_r");
  157.     
  158.     # open the documentation file
  159.     if (!open(DUMPFILE, ">$obj_r")) {
  160.       warn ("Can't open $obj_r: $!\n");
  161.       return 0;
  162.     } else {
  163.       if (!$opt_silent) {
  164.         print ("autodoc producing $obj_r ... ");
  165.         flush (STDOUT);
  166.       }
  167.     }
  168.     
  169.     # Header    
  170.     dump_header();
  171.     
  172.     # Body
  173.     dump_copyrightinfo();
  174.     dump_objectname();
  175.     dump_inheritsfrom_declaredin();
  176.     dump_classdescription()
  177.       if (!object_noobjectdefined());
  178.     dump_typedefs();
  179.     dump_defines();
  180.     dump_macros();
  181.     dump_functions();
  182.     dump_globals();
  183.     dump_instancevariables();
  184.     dump_methodtypes();
  185.     
  186.     dump_methods(1, object_classmethods())
  187.       if (object_classmethods());
  188.     dump_methods(0, object_instmethods())
  189.       if (object_instmethods());
  190.     
  191.     # Footer
  192.     dump_footer();    
  193.     
  194.     # close the docuentation file and message the user
  195.     close (DUMPFILE);
  196.     if (!$opt_silent) {
  197.       print ("done\n");
  198.     }
  199.     return 1;
  200. }                
  201.  
  202.  
  203. #
  204. # Dump the instance (or class) methods with full formatting, setup the 
  205. # format_italicwords so that the method documentaiton italicizes the 
  206. # arguments to the method.
  207. #
  208. sub dump_methods
  209.   {
  210.     local ($class_meth) = shift (@_);
  211.     local (@o_methods) = @_;
  212.     local ($index, $meth, $methname);
  213.     
  214.     if ($class_meth) {
  215.       dump_majorheading ("Class Methods");
  216.     } else {
  217.       dump_majorheading ("Instance Methods");
  218.     }
  219.  
  220.     @o_methods = sort bymethodname @o_methods;
  221.     
  222.     for ($index = 0; $index < @o_methods; $index ++) {
  223.       if ($dump_rtf) {
  224.         dump_line (rtf_newline_small(3))
  225.           if ($index);
  226.       }
  227.       $meth = $o_methods[$index];
  228.       if ($class_meth) {
  229.         $methname = "+";
  230.       } else {
  231.         $methname = "-";
  232.       }
  233.       $methname .= extract_methodname ($meth);
  234.       dump_method ($meth, $methname);
  235.     }
  236.   }
  237.  
  238.  
  239. #
  240. # dump a formatted method with documentation
  241. #
  242. sub dump_method
  243.   {
  244.     local ($meth, $methname, $methname_raw, $methtype, $f_method, $i_words);
  245.     local (%o_methoddocs);
  246.     
  247.     $meth          = $_[0];        # the full method declaration 
  248.     $methname      = $_[1];        # the abbrv. unique name
  249.     $methname      =~ m/^([\+\-])/;
  250.     $methname_raw = $';            # methname_raw is methname w/o + or -
  251.     $meth          = $1 . $meth;    # prepend the + or - onto the method name
  252.     
  253.     if ($dump_rtf) {
  254.       # write the raw methodname (no args or type info)
  255.       dump_paragraph(rtf_setfont_helvetica() . rtf_boldify($methname_raw));
  256.  
  257.       ($f_method, $i_words) = rtf_format_method ($meth);
  258.  
  259.       # write the formatted method with args and type info
  260.       dump_line (rtf_setfont_times() . rtf_newline_micro());
  261.       dump_methodline ($f_method);
  262.     }
  263.  
  264.     # set up the italic words for dumping the description documentation 
  265.     if ($i_words) {
  266.       @format_italicwords = split (" ", $i_words);
  267.     } else {
  268.       @format_italicwords = ();
  269.     }
  270.  
  271.     # dump the method documentation
  272.     %o_methoddocs = object_methoddocs();
  273.     if (defined($o_methoddocs{$methname}) && 
  274.         $o_methoddocs{$methname} ne "") {
  275.       
  276.       dump_paragraph ($o_methoddocs{$methname});
  277.     } else {
  278.       dump_paragraph ("No method description.");
  279.     }
  280.     @format_italicwords = ();
  281.   }
  282.  
  283.  
  284. #
  285. # Dump the formatted method names with block names before the methods they
  286. # were assigned to.
  287. #
  288. sub dump_methodtypes
  289.   {
  290.     local ($index);
  291.     local ($methname, $methname_raw, $methtype, $block);
  292.     local (@o_methodnames, %o_methodblocks);
  293.     
  294.     @o_methodnames = object_methodnames();
  295.     return 
  296.       if (scalar(@o_methodnames) == 0);
  297.     %o_methodblocks = object_methodblocks();
  298.     
  299.     dump_majorheading ("Method Types");
  300.     dump_keyvalue();
  301.  
  302.     for ($index=0; $index < @o_methodnames; $index++) {
  303.       $methname = $o_methodnames[$index];
  304.       
  305.       # If there is a method block assigned to this method
  306.       if (($block = $o_methodblocks{$methname})) {
  307.         dump_line (rtf_newline_small())
  308.           if ($dump_rtf && $index > 0);
  309.         dump_string ("$block");
  310.         
  311.         # long block names push methods to the next line
  312.         if (length($block) > 30) {
  313.           dump_string (rtf_newline());
  314.         } 
  315.       } 
  316.       $methname_raw = $methname;
  317.       $methname_raw =~ s/^([\+\-])//;
  318.       $methtype = $1;
  319.  
  320.       if ($dump_rtf) {
  321.         if ($methtype eq "-") {
  322.           dump_line ("\t" . rtf_emdash . " $methname_raw" . rtf_newline());
  323.         } else {
  324.           dump_line ("\t+ $methname_raw" . rtf_newline());
  325.         }
  326.       }
  327.     }
  328.   }
  329.  
  330.  
  331. sub dump_defines
  332.   {
  333.     local ($title, @names, %docs, %values, $fmt_expr);
  334.     
  335.     $title      = "Symbolic Constants";
  336.     @names      = object_defines();
  337.     %docs      = object_definedocs();
  338.     %values      = object_definevals();
  339.     $fmt_expr = 's!(.*)!\\\b $1\\\b0!'
  340.       if ($dump_rtf);
  341.     dump_synopsis_description (*title, *names, *docs, *values, $fmt_expr);
  342.   }
  343.  
  344.  
  345. sub dump_macros
  346.   {
  347.     local ($title, @names, %docs, %values, $fmt_expr);
  348.     
  349.     $title       = "Macro Definitions";
  350.     @names       = object_macros();
  351.     %docs       = object_macrodocs();
  352.     %values       = {};
  353.     $fmt_expr = 's!(\\S+\\s*\\()([^\\(]*)\\)$!\\\b $1\\\b0$2\\\b \)\\\b0!'
  354.       if ($dump_rtf);
  355.     dump_synopsis_description (*title, *names, *docs, *values, $fmt_expr);
  356.   }
  357.  
  358.  
  359. sub dump_functions
  360.   {
  361.     local ($title, @names, %docs, %values, $fmt_expr);
  362.     
  363.     $title       = "Functions";
  364.     @names       = object_functions();
  365.     %docs       = object_functiondocs();
  366.     %values       = {};
  367.     $fmt_expr = 's!(\\S+\\s*\\()([^\\(]*)\\)$!\\\b $1\\\b0$2\\\b \)\\\b0!'
  368.       if ($dump_rtf);
  369.     dump_synopsis_description (*title, *names, *docs, *values, $fmt_expr);
  370.   }
  371.  
  372.  
  373. sub dump_globals
  374.   {
  375.     local ($title, @names, %docs, %values, $fmt_expr);
  376.     
  377.     $title      = "Global Variables";
  378.     @names      = object_globals();
  379.     %docs      = object_globaldocs();
  380.     %values      = {};
  381.     $fmt_expr = 's!(\\S+)\\;$!\\\b $1\\\b0\\;!'
  382.       if ($dump_rtf);
  383.     dump_synopsis_description (*title, *names, *docs, *values, $fmt_expr);
  384.   }
  385.  
  386.  
  387. sub dump_typedefs
  388.   {
  389.     local ($title, @names, %docs, %values, $fmt_expr);
  390.     
  391.     $title      = "Defined Types";
  392.     @names      = object_typedefs();
  393.     %docs      = object_typedefdocs();
  394.     %values      = object_typedefvals();
  395.     $fmt_expr = 's!(.*)!\\\b $1\\\b0!'
  396.       if ($dump_rtf);
  397.     dump_synopsis_description (*title, *names, *docs, *values, $fmt_expr);
  398.   }
  399.  
  400.  
  401. sub dump_synopsis_description
  402.   {
  403.     local (*title, *names, *docs, *values) = @_;
  404.     local ($docs, $value, $show_synopsis, $name_expr);
  405.     local ($i, $max, $name);
  406.  
  407.     return 
  408.       if (!scalar(@names));
  409.  
  410.     # check for the special 4th argument - the executable formatting string
  411.     $name_expr = ""
  412.       if ((scalar(@_) < 5) || (($name_expr = $_[4]) eq ""));
  413.     
  414.     dump_majorheading($title);
  415.     
  416.     $show_synopsis = 1;
  417.     $show_docs       = 0;
  418.     $docs           = "";
  419.     $max           = scalar (@names);
  420.     
  421.     for ($i = 0; $i < $max; $i++) {
  422.       $name = $names[$i];
  423.       
  424.       if (defined($values{$name})) {
  425.         local ($valline, @valarray, $indent);
  426.  
  427.         $value = "$values{$name}";
  428.  
  429.         # reformat special characters to preserve them in the output
  430.         if ($dump_rtf) {
  431.           $value =~ s!([\{\}])!\\$1!g;
  432.           $value =~ s!\n!\\\n\t!g;
  433.  
  434.           $value = " $value "; # add extra spaces to help matching
  435.           $value =~ s!(\W)$name(\W)!$1\\b $name\\b0$2!;
  436.           $value =~ s!^ | $!!g; # remove the extra spaces
  437.  
  438.           # do some fancy indentation on the value (if curlies are there)
  439.           if ($value =~ m!\{!) {
  440.             $indent = "";
  441.             @valarray = split(m!\n!, $value);
  442.  
  443.             # for each line in the value, add indents to the approriate level
  444.             foreach $valline (@valarray) {
  445.               $indent =~ s!\t!!
  446.                 if ($valline =~ m!\}!);
  447.               $valline = "$indent$valline"
  448.                 if ($indent =~ m!\t!);
  449.               
  450.               if ($valline =~ m!\{!) {
  451.                 $indent = "\t$indent";
  452.                 $valline =~ s!\{\s*(\S+)!\{$indent$1!;
  453.               }
  454.             }
  455.             $value = join("\n", @valarray);
  456.           }
  457.         }          
  458.       } else {
  459.         $value = "";
  460.       }
  461.       
  462.       if ($show_synopsis) {
  463.         dump_minorheading("SYNOPSIS");
  464.         dump_synopsis();
  465.         $show_synopsis = 0;
  466.       }
  467.       if ($name_expr ne "") {
  468.         local ($fname) = $name;
  469.         # dblog(-5, "expr = $name_expr");
  470.         eval ("\$fname =~ $name_expr");
  471.         warn ("Error formatting names: $@")
  472.           if ($@ ne "");
  473.         dump_line ("$fname\t$value" . rtf_newline())
  474.           if ($dump_rtf);
  475.       } else {
  476.         dump_line ("$name\t$value" . rtf_newline())
  477.           if ($dump_rtf);
  478.       }
  479.       
  480.       $show_docs = 1
  481.         if (($i == ($max - 1)) || defined($docs{$names[$i+1]}));
  482.       $docs = "$docs{$name}"
  483.         if (defined($docs{$name}));
  484.       
  485.       if (($docs ne "") && ($show_docs == 1)) {
  486.         dump_line (rtf_newline_small())
  487.           if ($dump_rtf);
  488.         dump_minorheading("DESCRIPTION");
  489.         dump_paragraph ($docs);
  490.         dump_line (rtf_newline_small(2))
  491.           if ($dump_rtf && ($i != ($max - 1)));
  492.         $show_docs = 0;
  493.         $show_synopsis = 1;
  494.       }
  495.     }
  496.   }
  497.  
  498.  
  499. #
  500. # Dump the instance variables and their descriptions to the documentation file
  501. # descriptions are formatted by format_words
  502. #
  503. sub dump_instancevariables
  504.   {
  505.     my ($ivar, $lastivar, $docs);
  506.     my (@o_ivars, %o_ivartypes, %o_ivardocs);
  507.     my ($ivar_out) = "";
  508.     
  509.     @o_ivars = object_ivars();
  510.     return 
  511.       if (scalar(@o_ivars) == 0);
  512.     
  513.     %o_ivartypes = object_ivartypes();
  514.     %o_ivardocs  = object_ivardocs();
  515.     
  516.     dump_majorheading ("Instance Variables");
  517.  
  518.     # output ivar type list
  519.     if ($dump_rtf) {
  520.       foreach $ivar (@o_ivars) {
  521.         $ivar_out .= $o_ivartypes{$ivar} . rtf_boldify($ivar) . ";";
  522.         $ivar_out .= rtf_newline();
  523.       }
  524.       dump_paragraph ($ivar_out);
  525.  
  526.       # output ivar description list
  527.       dump_line (rtf_newline_small(2));
  528.       $lastivar = $o_ivars[$#o_ivars];
  529.       foreach $ivar (@o_ivars) {
  530.         $docs = rtf_format_words ($o_ivardocs{$ivar});
  531.         dump_keyvalue ("$ivar\t$docs");
  532.         dump_line (rtf_newline_small())
  533.           if ($ivar ne $lastivar);
  534.       }
  535.     }
  536.   }
  537.  
  538.  
  539. #
  540. # Dump the formatted class description to the docs.  Boldify any instance
  541. # variables or methods that appear in the description
  542. #
  543. sub dump_classdescription
  544.   {
  545.     # Problem here may be that both an obj and category are defined
  546.     # in the same .m file.  Maybe figuring out how to dump two
  547.     # seperate .rtf files would be optimal, but until then we should
  548.     # allow for both to be included in the same .m and thus .rtf.
  549.     dump_majorheading ("Class Description") 
  550.       if (object_inherits());
  551.     dump_majorheading ("Protocol Description")
  552.       if (object_protocol());
  553.     dump_majorheading ("Category Description") 
  554.       if (object_category());
  555.  
  556.     dump_paragraph (object_classdocs());
  557.   }
  558.  
  559. #
  560. # dump the formatting and text necessary to put the inheritance and
  561. # declaration location in the docs
  562. # This has been expanded to allow categories...
  563. #
  564. sub dump_inheritsfrom_declaredin
  565.   {
  566.     my ($o_name) = object_name();
  567.     my ($o_inh)     = object_inherits();
  568.     my ($o_cat)     = object_category();
  569.     my ($o_decl) = object_declaredin();
  570.     my (@o_conf) = object_conformsto();
  571.     
  572.     if (object_noobjectdefined()) {
  573.       dump_subtitle ("Resource Collection");
  574.     } else {
  575.       if ($o_inh) {
  576.         if ($o_inh =~ m!^none$!) {
  577.           $o_inh .= rtf_italicize(" ($o_name is a root class)")
  578.             if ($dump_rtf);
  579.         }
  580.         dump_subtitle ("Inherits From:", $o_inh);
  581.       } else {
  582.         dump_subtitle ("Category Name:", $o_cat)
  583.           if ($o_cat);
  584.       }
  585.       
  586.       dump_subtitle ("Conforms To:", @o_conf)
  587.         if (scalar (@o_conf) > 0);
  588.     }
  589.     dump_subtitle ("Declared In:", $o_decl);
  590.   }
  591.  
  592.  
  593. #
  594. # dump the formatting and text necessary to put the copyright info in the docs
  595. #
  596. sub dump_copyrightinfo
  597.   {
  598.     my ($head)          = "";
  599.     my ($timestamp)      = "";
  600.     my ($copyright)      = "";
  601.     my ($bycopyowner) = "";
  602.     my ($o_version)      = "";
  603.  
  604.     $timestamp = scalar (localtime (time ()))
  605.       if (usetimestamp());
  606.     $bycopyowner .= " by " . copyrightowner()
  607.       if (copyrightowner());
  608.     $o_version = object_version() . " "
  609.       if (object_version());
  610.  
  611.     if ($dump_rtf) {
  612.       $copyright = rtf_copyright() . " ";
  613.       $timestamp = rtf_italicize($timestamp);
  614.     }
  615.     
  616.     $head = $o_version . "Copyright " . $copyright . object_year();
  617.     $head .= $bycopyowner . " All Rights Reserved.  " . $timestamp;
  618.  
  619.     if ($dump_rtf) {
  620.       dump_line (rtf_head($head));
  621.     }
  622.   }
  623.  
  624.  
  625. #
  626. # Compares the methods passed in $a and $b for alphabetical sorting, ignoring
  627. # the typecasting
  628. #
  629. sub bymethodname
  630.   {
  631.     local ($one, $two);
  632.     if ($a =~/^\([^\)]+\)\s*/) {
  633.       $one = $';
  634.     } else {
  635.       $one = $a;
  636.     }
  637.     if ($b =~/^\([^\)]+\)\s*/) {
  638.       $two = $';
  639.     } else {
  640.       $two = $b;
  641.     }
  642.     return $one cmp $two;
  643.   }
  644.  
  645.  
  646. #
  647. # Write out all the arguments to the DUMPFILE and finish it off with a newline
  648. #
  649. sub dump_line
  650.   {
  651.     local ($buffer);
  652.     foreach $buffer (@_) {
  653.       print DUMPFILE ("$buffer");
  654.     }
  655.     print DUMPFILE ("\n");
  656.   }
  657.  
  658.  
  659. #
  660. # Write out all the arguments to the DUMPFILE 
  661. #
  662. sub dump_string
  663.   {
  664.     local ($buffer);
  665.     foreach $buffer (@_) {
  666.       print DUMPFILE ("$buffer");
  667.     }
  668.   }
  669.  
  670.  
  671. #
  672. # Dump the standard spacer to the docs
  673. #
  674. sub dump_spacer
  675.   {
  676.     if ($dump_rtf) {
  677.       dump_line (rtf_spacer());
  678.     }
  679.   }
  680.  
  681.  
  682. #
  683. # Write the file header, to start the documentation file.
  684. #
  685. sub dump_header
  686.   {
  687.     if ($dump_rtf) {
  688.       dump_line (rtf_fileheader());
  689.       dump_line (rtf_fonttable());
  690.       dump_line (rtf_stylesheet());
  691.     }
  692.   }
  693.  
  694. #
  695. # Write the file footer, to terminate the documentation file
  696. #
  697. sub dump_footer
  698.   {
  699.     if ($dump_rtf) {
  700.       dump_line (rtf_filefooter());
  701.     }
  702.   }
  703.  
  704.  
  705. #
  706. # dump the formatting and text necessary to put the object name in the docs
  707. #
  708. sub dump_objectname
  709.   {
  710.     dump_line (rtf_title (object_name()))
  711.       if ($dump_rtf);
  712.   }
  713.  
  714.  
  715. sub dump_majorheading
  716.   {
  717.     dump_line (rtf_majorheading (@_))
  718.       if ($dump_rtf);
  719.   }
  720.  
  721.  
  722. sub dump_minorheading
  723.   {
  724.     dump_line (rtf_minorheading (@_))
  725.       if ($dump_rtf);
  726.   }
  727.  
  728.  
  729. sub dump_subtitle
  730.   {
  731.     dump_line (rtf_subtitle (@_))
  732.       if ($dump_rtf);
  733.   }
  734.  
  735.  
  736. sub dump_paragraph
  737.   {
  738.     dump_line (rtf_paragraph (@_))
  739.       if ($dump_rtf);
  740.   }
  741.  
  742.  
  743. sub dump_synopsis
  744.   {
  745.     dump_line (rtf_synopsis (@_))
  746.       if ($dump_rtf);
  747.   }
  748.  
  749. sub dump_keyvalue
  750.   {
  751.     dump_line (rtf_keyvalue (@_))
  752.       if ($dump_rtf);
  753.   }
  754.  
  755. sub dump_methodline
  756.   {
  757.     dump_line (rtf_methodline (@_))
  758.       if ($dump_rtf);
  759.   }
  760.  
  761.  
  762. 1;
  763.