- Timestamp:
- 09/28/07 13:39:45 (16 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
lang/perl/Text-Nyarlax/trunk/lib/Text/Nyarlax/Parser/PRD.pm
r278 r295 88 88 <rulevar: local $h_level = 1 > 89 89 90 parse : <skip: ''> /\n*/ Content(s) 90 parse : <skip: ''> Root 91 { $return = $item{'Root'} } 92 93 Root : /\n*/ Content(s) 91 94 { 92 95 my $tree = $item{'Content(s)'}; … … 103 106 | Paragraph 104 107 105 Section : Heading Content(s?)108 Section : Heading Root(?) 106 109 { 107 110 $h_level--; 108 111 my $elm = element( $item[0] ); 109 $elm->push_content( $item{'Heading'}, @{ $item{'Content(s?)'} } ); 110 $elm->join_content( element => 'Section' ); 112 $elm->push_content( $item{'Heading'}, @{ flatten($item{'Root(?)'}) } ); 111 113 $return = $elm; 112 114 } … … 197 199 198 200 BlockQuote : />>>/ Blank Text(?) Blank /\n/ 199 Content(s)201 Root 200 202 /<<</ Blank URI(?) Blank /\n/ 201 203 { 202 204 my $elm = element( $item[0] ); 203 $elm->push_content( @{ $item{'Content(s)'} } ); 204 $elm->join_content( element => 'Section' ); 205 $elm->push_content( @{ $item{'Root'} } ); 205 206 $elm->attr->{'title'} = $item{'Text(?)'}->[0] if ( $item{'Text(?)'}->[0] ); 206 207 $elm->attr->{'cite'} = $item{'URI(?)'}->[0] if ( $item{'URI(?)'}->[0] ); … … 208 209 } 209 210 210 BlockNotes : /[(]{3}\n/ Content(s) /[)]{3}\n/ 211 { 212 my $elm = element( $item[0] ); 213 $elm->push_content( @{ $item{'Content(s)'} } ); 214 $elm->join_content( element => 'Section' ); 211 BlockNotes : /[(]{3}\n/ Root /[)]{3}\n/ 212 { 213 my $elm = element( $item[0] ); 214 $elm->push_content( @{ $item{'Root'} } ); 215 215 $return = $elm; 216 216 }
![(please configure the [header_logo] section in trac.ini)](/share/chrome/site/your_project_logo.png)