MiniGUI API Reference (MiniGUI-Threads)
v3.2.0
A mature and proven cross-platform GUI system for embedded and smart IoT devices
|
Data Structures | |
struct | _DESKTOPOPS |
Macros | |
#define | ReinitDesktop() ReinitDesktopEx (TRUE) |
Re-initializes the desktop including the local system text. More... | |
#define | MiniGUIMain |
The main entry of a MiniGUI application. More... | |
#define | IDM_DTI_FIRST (300) |
The minimum interger value of command ID when user customize desktop menu. More... | |
Typedefs | |
typedef struct _DESKTOPOPS | DESKTOPOPS |
Functions | |
MG_EXPORT BOOL GUIAPI | ReinitDesktopEx (BOOL init_sys_text) |
Re-initializes the desktop. More... | |
MG_EXPORT void GUIAPI | ExitGUISafely (int exitcode) |
Exits your MiniGUI application safely. More... | |
MG_EXPORT DESKTOPOPS *GUIAPI | SetCustomDesktopOperationSet (DESKTOPOPS *usr_dsk_ops) |
Set customer desktop operation set. More... | |
MG_EXPORT void GUIAPI | DesktopUpdateAllWindow (void) |
Update all visible windows on the desktop. More... | |
Normally, the only entry of any MiniGUI application is MiniGUIMain. The application will terminate when you call exit(3) or just return from MiniGUIMain.
Example 1:
Example 2:
#define IDM_DTI_FIRST (300) |
#define MiniGUIMain |
The main entry of a MiniGUI application.
This function should be defined by your application. Before Version 1.6.1, MiniGUI defines main() function in libminigui library for your application, and call MiniGUIMain() in this main() function. The main() defined by MiniGUI is responsible of initializing and terminating MiniGUI.
After version 1.6.1, MiniGUI defines MiniGUIMain as a macro.
args | The number of arguments passed to main() by operating system. |
argv | The arguments passed to main() by operating system. |
#define ReinitDesktop | ( | ) | ReinitDesktopEx (TRUE) |
Re-initializes the desktop including the local system text.
typedef struct _DESKTOPOPS DESKTOPOPS |
Desktop operation set
void GUIAPI DesktopUpdateAllWindow | ( | void | ) |
Update all visible windows on the desktop.
On MiniGUI-Processes update all the main windows of the client and desktop window, and it only can be used by mginit on MiniGUI-Processes. On MiniGUI-Threads and MiniGUI-Standalone update all visible windows and desktop window.
void GUIAPI ExitGUISafely | ( | int | exitcode | ) |
Exits your MiniGUI application safely.
Calling this function will terminate your MiniGUI application. This function will restore console attributes and call exit() function and pass exitcode to it.
exitcode | The exit status will be passed to exit(3) function. |
Re-initializes the desktop.
When you changed the charset or the background picture of the desktop, you should call this function to re-initialize the local system text (when init_sys_text is TRUE), the background picture, and the desktop menu.
init_sys_text | Indicates whether to initialize the local system text. |
DESKTOPOPS *GUIAPI SetCustomDesktopOperationSet | ( | DESKTOPOPS * | usr_dsk_ops | ) |
Set customer desktop operation set.
usr_dsk_ops | The pointer to user customer desktop operation set. |