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
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
|
#console_body {
background-color: white;
position: absolute;
color: black;
padding: 0;
width: 100%;
top: 0;
bottom: 0;
}
/* console_body when displayed as a window panel and not the whole app */
#console_body.windowpane {
position: fixed;
top: auto; /* Do not fix to top */
bottom: 0;
left: 0;
right: 0;
z-index: 1; /* Go in front of console_filler */
}
#console_body.windowpane.minimal {
border-top: 1px solid black;
}
#console_body.windowpane #console_body2 {
/* Need some padding in windowpane mode */
/* (In full mode, things are positioned absolutely) */
padding: 0.2em;
}
/* Heading bar */
#console_heading {
background-color: gray;
border: 2px solid black;
padding: 2px;
color: black;
font-family: monospace;
font-weight: bold;
}
/* If "minimized", console_heading and console_output are hidden */
#console_body.minimal #console_heading,
#console_body.minimal #console_output,
/* If "maximized", the maximize button is hidden */
#console_body.maximal .maximize {
display: none;
}
/* Minimize/maximize button */
.console_button {
cursor: pointer; /* Display hand cursor, since this is a button */
position: absolute;
right: 0.5em;
}
#console_output {
/*height: 20em;*/ /* Might be needed for windowpane mode */
/*margin-bottom: 0.5em;*/
position: absolute;
/* Start immediately under the blue header. */
top: 0;
/* 2.5em is to accomodate the input bar, and padding either side */
bottom: 2.5em;
left: 0;
right: 0;
/* Display scroll bars */
overflow: scroll;
/* Some browsers support overflow-x and overflow-y. In this case, use
* overflow-x: auto to disable the horizontal scroll bar.
* (If unsupported this will simply fall back to a harmless but annoying
* horizontal scroll bar).
*/
overflow-x: auto;
padding: 0.5em;
/* On some displays, monospace font is much smaller than everything else.
* We just set the console font to 13px to appear a bit bigger (this is
* the same size as the editor's font).
*/
font-size: 13px;
}
#console_body.windowpane #console_output {
/* Don't want this absolutely positioned in windowpane mode */
position: static;
/* Make it a bit higher up, because the header is thinner in this mode */
top: 2em;
/* Give it an explicit height instead */
height: 15em;
margin-bottom: 0.5em;
}
#console_body.windowpane.maximal, #console_body.windowpane #console_heading {
-moz-border-radius-topleft: 10px;
-moz-border-radius-topright: 10px;
-webkit-border-top-left-radius: 10px;
-webkit-border-top-right-radius: 10px;
border-top-left-radius: 10px;
border-top-right-radius: 10px;
}
#console_input {
position: absolute;
/* Input bar goes along the bottom. Pad all sides */
bottom: 0.5em;
padding: 0 0.5em;
/* Treat console line as table formatted, so the textbox is dynamic in size. */
display: table;
font-size: 13px;
}
#console_input > div {
display: table-row;
}
#console_input > div > * {
display: table-cell;
/* Don't let the buttons wrap onto multiple lines.
* This forces the textbox to shrink.
*/
white-space: nowrap;
}
#console_input > div > .console_button {
/* If the console button is in a cell, don't float */
position: static !important;
padding: 0 0.2em;
}
#console_inputCell {
width: 100%;
padding-right: 0.5em;
}
#console_body.windowpane #console_input {
/* Don't want this absolutely positioned in windowpane mode */
position: static;
}
#console_prompt {
font-family: monospace;
font-weight: bold;
white-space: pre;
}
#console_inputText {
font-family: monospace;
width: 100%;
}
/* console filler takes up the same space as console_body.windowpane
* but its position is relative, not fixed.
* This avoids having the console overlap with the bottom 28em of page
* content.
* It has two classes. "windowpane" turns it on. "minimal" or "maximal"
* control its height.
*/
#console_filler {
display: none;
}
#console_filler.windowpane {
display: block;
z-index: -1; /* Go behind the actual console */
width: 100%;
position: relative;
bottom: 0;
left: 0;
right: 0;
}
#console_filler.maximal {
/* Trial and error is useful to work this out. */
height: 14em;
}
#console_filler.minimal {
/* Trial and error is useful to work this out. */
height: 2em;
}
*.errorMsg {
color: red;
margin-top: 0em;
margin-bottom: 0em;
}
*.inputPrompt {
color: #800; /* Deep red */
font-weight: bold;
margin-top: 0em;
margin-bottom: 0em;
}
*.inputMsg {
color: #404040;
margin-top: 0em;
margin-bottom: 0em;
}
*.outputMsg {
margin-top: 0em;
margin-bottom: 0em;
}
|