MiniGUI API Reference (MiniGUI-Standalone)  v5.0.6
A mature and proven cross-platform GUI system for embedded and smart IoT devices
Macros

This control can be used to play the animation object, and you should specify the animation object when you create the control by using the dwAddData: More...

Macros

#define ANS_AUTOLOOP   0x0001L
 Loop playing the animation automatically. More...
 
#define ANS_SCALED   0x0002L
 Scale the animation to the control size. More...
 
#define ANS_FITTOANI   0x0004L
 Resize the control to fit the animation. More...
 
#define ANS_WINBGC   0x0010L
 Use the background color of the window. More...
 

Detailed Description

This control can be used to play the animation object, and you should specify the animation object when you create the control by using the dwAddData:

HWND hwnd;
if (anim == NULL)
goto error;
hwnd = CreateWindow (CTRL_ANIMATION,
"",
100,
10, 10, 300, 200, hWnd, (DWORD)anim);
SendMessage (hwnd, ANM_STARTPLAY, 0, 0);

Macro Definition Documentation

◆ ANS_AUTOLOOP

#define ANS_AUTOLOOP   0x0001L

Loop playing the animation automatically.

Definition at line 238 of file animation.h.

◆ ANS_FITTOANI

#define ANS_FITTOANI   0x0004L

Resize the control to fit the animation.

Definition at line 250 of file animation.h.

◆ ANS_SCALED

#define ANS_SCALED   0x0002L

Scale the animation to the control size.

Definition at line 244 of file animation.h.

◆ ANS_WINBGC

#define ANS_WINBGC   0x0010L

Use the background color of the window.

Definition at line 256 of file animation.h.

WS_VISIBLE
#define WS_VISIBLE
Creates a window initially visible.
Definition: window.h:4292
NULL
#define NULL
A value indicates null pointer.
Definition: common.h:369
DWORD
DWORD_PTR DWORD
A unsigned long type definition for pointer precision.
Definition: common.h:604
HWND
GHANDLE HWND
Handle to main window or control.
Definition: common.h:407
ANM_STARTPLAY
#define ANM_STARTPLAY
Indicates the control to start playing the animation.
Definition: animation.h:317
ANS_AUTOLOOP
#define ANS_AUTOLOOP
Loop playing the animation automatically.
Definition: animation.h:238
CreateAnimationFromGIF89aFile
MG_EXPORT ANIMATION * CreateAnimationFromGIF89aFile(HDC hdc, const char *file)
Creates an ANIMATION obeject from a GIF 89a file.
CTRL_ANIMATION
#define CTRL_ANIMATION
Definition: animation.h:200
_ANIMATION
Definition: animation.h:115
HDC_SCREEN
#define HDC_SCREEN
Handle to the device context of the whole screen or the fake screen when MiniGUI is running under Min...
Definition: gdi.h:1358
SendMessage
MG_EXPORT LRESULT GUIAPI SendMessage(HWND hWnd, UINT nMsg, WPARAM wParam, LPARAM lParam)
Send a message to a window and wait for the handling result.