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 Mar 13, 2023. It is now read-only.
It's not clear if (alocate-space pane ...) must resize its own pane or the children. In MCCLIM allocate-space methods sometimes do one thing, sometimes the other often both.
Also the notes in Documentation/Notes are contradictory, in Documentation/Notes/layout-protocol.org it is written that allocate-space does not change the geometry of its "own" pane, but in Documentation/Notes/sheet-geometry.org is given the following pseudocode:
I don't know what is better but I think that it is good if all methods do the same thing, and I see three possibilities:
the method resize its own pane (like the code in Documentation/Notes/sheet-geometry.org)
(defmethod allocate-space (pane width height)
(resize-sheet pane width height)
(loop for child in (sheet-children pane) do
(move-sheet child .....)
(allocate-space child ........))
the method doesn't resize its own pane (like written in Documentation/Notes/layout-protocol.org )
(defmethod allocate-space (pane width height)
(loop for child in (sheet-children pane) do
(move-and-resize-sheet child .....)
(allocate-space child ........))
A variant of 2) in which allocate-space is called at the end of resize-sheet in this way a pane it is automatically reallocated when its size change. I don't know if this is in conformance with the specification but it is what Franz CLIM does.
(defmethod allocate-space (pane width height)
(loop for child in (sheet-children pane) do
(move-and-resize-sheet child .....))
;; with one of the following (ofcourse you can also use :after methods)
(defmethod resize-sheet (pane width height)
....
....
(allocate-space pane width height))
;; or
(defmethod note-sheet-region-changed (pane width height)
....
....
(allocate-space pane width height))
;; or also
(defmethod (setf sheet-region) (region pane)
....
....
(allocate-space pane ....))
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
It's not clear if
(alocate-space pane ...)
must resize its own pane or the children. In MCCLIMallocate-space
methods sometimes do one thing, sometimes the other often both.Also the notes in Documentation/Notes are contradictory, in Documentation/Notes/layout-protocol.org it is written that
allocate-space
does not change the geometry of its "own" pane, but in Documentation/Notes/sheet-geometry.org is given the following pseudocode:I don't know what is better but I think that it is good if all methods do the same thing, and I see three possibilities:
allocate-space
is called at the end ofresize-sheet
in this way a pane it is automatically reallocated when its size change. I don't know if this is in conformance with the specification but it is what Franz CLIM does.The text was updated successfully, but these errors were encountered: