kitabu 1.0.0.rc1 → 1.0.0.rc2
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile.lock +14 -20
- data/README.rdoc +54 -23
- data/kitabu.gemspec +1 -1
- data/lib/kitabu.rb +11 -4
- data/lib/kitabu/cli.rb +49 -6
- data/lib/kitabu/dependency.rb +19 -0
- data/lib/kitabu/exporter.rb +4 -5
- data/lib/kitabu/generator.rb +12 -15
- data/lib/kitabu/parser.rb +27 -2
- data/lib/kitabu/parser/epub.rb +96 -83
- data/lib/kitabu/parser/html.rb +51 -16
- data/lib/kitabu/parser/mobi.rb +1 -4
- data/lib/kitabu/parser/pdf.rb +23 -20
- data/lib/kitabu/parser/txt.rb +1 -5
- data/lib/kitabu/syntax.rb +5 -3
- data/lib/kitabu/syntax/highlight.rb +22 -0
- data/lib/kitabu/toc.rb +4 -78
- data/lib/kitabu/toc/epub.rb +41 -0
- data/lib/kitabu/toc/html.rb +78 -0
- data/lib/kitabu/version.rb +1 -1
- data/spec/kitabu/cli/export_spec.rb +2 -2
- data/spec/kitabu/cli/new_spec.rb +1 -1
- data/spec/kitabu/cli/permalinks_spec.rb +1 -1
- data/spec/kitabu/cli/version_spec.rb +1 -1
- data/spec/kitabu/extensions/redcloth_spec.rb +6 -6
- data/spec/kitabu/extensions/string_spec.rb +1 -1
- data/spec/kitabu/parser/epub_spec.rb +5 -1
- data/spec/kitabu/parser/html_spec.rb +15 -15
- data/spec/kitabu/parser/pdf_spec.rb +4 -4
- data/spec/kitabu/syntax_spec.rb +78 -74
- data/spec/kitabu/{toc_spec.rb → toc/html_spec.rb} +5 -5
- data/spec/spec_helper.rb +3 -1
- data/spec/support/mybook/output/mybook.pdf.html +83 -0
- data/spec/support/mybook/templates/{cover.erb → epub/cover.erb} +1 -1
- data/spec/support/mybook/templates/{epub.erb → epub/page.erb} +1 -1
- data/spec/support/mybook/templates/epub/style.css +0 -0
- data/spec/support/mybook/templates/html/layout.css +353 -0
- data/spec/support/mybook/templates/html/layout.erb +50 -0
- data/spec/support/mybook/templates/html/syntax.css +58 -0
- data/spec/support/mybook/templates/html/user.css +1 -0
- data/spec/support/shared.rb +48 -15
- data/templates/cover.erb +1 -1
- data/templates/cover.png +0 -0
- data/templates/epub.css +1 -0
- data/templates/epub.erb +1 -1
- data/templates/sample.md +6 -0
- data/templates/syntax.css +58 -0
- metadata +32 -44
- data/spec/support/mybook/templates/epub.css +0 -1
- data/spec/support/mybook/templates/layout.css +0 -137
- data/spec/support/mybook/templates/layout.erb +0 -46
- data/spec/support/mybook/templates/syntax.css +0 -186
- data/spec/support/mybook/templates/user.css +0 -1
- data/templates/styles/active4d.css +0 -114
- data/templates/styles/all_hallows_eve.css +0 -72
- data/templates/styles/amy.css +0 -147
- data/templates/styles/blackboard.css +0 -88
- data/templates/styles/brilliance_black.css +0 -605
- data/templates/styles/brilliance_dull.css +0 -599
- data/templates/styles/cobalt.css +0 -149
- data/templates/styles/dawn.css +0 -121
- data/templates/styles/eiffel.css +0 -121
- data/templates/styles/espresso_libre.css +0 -109
- data/templates/styles/idle.css +0 -62
- data/templates/styles/iplastic.css +0 -80
- data/templates/styles/lazy.css +0 -73
- data/templates/styles/mac_classic.css +0 -123
- data/templates/styles/magicwb_amiga.css +0 -104
- data/templates/styles/pastels_on_dark.css +0 -188
- data/templates/styles/slush_poppies.css +0 -85
- data/templates/styles/spacecadet.css +0 -51
- data/templates/styles/sunburst.css +0 -180
- data/templates/styles/twilight.css +0 -137
- data/templates/styles/zenburnesque.css +0 -91
@@ -1,85 +0,0 @@
|
|
1
|
-
pre.slush_poppies .Directives {
|
2
|
-
font-weight: bold;
|
3
|
-
}
|
4
|
-
pre.slush_poppies .TypeName {
|
5
|
-
color: #800080;
|
6
|
-
}
|
7
|
-
pre.slush_poppies .InheritedClass {
|
8
|
-
}
|
9
|
-
pre.slush_poppies .OcamlInfixFPOperators {
|
10
|
-
text-decoration: underline;
|
11
|
-
}
|
12
|
-
pre.slush_poppies .Number {
|
13
|
-
color: #0080A0;
|
14
|
-
}
|
15
|
-
pre.slush_poppies .LibraryVariable {
|
16
|
-
}
|
17
|
-
pre.slush_poppies .Storage {
|
18
|
-
color: #008080;
|
19
|
-
}
|
20
|
-
pre.slush_poppies .line-numbers {
|
21
|
-
background-color: #B0B0FF;
|
22
|
-
color: #000000;
|
23
|
-
}
|
24
|
-
pre.slush_poppies .OcamlPrefixFPOperators {
|
25
|
-
text-decoration: underline;
|
26
|
-
}
|
27
|
-
pre.slush_poppies .OcamlFloatingPointConstants {
|
28
|
-
text-decoration: underline;
|
29
|
-
}
|
30
|
-
pre.slush_poppies .LineNumberDirectives {
|
31
|
-
}
|
32
|
-
pre.slush_poppies .TagName {
|
33
|
-
}
|
34
|
-
pre.slush_poppies .StorageTypes {
|
35
|
-
color: #A08000;
|
36
|
-
}
|
37
|
-
pre.slush_poppies .Operators {
|
38
|
-
color: #2060A0;
|
39
|
-
}
|
40
|
-
pre.slush_poppies .LibraryConstant {
|
41
|
-
}
|
42
|
-
pre.slush_poppies .VariantTypes {
|
43
|
-
color: #C08060;
|
44
|
-
}
|
45
|
-
pre.slush_poppies .FunctionArgument {
|
46
|
-
}
|
47
|
-
pre.slush_poppies .BuiltInConstant {
|
48
|
-
}
|
49
|
-
pre.slush_poppies .ClassTypeName {
|
50
|
-
color: #8000C0;
|
51
|
-
}
|
52
|
-
pre.slush_poppies .ModuleKeyword {
|
53
|
-
color: #0080FF;
|
54
|
-
}
|
55
|
-
pre.slush_poppies .Invalid {
|
56
|
-
}
|
57
|
-
pre.slush_poppies .LibraryClassType {
|
58
|
-
}
|
59
|
-
pre.slush_poppies .LibraryFunction {
|
60
|
-
}
|
61
|
-
pre.slush_poppies .TagAttribute {
|
62
|
-
}
|
63
|
-
pre.slush_poppies .Keyword {
|
64
|
-
color: #2060A0;
|
65
|
-
}
|
66
|
-
pre.slush_poppies .UserDefinedConstant {
|
67
|
-
}
|
68
|
-
pre.slush_poppies .CharacterConstants {
|
69
|
-
color: #800000;
|
70
|
-
}
|
71
|
-
pre.slush_poppies .String {
|
72
|
-
color: #C03030;
|
73
|
-
}
|
74
|
-
pre.slush_poppies {
|
75
|
-
background-color: #F1F1F1;
|
76
|
-
color: #000000;
|
77
|
-
}
|
78
|
-
pre.slush_poppies .FunctionName {
|
79
|
-
color: #800000;
|
80
|
-
}
|
81
|
-
pre.slush_poppies .Variable {
|
82
|
-
}
|
83
|
-
pre.slush_poppies .Comment {
|
84
|
-
color: #406040;
|
85
|
-
}
|
@@ -1,51 +0,0 @@
|
|
1
|
-
pre.spacecadet .Constant {
|
2
|
-
color: #BF9960;
|
3
|
-
}
|
4
|
-
pre.spacecadet .Support {
|
5
|
-
color: #8A4B66;
|
6
|
-
}
|
7
|
-
pre.spacecadet .InheritedClass {
|
8
|
-
font-style: italic;
|
9
|
-
}
|
10
|
-
pre.spacecadet .LibraryVariable {
|
11
|
-
}
|
12
|
-
pre.spacecadet .Storage {
|
13
|
-
color: #9EBF60;
|
14
|
-
}
|
15
|
-
pre.spacecadet .line-numbers {
|
16
|
-
background-color: #40002F;
|
17
|
-
color: #FFFFFF;
|
18
|
-
}
|
19
|
-
pre.spacecadet {
|
20
|
-
background-color: #0D0D0D;
|
21
|
-
color: #DDE6CF;
|
22
|
-
}
|
23
|
-
pre.spacecadet .TagName {
|
24
|
-
}
|
25
|
-
pre.spacecadet .Exception {
|
26
|
-
color: #893062;
|
27
|
-
}
|
28
|
-
pre.spacecadet .LibraryConstant {
|
29
|
-
}
|
30
|
-
pre.spacecadet .Invalid {
|
31
|
-
background-color: #5F0047;
|
32
|
-
}
|
33
|
-
pre.spacecadet .LibraryClassType {
|
34
|
-
}
|
35
|
-
pre.spacecadet .TagAttribute {
|
36
|
-
}
|
37
|
-
pre.spacecadet .Keyword {
|
38
|
-
color: #728059;
|
39
|
-
}
|
40
|
-
pre.spacecadet .String {
|
41
|
-
color: #805978;
|
42
|
-
}
|
43
|
-
pre.spacecadet .Entity {
|
44
|
-
color: #6078BF;
|
45
|
-
}
|
46
|
-
pre.spacecadet .Variable {
|
47
|
-
color: #596380;
|
48
|
-
}
|
49
|
-
pre.spacecadet .Comment {
|
50
|
-
color: #473C45;
|
51
|
-
}
|
@@ -1,180 +0,0 @@
|
|
1
|
-
pre.sunburst .DiffInserted {
|
2
|
-
background-color: #253B22;
|
3
|
-
color: #F8F8F8;
|
4
|
-
}
|
5
|
-
pre.sunburst .DiffHeader {
|
6
|
-
background-color: #0E2231;
|
7
|
-
color: #F8F8F8;
|
8
|
-
font-style: italic;
|
9
|
-
}
|
10
|
-
pre.sunburst .CssPropertyValue {
|
11
|
-
color: #F9EE98;
|
12
|
-
}
|
13
|
-
pre.sunburst .CCCPreprocessorDirective {
|
14
|
-
color: #AFC4DB;
|
15
|
-
}
|
16
|
-
pre.sunburst .Constant {
|
17
|
-
color: #3387CC;
|
18
|
-
}
|
19
|
-
pre.sunburst .DiffChanged {
|
20
|
-
background-color: #4A410D;
|
21
|
-
color: #F8F8F8;
|
22
|
-
}
|
23
|
-
pre.sunburst .Support {
|
24
|
-
color: #9B859D;
|
25
|
-
}
|
26
|
-
pre.sunburst .MarkupList {
|
27
|
-
color: #E1D4B9;
|
28
|
-
}
|
29
|
-
pre.sunburst .CssConstructorArgument {
|
30
|
-
color: #8F9D6A;
|
31
|
-
}
|
32
|
-
pre.sunburst .Storage {
|
33
|
-
color: #99CF50;
|
34
|
-
}
|
35
|
-
pre.sunburst .line-numbers {
|
36
|
-
background-color: #DDF0FF;
|
37
|
-
color: #000000;
|
38
|
-
}
|
39
|
-
pre.sunburst .CssClass {
|
40
|
-
color: #9B703F;
|
41
|
-
}
|
42
|
-
pre.sunburst .StringConstant {
|
43
|
-
color: #DDF2A4;
|
44
|
-
}
|
45
|
-
pre.sunburst .MarkupSeparator {
|
46
|
-
background-color: #242424;
|
47
|
-
color: #60A633;
|
48
|
-
}
|
49
|
-
pre.sunburst .MarkupUnderline {
|
50
|
-
text-decoration: underline;
|
51
|
-
color: #E18964;
|
52
|
-
}
|
53
|
-
pre.sunburst .CssAtRule {
|
54
|
-
color: #8693A5;
|
55
|
-
}
|
56
|
-
pre.sunburst .MetaTagInline {
|
57
|
-
color: #E0C589;
|
58
|
-
}
|
59
|
-
pre.sunburst .JEntityNameType {
|
60
|
-
text-decoration: underline;
|
61
|
-
}
|
62
|
-
pre.sunburst .LogEntryError {
|
63
|
-
background-color: #751012;
|
64
|
-
}
|
65
|
-
pre.sunburst .MarkupHeading {
|
66
|
-
background-color: #632D04;
|
67
|
-
color: #FEDCC5;
|
68
|
-
}
|
69
|
-
pre.sunburst .CssTagName {
|
70
|
-
color: #CDA869;
|
71
|
-
}
|
72
|
-
pre.sunburst .SupportConstant {
|
73
|
-
color: #CF6A4C;
|
74
|
-
}
|
75
|
-
pre.sunburst .MarkupQuote {
|
76
|
-
background-color: #ECD091;
|
77
|
-
color: #E1D4B9;
|
78
|
-
font-style: italic;
|
79
|
-
}
|
80
|
-
pre.sunburst .DiffDeleted {
|
81
|
-
background-color: #420E09;
|
82
|
-
color: #F8F8F8;
|
83
|
-
}
|
84
|
-
pre.sunburst .CCCPreprocessorLine {
|
85
|
-
color: #8996A8;
|
86
|
-
}
|
87
|
-
pre.sunburst .StringRegexpSpecial {
|
88
|
-
color: #CF7D34;
|
89
|
-
}
|
90
|
-
pre.sunburst .EmbeddedSourceBright {
|
91
|
-
background-color: #ABADB4;
|
92
|
-
}
|
93
|
-
pre.sunburst .InvalidIllegal {
|
94
|
-
background-color: #150B15;
|
95
|
-
color: #FD5FF1;
|
96
|
-
}
|
97
|
-
pre.sunburst .MarkupRaw {
|
98
|
-
background-color: #ABADB4;
|
99
|
-
color: #578BB3;
|
100
|
-
}
|
101
|
-
pre.sunburst .SupportFunction {
|
102
|
-
color: #DAD085;
|
103
|
-
}
|
104
|
-
pre.sunburst .CssAdditionalConstants {
|
105
|
-
color: #DD7B3B;
|
106
|
-
}
|
107
|
-
pre.sunburst .MetaTagAll {
|
108
|
-
color: #89BDFF;
|
109
|
-
}
|
110
|
-
pre.sunburst .StringRegexp {
|
111
|
-
color: #E9C062;
|
112
|
-
}
|
113
|
-
pre.sunburst .StringEmbeddedSource {
|
114
|
-
color: #DAEFA3;
|
115
|
-
}
|
116
|
-
pre.sunburst .EntityInheritedClass {
|
117
|
-
color: #9B5C2E;
|
118
|
-
font-style: italic;
|
119
|
-
}
|
120
|
-
pre.sunburst .MarkupComment {
|
121
|
-
color: #F67B37;
|
122
|
-
font-style: italic;
|
123
|
-
}
|
124
|
-
pre.sunburst .MarkupBold {
|
125
|
-
font-weight: bold;
|
126
|
-
color: #E9C062;
|
127
|
-
}
|
128
|
-
pre.sunburst .CssId {
|
129
|
-
color: #8B98AB;
|
130
|
-
}
|
131
|
-
pre.sunburst .CssPseudoClass {
|
132
|
-
color: #8F9D6A;
|
133
|
-
}
|
134
|
-
pre.sunburst .JCast {
|
135
|
-
color: #676767;
|
136
|
-
font-style: italic;
|
137
|
-
}
|
138
|
-
pre.sunburst .StringVariable {
|
139
|
-
color: #8A9A95;
|
140
|
-
}
|
141
|
-
pre.sunburst .String {
|
142
|
-
color: #65B042;
|
143
|
-
}
|
144
|
-
pre.sunburst .Keyword {
|
145
|
-
color: #E28964;
|
146
|
-
}
|
147
|
-
pre.sunburst {
|
148
|
-
background-color: #000000;
|
149
|
-
color: #F8F8F8;
|
150
|
-
}
|
151
|
-
pre.sunburst .LogEntry {
|
152
|
-
background-color: #C7C7C7;
|
153
|
-
}
|
154
|
-
pre.sunburst .MarkupItalic {
|
155
|
-
color: #E9C062;
|
156
|
-
font-style: italic;
|
157
|
-
}
|
158
|
-
pre.sunburst .CssPropertyName {
|
159
|
-
color: #C5AF75;
|
160
|
-
}
|
161
|
-
pre.sunburst .Namespaces {
|
162
|
-
color: #E18964;
|
163
|
-
}
|
164
|
-
pre.sunburst .DoctypeXmlProcessing {
|
165
|
-
color: #494949;
|
166
|
-
}
|
167
|
-
pre.sunburst .InvalidDeprecated {
|
168
|
-
color: #FD5FF1;
|
169
|
-
font-style: italic;
|
170
|
-
}
|
171
|
-
pre.sunburst .Variable {
|
172
|
-
color: #3E87E3;
|
173
|
-
}
|
174
|
-
pre.sunburst .Entity {
|
175
|
-
color: #89BDFF;
|
176
|
-
}
|
177
|
-
pre.sunburst .Comment {
|
178
|
-
color: #AEAEAE;
|
179
|
-
font-style: italic;
|
180
|
-
}
|
@@ -1,137 +0,0 @@
|
|
1
|
-
pre.twilight .DiffInserted {
|
2
|
-
background-color: #253B22;
|
3
|
-
color: #F8F8F8;
|
4
|
-
}
|
5
|
-
pre.twilight .DiffHeader {
|
6
|
-
background-color: #0E2231;
|
7
|
-
color: #F8F8F8;
|
8
|
-
font-style: italic;
|
9
|
-
}
|
10
|
-
pre.twilight .CssPropertyValue {
|
11
|
-
color: #F9EE98;
|
12
|
-
}
|
13
|
-
pre.twilight .CCCPreprocessorDirective {
|
14
|
-
color: #AFC4DB;
|
15
|
-
}
|
16
|
-
pre.twilight .Constant {
|
17
|
-
color: #CF6A4C;
|
18
|
-
}
|
19
|
-
pre.twilight .DiffChanged {
|
20
|
-
background-color: #4A410D;
|
21
|
-
color: #F8F8F8;
|
22
|
-
}
|
23
|
-
pre.twilight .EmbeddedSource {
|
24
|
-
background-color: #A3A6AD;
|
25
|
-
}
|
26
|
-
pre.twilight .Support {
|
27
|
-
color: #9B859D;
|
28
|
-
}
|
29
|
-
pre.twilight .MarkupList {
|
30
|
-
color: #F9EE98;
|
31
|
-
}
|
32
|
-
pre.twilight .CssConstructorArgument {
|
33
|
-
color: #8F9D6A;
|
34
|
-
}
|
35
|
-
pre.twilight .Storage {
|
36
|
-
color: #F9EE98;
|
37
|
-
}
|
38
|
-
pre.twilight .line-numbers {
|
39
|
-
background-color: #DDF0FF;
|
40
|
-
color: #000000;
|
41
|
-
}
|
42
|
-
pre.twilight .CssClass {
|
43
|
-
color: #9B703F;
|
44
|
-
}
|
45
|
-
pre.twilight .StringConstant {
|
46
|
-
color: #DDF2A4;
|
47
|
-
}
|
48
|
-
pre.twilight .CssAtRule {
|
49
|
-
color: #8693A5;
|
50
|
-
}
|
51
|
-
pre.twilight .MetaTagInline {
|
52
|
-
color: #E0C589;
|
53
|
-
}
|
54
|
-
pre.twilight .MarkupHeading {
|
55
|
-
color: #CF6A4C;
|
56
|
-
}
|
57
|
-
pre.twilight .CssTagName {
|
58
|
-
color: #CDA869;
|
59
|
-
}
|
60
|
-
pre.twilight .SupportConstant {
|
61
|
-
color: #CF6A4C;
|
62
|
-
}
|
63
|
-
pre.twilight .DiffDeleted {
|
64
|
-
background-color: #420E09;
|
65
|
-
color: #F8F8F8;
|
66
|
-
}
|
67
|
-
pre.twilight .CCCPreprocessorLine {
|
68
|
-
color: #8996A8;
|
69
|
-
}
|
70
|
-
pre.twilight .StringRegexpSpecial {
|
71
|
-
color: #CF7D34;
|
72
|
-
}
|
73
|
-
pre.twilight .EmbeddedSourceBright {
|
74
|
-
background-color: #9C9EA4;
|
75
|
-
}
|
76
|
-
pre.twilight .InvalidIllegal {
|
77
|
-
background-color: #241A24;
|
78
|
-
color: #F8F8F8;
|
79
|
-
}
|
80
|
-
pre.twilight .SupportFunction {
|
81
|
-
color: #DAD085;
|
82
|
-
}
|
83
|
-
pre.twilight .CssAdditionalConstants {
|
84
|
-
color: #CA7840;
|
85
|
-
}
|
86
|
-
pre.twilight .MetaTagAll {
|
87
|
-
color: #AC885B;
|
88
|
-
}
|
89
|
-
pre.twilight .StringRegexp {
|
90
|
-
color: #E9C062;
|
91
|
-
}
|
92
|
-
pre.twilight .StringEmbeddedSource {
|
93
|
-
color: #DAEFA3;
|
94
|
-
}
|
95
|
-
pre.twilight .EntityInheritedClass {
|
96
|
-
color: #9B5C2E;
|
97
|
-
font-style: italic;
|
98
|
-
}
|
99
|
-
pre.twilight .CssId {
|
100
|
-
color: #8B98AB;
|
101
|
-
}
|
102
|
-
pre.twilight .CssPseudoClass {
|
103
|
-
color: #8F9D6A;
|
104
|
-
}
|
105
|
-
pre.twilight .StringVariable {
|
106
|
-
color: #8A9A95;
|
107
|
-
}
|
108
|
-
pre.twilight .String {
|
109
|
-
color: #8F9D6A;
|
110
|
-
}
|
111
|
-
pre.twilight .Keyword {
|
112
|
-
color: #CDA869;
|
113
|
-
}
|
114
|
-
pre.twilight {
|
115
|
-
background-color: #141414;
|
116
|
-
color: #F8F8F8;
|
117
|
-
}
|
118
|
-
pre.twilight .CssPropertyName {
|
119
|
-
color: #C5AF75;
|
120
|
-
}
|
121
|
-
pre.twilight .DoctypeXmlProcessing {
|
122
|
-
color: #494949;
|
123
|
-
}
|
124
|
-
pre.twilight .InvalidDeprecated {
|
125
|
-
color: #D2A8A1;
|
126
|
-
font-style: italic;
|
127
|
-
}
|
128
|
-
pre.twilight .Variable {
|
129
|
-
color: #7587A6;
|
130
|
-
}
|
131
|
-
pre.twilight .Entity {
|
132
|
-
color: #9B703F;
|
133
|
-
}
|
134
|
-
pre.twilight .Comment {
|
135
|
-
color: #5F5A60;
|
136
|
-
font-style: italic;
|
137
|
-
}
|