1# supertabular.perl by Denis Koelewijn 2# 3# Extension to LaTeX2HTML supply support for the "supertabular" 4# LaTeX style, as described in "The LaTeX Companion," by 5# Goossens, Mittelbach and Samarin (ISBN 0-201-54199-8). 6# 7# Change Log: 8# =========== 9 10package main; 11# 12# Translate the supertabular environment as 13# an ordinary table. 14# 15# 16 17sub do_env_supertabular { 18# local($_) = @_; 19# &process_environment("tabular", $global{'max_id'}++); 20 &do_env_tabular(@_); 21 } 22 23sub do_cmd_tablecaption { 24 local($_) = @_; 25 local($contents); 26 local($cap_env, $captions, $cap_anchors) = ('table','',''); 27 $contents = &missing_braces unless ( 28 (s/$next_pair_pr_rx/$contents = $&;''/e) 29 ||(s/$next_pair_rx/$contents = $&;''/e)); 30 $contents = "\\caption". $contents; 31 &extract_captions; 32 $TABLE_CAPTION = $cap_anchors.$captions; 33 $_; 34} 35 36sub do_cmd_tablehead { 37 local($_) = @_; 38 local($text); 39 $text = &missing_braces unless ( 40 (s/$next_pair_pr_rx/$text = $2;''/e) 41 ||(s/$next_pair_rx/$text = $2;''/e)); 42 $TABLE_TITLE_TEXT = $text unless ($TABLE_TITLE_TEXT); 43 $_; 44} 45 46sub do_cmd_tablefirsthead { 47 local($_) = @_; 48 local($text); 49 $text = &missing_braces unless ( 50 (s/$next_pair_pr_rx/$text = $2;''/e) 51 ||(s/$next_pair_rx/$text = $2;''/e)); 52 $TABLE_TITLE_TEXT = $text; 53 $_; 54} 55 56sub do_cmd_tabletail { 57 local($_) = @_; 58 local($text); 59 $text = &missing_braces unless ( 60 (s/$next_pair_pr_rx/$text = $2;''/e) 61 ||(s/$next_pair_rx/$text = $2;''/e)); 62 $TABLE_TAIL_TEXT = $text unless ($TABLE_TAIL_TEXT); 63 $_; 64} 65 66sub do_cmd_tablelasttail { 67 local($_) = @_; 68 local($text); 69 $text = &missing_braces unless ( 70 (s/$next_pair_pr_rx/$text = $2;''/e) 71 ||(s/$next_pair_rx/$text = $2;''/e)); 72 $TABLE_TAIL_TEXT = $text; 73 $_; 74} 75 76 77&process_commands_wrap_deferred( <<_RAW_ARG_CMDS_); 78tablecaption # {} 79tablehead # {} 80tabletail # {} 81tablefirsthead # {} 82tablelasttail # {} 83_RAW_ARG_CMDS_ 84 851; # This must be the last line 86 87 88 89