git.iko.soy/typeable/pandoc
on master help sign in
Org reader: Added state changing blanklines.

This allows us to emphasize at the beginning of a new paragraph (or, in general, after blank lines).

commit73b887e2df06476bda567223f13d41bb34586f64 authorJesse Rosenthal <jrosenthal@jhu.edu> dateThu 4 Sep 2014, 01:53 (12 years ago) parent08359c4
1 file changed+8−1
src/Text/Pandoc/Readers/Org.hs+8−1
src/Text/Pandoc/Readers/Org.hs+8−1
@@ -37,7 +37,7 @@ import Text.Pandoc.Options
3737import qualified Text.Pandoc.Parsing as P
3838import Text.Pandoc.Parsing hiding ( F, unF, askF, asksF, runF
3939 , newline, orderedListMarker
40− , parseFromString
40+ , parseFromString, blanklines
4141 )
4242import Text.Pandoc.Readers.LaTeX (inlineCommand, rawLaTeXInline)
4343import Text.Pandoc.Shared (compactify', compactify'DL)
@@ -242,6 +242,13 @@ newline =
242242 <* updateLastPreCharPos
243243 <* updateLastForbiddenCharPos
244244
245+-- | Like @Text.Parsec.Char.blanklines@, but causes additional state changes.
246+blanklines :: OrgParser [Char]
247+blanklines =
248+ P.blanklines
249+ <* updateLastPreCharPos
250+ <* updateLastForbiddenCharPos
251+
245252--
246253-- parsing blocks
247254--