Skip to content

get absolute mouse position in screen space #2773

@Gibbz

Description

@Gibbz

Is your issue REALLY a bug?

  • My issue is indeed a bug!
  • I am not crazy! I will not fill out this form just to ask a question or request a feature. Pinky promise.

Is there an existing issue for this?

  • I have searched the existing issues.

Is this issue related to iced?

  • My hardware is compatible and my graphics drivers are up-to-date.

What happened?

I'm using cursorMoved from https://docs.rs/iced/latest/iced/advanced/mouse/enum.Event.html

The position is in the application window space. I'm trying to use it to move my app window. However as the window moves, the position changes so it does not work correctly.

What is the expected behavior?

I'd like to get coordinates of the mouse in the screen space. With access to the screen dimensions. So I can move my decoration free application around.

Version

crates.io release

Operating System

Linux

Do you have any log output?

Na

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions