-
-
Notifications
You must be signed in to change notification settings - Fork 424
Move highlighting and constraints from 'Shape Configuration' popover to new 'Shaper Extra' popover #1524
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
base: main
Are you sure you want to change the base?
Conversation
| <property name="width-request">300</property> | ||
| <property name="selection-mode">none</property> | ||
| <object class="GtkLabel"> | ||
| <property name="label" translatable="yes">Shaper Extra</property> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about a simple
Shape Configuration (2/2)
and adding a (1/2) on the first page.
Though at that point a next/previous page navigation makes more sense.
Maybe a nagivation view can work inside of the popover ? https://gnome.pages.gitlab.gnome.org/libadwaita/doc/1.7/class.NavigationView.html
|
@Doublonmousse Thanks for taking the time to review this PR, I'll try to work on it later today, I think naming the new popup What do you think about renaming what is currently called As for implementing |
Co-authored-by: Doublonmousse <[email protected]>
Then the gear icon would be used for the second panel I guess.
I would have kept the two buttons but added one to switch from one popup to the other. Although after the change of icon it's not needed anymore because you'd know where to click in the first place |
|
I am skeptical about a separate menu, what about adding a second page to the original menu? |
Would be more elegant but less nice to use in my opinion; could we maybe compromise with a scrollable popover with a fixed height? |
|
Or alternatively a second page containing only the |
|
yes, we should definitely re-order all items so that only the least frequently used are on the second page. |
|
I wanted to check whether or not I could do a quick test of a popover with two pages using NavigationView but it turns out that using this is an absolute disaster.
I think I could make it work by not using a Header Bar, placing buttons manually and doing the page switch action from the rust code and definitely not from the ui template |
|
I've managed to create a basic working version for the 2-paged settings here Doublonmousse@07d2478 If everyone is okay with the design of this, it can be used as a base to transfer the settings over. |
|
From https://gitlab.gnome.org/GNOME/gtk/-/issues/7958#note_2640752 (and linked PR with some utilities for popover https://gitlab.com/inkscape/inkscape/-/merge_requests/7710 where popovers can be made to be scrollable through a utility, and the direction changed to make it fit) |
|
I've left this one on the back-burner for too long, the 2-paged version looks pretty good, but I'm concerned about how nice it would be to use (e.g., next page button right next to the close popover button → pain on a touchscreen). When I have the time (soon™), I'll try to see if I can adapt what @Doublonmousse pointed to: void wrap_in_scrolled_window(Gtk::Popover& popover, int min_height, int min_width) {
auto child = popover.get_child();
if (!child || dynamic_cast<Gtk::ScrolledWindow*>(child)) {
return;
}
child->reference();
popover.unset_child();
auto scrolled = Gtk::make_managed<Gtk::ScrolledWindow>();
scrolled->set_child(*child);
scrolled->set_policy(Gtk::PolicyType::NEVER, Gtk::PolicyType::AUTOMATIC);
scrolled->set_propagate_natural_height(true);
scrolled->set_propagate_natural_width(true);
scrolled->set_min_content_height(min_height);
scrolled->set_min_content_width(min_width);
popover.set_child(*scrolled);
child->unreference();
}As a scrollable window would likely be nicer to use |
|
If we go with the 2 page solution, the Maybe making it scrollable is the better solution ? I think we can play around with both (even if it's to have placeholders around) on touchscreens/pen input to see what works better |



fixes #1504
Two things left to iron out: