You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 29, 2020. It is now read-only.
At some point I hope I'll be making GridLayout. The major question here is, how am I going to insert children? Of course, the children list is always linear and ordered, as we have to traverse the tree somehow. But that list shouldn't be exposed.
For GridLayout, we want to use layout:insert(row, column[, rowSpan, columnSpan[, rowStretch, columnStretch]]) or something. We could make the optional parameters element attributes, even though I'm not fond of that idea... what about the row and column, then?
All right, then. function Element:insert(...) self.layout:insert(...) end it is. Is it?
But how should we move elements to other layout cells? Therefore, no. A huge, heavy, unconditional no. Even if we could do something about this concern, proxying is a hack — an unacceptable hack. We already have enough hacks in the code.
So, anyway, this is how I've come to realize that the current layout system makes no sense. I'd like to make layouts nodes of the document tree, as it's done in such major GUI toolkits as Qt and GTK+.
To make life easier, I want to keep scrolling magical and applied to every non-leaf element as it is right now. Doing a ScrollView means making some element be treated specially. Perhaps there's no point to allow users to override the scroll view, but I just don't like additional restrictions.
The text was updated successfully, but these errors were encountered:
At some point I hope I'll be making
GridLayout
. The major question here is, how am I going to insert children? Of course, the children list is always linear and ordered, as we have to traverse the tree somehow. But that list shouldn't be exposed.For
GridLayout
, we want to uselayout:insert(row, column[, rowSpan, columnSpan[, rowStretch, columnStretch]])
or something. We could make the optional parameters element attributes, even though I'm not fond of that idea... what about the row and column, then?All right, then.
function Element:insert(...) self.layout:insert(...) end
it is. Is it?But how should we move elements to other layout cells? Therefore, no. A huge, heavy, unconditional no. Even if we could do something about this concern, proxying is a hack — an unacceptable hack. We already have enough hacks in the code.
So, anyway, this is how I've come to realize that the current layout system makes no sense. I'd like to make layouts nodes of the document tree, as it's done in such major GUI toolkits as Qt and GTK+.
To make life easier, I want to keep scrolling magical and applied to every non-leaf element as it is right now. Doing a
ScrollView
means making some element be treated specially. Perhaps there's no point to allow users to override the scroll view, but I just don't like additional restrictions.The text was updated successfully, but these errors were encountered: