Open
Bug 1253573
Opened 10 years ago
Updated 2 years ago
Stop limiting the size of custom cursor
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
UNCONFIRMED
People
(Reporter: ivan.kuckir, Unassigned)
Details
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.116 Safari/537.36
Steps to reproduce:
Make an element with CSS property cursor: url(...), auto;
Actual results:
Chrome and Firefox don't change cursor, if image width or height is larger than 128px.
Expected results:
Author of a website should be able to use as large cursor as he or she wants.
I am making a photo editor, where I use a custom cursor for a Brush tool. Go to http://www.Photopea.com, choose Brush, set diameter to 100px, it works well. Set it to 150px, cursor is cropped.
I see 2 possible reasons, why you are limiting the size of a cursor:
1) Large cursors may confuse the visitor.
- author of the web can already hide cursor and make a DOM element move instead of cursor. There is no point in not allowing web developers to do it in a "native" way.
2) Redrawing a large cursor takes too much performance.
- there are much better ways how a website can "eat" performance, e.g. running some useless JS. Let web developers decide, if they want to trade a large cursor for a little bit of performance, and if it is worth it.
Are there any other reasons, why are you doing it?
Component: Untriaged → CSS Parsing and Computation
Product: Firefox → Core
| Reporter | ||
Comment 1•10 years ago
|
||
Hi guys,
go to this page and see yourself, how it works: http://www.ivank.net/veci/cursors.html
It must be simple to fix it ( remove a condition if(size>128) ignore_custom_cursor(); )
David (when you have some time), could you explain the rationale behind the restriction of the size of CSS custom cursor?
Flags: needinfo?(dbaron)
I suspect because of concerns about various UI spoofing attacks, particularly since the cursor is able to draw in areas outside of the window (since only the hotspot position needs to be in the window).
Flags: needinfo?(dbaron)
| Reporter | ||
Comment 4•9 years ago
|
||
Hi guys, is there a chance that you will fix it? My app really needs large cursors for drawing with brushes.
Native apps usually can use cursors of any size. It makes no sense to handicap webapps in this way.
Updated•3 years ago
|
Severity: normal → S3
As far as I can tell, the spec actually mandates resizing instead of limiting the cursor size (https://www.w3.org/TR/css-ui-3/#ref-for-concrete-object-size):
If an operating system is incapable of rendering a cursor above a given size, cursors larger than that size must be shrunk to within the OS-supported size bounds, while maintaining the cursor image’s intrinsic ratio, if any.
You need to log in
before you can comment on or make changes to this bug.
Description
•