Jump to content

batman
 Share

Recommended Posts

Hi everyone, 

I checked many articles about this topic. All what I tried didn`t work for me. But unfortunately there is no clear vision what are the steps to make your custom designed (from your png or cur file) cursor view.  Just simply change from default one (white arrow) to my own. The questions are the follows:

  1. What kind of variables I should declare?
  2. Where in the code I should declare them (like global, or in setup function, or update function)?
  • Examples: 
  1. Complete code to use cursor defined in CSS file? ( example of css, and js file). Nothing else, just using cursor style defined in CSS.
  2. Complete code of defining your own cursor in js file (pixi application). Nothing else, just using my own cursor style (png, cur) in PIXI application.
  3. Any other solution. 

I think replies on these questions will shed the light on this mysterious topic.

What I checked:

Thank you in advance, 

Link to comment
Share on other sites

One way to achieve that is to have a container inside your container that is being rendered and use following:

container.cursor = "url('path to image'),auto";

Another way is to just set it with css directly to parent of canvas.

There's also settings in interactionmanager for default styles.

Link to comment
Share on other sites

  • 1 year later...
  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...