Rebol Programming/in-window?

From Wikibooks, open books for an open world
Jump to navigation Jump to search

USAGE:

[edit | edit source]
IN-WINDOW? window face 

DESCRIPTION:

[edit | edit source]

Return true if a window contains a given face.

IN-WINDOW? is a function value.

ARGUMENTS:

[edit | edit source]
  • window -- (Type: any)
  • face -- (Type: any)

SOURCE CODE

[edit | edit source]
in-window?: func [
    "Return true if a window contains a given face." 
    window face
][
    if face = window [return true] 
    if none? face/parent-face [return false] 
    in-window? window face/parent-face
]