Handbook
Glossary
write-gadget ( gadget stream -- )
Factor handbook
»
UI framework
»
Building user interfaces
»
Pre-made UI gadgets
»
Pane gadgets
Prev:
<pane-stream> ( pane -- pane-stream )
Next:
print-gadget ( gadget stream -- )
Vocabulary
ui
.
gadgets
.
panes
Inputs
gadget
a
gadget
stream
an output stream
Outputs
None
Generic word contract
Writes a gadget to the stream.
Notes
Not all streams support this operation.
See also
print-gadget
,
gadget.
Definition
IN:
ui.gadgets.panes
GENERIC:
write-gadget
( gadget stream -- )
Methods
USING:
accessors
io.styles
ui.gadgets.panes
;
M:
filter-writer
write-gadget
stream>>
write-gadget
;
USING:
io
kernel
ui.gadgets.panes
;
M:
object
write-gadget
[
gadget-alt-text
]
dip
stream-write
;
USING:
accessors
kernel
ui.gadgets
ui.gadgets.panes
ui.gadgets.panes.private
;
M:
pane-stream
write-gadget
[
current>>
swap
add-gadget
drop
]
do-pane-stream
;