1 USING: help.syntax help.markup kernel math classes classes.tuple
\r
6 { $class-description "Product model values are computed by collecting the values from a sequence of underlying models into a new sequence. Product models are automatically updated when underlying models change. Product models are constructed by " { $link <product> } "."
\r
8 "A product 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 models.product models.range ui.gadgets"
\r
13 "ui.gadgets.labels ui.gadgets.packs ui.gadgets.panes"
\r
14 "ui.gadgets.sliders ;"
\r
16 ": <funny-model> ( -- model ) 0 10 0 100 1 <range> ;"
\r
17 ": <funny-slider> ( model -- slider ) horizontal <slider> ;"
\r
19 "<funny-model> <funny-model> 2array"
\r
20 "[ <pile> [ horizontal <slider> add-gadget ] reduce gadget. ]"
\r
21 "[ <product> [ unparse ] <arrow> <label-control> gadget. ]"
\r
27 { $values { "models" "a sequence of models" } { "product" "a new " { $link product } } }
\r
28 { $description "Creates a new instance of " { $link product } ". The value of the new product model is obtained by mapping the " { $snippet "value" } " slot accessor over the given sequence of models." }
\r
29 { $examples "See the example in the documentation for " { $link product } "." } ;
\r
31 ARTICLE: "models.product" "Product models"
\r
32 "Product model values are computed by collecting the values from a sequence of underlying models into a new sequence."
\r
38 ABOUT: "models.product"
\r