recursive_acronym.pl 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. use vars qw(%result_texis %result_texts %result_trees %result_errors
  2. %result_indices %result_sectioning %result_nodes %result_menus
  3. %result_floats %result_converted %result_converted_errors
  4. %result_elements %result_directions_text);
  5. use utf8;
  6. $result_trees{'recursive_acronym'} = {
  7. 'contents' => [
  8. {
  9. 'contents' => [
  10. {
  11. 'args' => [
  12. {
  13. 'contents' => [
  14. {
  15. 'parent' => {},
  16. 'text' => 'GNU'
  17. }
  18. ],
  19. 'parent' => {},
  20. 'type' => 'brace_command_arg'
  21. },
  22. {
  23. 'contents' => [
  24. {
  25. 'parent' => {},
  26. 'text' => ' ',
  27. 'type' => 'empty_spaces_before_argument'
  28. },
  29. {
  30. 'args' => [
  31. {
  32. 'contents' => [
  33. {
  34. 'parent' => {},
  35. 'text' => 'GNU'
  36. }
  37. ],
  38. 'parent' => {},
  39. 'type' => 'brace_command_arg'
  40. }
  41. ],
  42. 'cmdname' => 'acronym',
  43. 'contents' => [],
  44. 'extra' => {
  45. 'brace_command_contents' => [
  46. [
  47. {}
  48. ]
  49. ],
  50. 'explanation_contents' => []
  51. },
  52. 'line_nr' => {
  53. 'file_name' => '',
  54. 'line_nr' => 1,
  55. 'macro' => ''
  56. },
  57. 'parent' => {}
  58. },
  59. {
  60. 'parent' => {},
  61. 'text' => '\'s Not Unix'
  62. }
  63. ],
  64. 'parent' => {},
  65. 'type' => 'brace_command_arg'
  66. }
  67. ],
  68. 'cmdname' => 'acronym',
  69. 'contents' => [],
  70. 'extra' => {
  71. 'brace_command_contents' => [
  72. [
  73. {}
  74. ],
  75. [
  76. {},
  77. {}
  78. ]
  79. ]
  80. },
  81. 'line_nr' => {},
  82. 'parent' => {}
  83. },
  84. {
  85. 'parent' => {},
  86. 'text' => '
  87. '
  88. }
  89. ],
  90. 'parent' => {},
  91. 'type' => 'paragraph'
  92. }
  93. ],
  94. 'type' => 'text_root'
  95. };
  96. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[0]{'contents'}[0]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[0];
  97. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[0]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0];
  98. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[0]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1];
  99. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1]{'args'}[0]{'contents'}[0]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1]{'args'}[0];
  100. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1]{'args'}[0]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1];
  101. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1]{'extra'}{'brace_command_contents'}[0][0] = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1]{'args'}[0]{'contents'}[0];
  102. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1];
  103. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[2]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1];
  104. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0];
  105. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'extra'}{'brace_command_contents'}[0][0] = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[0]{'contents'}[0];
  106. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'extra'}{'brace_command_contents'}[1][0] = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1];
  107. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'extra'}{'brace_command_contents'}[1][1] = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[2];
  108. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'line_nr'} = $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'args'}[1]{'contents'}[1]{'line_nr'};
  109. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[0]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0];
  110. $result_trees{'recursive_acronym'}{'contents'}[0]{'contents'}[1]{'parent'} = $result_trees{'recursive_acronym'}{'contents'}[0];
  111. $result_trees{'recursive_acronym'}{'contents'}[0]{'parent'} = $result_trees{'recursive_acronym'};
  112. $result_texis{'recursive_acronym'} = '@acronym{GNU, @acronym{GNU}\'s Not Unix}
  113. ';
  114. $result_texts{'recursive_acronym'} = 'GNU (GNU\'s Not Unix)
  115. ';
  116. $result_errors{'recursive_acronym'} = [];
  117. $result_converted{'plaintext'}->{'recursive_acronym'} = 'GNU (GNU\'s Not Unix)
  118. ';
  119. $result_converted{'html_text'}->{'recursive_acronym'} = '<p><acronym title="GNU&rsquo;s Not Unix">GNU</acronym> (<acronym>GNU</acronym>&rsquo;s Not Unix)
  120. </p>';
  121. 1;