Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!
  • Guest, before posting your code please take these rules into consideration:
    • It is required to use our BBCode feature to display your code. While within the editor click < / > or >_ and place your code within the BB Code prompt. This helps others with finding a solution by making it easier to read and easier to copy.
    • You can also use markdown to share your code. When using markdown your code will be automatically converted to BBCode. For help with markdown check out the markdown guide.
    • Don't share a wall of code. All we want is the problem area, the code related to your issue.


    To learn more about how to use our BBCode feature, please click here.

    Thank you, Code Forum.

CSS How many cursor entries till the browser starts to lag?

KittenKatja

Well-Known Coder
Hey there,

Just as much I'd like to have added a background picture I wanted to have a cursor scale automatically to a smaller size since anything above 32x32 will get replaced by a backfall entry that has to be provided in order for the cursor to work at all.
I extracted the cursor SVG from Cute Cursors, studied its structure, and changed its size for each entry, the first version was going down in 16px steps from 128.
A few days ago I got around my laziness and started 1px steps resulting in 97 entries which after like 80 entries start to show as plain text in the Stylus editor and doing it in the editor itself would lag it out after ~40 steps. (scrolling past it also lags)

I'd like to look for a more resource-friendly solution.
 
Without code or a link to a site we can't help. I'm am an old programmer and find it hard to understand what you did and why your having a problem. Please try to explain clearer.
 
Go to the chrome web store and download the Cute Cursors extension.
Select one and go into a website's CSS and look for the cursor entry of the extension.
Because I took it from there, I can't publicize my edits. (I only edited the color)
Next up, paste it 97 times into your text editor of your choosing (I took Notepad++) and change its height and width (starting at 128) down by one per entry.
In the entries list, you have to put default at the very end, a cursor with 32px x 32px is not enough as the last fallback entry.

To relieve some lag, I redid it into 2 steps and added 2 global sheets in Stylus that I can just click a checkbox to de/activate both.
I have a (main) global sheet that has the CSS code * {cursor: var(--cursor) !important;}.

The resource-friendly method I'd like to learn about is something that automatically scales the cursor down when it normally would have to use the next fallback entry or that a single entry persists even outside of the chrome window onto the taskbar (like it already does when chrome is lagging) or persists in a way that it cuts the cursor image so it doesn't overflow out-of-bounds.
 

New Threads

Latest posts

Buy us a coffee!

Back
Top Bottom