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

Provide a prelude module #69

Closed
Tracked by #102
antoyo opened this issue Sep 30, 2017 · 8 comments
Closed
Tracked by #102

Provide a prelude module #69

antoyo opened this issue Sep 30, 2017 · 8 comments

Comments

@antoyo
Copy link
Owner

antoyo commented Sep 30, 2017

To import all the gtk::*Ext traits that does not conflicts.

@zzeroo
Copy link
Contributor

zzeroo commented Nov 12, 2017

I would like to do that. Is that ok?

  • create a prelude module
  • include gtk::*Ext traits that do not cause a conflict
  • update all examples/ documentation and include new prelude module

@antoyo
Copy link
Owner Author

antoyo commented Nov 12, 2017

Yes, that would be awesome.
You can just use gtk::prelude::* instead of manually finding out which traits have no conflicts.
Thanks a lot for your contributions.

@zzeroo
Copy link
Contributor

zzeroo commented Nov 14, 2017

Hi @antoyo, I need a decision.

I could just include use gtk::prelude::* everywhere (examples, README, ...) and fix the use statements, like so:

or, should we have a own prelude module like here:

I mean the first version is very quick and shows that relm is very tight bound to gtk. The second example is more standard, and extenable. What do you think?

@antoyo
Copy link
Owner Author

antoyo commented Nov 16, 2017

The idea of using gtk::prelude directly is nice:
we don't need an additional prelude module for relm indeed.
I prefer to update the examples to use gtk::prelude.
Thanks for proposing this idea.

@antoyo antoyo added this to the 1.0 milestone Apr 4, 2018
@antoyo
Copy link
Owner Author

antoyo commented Apr 4, 2018

@zzeroo I specified this issue for the milestone 1.0, so please tell me if you're still working on this issue and would like me to do it?
Thanks.

@antoyo antoyo mentioned this issue Apr 4, 2018
39 tasks
@zzeroo
Copy link
Contributor

zzeroo commented Apr 7, 2018

@antoyo I started to work on this issue, but because we restructure many of the examples and the benefit is very low so I think we should close this issue and the PR #78 and focus on more essential parts.

@antoyo
Copy link
Owner Author

antoyo commented Apr 7, 2018

Ok, since I'll rework all examples, I'll do it at the same time.

@antoyo antoyo modified the milestone: 1.0 Apr 8, 2018
@antoyo
Copy link
Owner Author

antoyo commented Apr 20, 2018

I tried to do use gtk::*; but this was not working in some cases because different traits can have the same methods which causes ambiguity.
So, I'm closing as there's not much we can do, I think.

@antoyo antoyo closed this as completed Apr 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants