-
Notifications
You must be signed in to change notification settings - Fork 25
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
Widget Identifiers #91
Comments
Another possible goal:
Making the above robust implies:
|
As noted above, I have a few potential solutions: Paths (e.g.
|
#243 brings up an issue which I really should have spotted earlier: The best solution I can think of right now: use index-paths like above (e.g.
|
Local reconfigure was implemented in #276. |
The
WidgetId
type is currently a simple numeric identifier assigned to widgets in a depth-first search. It is widely used and should ideally have all of these properties:O(1)
tests of whether a widget is an ancestor of a given identifier (this could be achieved by giving widgets an identifier range, instead of just the last id in that range)O(log n)
identification of which child is the ancestor of anid
givenn
children (hard in the general case when children can have different numbers of descendants; guesses assuming equal numbers of descendants may be enough)List
) to add/remove children without having to re-enumerate all widgetsCurrently things are "fast enough" with a few thousand widgets on a decent machine (even a few hundred thousand in an optimised build, ignoring other issues like calculating size requirements and notifying all subscribed radio boxes) so this isn't a priority, but being able to scale well is a goal (e.g. for spreadsheets where each cell is a widget).
I have some additional notes offline, but no real solution.
The text was updated successfully, but these errors were encountered: