]> gitweb.factorcode.org Git - factor.git/blob - basis/ui/gadgets/status-bar/status-bar-docs.factor
docs: change $subsection to $subsections
[factor.git] / basis / ui / gadgets / status-bar / status-bar-docs.factor
1 USING: help.markup help.syntax models strings
2 ui.gadgets ui.gadgets.worlds ui ;
3 IN: ui.gadgets.status-bar
4
5 HELP: show-status
6 { $values { "string/f" string } { "gadget" gadget } }
7 { $description "Displays a status message in the gadget's world." }
8 { $notes "The status message will only be visible if the window was opened with " { $link open-status-window } ", and not " { $link open-window } "." } ;
9
10 HELP: hide-status
11 { $values { "gadget" gadget } }
12 { $description "Hides the status message in the gadget's world." }
13 { $notes "The gadget passed in must be the gadget passed to " { $link show-status } ", otherwise the word does nothing. This ensures that one gadget does not hide another gadget's status message." } ;
14
15 HELP: <status-bar>
16 { $values { "model" model } { "gadget" "a new " { $link gadget } } }
17 { $description "Creates a new " { $link gadget } " displaying the model value, which must be a string or " { $link f } "." }
18 { $notes "If the " { $snippet "model" } " is " { $snippet "status" } ", this gadget will display mouse over help for " { $link "ui.gadgets.presentations" } "." } ;
19
20 HELP: open-status-window
21 { $values { "gadget" gadget } { "title/attributes" { "a " { $link string } " or a " { $link world-attributes } " tuple" } } }
22 { $description "Like " { $link open-window } ", with the additional feature that the new window iwll have a status bar displaying the value stored in the world's " { $slot "status" } " slot." }
23 { $see-also show-status hide-status } ;
24
25 ARTICLE: "ui.gadgets.status-bar" "Status bars and mouse-over help"
26 "The " { $vocab-link "ui.gadgets.status-bar" } " vocabulary implements a word to display windows with a status bar."
27 { $subsections open-status-window }
28 "Gadgets can use a pair of words to show and hide status bar messages. These words will work in any gadget, but will have no effect unless the gadget is displayed inside a window with a status bar."
29 { $subsections
30     show-status
31     hide-status
32 }
33 { $link "ui.gadgets.presentations" } " use the status bar to display object summary." ;
34
35 ABOUT: "ui.gadgets.status-bar"