]> gitweb.factorcode.org Git - factor.git/blob - basis/ui/gadgets/frames/frames-docs.factor
Fix conflicts
[factor.git] / basis / ui / gadgets / frames / frames-docs.factor
1 USING: help.syntax help.markup ui.gadgets kernel arrays math help sequences
2 quotations classes.tuple ui.gadgets.grids ;
3 IN: ui.gadgets.frames
4
5 ARTICLE: "ui-frame-layout" "Frame layouts"
6 "Frames extend " { $link "ui-grid-layout" } " with the ability to give all remaining space to a distinguished filled cell."
7 $nl
8 "The filled cell's column/row pair is stored in the frame gadget's " { $slot "filled-cell" } " slot. If the actual dimensions of a frame exceed it preferred dimensions, then the fill slot is resized appropriately, together with its row and column."
9 $nl
10 "Because frames inherit from grids, grid layout words can be used to add and remove children."
11 { $subsection frame }
12 "Creating empty frames:"
13 { $subsection <frame> } ;
14
15 HELP: frame
16 { $class-description "A frame is a gadget which lays out its children in a grid, and assigns all remaining space to a distinguished filled cell. The " { $slot "filled-cell" } " slot stores a pair with shape " { $snippet "{ col row }" } "."
17 $nl
18 "Frames are constructed by calling " { $link <frame> } " and since they inherit from " { $link grid } ", children can be managed with " { $link grid-add } " and " { $link grid-remove } "." } ;
19
20 HELP: <frame>
21 { $values { "cols" integer } { "rows" integer } { "frame" frame } }
22 { $description "Creates a new " { $link frame } " for laying out gadgets in a grid." } ;
23
24 { grid frame } related-words
25
26 ABOUT: "ui-frame-layout"