Re: [whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly

2012-12-10 Thread Ian Hickson
On Mon, 20 Aug 2012, Kevin Gadd wrote: Hi, I've been digging into an inconsistency between various browsers' Canvas implementations and I think the spec might be allowing undesirable behavior here. The current version of the spec says

Re: [whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly

2012-12-10 Thread Kevin Gadd
(Sorry if you get this twice. For some reason my first reply was bounced by the listserv?) On Mon, Dec 10, 2012 at 10:24 AM, Ian Hickson i...@hixie.ch wrote: There's two ways to do scaled sprites with drawImage(): have a border of transparent black around each sprite, or copy the data out of

Re: [whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly

2012-12-10 Thread Justin Novosad
On Mon, Dec 10, 2012 at 1:24 PM, Ian Hickson i...@hixie.ch wrote: The reason to prefer the current behaviour is if you want to just update a small part of an image. For example, if you draw a bit photo, then draw text over it, then want to remove the text by just drawing the photo over where

Re: [whatwg] Fwd: fallback section taking over for 4xx and 5xx responses while online

2012-12-10 Thread Ian Hickson
On Fri, 24 Aug 2012, Josh Sharpe wrote: I have a manifest that looks something like this: CACHE MANIFEST # e4a75fb378cb627a0d51a80c1cc5684c2d918d93e267f5854a511aa3c8db5b1a /a/application.js /a/application.css NETWORK: * FALLBACK: / /offline Notably, it has a / /offline fallback

Re: [whatwg] Proposal for public data in drag events

2012-12-10 Thread Ian Hickson
On Thu, 30 Aug 2012, Trevor Burnham wrote: The main use case I have in mind is an interface where elements respond to the object being dragged. A common case is showing visual feedback depending on whether the element emitting a dragenter/dragover is a valid drop target for the object

Re: [whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly

2012-12-10 Thread Rik Cabanier
On Mon, Dec 10, 2012 at 11:03 AM, Justin Novosad ju...@chromium.org wrote: On Mon, Dec 10, 2012 at 1:24 PM, Ian Hickson i...@hixie.ch wrote: The reason to prefer the current behaviour is if you want to just update a small part of an image. For example, if you draw a bit photo, then draw

Re: [whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly

2012-12-10 Thread Kevin Gadd
I can't speak for the most common approach in HTML5 games, but using a temporary surface for drawing sprites is definitely not a common approach in non-canvas games. I've never seen it proposed before this thread for canvas dev, either, but I'm not an expert there. This is at least an area where

Re: [whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly

2012-12-10 Thread Justin Novosad
On Mon, Dec 10, 2012 at 4:04 PM, Rik Cabanier caban...@gmail.com wrote: As Ian said, copying the sprite image to a non-scaled canvas first (which most games probably do anyway) works around the issue. There is no need for padding in that case. Yes, I am sure a lot of games do it already to

Re: [whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly

2012-12-10 Thread Rik Cabanier
On Mon, Dec 10, 2012 at 1:18 PM, Justin Novosad ju...@chromium.org wrote: On Mon, Dec 10, 2012 at 4:04 PM, Rik Cabanier caban...@gmail.com wrote: As Ian said, copying the sprite image to a non-scaled canvas first (which most games probably do anyway) works around the issue. There is no

Re: [whatwg] gradient edge case

2012-12-10 Thread Ian Hickson
On Sat, 1 Sep 2012, Rik Cabanier wrote: Currently the canvas spec specifies the following: If x0 = x1 and y0 = y1, then the linear gradient must paint nothing. and If x0 = x1 and y0 = y1 and r0 = r1, then the radial gradient must paint nothing Why is this? At this point: it's

Re: [whatwg] Quirks mode handling of rowspan=0

2012-12-10 Thread Ian Hickson
On Sun, 2 Sep 2012, Boris Zbarsky wrote: Per HTML5 spec, rowspan=0 should span to the end of the table section. WebKit seems to not implement this at all. Opera implements this in quirks and standards mode. Gecko implements this in standards mode only; in quirks mode, rowspan=0 is

Re: [whatwg] gradient edge case

2012-12-10 Thread Rik Cabanier
On Mon, Dec 10, 2012 at 4:07 PM, Ian Hickson i...@hixie.ch wrote: On Sat, 1 Sep 2012, Rik Cabanier wrote: Currently the canvas spec specifies the following: If x0 = x1 and y0 = y1, then the linear gradient must paint nothing. and If x0 = x1 and y0 = y1 and r0 = r1, then the

Re: [whatwg] Cycles in anchored positioning

2012-12-10 Thread Tab Atkins Jr.
On Fri, Dec 7, 2012 at 3:58 PM, Matt Falkenhagen fal...@chromium.org wrote: How are cycles with magically aligned[1] elements resolved? For example, if a and b are dialogs and you do: a.show(b); b.show(a); I think an anchoring cycle can also occur if an element |a| is anchored to a

Re: [whatwg] Autocomplete and autofill features and feedback thereon

2012-12-10 Thread Ian Hickson
On Wed, 21 Nov 2012, Ilya Sherman wrote: On Tue, Nov 20, 2012 at 5:17 PM, Ian Hickson i...@hixie.ch wrote: On Tue, 16 Oct 2012, Ilya Sherman wrote: The payment instrument type is almost certainly appropriate to add -- it is included on almost every website that I've encountered that

Re: [whatwg] gradient edge case

2012-12-10 Thread Ian Hickson
On Mon, 10 Dec 2012, Rik Cabanier wrote: yes, however it will be slower since the pattern has to be rendered two or four times. If you can reflect in x and y, you can calculate the pattern cell once and then have your hardware do the tiling. If it's something that happens a lot, then

Re: [whatwg] Autocomplete and autofill features and feedback thereon

2012-12-10 Thread Ilya Sherman
On Mon, Dec 10, 2012 at 7:49 PM, Ian Hickson i...@hixie.ch wrote: Finally, I have gotten a request to include a field type for bank account numbers, though I have only seen this info actually requested on a small handful of extremely prominent (and generally trusted) websites:

Re: [whatwg] Autocomplete and autofill features and feedback thereon

2012-12-10 Thread Ian Hickson
On Mon, 10 Dec 2012, Ilya Sherman wrote: On Mon, Dec 10, 2012 at 7:49 PM, Ian Hickson i...@hixie.ch wrote: Finally, I have gotten a request to include a field type for bank account numbers, though I have only seen this info actually requested on a small handful of extremely

Re: [whatwg] Proposal: Loading and executing script as quickly as possible using multipart/mixed

2012-12-10 Thread Maciej Stachowiak
On Dec 3, 2012, at 11:19 PM, Adam Barth w...@adambarth.com wrote: On Mon, Dec 3, 2012 at 9:57 PM, Maciej Stachowiak m...@apple.com wrote: On Dec 3, 2012, at 2:11 PM, William Chan (陈智昌) willc...@chromium.org wrote: Unless I am misunderstanding, SPDY will not solve this problem. SPDY uses

Re: [whatwg] Canvas in Workers

2012-12-10 Thread 社用
discussion seems to have died down here but I'd like to bring up another issue In WebGL land we have creation attributes on the drawingbuffer made for a canvas. Example gl = canvas.getContext(webgl, { preserveDrawingBuffer: false }); We're working out the details on how to set those options