From d23fdb8a69c4d797c5ab71a3203ec782264431e9 Mon Sep 17 00:00:00 2001 From: Jess Robinson Date: Tue, 6 Mar 2012 21:37:27 +0000 Subject: [PATCH] Now straighten out tables after the blankline changes --- src/Text/Pandoc/Writers/PseudoPod.hs | 4 +- tests/tables.pod | 80 ---------------------------- 2 files changed, 2 insertions(+), 82 deletions(-) diff --git a/src/Text/Pandoc/Writers/PseudoPod.hs b/src/Text/Pandoc/Writers/PseudoPod.hs index 6070562432c4..753407f3c95f 100644 --- a/src/Text/Pandoc/Writers/PseudoPod.hs +++ b/src/Text/Pandoc/Writers/PseudoPod.hs @@ -225,8 +225,8 @@ blockToPseudoPod opts (Table caption _ _ headers rows) = do headers' <- mapM (blockListToPseudoPod opts) headers rawRows <- mapM (mapM (blockListToPseudoPod opts)) rows - let makeRow = hcat . intersperse (text("\n=cell ")) - let makeRowBlock = hcat . intersperse (text("\n=row\n\n=cell ")) + let makeRow = hcat . intersperse (text("\n\n=cell ")) + let makeRowBlock = hcat . intersperse (text("\n\n=row\n\n=cell ")) let rows' = map makeRow rawRows let rows'' = makeRowBlock rows' diff --git a/tests/tables.pod b/tests/tables.pod index 6e990a5274e2..f5e94397402d 100644 --- a/tests/tables.pod +++ b/tests/tables.pod @@ -10,13 +10,10 @@ Simple table with caption: =cell Right - =cell Left - =cell Center - =cell Default =bodyrows @@ -25,41 +22,30 @@ Simple table with caption: =cell 12 - =cell 12 - =cell 12 - =cell 12 - =row =cell 123 - =cell 123 - =cell 123 - =cell 123 - =row =cell 1 - =cell 1 - =cell 1 - =cell 1 =end table @@ -74,13 +60,10 @@ Simple table without caption: =cell Right - =cell Left - =cell Center - =cell Default =bodyrows @@ -89,41 +72,30 @@ Simple table without caption: =cell 12 - =cell 12 - =cell 12 - =cell 12 - =row =cell 123 - =cell 123 - =cell 123 - =cell 123 - =row =cell 1 - =cell 1 - =cell 1 - =cell 1 =end table @@ -138,13 +110,10 @@ Simple table indented two spaces: =cell Right - =cell Left - =cell Center - =cell Default =bodyrows @@ -153,41 +122,30 @@ Simple table indented two spaces: =cell 12 - =cell 12 - =cell 12 - =cell 12 - =row =cell 123 - =cell 123 - =cell 123 - =cell 123 - =row =cell 1 - =cell 1 - =cell 1 - =cell 1 =end table @@ -202,13 +160,10 @@ Multiline table with caption: =cell Centered Header - =cell Left Aligned - =cell Right Aligned - =cell Default aligned =bodyrows @@ -217,27 +172,20 @@ Multiline table with caption: =cell First - =cell row - =cell 12.0 - =cell Example of a row that spans multiple lines. - =row =cell Second - =cell row - =cell 5.0 - =cell Here's another one. Note the blank line between rows. =end table @@ -252,13 +200,10 @@ Multiline table without caption: =cell Centered Header - =cell Left Aligned - =cell Right Aligned - =cell Default aligned =bodyrows @@ -267,27 +212,20 @@ Multiline table without caption: =cell First - =cell row - =cell 12.0 - =cell Example of a row that spans multiple lines. - =row =cell Second - =cell row - =cell 5.0 - =cell Here's another one. Note the blank line between rows. =end table @@ -302,41 +240,30 @@ Table without column headers: =cell 12 - =cell 12 - =cell 12 - =cell 12 - =row =cell 123 - =cell 123 - =cell 123 - =cell 123 - =row =cell 1 - =cell 1 - =cell 1 - =cell 1 =end table @@ -351,27 +278,20 @@ Multiline table without column headers: =cell First - =cell row - =cell 12.0 - =cell Example of a row that spans multiple lines. - =row =cell Second - =cell row - =cell 5.0 - =cell Here's another one. Note the blank line between rows. =end table