Problems with grid-layout
I'm trying to implement a capi interface which has a very dynamic grid-layout as one of its parts. I set the layout-description of this grid-layout this way (where slot-input-pane generates two sub-panes, one is a column-layout consisting of a title-pane and a button and one is either a grid-layout with complex contents or an empty title-pane): (defmethod make-edit-lists ((csf customer-select-form)) (with-slots (edit edit-lists edit-main edit-buttons edited-customer) csf (let ((alist-panes (loop for things in (customer-alists edited-customer) for slot = (first things) append (slot-input-pane csf slot nil)))) (setf (layout-description edit-lists) alist-panes)))) This almost works, but sometimes the program crashes while doing the (setf layout-description), and I end up with a backtrace like the one below. Any ideas? Error: In a call to ARRAY-DIMENSION: NIL is not of type ARRAY. 1 (abort) Return to event loop. Type :b for backtrace, :c <option number> to proceed, or :? for other options CL-USER 1 : 1 > :b Call to (METHOD CAPI:CALCULATE-CONSTRAINTS (CAPI:GRID-LAYOUT)) Call to (METHOD CAPI::CALCULATE-INTERNAL-CONSTRAINTS (CAPI::SIMPLE-ELEMENT)) Call to CLOS::NEXT-METHOD-CALL-1 Call to (METHOD CAPI::CALCULATE-INTERNAL-CONSTRAINTS :AROUND (CAPI:SIMPLE-PANE)) Call to (METHOD CAPI::CALCULATE-EXTERNAL-CONSTRAINTS (CAPI::SIMPLE-ELEMENT)) Call to CLOS::NEXT-METHOD-CALL-1 Call to CLOS::NEXT-METHOD-CALL-1 Call to (METHOD CAPI::CALCULATE-EXTERNAL-CONSTRAINTS :AROUND (CAPI:SIMPLE-PANE)) Call to CAPI-INTERNALS:GET-CONSTRAINTS Call to (SUBFUNCTION 3 (METHOD CAPI:CALCULATE-CONSTRAINTS (CAPI:GRID-LAYOUT))) Call to CAPI::CALCULATE-GRID-CONSTRAINTS-1 Call to (METHOD CAPI:CALCULATE-CONSTRAINTS (CAPI:GRID-LAYOUT)) Call to (METHOD CAPI::CALCULATE-INTERNAL-CONSTRAINTS (CAPI::SIMPLE-ELEMENT)) Call to CLOS::NEXT-METHOD-CALL-1 Call to (METHOD CAPI::CALCULATE-INTERNAL-CONSTRAINTS :AROUND (CAPI:SIMPLE-PANE)) Call to (METHOD CAPI::CALCULATE-EXTERNAL-CONSTRAINTS (CAPI::SIMPLE-ELEMENT)) Call to CLOS::NEXT-METHOD-CALL-1 Call to (METHOD CAPI::CALCULATE-EXTERNAL-CONSTRAINTS :AROUND (CAPI::SIMPLE-ELEME NT)) Call to CLOS::NEXT-METHOD-CALL-1 Call to (METHOD CAPI::CALCULATE-EXTERNAL-CONSTRAINTS :AROUND (CAPI:SIMPLE-PANE)) Call to CAPI-INTERNALS:GET-CONSTRAINTS Call to CAPI::PANE-UPDATE-GEOMETRY-OF-CHILDREN Call to (METHOD CAPI:MAP-PANE-CHILDREN (CAPI:LAYOUT T)) Call to (METHOD CAPI::CHANGE-CHILDREN-GEOMETRY (CAPI::PANE-WITH-CHILDREN)) Call to (METHOD CAPI:MAP-PANE-CHILDREN (CAPI:LAYOUT T)) Call to (METHOD CAPI::CHANGE-CHILDREN-GEOMETRY (CAPI::PANE-WITH-CHILDREN)) Call to (METHOD CAPI:MAP-PANE-CHILDREN (CAPI:LAYOUT T)) Call to (METHOD CAPI::CHANGE-CHILDREN-GEOMETRY (CAPI::PANE-WITH-CHILDREN)) Call to (METHOD CAPI:MAP-PANE-CHILDREN (CAPI:LAYOUT T)) Call to (METHOD CAPI::CHANGE-CHILDREN-GEOMETRY (CAPI::PANE-WITH-CHILDREN)) Call to (METHOD CAPI::CHANGE-CHILDREN-GEOMETRY (CAPI::PANE-WITH-CHILDREN)) Call to CAPI::DO-REDISPLAY Call to (METHOD CAPI::REDISPLAY (CAPI::PANE-WITH-CHILDREN)) Call to CLOS::NEXT-METHOD-CALL-1 Call to (METHOD CAPI-INTERNALS:CAPI-GEOMETRY-CHANGE-CALLBACK (CAPI:INTERFACE T T T T T)) Call to MP::PROCESS-ALL-EVENTS Call to CAPI-MOTIF-LIBRARY::DO-DESTROY Call to CAPI::EXECUTE-WITH-INTERFACE-INTERNAL Call to CAPI-MOTIF-LIBRARY::PERFORM-WINDOW-DESTROY Call to (METHOD CAPI:MAP-PANE-CHILDREN (CAPI:LAYOUT T)) Call to (METHOD CAPI::IMMEDIATE-DESTROY :AFTER (CAPI::PANE-WITH-CHILDREN)) Call to (METHOD CAPI:DESTROY (CAPI:SIMPLE-PANE)) Call to (METHOD CAPI:MAP-PANE-CHILDREN (CAPI:LAYOUT T)) Call to CAPI::LAYOUT-INSTALL-PANES Call to (METHOD CAPI::MAYBE-INSTALL-DESCRIPTION (CAPI:LAYOUT)) Call to (METHOD CAPI::REDO-LAYOUT (CAPI:LAYOUT)) Call to (METHOD CAPI::INVALIDATE-PANE-CONSTRAINTS-WITH-CONTROL-OVER-REDISPLAY (C API:LAYOUT)) Call to CAPI::INVALIDATE-PANE-CONSTRAINTS-WITH-REDISPLAY Call to CAPI::REDISPLAY-LAYOUT-CREATING-UNMAPPED-CHILDREN Call to (METHOD CAPI::SET-LAYOUT-DESCRIPTION (CAPI:LAYOUT T)) Call to CAPI::EXECUTE-CALLBACK Call to CAPI-INTERNALS:LOOP-PROCESS-EVENTS Call to CAPI::INTERFACE-EVENT-LOOP Call to CAPI::INITIALIZE-AND-PROCESS-EVENTS Call to (METHOD CAPI-LIBRARY:INTERFACE-PROCESS-WRAPPER (CAPI-MOTIF-LIBRARY::SCRE -- (espen)