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

Contributing and Roadmap #1

Open
aggmoulik opened this issue Dec 21, 2021 · 4 comments
Open

Contributing and Roadmap #1

aggmoulik opened this issue Dec 21, 2021 · 4 comments
Labels
question Further information is requested

Comments

@aggmoulik
Copy link

Hi, @madsmtm I was looking for a good library in rust to create Menubar Applications, I found you are working on it. I am new to Rust and I want to learn by contributing. So, it will be great to collaborate with you and work on this project. If you can share the roadmap for features and what has been built till now.

@madsmtm
Copy link
Owner

madsmtm commented Dec 21, 2021

Hey @aggmoulik, thanks for the interest! I would very much like some help with this project.

I initially started on a macOS / AppKit implementation, and progress on that went okay-ish, but quickly found that I was not satisfied with the available libraries for interacting with Objective-C, so I've started a whole endeavour to make that better (which is what now takes most of my time 🙄).
Missing from the current macOS implementation is probably the most important thing: the ability to add callbacks (e.g. functions that trigger when the item is clicked).

Anyhow, the general plan is split in two stages: The first is to develop and expose Rust APIs wrapping the platform-specific primitives (NSMenu, HMENU, GtkMenu and so on). These should be as zero-cost as possible, and allow for essentially everything you could want to do with the menu.

This includes:

  • Using it in the application’s menu bar
  • Contextual menus
  • Creating macOS pop-up menus
  • Using it in the macOS status bar
  • The macOS Dock menu
  • ...

Having the platform specific API, it will be much easier to go to the next stage: To try and build a common abstraction over it. So that's the approximate roadmap, though I don't have any dates for this or anything.

I'm thinking we want "backends" for at least the following GUI toolkits:

@madsmtm
Copy link
Owner

madsmtm commented Dec 21, 2021

If you want something to work on, it would be nice to get started on a Windows/Win32 implementation, probably using stuff in windows-sys (instead of the older winapi, since the windows crates are directly supported by Microsoft).

I should note, picking this project as a starting point for learning Rust is quite tough even if you know C/C++ already, because it entails interacting safely with libraries written in those languages, and that requires quite intricate knowledge on Rust's safety and memory models. On the other hand, it's a good way to gain said knowledge.

@madsmtm madsmtm added the question Further information is requested label Dec 21, 2021
@aggmoulik
Copy link
Author

Hey, @madsmtm Thank You for the detailed answer here. Yeah, I understand it will be a difficult task but at least I can try. I think supporting windows API is ok but how can I test or work on that because I have mac os and Linux.

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

No branches or pull requests

2 participants