What's new in Opera development snapshots: 28 February edition

There is a new Opera Next out! Download it from the links in the Desktop team's blog post or wait a while for it to show up on your Opera Next updates (Browser Identification section should show Presto/2.10.269 in opera:about).

Major Updates

  • We now have better precision handling of fixed point values used for lengths and font-sizes. This has been a significant issue with Opera as many units were rounded off. Vadim has a neat demo of how this works in reality. Check it in Opera Next and marvel at the precision!

  • Updating media query implementation to match the latest drafts of the specs, and to pass all the W3C Media Queries tests. Now you can use dpi, dpcm and dppx as unit values for the resolution media query feature. Here is an example. This also fixes issues with Opera applying rules that are within invalid/incorrect media queries.

CSS

  • Not quite CSS, but malformed fonts never stopped loading, but now they do.
  • Setting cursor property on input elements now works.
  • The spec allows border-radius to inherit. Previously this used to fail in Opera, now it no longer does.
  • There used to be random artifacts on linear gradients used with position: absolute, but this has been fixed.
  • Inset Box Shadow's offsets were calculated incorrectly if border-top-width is 0 or border-left-width is 0. This has been fixed.
  • Opera's ::first-letter CSS selector used to select even punctuation characters. But this is no longer the case.

HTML

  • For some reason, entering 5210000010001001 into a field that is of type number caused validation error. This is no longer the case.
  • Setting bgcolor=transparent on a table element seems to not make the underlying background color show but rather render table blue.

SVG

XML

  • XML document had no document.elementFromPoint but this has now been fixed.
  • XML namespaces were also not output correctly when XML was serialised for innerHTML. This has now been fixed.

ECMAScript

  • Regex matching failed to match BOM for \s. This has now been fixed.
  • Array.prototype.join and Array.prototype.concat have been made faster.
  • Improved parseInt performance.
  • The incorrect cache resolution over string values has now been fixed.
  • Not quite ECMAScript, but relevant nonetheless. The line numbers were previously reported relative to the script tag in stack traces (when you do try {} catch (e) {}). This has been fixed. Thanks to fearphage for the bug report!
  • Number.prototype.toString() was not returning accurate values accurate values for large non-base 10 numbers. This has now been fixed (seems like Chrome suffers from this bug).
  • Fixes for JSON.stringify(). A bunch of tests from JSON-test-suite were imported and used to fix our JSON.stringify() implementation. Thanks Luke Smith for this test suite!

APIs

WebRTC

  • The getUserMedia implementation has been updated to accept MediaStreamOptions.
  • If you had allowed a camera to be accessed from multiple domains, it used to crash on reload, it does not now.

Canvas

DOM

  • If you had previously set the charset of a script element from within JavaScript, you would have noticed that it gets ignored (e.g. script.charset = "ISO-8859-1". But we no longer do so.
  • selectionStart/selectionEnd were working incorrectly in a text field. This has been fixed.
  • Constants on DOMException Interface and Node interface had writable and configurable set to true. This has now been fixed.
  • Read-only properties like event.target if set in your script would previously throw an exception. This has been updated to only throw when in ECMAScript strict mode and not otherwise.
  • initEvent on a dispatched event previously threw an error, this has been rectified to have no effect at all.
  • Calling preventDefault() on a non-cancelable event previously returned true and was executed but has now been fixed to have no effect. Thanks for the report Romuald Quantin!
  • Previously scroll event did not fire when scrolling within a textarea. This has now been fixed.
  • By now you must be sensing a theme to all the DOM fixes - prevent unwanted errors from throwing. In this vein, we also have stopped XHR from firing error events and returning status code as 0 when http responses are anything but 200. In this snapshot, Opera will transparently pass through the right HTTP response codes.
  • You can now set the responseType for a XMLHTttpRequest to be json. This means the data returned would be a JavaScript object parsed from the JSON returned by the server as a response to this request.

Misc

  • How do browsers do page scroll when you press the "page down"/"space" button? How do they know how much to scroll by?

    There is no standard way of doing this, but we had an interesting issue where Opera was doing this significantly differently from other browsers. From our investigation, it seems like Chrome 15+, Safari 5+, IE9+ scroll by innerHeight - (innerHeight * 12.5%) while Gecko does so by innerHeight - (innerHeight * 10%).

    This snapshot aligns our page scroll on page down/space key to match WebKit/Trident's behaviour. Here is a fun screenshot of this behaviour across current Opera/IE/Firefox.

  • 32-bit builds running on 64-bit OS now include "WOW64" in the User-Agent String.

Opera Mobile 12, and introducing Opera Mini Nextstandards.next - "Mobile and devices", Manchester

Comments

Martin KadlecBS-Harou Wednesday, February 29, 2012 3:48:41 PM

For some reason, entering 5210000010001001 into a field that is of type number caused validation error. This is no longer the case.



The evil number bigeyes

The getUserMedia implementation has been updated to accept MediaStreamOptions.


There is not getUserMedia method on navigator object. p

netwolf Thursday, March 1, 2012 8:47:26 PM

Originally posted by BS-Harou:

For some reason, entering 5210000010001001 into a field that is of type number caused validation error. This is no longer the case.



The evil number

I'd really like to know why it's exactly this number. It's not a power of 2, might be a prime,... what is so special about it that it's the only number that's causing issues in this context?

Chairul Adli Muhammaddown2down Saturday, March 3, 2012 4:28:39 AM

wow up can draw heart yikes evil number

rseiler Friday, March 9, 2012 6:44:08 AM

Re the new page-down behavior, great, Opera getting in line with other browsers is usually a good thing, but could you give those of us used to the old, more efficient way of paging down, an opera:config setting to revert this behavior?

Samee Ullahsame2cool Sunday, March 11, 2012 5:40:58 PM

nice friend

Hanvordhanvord Monday, March 12, 2012 5:34:39 AM

It's very good.

Vlad Paulvlad74paul Wednesday, March 14, 2012 7:55:46 PM

Today opera next has been update. I love this opera but i have 1 problem. Videos doesnt working on this site with news: http://stirileprotv.ro/stiri/ilikeit/ .(with official opera 11.61 working videos on this adress) sad Please help me....

Mimis Mum (MM)mimi_s_mum Thursday, March 15, 2012 6:59:58 PM

Originally posted by rseiler:

Re the new page-down behavior, great, Opera getting in line with other browsers is usually a good thing, ...

But not in this case. sad

I think Opera's original page-down behaviour is superior and should be retained, because:
  1. Page-down is more likely used by laptop users with smaller vertical screen space.
  2. Opera's original way provides more efficient use of the vertical screen space and better browsing experience, especially to the laptop users
  3. Such unique features, even small, are a part of what make Opera special and distinct from other browsers. Doing the same things as competitors does not help marketing of the product, either. Emphasising of points of difference does.

Opera developers would do well to ask users opinions first when changing something not for better functionality, but only for the same of being in line with other browsers, especially if the change means an altered or lost functionality to long time users. Isn't it what the user forums are for? wink

Kate Joanhealthlife Monday, March 19, 2012 2:16:02 AM

very nice job!

Write a comment

New comments have been disabled for this post.