Commit | Line | Data |
---|---|---|
9099c61d RK |
1 | /* This Source Code Form is subject to the terms of the Mozilla Public |
2 | * License, v. 2.0. If a copy of the MPL was not distributed with this | |
3 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | |
351107c9 | 4 | |
b1eaa419 | 5 | /* ===== scrollbars.css ================================================= |
6 | == Styles used by XUL scrollbar-related elements. | |
7 | ======================================================================= */ | |
351107c9 | 8 | |
f98e9249 RK |
9 | @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); |
10 | @namespace html url("http://www.w3.org/1999/xhtml"); /* namespace for HTML elements */ | |
11 | ||
b1eaa419 | 12 | /* ::::: scrollbar ::::: */ |
13 | ||
14 | scrollbar { | |
15 | -moz-binding: url("chrome://global/content/bindings/scrollbar.xml#scrollbar"); | |
16 | cursor: default; | |
17 | background-color: #000000; | |
d8ed26fd | 18 | border-radius: 50%; |
87a1144f RK |
19 | pointer-events: auto; |
20 | } | |
21 | ||
87a1144f | 22 | @media all and (-moz-overlay-scrollbars) { |
2e88f3cc RK |
23 | scrollbar[root="true"] { |
24 | position: relative; | |
25 | z-index: 2147483647; /* largest positive value of a signed 32-bit integer */ | |
26 | } | |
27 | ||
87a1144f RK |
28 | scrollbar:not([active="true"]), |
29 | scrollbar[disabled="true"] { | |
30 | visibility: hidden; | |
31 | } | |
b1eaa419 | 32 | } |
33 | ||
34 | /* ::::: slider ::::: */ | |
35 | ||
36 | slider { | |
37 | height: 13px; | |
5968ec68 | 38 | background-color: #404048; /* #202024;*/ |
b1eaa419 | 39 | } |
40 | ||
41 | slider[orient="vertical"] { | |
42 | width: 13px; | |
43 | } | |
44 | ||
45 | /* ::::: borders for thumb and buttons ::::: */ | |
46 | ||
47 | thumb, | |
48 | scrollbarbutton { | |
49 | border: none; | |
50 | background: transparent 50% 50% no-repeat; | |
51 | padding: 1px; | |
52 | min-width: 13px; | |
53 | min-height: 13px; | |
351107c9 | 54 | } |
55 | ||
e08553ef RK |
56 | scrollbar:not([orient="vertical"]) > scrollbarbutton { |
57 | min-width: 16px; | |
58 | } | |
59 | ||
60 | scrollbar[orient="vertical"] > scrollbarbutton { | |
61 | min-height: 16px; | |
62 | } | |
63 | ||
64 | ||
b1eaa419 | 65 | /* ::::: thumb ::::: */ |
66 | ||
67 | thumb { | |
d8ed26fd | 68 | background-color: #A09090; |
b1eaa419 | 69 | background-image: url("chrome://global/skin/scrollbar/thumb-vert-grip.gif"); |
351107c9 | 70 | } |
71 | ||
b1eaa419 | 72 | thumb[orient="horizontal"] { |
73 | background-image: url("chrome://global/skin/scrollbar/thumb-horiz-grip.gif"); | |
351107c9 | 74 | } |
75 | ||
b1eaa419 | 76 | |
351107c9 | 77 | thumb:active, |
78 | thumb:hover:active { | |
79 | background-color: #008484; | |
80 | } | |
81 | ||
82 | thumb:hover { | |
83 | background-color: #FFCF00; | |
84 | } | |
b1eaa419 | 85 | |
86 | thumb[disabled="true"] { | |
87 | background-image: url("chrome://global/skin/scrollbar/thumb-vert-grip-disabled.gif"); | |
88 | } | |
89 | ||
90 | thumb[orient="horizontal"][disabled="true"] { | |
91 | background-image: url("chrome://global/skin/scrollbar/thumb-horiz-grip-disabled.gif"); | |
92 | } | |
93 | ||
94 | /* ::::: scrollbar button ::::: */ | |
95 | ||
96 | scrollbarbutton { | |
d8ed26fd | 97 | background-color: #C09070; |
b1eaa419 | 98 | } |
99 | ||
a12570b9 | 100 | scrollbarbutton:hover:active, |
101 | scrollbarbutton[active="true"] { | |
e08553ef | 102 | background-position: calc(50% + 1px) calc(50% + 1px); |
3d6dd546 | 103 | } |
b1eaa419 | 104 | |
9c1ab967 RK |
105 | scrollbarbutton:hover { |
106 | background-color: #FFCF00; | |
107 | } | |
108 | ||
109 | scrollbarbutton:hover:active { | |
e08553ef | 110 | background-color: #FF9F00; |
9c1ab967 RK |
111 | } |
112 | ||
113 | scrollbarbutton[disabled="true"] { | |
d8ed26fd | 114 | background-color: #402858 !important; |
9c1ab967 RK |
115 | } |
116 | ||
f98e9249 RK |
117 | /* XXX - scrollbar.xml always grabs the OS settings and we don't want that */ |
118 | scrollbarbutton[sbattr="scrollbar-up-bottom"], | |
119 | scrollbarbutton[sbattr="scrollbar-down-top"] { | |
120 | display: none; | |
121 | } | |
122 | ||
03f6f39c | 123 | /* ::::: square at the corner of two scrollbars ::::: */ |
124 | ||
125 | scrollcorner { | |
3d6dd546 | 126 | -moz-binding: url("chrome://global/content/bindings/scrollbar.xml#scrollbar-base"); |
127 | cursor: default; | |
03f6f39c | 128 | background-color: #000000; |
6046f027 | 129 | width: 13px; |
03f6f39c | 130 | } |
131 | ||
b1eaa419 | 132 | /* ..... increment .... */ |
133 | ||
134 | scrollbarbutton[type="increment"] { | |
9c1ab967 | 135 | background-image: url("chrome://global/skin/scrollbar/arrow-right.png"); |
e08553ef | 136 | border-radius: 0 300px 300px 0; |
cc56c65e | 137 | -moz-border-start: 3px solid #000000; |
b1eaa419 | 138 | } |
139 | ||
b1eaa419 | 140 | scrollbar[orient="vertical"] > scrollbarbutton[type="increment"] { |
9c1ab967 | 141 | background-image: url("chrome://global/skin/scrollbar/arrow-down.png"); |
e08553ef RK |
142 | border-radius: 0 0 300px 300px; |
143 | -moz-border-start: none; | |
cc56c65e | 144 | border-top: 3px solid #000000; |
b1eaa419 | 145 | } |
146 | ||
b1eaa419 | 147 | /* ..... decrement .... */ |
148 | ||
149 | scrollbarbutton[type="decrement"] { | |
9c1ab967 | 150 | background-image: url("chrome://global/skin/scrollbar/arrow-left.png"); |
e08553ef | 151 | border-radius: 300px 0 0 300px; |
cc56c65e | 152 | -moz-border-end: 3px solid #000000; |
b1eaa419 | 153 | } |
154 | ||
b1eaa419 | 155 | scrollbar[orient="vertical"] > scrollbarbutton[type="decrement"] { |
9c1ab967 | 156 | background-image: url("chrome://global/skin/scrollbar/arrow-up.png"); |
e08553ef RK |
157 | border-radius: 300px 300px 0 0; |
158 | -moz-border-end: none; | |
cc56c65e | 159 | border-bottom: 3px solid #000000; |
b1eaa419 | 160 | } |
161 | ||
b1e5c9b1 | 162 | /* :::::::::::::::::::::::::::::::::::::::::::::::::::::::: */ |
163 | /* ::::::::::::::::::::: MEDIA PRINT :::::::::::::::::::::: */ | |
164 | /* :::::::::::::::::::::::::::::::::::::::::::::::::::::::: */ | |
165 | @media print { | |
166 | /* ::::: scrollbar ::::: */ | |
167 | ||
168 | html|div scrollbar { | |
169 | -moz-appearance: scrollbartrack-horizontal; | |
170 | -moz-binding: url("chrome://global/content/bindings/scrollbar.xml#scrollbar"); | |
171 | cursor: default; | |
172 | background: url("chrome://global/skin/scrollbar/slider.gif") scrollbar; | |
173 | } | |
174 | ||
3d6dd546 | 175 | html|div scrollbar[orient="vertical"] |
b1e5c9b1 | 176 | { |
177 | -moz-appearance: scrollbartrack-vertical; | |
178 | } | |
179 | ||
180 | /* ::::: borders for thumb and buttons ::::: */ | |
181 | ||
182 | html|div thumb, | |
183 | html|div scrollbarbutton { | |
184 | border: 2px solid; | |
185 | -moz-border-top-colors: ThreeDLightShadow ThreeDHighlight; | |
186 | -moz-border-right-colors: ThreeDDarkShadow ThreeDShadow; | |
187 | -moz-border-bottom-colors: ThreeDDarkShadow ThreeDShadow; | |
188 | -moz-border-left-colors: ThreeDLightShadow ThreeDHighlight; | |
189 | background-color: -moz-Dialog; | |
190 | } | |
191 | ||
192 | /* ::::: thumb (horizontal) ::::: */ | |
193 | ||
194 | html|div thumb { | |
195 | -moz-appearance: scrollbarthumb-vertical; | |
196 | min-height: 8px; | |
197 | } | |
198 | ||
199 | html|div thumb[orient="horizontal"] { | |
200 | -moz-appearance: scrollbarthumb-horizontal; | |
201 | min-width: 8px; | |
202 | } | |
203 | ||
b1e5c9b1 | 204 | /* ::::: scrollbar button ::::: */ |
205 | ||
206 | html|div scrollbarbutton { | |
cfae8c74 | 207 | background: -moz-Dialog no-repeat 50% 50%; |
b1e5c9b1 | 208 | min-width: 16px; |
209 | min-height: 16px; | |
210 | } | |
211 | ||
a12570b9 | 212 | html|div scrollbarbutton:hover:active, |
213 | html|div scrollbarbutton[active="true"] { | |
b1e5c9b1 | 214 | -moz-border-top-colors: ThreeDShadow -moz-Dialog; |
215 | -moz-border-right-colors: ThreeDShadow -moz-Dialog; | |
216 | -moz-border-bottom-colors: ThreeDShadow -moz-Dialog; | |
217 | -moz-border-left-colors: ThreeDShadow -moz-Dialog; | |
cfae8c74 | 218 | background-position: 60% 60%; |
b1e5c9b1 | 219 | } |
220 | ||
221 | /* ..... increment .... */ | |
222 | ||
223 | html|div scrollbarbutton[type="increment"] { | |
224 | -moz-appearance: scrollbarbutton-right; | |
8b5fc82e | 225 | background-image: url("chrome://global/skin/scrollbar/arrow-right.png") |
b1e5c9b1 | 226 | } |
227 | ||
228 | html|div scrollbar[orient="vertical"] > scrollbarbutton[type="increment"] { | |
229 | -moz-appearance: scrollbarbutton-down; | |
8b5fc82e | 230 | background-image: url("chrome://global/skin/scrollbar/arrow-down.png") |
b1e5c9b1 | 231 | } |
232 | ||
233 | /* ..... decrement .... */ | |
234 | ||
235 | html|div scrollbarbutton[type="decrement"] { | |
236 | -moz-appearance: scrollbarbutton-left; | |
8b5fc82e | 237 | background-image: url("chrome://global/skin/scrollbar/arrow-left.png") |
b1e5c9b1 | 238 | } |
239 | ||
240 | html|div scrollbar[orient="vertical"] > scrollbarbutton[type="decrement"] { | |
241 | -moz-appearance: scrollbarbutton-up; | |
8b5fc82e | 242 | background-image: url("chrome://global/skin/scrollbar/arrow-up.png") |
b1e5c9b1 | 243 | } |
244 | ||
03f6f39c | 245 | } |