Is There User-Select for Opera 10.62 and IE9

Is there user-select for Opera 10.62 and IE9?

Did you try using ::selection {color:currentColor;background:transparent}?

For Firefox you can use ::-moz-selection.

https://developer.mozilla.org/En/CSS/::selection

http://msdn.microsoft.com/en-us/library/ff974109(v=VS.85).aspx

http://reference.sitepoint.com/css/pseudoelement-selection


// update //

There's also the unselectable property.

Why is IE9 ignoring my CSS?

Essentially, in IE versions preceding IE10, you can't use that CSS. You have to manually apply an unselectable="on" attribute to all the divs you wish to make unselectable.

See the second highest answer to this question for more info.

How to reset -moz-user-select to be selectable?

Why oh why are you using the universal selector? Please, you have to be more specific with your selectors than that.

As to the answer to your question, reading the MDC documentations carefully, you'll see that the -moz-none value is the one you're looking for, not none:

-moz-none


The text of the element and sub-elements cannot be selected,
but selection can be enabled on sub-elements using -moz-user-select: text.

Set this to the universal selector, and you'll be fine. See this demo to see it working live: http://jsfiddle.net/KqJ7R/

If a browser's element inspector says the width of an element is 300px, can I be sure that it'll be the same across all browsers?

Unless you specified width: 547px; height: 308px then no. If you're allowing the element to shrink and grow based on the size of the descendant elements (and the descendant's dimensions are not constrained by a fixed width or height), then it will vary.

You can never be certain how the user has configured their browser in terms of font-size (some users like a larger font-size so it is easier to read). You can't even be certain the user has the font-family specified, and their default font-face might have wider or narrower glyphs than what you're expecting.



Related Topics



Leave a reply



Submit