ui.pixel-formats: fix using list in example

db4
Keita Haga 2010-12-23 03:10:54 +09:00
parent f4c6b868ac
commit 33c14b8bb0
1 changed files with 2 additions and 4 deletions

View File

@ -45,8 +45,7 @@ ARTICLE: "ui.pixel-formats-attributes" "Pixel format attributes"
}
{ $examples
"The following " { $link world } " subclass will request a double-buffered window with minimum 24-bit color and depth buffers, and will throw an error if the requirements aren't met:"
{ $code """
USING: kernel ui.worlds ui.pixel-formats ;
{ $code """USING: kernel ui.gadgets.worlds ui.pixel-formats ;
IN: ui.pixel-formats.examples
TUPLE: picky-depth-buffered-world < world ;
@ -63,8 +62,7 @@ M: picky-depth-buffered-world check-world-pixel-format
[ double-buffered pixel-format-attribute 0 = [ "Not double buffered!" throw ] when ]
[ color-bits pixel-format-attribute 24 < [ "Not enough color bits!" throw ] when ]
[ depth-bits pixel-format-attribute 24 < [ "Not enough depth bits!" throw ] when ]
tri ;
""" } }
tri ;""" } }
;
HELP: double-buffered