ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Controls, pages and windows / Animation functions / Animation of windows
  • Overview
  • How to?
  • Configuring the animation of windows at project level
  • Configuring the animation of windows at window level
  • Configuring the animation of windows through programming
  • Automatic feature: Disabling the animation
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Overview
To give your applications an outstanding touch and to impress the users when starting your applications, the windows can be animated when they are opened and/or closed: a window can turn around when it is opened, coming from the background of the screen, ... (a little bit like video effects).
The effect can be fixed or chosen at random.
This feature can be defined in the options of the project, in the window description or through programming.
If a window loads several elements, an "animation" (performed independently of the current processes) allows the users to wait for the window to be ready!
This feature must be used sparingly to avoid annoying the users. You can for example animate the first window of your application or limit this animation to a specific number of windows.
Remark: The context menu of windows (AAFs) allows the user to disable the animations of windows ("Disable the animations of windows"). For more details, see Automatic feature: Disabling the animation.
How to?

Configuring the animation of windows at project level

To configure the animation of windows at project level:
  1. Open the project description window: on the "Project" tab, in the "Project" group, click "Description".
  2. In the "Advanced" tab, click "Animations of windows".
  3. The window that is displayed allows you to configure the animation:
    • of the first project window.
    • all the project windows.
To configure the animation of the first project window:
  1. Choose the animation to perform (opening or closing) and click the "None" link.
  2. In the window that appears, check "Enable animation" and select the animation parameters:
    • Duration of animation (in hundredths of a second).
    • Type of animation (if the random mode is chosen, the animation will be automatically selected by the application whenever the window is opened).
  3. The "Preview" button allows you to view the selected parameters.
  4. You can also apply the selected animation to the current window (check "Animate this description window").
  5. Validate.
Remark: A window must necessarily be defined as "First project window".
To configure the animation of all project windows:
  1. Choose the animation to perform (opening or closing) and click the "None" link.
  2. In the window that appears, check "Enable animation" and select the animation parameters:
    • Duration of animation (in hundredths of a second).
    • Type of animation (if the random mode is chosen, the animation will be automatically selected by the application whenever the window is opened).
  3. The "Preview" button allows you to view the selected parameters.
  4. You can also apply the selected animation to the current window (check "Animate this description window").
  5. Validate.
  6. Specify the frequency of animations:
    • Always: the animation will be performed on each application window.
    • Often: the animation will be performed whenever a window out of ten is opened/closed.
    • Rarely: the animation will be performed whenever a window out of thirty is opened/closed.
    • Custom frequency.
Remark: This setting is taken into account by all the windows with no specific setting. For example:
  • if the opening animation defined for all the project windows corresponds to "None" and if an opening animation was configured for the "WIN_Customer" window, this animation will be performed when opening the "WIN_Customer" window.
  • if the opening animation defined for all the project windows corresponds to "Custom" and if an opening animation was configured for the "WIN_Customer" window, the animation defined for the "WIN_Customer" window will be performed when this window is opened.

Configuring the animation of windows at window level

To configure the animation of windows at window level:
  1. Open the window to animate in the window editor.
  2. Open the window description (select "Description" in the context menu).
  3. In the "Details" tab, choose the type of animation to perform (opening or closing) and click the "None" link.
  4. In the window that appears, check "Enable animation" and select the animation parameters:
    • Duration of animation (in hundredths of a second).
    • Type of animation (if the random mode is chosen, the animation will be automatically selected by the application whenever the window is opened).
  5. The "Preview" button allows you to view the selected parameters.
  6. You can also apply the selected animation to the current window (check "Animate this description window").
  7. Validate.
Remark: This setting is applied to the current window even if a different setting was specified at project level.

Configuring the animation of windows through programming

Several WLanguage functions are used to configure the animation of windows:
WinAnimationClosingModifies the type and duration of the animation used when closing the application windows.
WinAnimationNextModifies the type and duration of animations used when opening and closing the next window.
WinAnimationOpeningModifies the type and duration of animations used when opening the application windows.
These functions can be applied to the windows for which no animation was configured otherwise (from the project editor or from the window editor for example).
WinDisableEffect is used to disable the animation of windows (on a TSE computer with low bandwidth for example).

Automatic feature: Disabling the animation

The user can disable the window animations at any time, via the option "Disable window animations" in the window context menu. This option prevents the use of window animations on all the windows of the project.
To avoid proposing this option in the popup menu of windows, you can:
  • disable the option for all the project windows:
    1. On the "Project" tab, in the "Project" group, click "Description". The project description window appears.
    2. In the "Advanced" tab, click "AAF menu".
    3. Select the "Window" element and uncheck "Disable the animations of windows".
  • disable the option when necessary, through programming with AAFDisable associated with the aafDisableWindowAnimation constant.
Related Examples:
Animation when opening and closing the windows Unit examples (WINDEV): Animation when opening and closing the windows
[ + ] Using window animations (opening or closing).
You also have the ability to see the available animations.
You have the ability to modify the different parameters such as the duration of the animation for example.
Minimum version required
  • Version 10
Comments
Click [Add] to post a comment

Last update: 06/22/2023

Send a report | Local help