Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/bundles/xo/res/contenteditable.css
blob: 3adda8dc95fe7974e08c710fd8a2a5ad7f1792f4 (plain)
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
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
 *
 * The contents of this file are subject to the Mozilla Public License Version
 * 1.1 (the "License"); you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
 * http://www.mozilla.org/MPL/
 *
 * Software distributed under the License is distributed on an "AS IS" basis,
 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
 * for the specific language governing rights and limitations under the
 * License.
 *
 * The Original Code is Mozilla.org code.
 *
 * The Initial Developer of the Original Code is
 * Disruptive Innovations.
 * Portions created by the Initial Developer are Copyright (C) 2004
 * the Initial Developer. All Rights Reserved.
 *
 * Contributor(s):
 *   Peter Van der Beken <peterv@propagandism.org>
 *
 * Alternatively, the contents of this file may be used under the terms of
 * either of the GNU General Public License Version 2 or later (the "GPL"),
 * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
 * in which case the provisions of the GPL or the LGPL are applicable instead
 * of those above. If you wish to allow use of your version of this file only
 * under the terms of either the GPL or the LGPL, and not to allow others to
 * use your version of this file under the terms of the MPL, indicate your
 * decision by deleting the provisions above and replace them with the notice
 * and other provisions required by the GPL or the LGPL. If you do not delete
 * the provisions above, a recipient may use your version of this file under
 * the terms of any one of the MPL, the GPL or the LGPL.
 *
 * ***** END LICENSE BLOCK ***** */

::-moz-canvas {
  cursor: text;
}

:focus:-moz-read-write :-moz-read-only {
  -moz-user-select: all !important;
}

input:-moz-read-write > .anonymous-div:-moz-read-only,
textarea:-moz-read-write > .anonymous-div:-moz-read-only {
  -moz-user-select: text !important;
}

/* Use default arrow over objects with size that 
   are selected when clicked on.
   Override the browser's pointer cursor over links
*/

img:-moz-read-write, img:-moz-read-write[usemap], area:-moz-read-write,
object:-moz-read-write, object:-moz-read-write[usemap], 
applet:-moz-read-write, hr:-moz-read-write, button:-moz-read-write,
isindex:-moz-read-write, select:-moz-read-write,
a:-moz-read-write:link img, a:-moz-read-write:visited img,
a:-moz-read-write:active img, a:-moz-read-write:-moz-only-whitespace[name] {
  cursor: default;
}

:-moz-any-link:-moz-read-write {
  cursor: text;
}

/* Prevent clicking on links from going to link */
a:link:-moz-read-write img, a:visited:-moz-read-write img,
a:active:-moz-read-write img {
  -moz-user-input: none;
}

/* We suppress user/author's prefs for link underline, 
   so we must set explicitly. This isn't good!
*/
a:link:-moz-read-write {
  text-decoration: underline -moz-anchor-decoration;
  color: -moz-hyperlinktext;
}

/* Allow double-clicks on these widgets to open properties dialogs
   XXX except when the widget has disabled attribute */
:-moz-read-write > input:-moz-read-only,
:-moz-read-write > button:-moz-read-only,
:-moz-read-write > textarea:-moz-read-only {
  -moz-user-select: all !important;
  -moz-user-input: auto !important;
  -moz-user-focus: none !important;
}

/* XXX Still need a better way of blocking other events to these widgets */
select:-moz-read-write,
:-moz-read-write > input[disabled],
:-moz-read-write > input[type="checkbox"],
:-moz-read-write > input[type="radio"],
:-moz-read-write > input[type="file"],
input[contenteditable="true"][disabled],
input[contenteditable="true"][type="checkbox"],
input[contenteditable="true"][type="radio"],
input[contenteditable="true"][type="file"] {
  -moz-user-select: all !important;
  -moz-user-input: none !important;
  -moz-user-focus: none !important;
}

isindex:-moz-read-write[prompt]
{
  -moz-user-select: none !important;
  -moz-user-input: none !important;
  -moz-user-focus: none !important;
}

/* emulation of non-standard HTML <marquee> tag */
marquee:-moz-read-write {
  -moz-binding: url('chrome://xbl-marquee/content/xbl-marquee.xml#marquee-horizontal-editable');
}

marquee[direction="up"]:-moz-read-write, marquee[direction="down"]:-moz-read-write {
  -moz-binding: url('chrome://xbl-marquee/content/xbl-marquee.xml#marquee-vertical-editable');
}

:-moz-read-write > input[type="hidden"],
input[contenteditable="true"][type="hidden"] {
  border: 1px solid black !important;
  visibility: visible !important;
}

label:-moz-read-write {
    -moz-user-select: all !important;
}

::-moz-display-comboboxcontrol-frame {
  -moz-user-select: text !important;
}

option:-moz-read-write {
  -moz-user-select: text !important;
}

/* the following rules are for Image Resizing */

span[\_moz_anonclass="mozResizer"] {
  width: 5px;
  height: 5px;
  position: absolute;
  border: 1px black solid;
  background-color: white;
  -moz-user-select: none;
  z-index: 2147483646; /* max value -1 for this property */
}

/* we can't use :active below */
span[\_moz_anonclass="mozResizer"][\_moz_activated],
span[\_moz_anonclass="mozResizer"]:hover {
  background-color: black;
}

span[\_moz_anonclass="mozResizer"].hidden,
span[\_moz_anonclass="mozResizingShadow"].hidden,
img[\_moz_anonclass="mozResizingShadow"].hidden,
span[\_moz_anonclass="mozGrabber"].hidden,
span[\_moz_anonclass="mozResizingInfo"].hidden,
a[\_moz_anonclass="mozTableRemoveRow"].hidden,
a[\_moz_anonclass="mozTableRemoveColumn"].hidden {
  display: none !important;
}

span[\_moz_anonclass="mozResizer"][anonlocation="nw"] {
  cursor: nw-resize;
}
span[\_moz_anonclass="mozResizer"][anonlocation="n"] {
  cursor: n-resize;
}
span[\_moz_anonclass="mozResizer"][anonlocation="ne"] {
  cursor: ne-resize;
}
span[\_moz_anonclass="mozResizer"][anonlocation="w"] {
  cursor: w-resize;
}
span[\_moz_anonclass="mozResizer"][anonlocation="e"] {
  cursor: e-resize;
}
span[\_moz_anonclass="mozResizer"][anonlocation="sw"] {
  cursor: sw-resize;
}
span[\_moz_anonclass="mozResizer"][anonlocation="s"] {
  cursor: s-resize;
}
span[\_moz_anonclass="mozResizer"][anonlocation="se"] {
  cursor: se-resize;
}

span[\_moz_anonclass="mozResizingShadow"],
img[\_moz_anonclass="mozResizingShadow"] {
  outline: thin dashed black;
  -moz-user-select: none;
  opacity: 0.5;
  position: absolute;
  z-index: 2147483647; /* max value for this property */
}

span[\_moz_anonclass="mozResizingInfo"] {
  font-family: sans-serif;
  font-size: x-small;
  color: black;
  background-color: #d0d0d0;
  border: ridge 2px #d0d0d0;
  padding: 2px;
  position: absolute;
  z-index: 2147483647; /* max value for this property */
}

img[\_moz_resizing] {
  outline: thin solid black;
}

*[\_moz_abspos] {
  outline: silver ridge 2px;
  z-index: 2147483645 !important; /* max value -2 for this property */
}
*[\_moz_abspos="white"] {
  background-color: white !important;
}
*[\_moz_abspos="black"] {
  background-color: black !important;
}

span[\_moz_anonclass="mozGrabber"] {
  outline: ridge 2px silver;
  padding: 2px;
  position: absolute;
  width: 12px;
  height: 12px;
  background-image: url("resource://gre/res/grabber.gif");
  background-repeat: no-repeat;
  background-position: center center;
  -moz-user-select: none;
  cursor: move;
}

/* INLINE TABLE EDITING */

a[\_moz_anonclass="mozTableAddColumnBefore"] {
  position: absolute;
  z-index: 2147483647; /* max value for this property */
  text-decoration: none !important;
  border: none 0px !important;
  width: 4px;
  height: 8px;
  background-image: url("resource://gre/res/table-add-column-before.gif");
  background-repeat: no-repeat;
  background-position: center center;
  -moz-user-select: none !important;
  -moz-user-focus: none !important;
}

a[\_moz_anonclass="mozTableAddColumnBefore"]:hover {
  background-image: url("resource://gre/res/table-add-column-before-hover.gif");
}

a[\_moz_anonclass="mozTableAddColumnBefore"]:active {
  background-image: url("resource://gre/res/table-add-column-before-active.gif");
}

a[\_moz_anonclass="mozTableAddColumnAfter"] {
  position: absolute;
  z-index: 2147483647; /* max value for this property */
  text-decoration: none !important;
  border: none 0px !important;
  width: 4px;
  height: 8px;
  background-image: url("resource://gre/res/table-add-column-after.gif");
  background-repeat: no-repeat;
  background-position: center center;
  -moz-user-select: none !important;
  -moz-user-focus: none !important;
}

a[\_moz_anonclass="mozTableAddColumnAfter"]:hover {
  background-image: url("resource://gre/res/table-add-column-after-hover.gif");
}

a[\_moz_anonclass="mozTableAddColumnAfter"]:active {
  background-image: url("resource://gre/res/table-add-column-after-active.gif");
}

a[\_moz_anonclass="mozTableRemoveColumn"] {
  position: absolute;
  z-index: 2147483647; /* max value for this property */
  text-decoration: none !important;
  border: none 0px !important;
  width: 8px;
  height: 8px;
  background-image: url("resource://gre/res/table-remove-column.gif");
  background-repeat: no-repeat;
  background-position: center center;
  -moz-user-select: none !important;
  -moz-user-focus: none !important;
}

a[\_moz_anonclass="mozTableRemoveColumn"]:hover {
  background-image: url("resource://gre/res/table-remove-column-hover.gif");
}

a[\_moz_anonclass="mozTableRemoveColumn"]:active {
  background-image: url("resource://gre/res/table-remove-column-active.gif");
}

a[\_moz_anonclass="mozTableAddRowBefore"] {
  position: absolute;
  z-index: 2147483647; /* max value for this property */
  text-decoration: none !important;
  border: none 0px !important;
  width: 8px;
  height: 4px;
  background-image: url("resource://gre/res/table-add-row-before.gif");
  background-repeat: no-repeat;
  background-position: center center;
  -moz-user-select: none !important;
  -moz-user-focus: none !important;
}

a[\_moz_anonclass="mozTableAddRowBefore"]:hover {
  background-image: url("resource://gre/res/table-add-row-before-hover.gif");
}

a[\_moz_anonclass="mozTableAddRowBefore"]:active {
  background-image: url("resource://gre/res/table-add-row-before-active.gif");
}

a[\_moz_anonclass="mozTableAddRowAfter"] {
  position: absolute;
  z-index: 2147483647; /* max value for this property */
  text-decoration: none !important;
  border: none 0px !important;
  width: 8px;
  height: 4px;
  background-image: url("resource://gre/res/table-add-row-after.gif");
  background-repeat: no-repeat;
  background-position: center center;
  -moz-user-select: none !important;
  -moz-user-focus: none !important;
}

a[\_moz_anonclass="mozTableAddRowAfter"]:hover {
  background-image: url("resource://gre/res/table-add-row-after-hover.gif");
}

a[\_moz_anonclass="mozTableAddRowAfter"]:active {
  background-image: url("resource://gre/res/table-add-row-after-active.gif");
}

a[\_moz_anonclass="mozTableRemoveRow"] {
  position: absolute;
  z-index: 2147483647; /* max value for this property */
  text-decoration: none !important;
  border: none 0px !important;
  width: 8px;
  height: 8px;
  background-image: url("resource://gre/res/table-remove-row.gif");
  background-repeat: no-repeat;
  background-position: center center;
  -moz-user-select: none !important;
  -moz-user-focus: none !important;
}

a[\_moz_anonclass="mozTableRemoveRow"]:hover {
  background-image: url("resource://gre/res/table-remove-row-hover.gif");
}

a[\_moz_anonclass="mozTableRemoveRow"]:active {
  background-image: url("resource://gre/res/table-remove-row-active.gif");
}