1442.1.28
by William Grant
Move the docutils CSS from tutorial.css to worksheet.css, which is only included in WorksheetView. |
1 |
/*
|
2 |
:Author: Edward Loper, James Curran
|
|
3 |
:Copyright: This stylesheet has been placed in the public domain.
|
|
4 |
||
5 |
Stylesheet for use with Docutils.
|
|
6 |
||
7 |
This stylesheet defines new css classes used by NLTK.
|
|
8 |
||
9 |
It uses a Python syntax highlighting scheme that matches
|
|
10 |
the colour scheme used by IDLE, which makes it easier for
|
|
11 |
beginners to check they are typing things in correctly.
|
|
12 |
*/
|
|
13 |
||
14 |
/* Include the standard docutils stylesheet. */
|
|
1487
by William Grant
Comment out the default.css import, which was accidentally unignored by some of my recent work. |
15 |
/* XXX: We're not ready for this CSS, apparently. See bug #516911. */
|
16 |
/* @import url(default.css); */
|
|
1442.1.28
by William Grant
Move the docutils CSS from tutorial.css to worksheet.css, which is only included in WorksheetView. |
17 |
|
18 |
/* Custom inline roles */
|
|
19 |
span.placeholder { font-style: italic; font-family: monospace; } |
|
20 |
span.example { font-style: italic; } |
|
21 |
span.emphasis { font-style: italic; } |
|
22 |
span.termdef { font-weight: bold; } |
|
23 |
/*span.term { font-style: italic; }*/
|
|
24 |
span.category { font-variant: small-caps; } |
|
25 |
span.feature { font-variant: small-caps; } |
|
26 |
span.fval { font-style: italic; } |
|
27 |
span.math { font-style: italic; } |
|
28 |
span.mathit { font-style: italic; } |
|
29 |
span.lex { font-variant: small-caps; } |
|
30 |
||
31 |
/* Python souce code listings */
|
|
32 |
span.pysrc-prompt { color: #9b0000; } |
|
33 |
span.pysrc-more { color: #9b00ff; } |
|
34 |
span.pysrc-keyword { color: #e06000; } |
|
35 |
span.pysrc-builtin { color: #940094; } |
|
36 |
span.pysrc-string { color: #00aa00; } |
|
37 |
span.pysrc-comment { color: #ff0000; } |
|
38 |
span.pysrc-output { color: #0000ff; } |
|
39 |
span.pysrc-except { color: #ff0000; } |
|
40 |
span.pysrc-defname { color: #008080; } |
|
41 |
||
42 |
||
43 |
/* Doctest blocks */
|
|
44 |
pre.doctest { margin: 0; padding: 0; font-weight: bold; } |
|
45 |
div.doctest { margin: 0 1em 1em 1em; padding: 0; } |
|
46 |
table.doctest { margin: 0; padding: 0; |
|
47 |
border-top: 1px solid gray; |
|
48 |
border-bottom: 1px solid gray; } |
|
49 |
pre.copy-notify { margin: 0; padding: 0.2em; font-weight: bold; |
|
50 |
background-color: #ffffff; } |
|
51 |
||
52 |
/* Python source listings */
|
|
53 |
div.pylisting { margin: 0 1em 1em 1em; padding: 0; } |
|
54 |
table.pylisting { margin: 0; padding: 0; |
|
55 |
border-top: 1px solid gray; } |
|
56 |
td.caption { border-top: 1px solid black; margin: 0; padding: 0; } |
|
57 |
.caption-label { font-weight: bold; } |
|
58 |
td.caption p { margin: 0; padding: 0; font-style: normal;} |
|
59 |
||
60 |
table tr td.codeblock { |
|
61 |
padding: 0.2em ! important; margin: 0; |
|
62 |
border-left: 1px solid gray; |
|
63 |
border-right: 2px solid gray; |
|
64 |
border-top: 0px solid gray; |
|
65 |
border-bottom: 1px solid gray; |
|
66 |
font-weight: bold; background-color: #eeffee; |
|
67 |
}
|
|
68 |
||
69 |
table tr td.doctest { |
|
70 |
padding: 0.2em; margin: 0; |
|
71 |
border-left: 1px solid gray; |
|
72 |
border-right: 2px solid gray; |
|
73 |
border-top: 0px solid gray; |
|
74 |
border-bottom: 1px solid gray; |
|
75 |
font-weight: bold; background-color: #eeeeff; |
|
76 |
}
|
|
77 |
||
78 |
td.codeblock table tr td.copybar { |
|
79 |
background: #40a060; border: 1px solid gray; |
|
80 |
font-family: monospace; padding: 0; margin: 0; } |
|
81 |
td.doctest table tr td.copybar { |
|
82 |
background: #4060a0; border: 1px solid gray; |
|
83 |
font-family: monospace; padding: 0; margin: 0; } |
|
84 |
||
85 |
td.pysrc { padding-left: 0.5em; } |
|
86 |
||
87 |
img.callout { border-width: 0px; } |
|
88 |
||
89 |
table.docutils { |
|
90 |
border-style: solid; |
|
91 |
border-width: 1px; |
|
92 |
margin-top: 6px; |
|
93 |
border-color: grey; |
|
94 |
border-collapse: collapse; } |
|
95 |
||
96 |
table.docutils th { |
|
97 |
border-style: none; |
|
98 |
border-width: 1px; |
|
99 |
border-color: grey; |
|
100 |
padding: 0 .5em 0 .5em; } |
|
101 |
||
102 |
table.docutils td { |
|
103 |
border-style: none; |
|
104 |
border-width: 1px; |
|
105 |
border-color: grey; |
|
106 |
padding: 0 .5em 0 .5em; } |
|
107 |
||
108 |
table.footnote td { padding: 0; } |
|
109 |
table.footnote { border-width: 0; } |
|
110 |
table.footnote td { border-width: 0; } |
|
111 |
table.footnote th { border-width: 0; } |
|
112 |
||
113 |
table.noborder { border-width: 0; } |
|
114 |
||
115 |
table.example pre { margin-top: 4px; margin-bottom: 0; } |
|
116 |
||
117 |
/* For figures & tables */
|
|
118 |
p.caption { margin-bottom: 0; } |
|
119 |
div.figure { text-align: center; } |
|
120 |
||
121 |
/* The index */
|
|
122 |
div.index { border: 1px solid black; |
|
123 |
background-color: #eeeeee; } |
|
124 |
div.index h1 { padding-left: 0.5em; margin-top: 0.5ex; |
|
125 |
border-bottom: 1px solid black; } |
|
126 |
ul.index { margin-left: 0.5em; padding-left: 0; } |
|
127 |
li.index { list-style-type: none; } |
|
128 |
p.index-heading { font-size: 120%; font-style: italic; margin: 0; } |
|
129 |
li.index ul { margin-left: 2em; padding-left: 0; } |
|
130 |
||
131 |
/* 'Note' callouts */
|
|
132 |
div.note |
|
133 |
{
|
|
134 |
padding: 4px; |
|
135 |
margin: 2px 5% 10px; |
|
136 |
font-style: normal; |
|
137 |
font-family: sans-serif; |
|
138 |
background-color: #b0c4de; |
|
139 |
-moz-border-radius: 10px; |
|
140 |
}
|
|
141 |
||
142 |
div.note p.admonition-title |
|
143 |
{
|
|
144 |
font-weight: bold; |
|
145 |
}
|
|
146 |
||
147 |
table.rst-example { border: 1px solid black; } |
|
148 |
table.rst-example tbody tr td { background: #eeeeee; } |
|
149 |
table.rst-example thead tr th { background: #c0ffff; } |
|
150 |
td.rst-raw { width: 0; } |
|
151 |
||
152 |
/* Used by nltk.org/doc/test: */
|
|
153 |
div.doctest-list { text-align: center; } |
|
154 |
table.doctest-list { border: 1px solid black; |
|
155 |
margin-left: auto; margin-right: auto; |
|
156 |
}
|
|
157 |
table.doctest-list tbody tr td { background: #eeeeee; |
|
158 |
border: 1px solid #cccccc; text-align: left; } |
|
159 |
table.doctest-list thead tr th { background: #304050; color: #ffffff; |
|
160 |
border: 1px solid #000000;} |
|
161 |
span.doctest-passed { color: #008000; } |
|
162 |
span.doctest-failed { color: #800000; } |