forked from kawabata/iwds
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpdf.css
More file actions
167 lines (109 loc) · 3.55 KB
/
Copy pathpdf.css
File metadata and controls
167 lines (109 loc) · 3.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
/* Very basic structural stylesheet for HTMLBook in conjunction
with a PDF formatter such as AntennaHouse or PrinceXML.
Assumes the existence of a user agent stylesheet. */
@charset "UTF-8";
@page {
/*size: 7in 9in; */
margin: 1cm 1cm;
}
body[data-type="book"] {
color: cmyk(0%,0%,0%,100%);
hyphens: auto;
}
/* page counters are tricky */
body[data-type="book"] > div[data-type="part"]:first-of-type,
body[data-type="book"] > section[data-type="chapter"]:first-of-type { counter-reset: page 1 }
body[data-type="book"] > section[data-type="chapter"]+div[data-type="part"] { counter-reset: none }
/* (((((((((((((( TITLEPAGE )))))))))))))) */
section[data-type="titlepage"] { page: titlepage }
section[data-type="titlepage"] * { text-align: center }
h2.author { font-style: italic }
/* (((((((((((((( COPYRIGHT )))))))))))))) */
section[data-type="titlepage"] { page: copyright }
/* (((((((((((((( DEDICATION )))))))))))))) */
section[data-type="dedication"] { page: dedication }
section[data-type="dedication"] p { font-style: italic }
section[data-type="dedication"] * { text-align: center }
/* (((((((((((((( TOC )))))))))))))) */
nav[data-type="toc"] { page: toc }
@page toc:right {
@bottom-right-corner { content: counter(page, lower-roman) }
}
@page toc:left {
@bottom-left-corner { content: counter(page, lower-roman) }
}
nav[data-type="toc"] ol { list-style-type: none }
/* (((((((((((((( FOREWORD )))))))))))))) */
section[data-type="foreword"] { page: foreword }
@page foreword:right {
@bottom-right-corner { content: counter(page, lower-roman) }
}
@page foreword:left {
@bottom-left-corner { content: counter(page, lower-roman) }
}
/* (((((((((((((( PREFACE )))))))))))))) */
section[data-type="preface"] { page: preface }
@page preface:right {
@bottom-right-corner { content: counter(page, lower-roman) }
}
@page preface:left {
@bottom-left-corner { content: counter(page, lower-roman) }
}
/* (((((((((((((( PART )))))))))))))) */
div[data-type="part"] { page: part }
/* (((((((((((((( CHAPTER )))))))))))))) */
section[data-type="chapter"] {
page: chapter;
page-break-before: always;
}
@page chapter:right {
@bottom-right-corner { content: counter(page) }
}
@page chapter:left {
@bottom-left-corner { content: counter(page) }
}
/* (((((((((((((( APPENDIX )))))))))))))) */
section[data-type="appendix"] {
page: appendix;
page-break-before: always;
}
@page appendix:right {
@bottom-right-corner { content: counter(page) }
}
@page appendix:left {
@bottom-left-corner { content: counter(page) }
}
/* (((((((((((((( GLOSSARY )))))))))))))) */
section[data-type="glossary"] { page: glossary }
@page glossary:right {
@bottom-right-corner { content: counter(page) }
}
@page glossary:left {
@bottom-left-corner { content: counter(page) }
}
/* (((((((((((((( BIBLIOGRAPHY )))))))))))))) */
section[data-type="bibliography"] { page: bibliography }
@page bibliography:right {
@bottom-right-corner { content: counter(page) }
}
@page bibliography:left {
@bottom-left-corner { content: counter(page) }
}
/* (((((((((((((( INDEX )))))))))))))) */
section[data-type="index"] { page: index }
@page index:right {
@bottom-right-corner { content: counter(page) }
}
@page index:left {
@bottom-left-corner { content: counter(page) }
}
/* (((((((((((((( COLOPHON )))))))))))))) */
section[data-type="colophon"] { page: colophon }
/* (((((((((((((( BLOCKS )))))))))))))) */
h1, h2, h3, h4, h5 {
hyphens: none;
text-align: left;
}
img { max-width: 100% }
/* (((((((((((((( INLINES )))))))))))))) */
code { font-family: monospace }