From 3263d0d7c4052307ce38f342800197dec5a3fba0 Mon Sep 17 00:00:00 2001
From: Alexander (#4004)
According to FB2 XML schema . Linux FBReader can't display such paragraphs, e.g. any "loose"
lists produced by pandoc prior to this commit. Besides that,
FB2 writer placed inside when writing nested lists,
this commit fixes the bug.
Also this commit removes leading non-breaking space from ordered
lists for consistency with bullet lists.
Definition lists are not affected at all.
---
test/fb2/basic.fb2 | 2 +-
test/writer.fb2 | 168 +++++++++++++++++++++++++++--------------------------
2 files changed, 87 insertions(+), 83 deletions(-)
(limited to 'test')
diff --git a/test/fb2/basic.fb2 b/test/fb2/basic.fb2
index ffb2bfbdf..ff1c65c11 100644
--- a/test/fb2/basic.fb2
+++ b/test/fb2/basic.fb2
@@ -1,3 +1,3 @@
- Top-level title Section Subsection This Ordered list: 1. one 2. two 3. three Blockquote is for citatons. Math is another Pandoc extension: 1 2 Sometimes. Top-level title Section Subsection This Ordered list: 1. one 2. two 3. three Blockquote is for citatons. Math is another Pandoc extension: 1 2 Sometimes. A list: 1. item one 2. item two 1. item one 2. item two Nested block quotes: nested • asterisk 2 • asterisk 3 Asterisks loose: • asterisk 1 • asterisk 2 • asterisk 3 • asterisk 1 • asterisk 2 • asterisk 3 Pluses tight: • Plus 1 • Plus 2 • Plus 3 Pluses loose: • Plus 1 • Plus 2 • Plus 3 • Plus 1 • Plus 2 • Plus 3 Minuses tight: • Minus 1 • Minus 2 • Minus 3 Minuses loose: • Minus 1 • Minus 2 • Minus 3 • Minus 1 • Minus 2 • Minus 3 Ordered Tight: 1. First 2. Second 3. Third 1. First 2. Second 3. Third and: 1. One 2. Two 3. Three 1. One 2. Two 3. Three Loose using tabs: 1. First 2. Second 3. Third 1. First 2. Second 3. Third and using spaces: 1. One 2. Two 3. Three 1. One 2. Two 3. Three Multiple paragraphs: 1. Item 1, graf one. 2. Item 2. 3. Item 3. 1. Item 1, graf one. Item 1. graf two. The quick brown fox jumped over the lazy dog’s back. 2. Item 2. 3. Item 3. Nested • Tab ◦ Tab * Tabverbatim
markdown. See this link[1].Code
block
is
for
code.
E = m c^2
.http://example.com/
verbatim
markdown. See this link[1].Code
block
is
for
code.
E = m c^2
.http://example.com/
• Tab
+◦ Tab
+* Tab
Here’s another:
-1. First
-2. Second:
• Fee
+1. First
+2. Second:
+• Fee
• Fie
• Foe
- -3. Third
+3. Third
Same thing but with paragraphs:
- 1. First
2. Second:
1. First
+2. Second:
+• Fee
• Fie
• Foe
- - 3. Third
3. Third
+Tabs and spaces
• this is a list item indented with tabs
• this is a list item indented with spaces
◦ this is an example list item indented with tabs
◦ this is an example list item indented with spaces
• this is a list item indented with tabs
+• this is a list item indented with spaces
+◦ this is an example list item indented with tabs
+◦ this is an example list item indented with spaces
+Fancy list markers
(2) begins with 2
- (3) and now 3
(3) iv. sublist with roman numerals, starting with 4
-(3) v. more items
(3) v. (A) a subsublist
-(3) v. (B) a subsublist
- - +(2) begins with 2
+(3) and now 3
+with a continuation
+(3) iv. sublist with roman numerals, starting with 4
+(3) v. more items
+(3) v. (A) a subsublist
+(3) v. (B) a subsublist
Nesting:
-A. Upper Alpha
A. I. Upper Roman.
A. I. (6) Decimal start with 6
A. I. (6) c) Lower alpha with paren
- - - +A. Upper Alpha
+A. I. Upper Roman.
+A. I. (6) Decimal start with 6
+A. I. (6) c) Lower alpha with paren
Autonumbering:
-1. Autonumber.
-2. More.
2. 1. Nested.
- +1. Autonumber.
+2. More.
+2. 1. Nested.
Should not be a list item:
M.A. 2007
B. Williams
@@ -427,8 +431,8 @@ orange orange fruit
1. sublist
-2. sublist
+1. sublist
+2. sublist
1. And in list items.
+ 1. And in list items.
[32]