I was careless and did not check up on my application that used graph layout while a couple of rounds of changes were made. Now I find that my application is all stuffed up, and I was hoping that someone could make some suggestions. In particular:
1. My old code would draw graphs, and at the end of each graph-drawing function would invoke:
(change-space-requirements stream :min-width (bounding-rectangle-width rect) :min-height (bounding-rectangle-height rect))
In the past this seemed to Do The Right Thing: the application pane (at the top, over an interactor pane) would get larger, and scroll bars would appear as needed. Now, however, something that seems very wrong to me happens, viz:
a. I stretch the frame larger than its original size. b. I invoke a graph drawer. c. The frame resizes itself to its original size.
My conjecture is that the effect of changing space requirements may have changed.
Weirdly, the space requirement is now:
[1i] GRAPH-MDP(74): :i 22 A NEW CLIMI::STANDARD-SPACE-REQUIREMENT @ #x881c250a = #<CLIMI::STANDARD-SPACE-REQUIREMENT width: 0.0d0 [0.0d0,100000000] height: 0.0d0 [0.0d0,100000000]> 0 Class --------> #<STANDARD-CLASS CLIMI::STANDARD-SPACE-REQUIREMENT> 1 WIDTH --------> double-float = 0.0d0 [#x00000000 00000000] 2 MAX-WIDTH ----> fixnum 100000000 [#x17d78400] 3 MIN-WIDTH ----> double-float = 0.0d0 [#x00000000 00000000] 4 HEIGHT -------> double-float = 0.0d0 [#x00000000 00000000] 5 MAX-HEIGHT ---> fixnum 100000000 [#x17d78400] 6 MIN-HEIGHT ---> double-float = 0.0d0 [#x00000000 00000000]
although the current-width is 6952.0 and the current-height is 4261.5.
I was considering that perhaps I should have been changing the width and height slots of the space-requirement instead of min- values, but (a) this used to work and (b) it seems like none of my changed space requirements are "taking."
Here's what happens when I trace change-space-requirements:
0[9]: (CLIM:CHANGE-SPACE-REQUIREMENTS #<CLIM:APPLICATION-PANE SIFT.MDP:MDP @ #x72d0bc22> :WIDTH 6952.0 :HEIGHT 4261.5 :MIN-WIDTH 6952.0 :MIN-HEIGHT 4261.5) 0* (CALL-METHOD #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS :AROUND (CLIM:CLIM-STREAM-PANE)> ((MULTIPLE-VALUE-PROG1 (PROGN #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS :BEFORE (CLIM-INTERNALS::SPACE-REQUIREMENT-OPTIONS-MIXIN)> #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS :BEFORE (CLIM-INTERNALS::LAYOUT-PROTOCOL-MIXIN)> #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS (CLIM-INTERNALS::LAYOUT-PROTOCOL-MIXIN)>) #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS :AFTER (CLIM-INTERNALS::LAYOUT-PROTOCOL-MIXIN)>))) 1[9]: (CLIM:CHANGE-SPACE-REQUIREMENTS #<CLIM-EXTENSIONS:VIEWPORT-PANE "(Unnamed Pane)" @ #x72d0c35a> :RESIZE-FRAME NIL) 1* (MULTIPLE-VALUE-PROG1 (PROGN #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS :BEFORE (CLIM-INTERNALS::SPACE-REQUIREMENT-OPTIONS-MIXIN)> #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS :BEFORE (CLIM-INTERNALS::LAYOUT-PROTOCOL-MIXIN)> #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS (CLIM-EXTENSIONS:VIEWPORT-PANE)>) #<STANDARD-METHOD CLIM:CHANGE-SPACE-REQUIREMENTS :AFTER (CLIM-INTERNALS::LAYOUT-PROTOCOL-MIXIN)>) 1[9]: returned NIL 0[9]: returned NIL
Possibly the information about the space requirements is not properly percolating up from the application-pane to its enclosing viewport-pane?
[1i] GRAPH-MDP(85): :i A TENURED CLIM-EXTENSIONS:VIEWPORT-PANE @ #x72d0c35a = #<CLIM-EXTENSIONS:VIEWPORT-PANE "(Unnamed Pane)" @ #x72d0c35a> 0 Class --------> #<STANDARD-CLASS CLIM-EXTENSIONS:VIEWPORT-PANE> 1 REGION -------> #<STANDARD-BOUNDING-RECTANGLE X 0:646.0d0 Y 0:590 @ #x735b3e8a> 2 NATIVE-TRANSFORMATION -> #<CLIMI::STANDARD-IDENTITY-TRANSFORMATION 1 0 0 1 0 0> 3 NATIVE-REGION -> #<STANDARD-RECTANGLE X 0:646.0d0 Y 0:590 @ #x735b3e9a> 4 DEVICE-TRANSFORMATION -> The symbol NIL 5 DEVICE-REGION -> The symbol NIL 6 POINTER-CURSOR -> The symbol :DEFAULT 7 ENABLED-P ----> The symbol T 8 CURRENT-WIDTH -> The symbol NIL 9 CURRENT-HEIGHT -> The symbol NIL 10 TRANSFORMATION -> #<CLIMI::STANDARD-TRANSLATION 1 0 0 1 4 4> 11 QUEUE --------> #<CLIMI::PORT-EVENT-QUEUE @ #x72d06c52> 12 NAME ---------> A simple-string (14) "(Unnamed Pane)" 13 MANAGER ------> #<CLIM-CLX::CLX-FRAME-MANAGER @ #x72c0b642> 14 FRAME --------> #<TAEMS-MDP-APP @ #x72ceb5b2> 15 ENABLEDP -----> The symbol NIL 16 SPACE-REQUIREMENT -> The symbol NIL 17 NEW-WIDTH ----> The symbol NIL 18 NEW-HEIGHT ---> The symbol NIL 19 REDISPLAY-NEEDED -> The symbol NIL 20 PORT ---------> #<CLIM-CLX::CLX-PORT :HOST "" :DISPLAY-ID 0 @ #x72c02ada> 21 MIRROR-TRANSFORMATION -> #<CLIMI::STANDARD-TRANSLATION 1 0 0 1 4 4> 22 MIRROR-REGION -> #<STANDARD-RECTANGLE X 0:646 Y 0:590 @ #x735b3eca> 23 PARENT -------> #<SCROLLER-PANE "(Unnamed Pane)" @ #x72d0c7aa> 24 USER-WIDTH ---> The symbol NIL 25 USER-MIN-WIDTH -> The symbol NIL 26 USER-MAX-WIDTH -> The symbol NIL 27 USER-HEIGHT --> The symbol NIL 28 USER-MIN-HEIGHT -> The symbol NIL 29 USER-MAX-HEIGHT -> The symbol NIL 30 X-SPACING ----> fixnum 0 [#x00000000] 31 Y-SPACING ----> fixnum 0 [#x00000000] 32 FOREGROUND ---> #<CLIMI::NAMED-COLOR "black"> 33 BACKGROUND ---> #<CLIMI::NAMED-COLOR "gray84"> 34 TEXT-STYLE ---> #<STANDARD-TEXT-STYLE :FIX :ROMAN :NORMAL> 35 ALIGN-X ------> The symbol :LEFT 36 ALIGN-Y ------> The symbol :TOP 37 CHILD --------> #<APPLICATION-PANE MDP @ #x72d0bc22> [1i] GRAPH-MDP(86): :i 37 A TENURED APPLICATION-PANE @ #x72d0bc22 = #<APPLICATION-PANE MDP @ #x72d0bc22> 0 Class --------> #<STANDARD-CLASS APPLICATION-PANE> 1 MARKINGS -----> The symbol NIL 2 POINT-1-X ----> The symbol NIL 3 POINT-1-Y ----> The symbol NIL 4 POINT-2-X ----> The symbol NIL 5 POINT-2-Y ----> The symbol NIL 6 DRAGGING-P ---> The symbol NIL 7 REGION -------> #<STANDARD-BOUNDING-RECTANGLE X 0:6952.0 Y 0:4261.5 @ #x87f3415a> 8 NATIVE-TRANSFORMATION -> #<CLIMI::STANDARD-IDENTITY-TRANSFORMATION 1 0 0 1 0 0> 9 NATIVE-REGION -> #<STANDARD-RECTANGLE X 0:646.0d0 Y 0:590 @ #x87f34172> 10 DEVICE-TRANSFORMATION -> The symbol NIL 11 DEVICE-REGION -> #<STANDARD-RECTANGLE X 0:646.0d0 Y 0:590 @ #x87f34172> 12 POINTER-CURSOR -> The symbol :DEFAULT 13 ENABLED-P ----> The symbol T 14 CURRENT-WIDTH -> single-float = 6952.0 [#x45d94000] 15 CURRENT-HEIGHT -> single-float = 4261.5 [#x45852c00] 16 TRANSFORMATION -> #<CLIMI::STANDARD-IDENTITY-TRANSFORMATION 1 0 0 1 0 0> 17 QUEUE --------> #<CLIMI::PORT-EVENT-QUEUE @ #x72d06c52> 18 NAME ---------> The symbol MDP 19 MANAGER ------> #<CLIM-CLX::CLX-FRAME-MANAGER @ #x72c0b642> 20 FRAME --------> #<TAEMS-MDP-APP @ #x72ceb5b2> 21 ENABLEDP -----> The symbol NIL 22 SPACE-REQUIREMENT -> #<CLIMI::STANDARD-SPACE-REQUIREMENT width: 0.0d0 [0.0d0,100000000] height: 0.0d0 [0.0d0,100000000]> 23 NEW-WIDTH ----> The symbol NIL 24 NEW-HEIGHT ---> The symbol NIL 25 PORT ---------> #<CLIM-CLX::CLX-PORT :HOST "" :DISPLAY-ID 0 @ #x72c02ada> 26 MIRROR-TRANSFORMATION -> #<CLIMI::STANDARD-IDENTITY-TRANSFORMATION 1 0 0 1 0 0> 27 MIRROR-REGION -> #<STANDARD-RECTANGLE X 0:3799 Y 0:2425 @ #x87f341c2> 28 PARENT -------> #<CLIM-EXTENSIONS:VIEWPORT-PANE "(Unnamed Pane)" @ #x72d0c35a> 29 X-SPACING ----> fixnum 0 [#x00000000] 30 Y-SPACING ----> fixnum 0 [#x00000000] 31 ALIGN-X ------> The symbol :LEFT 32 ALIGN-Y ------> The symbol :TOP 33 CHILDREN -----> The symbol NIL 34 RECORDING-P --> The symbol T 35 DRAWING-P ----> The symbol T 36 OUTPUT-HISTORY -> #<STANDARD-TREE-OUTPUT-HISTORY X 0.0d0:6952.0 Y 0.0d0:4261.5 @ #x72d0c36a> 37 CURRENT-OUTPUT-RECORD -> #<STANDARD-TREE-OUTPUT-HISTORY X 0.0d0:6952.0 Y 0.0d0:4261.5 @ #x72d0c36a> 38 CURRENT-TEXT-OUTPUT-RECORD -> The symbol NIL 39 LOCAL-RECORD-P -> The symbol T ... 123 (MISC C APPLICATION-PANE) -> #<Function STM-FUNDAMENTAL-MISC>
2. I have three flavors of layouts, two use the built in graph types, and one uses my own, experimental tree-with-cross-edges graph subtype. Previously they all three worked (for some definition of "worked," that does not extend to "lays out graphs in an aesthetically-pleasing way :->). Now only my own tree-with-cross-edges works; the other two seem to display nothing, although I can see a traced call to format-graph-from-roots, I find reasonable bounds (which *should* trigger the addition of scroll bars, AFAICT), and if I take a long and laborious trip down into the guts of the pane's output record, I find a CLIMI::DAG-GRAPH-OUTPUT-RECORD inside a STANDARD-SEQUENCE-OUTPUT-RECORD inside a STANDARD-UPDATING-OUTPUT-RECORD.
As I said, this used to work, but alas, that was even before the addition of spatial-trees, so I'm not sure where this went south.
Any suggestions about how I might figure out why this is not showing up?
Actually, it might be as simple as the graph being so large that none of it actually appears in the part of the pane that is actually displayed... So perhaps the answer to this question reduces to answering question 1...