[Prev][Next][Index][Thread]

DUIM: define frame q?



Suppose I have a define frame with a table, like:

define frame <template-frame> (<simple-frame>)
  pane main-pane (frame)
  make (<table-control>, ...);

What I want to do is provide keyword arguments for the table via the
frame instantiation, like:

start-frame (make (<template-frame>, 
                                     headings: my-headings, 
                                     generators: my-generators, 
                                     items: my-items));

and have the passed in arguments be used for the headings:, generators:,
and items: arguments to make (<table-control>). But I can't figure out a
straightforward syntax for this.

The 3 alternatives I have thought of:

1) stuff the values into global variables that are referenced in the
define frame (YUCK!)

2) don't use define frame; build the frame using nested calls to make
and passing the values to make (<table-control>) where appropriate (kind
of complicated)

3) create my own macro???

Part of my problem is that I haven't worked through the multiple levels
of macro expansion kicked off by define frame. So I don't understand the
underlying classes/methods generated and how they fit together.



Follow-Ups: