1 USING: help.syntax help.markup kernel math classes classes.tuple
\r
6 { $class-description "Composed model values are computed by collecting the values from a sequence of underlying models into a new sequence. Composed models are automatically updated when underlying models change. Composed models are constructed by " { $link <compose> } "."
\r
8 "A composed model whose children are all " { $link "models-range" } " conforms to the " { $link "range-model-protocol" } " and represents a point in n-dimensional space which is bounded by a rectangle." }
\r
10 "The following code displays a pair of sliders, and an updating label showing their current values:"
\r
12 "USING: models ui.gadgets.labels ui.gadgets.sliders ui.gadgets.panes ;"
\r
13 ": <funny-slider> <x-slider> 100 over set-slider-max ;"
\r
14 "<funny-slider> <funny-slider> 2array"
\r
15 "dup make-pile gadget."
\r
16 "dup [ gadget-model ] map <compose> [ unparse ] <filter>"
\r
17 "<label-control> gadget."
\r
22 { $values { "models" "a sequence of models" } { "compose" "a new " { $link compose } } }
\r
23 { $description "Creates a new instance of " { $link compose } ". The value of the new compose model is obtained by mapping the " { $snippet "value" } " slot accessor over the given sequence of models." }
\r
24 { $examples "See the example in the documentation for " { $link compose } "." } ;
\r
26 ARTICLE: "models-compose" "Composed models"
\r
27 "Composed model values are computed by collecting the values from a sequence of underlying models into a new sequence."
\r
28 { $subsection compose }
\r
29 { $subsection <compose> } ;
\r
31 ABOUT: "models-compose"
\r