Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6674877
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T03:47:01+00:00 2026-05-26T03:47:01+00:00

I have a canvas with an icon in the upper right hand corner. What

  • 0

I have a canvas with an icon in the upper right hand corner.
What I would like is this:

  • the user clicks the icon
  • user holds down their mouse button
  • user slides the mouse left/right in order to move the canvas the same direction.

Here’s the thing that’s stumping me… I don’t want the canvas to move until the mouse has traveled a certain distance (in pixels). Then, once the mouse has passed that many pixels, the projects needs to move the same amount of pixels.

Is there a way to find how many pixels the mouse has moved since the mouse was clicked?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T03:47:02+00:00Added an answer on May 26, 2026 at 3:47 am

    On MOUSE_DOWN MouseEvent get mouseX on MOUSE_MOVE MouseEvent get mouseX compair the two values and you have your answer.
    Make sure you up date the old mouseX with the new mouseX if the compaired value is greater then the amount you want.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I Have a canvas and would like to place silverlight elements within that canvas
i wish bind the mouse icon in a Visual Brush,i.e i have a Canvas
I am using the canvas and HTML5. I have an icon in my canvas
I have a grid/canvas that has an element (say an icon with an image
I have a Canvas in which user can add UserControl subclasses containing a form.
I have a canvas on my page <canvas id=oneCanvas width=250px heigth=250px></canvas>​ then I want
I have a canvas in Flex that shall be able only to be scrolled
I have a Canvas in a Flex application which has items inside it that
I have two Canvas A and B, A is the child of B. A
I have a Canvas with a scale translation applied in XAML. Using DrawingContext I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.