Reference Manual: (offline | online) Quickstart: (offline | online)

# Fade

Function: Fade( | out_time, hold_time, in_time, old_widget=None, new_widget=None, color=None, widget=None)

This returns an object that can be used as an argument to a with statement to fade the old scene into a solid color, waits for a given amount of time, and then fades from the solid color into the new scene.

out_time - The amount of time that will be spent fading from the old scene to the solid color. A float, given as seconds.

hold_time - The amount of time that will be spent displaying the solid color. A float, given as seconds.

in_time - The amount of time that will be spent fading from the solid color to the new scene. A float, given as seconds.

color - The solid color that will be fade to. A tuple containing three components, each between 0 or 255. This can also be `None`.

widget - This is a widget that will be faded to, if color is `None`. This allows a fade to be to an image rather than just a solid color.

If both color and widget are `None`, then the fade is to black.

## Example

    init:
        $ fade = Fade(.5, 0, .5) # Fade to black and back.

    scene bg washington with fade

Reference Manual: (offline | online) Quickstart: (offline | online)