Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add WlOutput and OutputInfo getters #208

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Conversation

Faervan
Copy link

@Faervan Faervan commented Jan 9, 2025

I was unable to find any functionality to obtain the WlOutput that can be passed the the IcedOutput enum, so I added a command for it and an example as well.
Please let me know if merging this would be desired, and if anything should be changed before that. This is my first pull to another repository, please bear with me :)

@wash2
Copy link

wash2 commented Jan 17, 2025

Typically wayland specific libcosmic apps will use https://pop-os.github.io/libcosmic/cosmic/iced/advanced/graphics/futures/event/fn.listen_with.html and check for https://pop-os.github.io/libcosmic/cosmic/iced_winit/graphics/core/event/enum.PlatformSpecific.html PlatformSpecific::Wayland(wayland::Event::Output(output_event, wl_output)) events to be notified of output creation, updates, and removals. I'm not too opposed to getters, but I figure maybe it's best to keep track of the events. Does that sound ok for your use case?

@Faervan
Copy link
Author

Faervan commented Jan 17, 2025

https://pop-os.github.io/libcosmic/cosmic/iced/advanced/graphics/futures/event/fn.listen_with.html

Oh no, missed that one :/
Well, that sure seems to work out as well... I think I might have overseen it because the online docs are build without the wayland flag so the PlatformSpecific event doesn't contain anything.
Well then you can close this if you don't think this is useful enough...

Thanks for your reply!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants