1
0
mirror of https://github.com/azure-rtos/guix.git synced 2025-02-04 07:13:17 +08:00
guix/tutorials/demo_guix_scrollbar/demo_guix_scrollbar.c

52 lines
1.8 KiB
C
Raw Permalink Normal View History

2021-04-03 01:05:26 +00:00
/* This is a small demo of the high-performance GUIX graphics framework. */
#include <stdio.h>
#include "gx_api.h"
#include "demo_guix_scrollbar_resources.h"
#include "demo_guix_scrollbar_specifications.h"
/* Define variables. */
GX_WINDOW_ROOT *root;
/* Define prototypes. */
VOID start_guix(VOID);
extern UINT win32_graphics_driver_setup_24xrgb(GX_DISPLAY *display);
/******************************************************************************************/
/* Application entry. */
/******************************************************************************************/
int main(int argc, char ** argv)
{
tx_kernel_enter();
return(0);
}
/******************************************************************************************/
/* Define tx_application_define function. */
/******************************************************************************************/
VOID tx_application_define(void *first_unused_memory)
{
start_guix();
}
/******************************************************************************************/
/* Initiate and run GUIX. */
/******************************************************************************************/
VOID start_guix(VOID)
{
/* Initialize GUIX. */
gx_system_initialize();
/* Configure display. */
gx_studio_display_configure(DISPLAY_1, win32_graphics_driver_setup_24xrgb,
LANGUAGE_ENGLISH, DISPLAY_1_THEME_1, &root);
/* create the main screen */
gx_studio_named_widget_create("main_screen", (GX_WIDGET *) root, GX_NULL);
/* Show the root window to make it and patients screen visible. */
gx_widget_show(root);
/* let GUIX run */
gx_system_start();
}