Difference between revisions of "emWin Examples"

From SEGGER Wiki
Jump to: navigation, search
(Created page with "The emWin examples have the purpose to explain and visualize emWin's features in a straight-forward and simplified way. Thus, most of these examples do not have elaborate grap...")
 
(List of examples)
Line 23: Line 23:
 
== List of examples ==
 
== List of examples ==
   
  +
=== 2D graphic operations ===
{| class="wikitable"
 
  +
! File(s) !! Description !! Download
 
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
  +
|style="font-family: monospace,monospace; width: 25%;"| [[DIRTYDEVICE (Sample)|GUI_DIRTYDEVICE_Usage.c]]
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''2D graphic operations'''
 
  +
|style="width: 75%;"| Demonstrates how to use DIRTYDEVICES. A DIRTYDEVICE monitors the area on the screen that is 'dirty', meaning the area where screen changes happened.
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DIRTYDEVICE_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Polygon (Sample)|GUI_Polygon.c]]
  +
|style="width: 75%;"| Demonstrates how to draw polygons and what can be done with them.
| Demonstrates how to use DIRTYDEVICES. A DIRTYDEVICE monitors the area on the screen that is 'dirty', meaning the area where screen changes happened.
 
| [https://wiki.segger.com/images/5/5a/GUI_DIRTYDEVICE_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_Polygon.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[QR Code (Sample)|GUI_QRCode.c]]
| Demonstrates how to draw polygons and what can be done with them.
+
|style="width: 75%;"|Shows how to draw a QR code with emWin.
| [https://wiki.segger.com/images/8/88/GUI_Polygon.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_QRCode.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Spline (Sample)|GUI_SPLINE.c]]
| Shows how to draw a QR code with emWin.
+
|style="width: 75%;"|Demonstrates how splines can be drawn with emWin.
| [https://wiki.segger.com/images/5/59/GUI_QRCode.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_SPLINE.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[YUV device (Sample)|GUI_YUV_PixelData.c]]
| Demonstrates how splines can be drawn with emWin.
+
|style="width: 75%;"|Demonstrates how splines can be drawn with emWin.
| [https://wiki.segger.com/images/c/cc/GUI_SPLINE.c Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Animations'''
 
  +
  +
=== Animations ===
  +
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_AdvancedAnimation.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Animation - simple (Sample)|GUI_AdvancedAnimation.c]]
| This sample demonstrates how more advanced animations can be created with emWin. The advanced animation makes use of slice callbacks, custom position calculation and several animation items.
+
|style="width: 75%;"|This sample demonstrates how more advanced animations can be created with emWin. The advanced animation makes use of slice callbacks, custom position calculation and several animation items.
| [https://wiki.segger.com/images/1/14/GUI_AdvancedAnimation.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_SimpleAnimation.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Animation - advanced (Sample)|GUI_SimpleAnimation.c]]
| Shows how to perform simple animations using emWin. This example shows the basic steps for creating an animation, such as creating and running it, adding animation items and using a delete callback routine.
+
|style="width: 75%;"|Shows how to perform simple animations using emWin. This example shows the basic steps for creating an animation, such as creating and running it, adding animation items and using a delete callback routine.
| [https://wiki.segger.com/images/f/f6/GUI_SimpleAnimation.c Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Bitmaps and images'''
 
  +
  +
=== Bitmaps and images ===
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_CreateBitmapFromStream.c <br/> segger-logo.dta
+
|style="font-family: monospace,monospace; width: 25%;"| [[Create streamed bitmap (Sample)|GUI_CreateBitmapFromStream.c]]
| Creates and draws a streamed bitmap from an external .dta file. The example supports both the usage of Windows file system and [[emFile]], if run on a target.
+
|style="width: 75%;"|Creates and draws a streamed bitmap from an external .dta file. The example supports both the usage of Windows file system and [[emFile]], if run on a target.
| [https://wiki.segger.com/images/0/0c/GUI_CreateBitmapFromStream.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DrawAnimatedGIFBin.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Animated GIF (Sample)|GUI_DrawAnimatedGIFBin.c]]
| Draws an animated GIF image after it has been converted into binary form using [[Bin2C]].
+
|style="width: 75%;"|Draws an animated GIF image after it has been converted into binary form using [[Bin2C]].
| [https://wiki.segger.com/images/1/13/GUI_DrawAnimatedGIFBin.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DrawAnimatedSprite.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Animated sprite (Sample)|GUI_DrawAnimatedSprite.c]]
| Draws an animated GIF image after it has been converted into an animated sprite using the [[Bitmap Converter]].
+
|style="width: 75%;"|Draws an animated GIF image after it has been converted into an animated sprite using the [[Bitmap Converter]].
| [https://wiki.segger.com/images/e/ef/GUI_DrawAnimatedSprite.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DrawExternalImage_BMP.c <br/> segger-logo.bmp
+
|style="font-family: monospace,monospace; width: 25%;"| [[External image - BMP (Sample)|GUI_DrawExternalImage_BMP.c]]
| Shows how to draw BMP images in emWin from external memory. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how to draw BMP images in emWin from external memory. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/9/98/GUI_DrawExternalImage_BMP.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DrawExternalImage_GIF.c <br/> segger-logo.gif
+
|style="font-family: monospace,monospace; width: 25%;"| [[External image - GIF (Sample)|GUI_DrawExternalImage_GIF.c]]
| Shows how to draw GIF images in emWin from external memory. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how to draw GIF images in emWin from external memory. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/f/f3/GUI_DrawExternalImage_GIF.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DrawExternalImage_JPG.c <br/> segger-logo.jpg
+
|style="font-family: monospace,monospace; width: 25%;"| [[External image - JPG (sample)|GUI_DrawExternalImage_JPG.c]]
| Shows how to draw JPG images in emWin from external memory. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how to draw JPG images in emWin from external memory. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/7/78/GUI_DrawExternalImage_JPG.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DrawExternalImage_PNG.c <br/> segger-logo.png
+
|style="font-family: monospace,monospace; width: 25%;"| [[External image - PNG (Sample)|GUI_DrawExternalImage_PNG.c]]
| Shows how to draw PNG images in emWin from external memory. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how to draw PNG images in emWin from external memory. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/0/0f/GUI_DrawExternalImage_PNG.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_DrawStreamedBitmap.c <br/> segger-logo.dta
+
|style="font-family: monospace,monospace; width: 25%;"| [[Draw streamed bitmap (Sample)|GUI_DrawStreamedBitmap.c]]
| Demonstrates how streamed bitmaps can be drawn from external .dta files. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Demonstrates how streamed bitmaps can be drawn from external .dta files. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/4/4f/GUI_DrawStreamedBitmap.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_SerializeBMP.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Serialize BMP (Sample)|GUI_SerializeBMP.c]]
| Example that shows how screenshots can be created by serializing the LCD contents into a .bmp file. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Example that shows how screenshots can be created by serializing the LCD contents into a .bmp file. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/2/29/GUI_SerializeBMP.c Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Fonts'''
 
  +
  +
=== Fonts ===
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_SetExternalFont_TTF.c <br/> Roboto.ttf
+
|style="font-family: monospace,monospace; width: 25%;"| [[Set external TTF font (Sample)|GUI_SetExternalFont_TTF.c]]
| Shows how to create a custom font from an external .ttf file. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how to create a custom font from an external .ttf file. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/c/c8/GUI_SetExternalFont_TTF.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_SetExternalFont_XBF.c <br/> Roboto30.xbf
+
|style="font-family: monospace,monospace; width: 25%;"| [[Set external XBF font (Sample)|GUI_SetExternalFont_XBF.c]]
| Shows how to create a custom font from an external .xbf file. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how to create a custom font from an external .xbf file. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/9/90/GUI_SetExternalFont_XBF.zip Download]
 
 
|-
 
|-
  +
|style="font-family: monospace,monospace; width: 25%;"| [[Set TTF font (Sample)|GUI_SetFont_TTF.c]]
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Timers'''
 
  +
|style="width: 75%;"|Shows how to create a custom font from a .ttf file located in accessible memory.
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| GUI_Timers.c
 
  +
| Demonstrates how to use timers without the use of the WindowManager in emWin.
 
  +
=== Timers ===
| [https://wiki.segger.com/images/1/15/GUI_Timers.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
  +
|style="font-family: monospace,monospace; width: 25%;"| [[Timers (Sample)|GUI_Timers.c]]
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''MultiTouch'''
 
  +
|style="width: 75%;"|Demonstrates how to use timers without the use of the WindowManager in emWin.
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| GUI_MultiTouch.c
 
  +
| Shows how multi-touch points can be polled with emWin.
 
  +
=== MultiTouch ===
| [https://wiki.segger.com/images/4/46/GUI_MultiTouch.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
  +
|style="font-family: monospace,monospace; width: 25%;"| [[MultiTouch (Sample)|GUI_MultiTouch.c]]
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Dialogs'''
 
  +
|style="width: 75%;"|Demonstrates how to use timers without the use of the WindowManager in emWin.
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| CALENDAR_Usage.c
 
  +
| Demonstrates the usage of CALENDAR dialogs.
 
  +
=== Dialogs ===
| [https://wiki.segger.com/images/5/53/CALENDAR_Usage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| CHOOSECOLOR_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[CALENDAR (Sample)|CALENDAR_Usage.c]]
| Demonstrates the usage of CHOOSECOLOR dialogs.
+
|style="width: 75%;"|Demonstrates the usage of CALENDAR dialogs.
| [https://wiki.segger.com/images/4/49/CHOOSECOLOR_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| CHOOSEFILE_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[CHOOSECOLOR (Sample)|CHOOSECOLOR_Usage.c]]
| Demonstrates the usage of CHOOSEFILE dialogs.
+
|style="width: 75%;"|Demonstrates the usage of CHOOSECOLOR dialogs.
| [https://wiki.segger.com/images/8/8a/CHOOSEFILE_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| DIALOG_CreateDialogs.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[CHOOSEFILE (Sample)|CHOOSEFILE_Usage.c]]
  +
|style="width: 75%;"|Demonstrates the usage of CHOOSEFILE dialogs.
| Shows how custom dialogs can be created.
 
| [https://wiki.segger.com/images/7/7c/DIALOG_CreateDialogs.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_Messagebox.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Create dialogs (Sample)|DIALOG_CreateDialogs.c]]
  +
|style="width: 75%;"|Shows how custom dialogs can be created.
| Demonstrates the usage of MESSAGEBOX dialogs.
 
| [https://wiki.segger.com/images/6/65/GUI_Messagebox.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| DIALOG_Keypad.c <br/> DIALOG_Keypad.h <br/> DIALOG_Keypad_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Messagebox (Sample)|GUI_Messagebox.c]]
  +
|style="width: 75%;"|Demonstrates the usage of MESSAGEBOX dialogs.
| The files DIALOG_Keypad.c and DIALOG_Keypad.h provide a QWERTY keyboard dialog, that can be integrated into an emWin application. The file DIALOG_Keypad_Usage.c shows how the keyboard dialog can be integrated and used.
 
| [https://wiki.segger.com/images/2/2b/DIALOG_Keypad.zip Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Language Support'''
 
  +
  +
=== Language Support ===
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_LANG_BiDiArabic.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[BiDi Arabic support (Sample)|GUI_LANG_BiDiArabic.c]]
| Demonstrates how arabic text can be displayed/used via bi-directional text support.
+
|style="width: 75%;"|Demonstrates how arabic text can be displayed/used via bi-directional text support.
| [https://wiki.segger.com/images/2/21/GUI_LANG_BiDiArabic.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_LANG_ReadCSV.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Read CSV file (Sample)|GUI_LANG_ReadCSV.c]]
| Shows how to read different languages from a .csv file that has been converted into binary form.
+
|style="width: 75%;"|Shows how to read different languages from a .csv file that has been converted into binary form.
| [https://wiki.segger.com/images/4/44/GUI_LANG_ReadCSV.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_LANG_ReadCSVEx.c <br/> SampleCSV.csv
+
|style="font-family: monospace,monospace; width: 25%;"| [[Read external CSV file (Sample)|GUI_LANG_ReadCSVEx.c]]
| Shows how to read different languages from a .csv file that is located in external memory. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how to read different languages from a .csv file that is located in external memory. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/4/4b/GUI_LANG_ReadCSVEx.zip Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_LANG_Thai.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Thai support (Sample)|GUI_LANG_Thai.c]]
| Demonstrates how thai text can be displayed/used via thai text support.
+
|style="width: 75%;"|Demonstrates how thai text can be displayed/used via thai text support.
| [https://wiki.segger.com/images/1/19/GUI_LANG_Thai.c Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Memory Devices'''
 
  +
  +
=== Memory Devices ===
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_MEMDEV_BlurringAndBlending.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Memory Device - Blur and blend (Sample)|GUI_MEMDEV_BlurringAndBlending.c]]
| Shows how blurring and blending operations are done using memory devices.
+
|style="width: 75%;"|Shows how blurring and blending operations are done using memory devices.
| [https://wiki.segger.com/images/2/22/GUI_MEMDEV_BlurringAndBlending.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_MEMDEV_Container.c <br/> seggerlogo.jpg
+
|style="font-family: monospace,monospace; width: 25%;"| [[Memory Device - Container (Sample)|GUI_MEMDEV_Container.c]]
| Shows how memory devices can be used as a container to pre-load JPEG images (or something else) to avoid flickering.
+
|style="width: 75%;"|Shows how memory devices can be used as a container to pre-load JPEG images (or something else) to avoid flickering.
| [https://wiki.segger.com/images/0/0b/GUI_MEMDEV_Container.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_MEMDEV_Fading.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Memory Device - Fading (Sample)|GUI_MEMDEV_Fading.c]]
| Demonstrates how a fading animation between two windows can be executed using memory devices.
+
|style="width: 75%;"|Demonstrates how a fading animation between two windows can be executed using memory devices.
| [https://wiki.segger.com/images/3/34/GUI_MEMDEV_Fading.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_MEMDEV_Rotate.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Memory Device - Rotate (Sample)|GUI_MEMDEV_Rotate.c]]
| Shows how to rotate images using memory devices.
+
|style="width: 75%;"|Shows how to rotate images using memory devices.
| [https://wiki.segger.com/images/4/43/GUI_MEMDEV_Rotate.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_MEMDEV_SerializeBMP.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Memory Device - Serialize BMP (Sample)|GUI_MEMDEV_SerializeBMP.c]]
| Shows how bitmap files can be created from the contents of a memory device. Supports both the usage of Windows file system and emFile.
+
|style="width: 75%;"|Shows how bitmap files can be created from the contents of a memory device. Supports both the usage of Windows file system and emFile.
| [https://wiki.segger.com/images/3/33/GUI_MEMDEV_SerializeBMP.c Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Movies'''
 
  +
  +
=== Movies ===
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_MOVIE_CreateMovie.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[MOVIE (Sample)|GUI_MOVIE_CreateMovie.c]]
| Demonstrates how to display an emWin movie from accessable memory.
+
|style="width: 75%;"|Demonstrates how to display an emWin movie from accessable memory.
| [https://wiki.segger.com/images/6/6d/GUI_MOVIE_CreateMovie.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_MOVIE_CreateMovieEx.c <br/> Video.emf
+
|style="font-family: monospace,monospace; width: 25%;"| [[External MOVIE (Sample)|GUI_MOVIE_CreateMovieEx.c]]
| Demonstrates how to display an emWin movie from external memory.
+
|style="width: 75%;"|Demonstrates how to display an emWin movie from external memory.
| [https://wiki.segger.com/images/a/ad/GUI_MOVIE_CreateMovieEx.zip Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''VNC'''
 
  +
  +
=== VNC ===
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_VNC_FileTransfer.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[VNC file transfer (Sample)|GUI_VNC_FileTransfer.c]]
| Shows how to use a VNC server with emWin to transfer files.
+
|style="width: 75%;"|Shows how to use a VNC server with emWin to transfer files.
| [https://wiki.segger.com/images/8/83/GUI_VNC_FileTransfer.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GUI_VNC_StartServer.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Start VNC server (Sample)|GUI_VNC_StartServer.c]]
| Shows how to use a VNC server with emWin.
+
|style="width: 75%;"|Shows how to use a VNC server with emWin.
| [https://wiki.segger.com/images/e/eb/GUI_VNC_StartServer.c Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Widgets'''
 
  +
  +
=== Widgets ===
  +
  +
==== General ====
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| BUTTON_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Custom scrollbar (Sample)|WIDGET_CustomScrollbar.c]]
  +
|style="width: 75%;"|Explains how the SCROLLBAR of a widget can be customized and manipulated.
| Custom drawing of a BUTTON widget.
 
| [https://wiki.segger.com/images/0/04/BUTTON_Custom.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| BUTTON_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Custom widget callback (Sample)|WIDGET_CustomCallback.c]]
  +
|style="width: 75%;"|Explains how the callback of a widget can be overwritten.
| Usage of a BUTTON widget.
 
| [https://wiki.segger.com/images/5/57/BUTTON_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| CHECKBOX_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[OwnerDraw (Sample)|WIDGET_OwnerDraw.c]]
  +
|style="width: 75%;"|Shows how OwnerDraw routines can be set for widgets that support OwnerDraw.
| Custom drawing of a CHECKBOX widget.
 
| [https://wiki.segger.com/images/6/67/CHECKBOX_Custom.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| CHECKBOX_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[React on messages (Sample)|WIDGET_ReactOnMessages.c]]
  +
|style="width: 75%;"|Demonstrates how the application can react on messages sent by widgets.
| Usage of a CHECKBOX widget.
 
| [https://wiki.segger.com/images/a/ac/CHECKBOX_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| DROPDOWN_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Skinning properties (Sample)|WIDGET_SkinningProps.c]]
  +
|style="width: 75%;"|Shows how the appearance of widgets can be changed using skinning properties. This can only be done for widgets that support skinning.
| Custom drawing of a DROPDOWN widget.
 
| [https://wiki.segger.com/images/e/e8/DROPDOWN_Custom.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| DROPDOWN_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[Skinning routine (Sample)|WIDGET_SkinningRoutine.c]]
  +
|style="width: 75%;"|Shows how the appearance of widgets can be changed using a skinning routine. This can only be done for widgets that support skinning.
| Usage of a DROPDOWN widget.
 
| [https://wiki.segger.com/images/d/df/DROPDOWN_Usage.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| FRAMEWIN_Custom.c
 
  +
| Custom drawing of a FRAMEWIN widget.
 
  +
==== BUTTON widget ====
| [https://wiki.segger.com/images/b/b9/FRAMEWIN_Custom.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| FRAMEWIN_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[BUTTON - Custom (Sample)|BUTTON_Custom.c]]
| Usage of a FRAMEWIN widget.
+
|style="width: 75%;"|Custom drawing of a BUTTON widget.
| [https://wiki.segger.com/images/a/a6/FRAMEWIN_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| GRAPH_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[BUTTON - Usage (Sample)|BUTTON_Usage.c]]
| Custom drawing of a GRAPH widget.
+
|style="width: 75%;"|Usage of a BUTTON widget.
| [https://wiki.segger.com/images/a/a8/GRAPH_Custom.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| GRAPH_Usage.c
 
  +
| Usage of a GRAPH widget.
 
  +
==== CHECKBOX widget ====
| [https://wiki.segger.com/images/2/2c/GRAPH_Usage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| ICONVIEW_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[CHECKBOX - Custom (Sample)|CHECKBOX_Custom.c]]
| Custom drawing of a ICONVIEW widget.
+
|style="width: 75%;"|Custom drawing of a CHECKBOX widget.
| [https://wiki.segger.com/images/7/72/ICONVIEW_Custom.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| ICONVIEW_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[CHECKBOX - Usage (Sample)|CHECKBOX_Usage.c]]
| Usage of a ICONVIEW widget.
+
|style="width: 75%;"|Usage of a CHECKBOX widget.
| [https://wiki.segger.com/images/9/9e/ICONVIEW_Usage.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| LISTBOX_Custom.c
 
  +
| Custom drawing of a LISTBOX widget.
 
  +
==== DROPDOWN widget ====
| [https://wiki.segger.com/images/6/6f/LISTBOX_Custom.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| LISTBOX_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[DROPDOWN - Custom (Sample)|DROPDOWN_Custom.c]]
| Usage of a LISTBOX widget.
+
|style="width: 75%;"|Custom drawing of a DROPDOWN widget.
| [https://wiki.segger.com/images/2/2a/LISTBOX_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| LISTVIEW_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[DROPDOWN - Usage (Sample)|DROPDOWN_Usage.c]]
| Custom drawing of a LISTVIEW widget.
+
|style="width: 75%;"|Usage of a DROPDOWN widget.
| [https://wiki.segger.com/images/a/ac/LISTVIEW_Custom.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| LISTVIEW_Usage.c
 
  +
| Usage of a LISTVIEW widget.
 
  +
==== FRAMEWIN widget ====
| [https://wiki.segger.com/images/0/0f/LISTVIEW_Usage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| LISTWHEEL_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[FRAMEWIN - Custom (Sample)|FRAMEWIN_Custom.c]]
| Custom drawing of a LISTWHEEL widget.
+
|style="width: 75%;"|Custom drawing of a FRAMEWIN widget.
| [https://wiki.segger.com/images/8/87/LISTWHEEL_Custom.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| LISTWHEEL_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[FRAMEWIN - Usage (Sample)|FRAMEWIN_Usage.c]]
| Usage of a LISTWHEEL widget.
+
|style="width: 75%;"|Usage of a FRAMEWIN widget.
| [https://wiki.segger.com/images/0/0c/LISTWHEEL_Usage.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| MULTIPAGE_Custom.c
 
  +
| Custom drawing of a MULTIPAGE widget.
 
  +
==== GRAPH widget ====
| [https://wiki.segger.com/images/5/52/MULTIPAGE_Custom.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| MULTIPAGE_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[GRAPH - Custom (Sample)|GRAPH_Custom.c]]
| Usage of a MULTIPAGE widget.
+
|style="width: 75%;"|Custom drawing of a GRAPH widget.
| [https://wiki.segger.com/images/c/c9/MULTIPAGE_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| PROGBAR_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[GRAPH - Usage (Sample)|GRAPH_Usage.c]]
| Custom drawing of a PROGBAR widget.
+
|style="width: 75%;"|Usage of a GRAPH widget.
| [https://wiki.segger.com/images/e/e2/PROGBAR_Custom.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| PROGBAR_Usage.c
 
  +
| Usage of a PROGBAR widget.
 
  +
==== ICONVIEW widget ====
| [https://wiki.segger.com/images/9/93/PROGBAR_Usage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| RADIO_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[ICONVIEW - Custom (Sample)|ICONVIEW_Custom.c]]
| Custom drawing of a RADIO widget.
+
|style="width: 75%;"|Custom drawing of a ICONVIEW widget.
| [https://wiki.segger.com/images/0/02/RADIO_Custom.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| RADIO_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[ICONVIEW - Usage (Sample)|ICONVIEW_Usage.c]]
| Usage of a RADIO widget.
+
|style="width: 75%;"|Usage of a ICONVIEW widget.
| [https://wiki.segger.com/images/3/3d/RADIO_Usage.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| ROTARY_Usage.c
 
  +
| Usage and custom drawing of a ROTARY widget.
 
  +
==== LISTBOX widget ====
| [https://wiki.segger.com/images/a/ab/ROTARY_Usage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| SLIDER_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[LISTBOX - Custom (Sample)|LISTBOX_Custom.c]]
| Custom drawing of a SLIDER widget.
+
|style="width: 75%;"|Custom drawing of a LISTBOX widget.
| [https://wiki.segger.com/images/7/74/SLIDER_Custom.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| SLIDER_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[LISTBOX - Usage (Sample)|LISTBOX_Usage.c]]
| Usage of a SLIDER widget.
+
|style="width: 75%;"|Usage of a LISTBOX widget.
| [https://wiki.segger.com/images/6/6a/SLIDER_Usage.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| SPINBOX_Custom.c
 
  +
| Custom drawing of a SPINBOX widget.
 
  +
==== LISTVIEW widget ====
| [https://wiki.segger.com/images/c/c9/SPINBOX_Custom.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| SPINBOX_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[LISTVIEW - Custom (Sample)|LISTVIEW_Usage.c]]
| Usage of a SPINBOX widget.
+
|style="width: 75%;"|Usage of a LISTVIEW widget.
| [https://wiki.segger.com/images/a/aa/SPINBOX_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| SWIPELIST_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[LISTVIEW - Usage (Sample)|LISTVIEW_Custom.c]]
| Custom drawing of a SWIPELIST widget.
+
|style="width: 75%;"|Custom drawing of a LISTVIEW widget.
| [https://wiki.segger.com/images/b/b6/SWIPELIST_Custom.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| SWIPELIST_Usage.c
 
  +
| Usage of a SWIPELIST widget.
 
  +
==== LISTWHEEL widget ====
| [https://wiki.segger.com/images/a/ae/SWIPELIST_Usage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| SWITCH_Usage.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[LISTWHEEL - Custom (Sample)|LISTWHEEL_Usage.c]]
| Usage and custom drawing of a SWITCH widget.
+
|style="width: 75%;"|Usage of a LISTWHEEL widget.
| [https://wiki.segger.com/images/9/9e/SWITCH_Usage.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| TREEVIEW_Custom.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[LISTWHEEL - Usage (Sample)|LISTWHEEL_Custom.c]]
| Custom drawing of a TREEVIEW widget.
+
|style="width: 75%;"|Custom drawing of a LISTWHEEL widget.
| [https://wiki.segger.com/images/5/5a/TREEVIEW_Custom.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| TREEVIEW_Usage.c
 
  +
| Usage of a TREEVIEW widget.
 
  +
==== MULTIPAGE widget ====
| [https://wiki.segger.com/images/2/2f/TREEVIEW_Usage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| WIDGET_CustomCallback.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[MULTIPAGE - Custom (Sample)|MULTIPAGE_Custom.c]]
  +
|style="width: 75%;"|Custom drawing of a MULTIPAGE widget.
| Explains how the callback of a widget can be overwritten.
 
| [https://wiki.segger.com/images/0/0d/WIDGET_CustomCallback.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| WIDGET_OwnerDraw.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[MULTIPAGE - Usage (Sample)|MULTIPAGE_Usage.c]]
  +
|style="width: 75%;"|Usage of a MULTIPAGE widget.
| Shows how OwnerDraw routines can be set for widgets that support OwnerDraw.
 
| [https://wiki.segger.com/images/4/41/WIDGET_OwnerDraw.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| WIDGET_ReactOnMessages.c
 
  +
| Demonstrates how the application can react on messages sent by widgets.
 
  +
==== PROGBAR widget ====
| [https://wiki.segger.com/images/2/24/WIDGET_ReactOnMessages.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| WIDGET_SkinningProps.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[PROGBAR - Custom (Sample)|PROGBAR_Custom.c]]
  +
|style="width: 75%;"|Custom drawing of a PROGBAR widget.
| Shows how the appearance of widgets can be changed using skinning properties. This can only be done for widgets that support skinning.
 
| [https://wiki.segger.com/images/1/1e/WIDGET_SkinningProps.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| WIDGET_SkinningRoutine.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[PROGBAR - Usage (Sample)|PROGBAR_Usage.c]]
  +
|style="width: 75%;"|Usage of a PROGBAR widget.
| Shows how the appearance of widgets can be changed using a skinning routine. This can only be done for widgets that support skinning.
 
| [https://wiki.segger.com/images/1/18/WIDGET_SkinningRoutine.c Download]
 
 
|-
 
|-
  +
|}
|colspan="5" style="text-align:center; background-color:#D0D0D0;"| '''Window Manager'''
 
  +
  +
==== RADIO widget ====
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_AllMessages.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[RADIO - Custom (Sample)|RADIO_Custom.c]]
  +
|style="width: 75%;"|Custom drawing of a RADIO widget.
| Example that shows all window messages that can be used.
 
| [https://wiki.segger.com/images/0/04/WM_AllMessages.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_ChildWindows.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[RADIO - Usage (Sample)|RADIO_Usage.c]]
  +
|style="width: 75%;"|Usage of a RADIO widget.
| Demonstrates how child windows work and how they are created.
 
| [https://wiki.segger.com/images/c/ca/WM_ChildWindows.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| WM_Clipping.c
 
  +
| Shows how clipping is performed in emWin.
 
  +
==== ROTARY widget ====
| [https://wiki.segger.com/images/9/9d/WM_Clipping.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_CreateWindows.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[ROTARY (Sample)|ROTARY_Usage.c]]
  +
|style="width: 75%;"|Usage and custom drawing of a ROTARY widget.
| Demonstrates how to create windows.
 
| [https://wiki.segger.com/images/a/a4/WM_CreateWindows.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| WM_CustomMessage.c
 
  +
| Demonstrates how custom messages can be sent between windows.
 
  +
==== SLIDER widget ====
| [https://wiki.segger.com/images/3/3c/WM_CustomMessage.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_FocusableWindow.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[SLIDER - Custom (Sample)|SLIDER_Custom.c]]
  +
|style="width: 75%;"|Custom drawing of a SLIDER widget.
| Shows how a window can accept focus like most other widgets.
 
| [https://wiki.segger.com/images/b/b7/WM_FocusableWindow.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_LateClipping.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[SLIDER - Usage (Sample)|SLIDER_Usage.c]]
  +
|style="width: 75%;"|Usage of a SLIDER widget.
| Demonstrates the difference between late and early clipping.
 
| [https://wiki.segger.com/images/e/e0/WM_LateClipping.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| WM_MOTION_MoveContent.c
 
  +
| Shows how motion support works for movable content, such as text that can be scrolled.
 
  +
==== SPINBOX widget ====
| [https://wiki.segger.com/images/f/fa/WM_MOTION_MoveContent.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_MOTION_MoveWindows.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[SPINBOX - Custom (Sample)|SPINBOX_Custom.c]]
  +
|style="width: 75%;"|Custom drawing of a SPINBOX widget.
| Shows how motion support can be used for moving windows.
 
| [https://wiki.segger.com/images/b/b6/WM_MOTION_MoveWindows.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_SetUntouchable.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[SPINBOX - Usage (Sample)|SPINBOX_Usage.c]]
  +
|style="width: 75%;"|Usage of a SPINBOX widget.
| Demonstrates how windows can be marked as "untouchable".
 
| [https://wiki.segger.com/images/c/c6/WM_SetUntouchable.c Download]
 
 
|-
 
|-
  +
|}
|style="font-family: monospace,monospace;"| WM_SetUserData.c
 
  +
| Example that shows how to set extra data to a window or widget. User data are extra bytes that are allocated upon creation of the window or widget. This can be utilized to transfer data between windows.
 
  +
==== SWIPELIST widget ====
| [https://wiki.segger.com/images/e/e5/WM_SetUserData.c Download]
 
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_SimpleTimer.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[SWIPELIST - Custom (Sample)|SWIPELIST_Custom.c]]
  +
|style="width: 75%;"|Custom drawing of a SWIPELIST widget.
| Sample that demonstrates how to use timers with the Window Manager.
 
| [https://wiki.segger.com/images/e/e6/WM_SimpleTimer.c Download]
 
 
|-
 
|-
|style="font-family: monospace,monospace;"| WM_TransparentWindows.c
+
|style="font-family: monospace,monospace; width: 25%;"| [[SWIPELIST - Usage (Sample)|SWIPELIST_Usage.c]]
  +
|style="width: 75%;"|Usage of a SWIPELIST widget.
| Shows how transparent windows can be created.
 
  +
|-
| [https://wiki.segger.com/images/8/84/WM_TransparentWindows.c Download]
 
  +
|}
  +
  +
==== SWITCH widget ====
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
  +
|-
  +
|style="font-family: monospace,monospace; width: 25%;"| [[SWITCH (Sample)|SWITCH_Usage.c]]
  +
|style="width: 75%;"|Usage and custom drawing of a SWITCH widget.
  +
|-
  +
|}
  +
  +
==== TREEVIEW widget ====
  +
  +
{| class="wikitable" style="width: 80%;"
  +
! Name of sample !! Description
  +
|-
  +
|style="font-family: monospace,monospace; width: 25%;"| [[TREEVIEW - Custom (Sample)|TREEVIEW_Custom.c]]
  +
|style="width: 75%;"|Custom drawing of a TREEVIEW widget.
  +
|-
  +
|style="font-family: monospace,monospace; width: 25%;"| [[TREEVIEW - Usage (Sample)|TREEVIEW_Usage.c]]
  +
|style="width: 75%;"|Usage of a TREEVIEW widget.
 
|-
 
|-
 
|}
 
|}

Revision as of 17:58, 22 April 2020

The emWin examples have the purpose to explain and visualize emWin's features in a straight-forward and simplified way. Thus, most of these examples do not have elaborate graphics, but instead have code that is easy to read and understand.

How to use the examples

The examples are ready-to-run and can be run on most hardware targets and in the Windows simulation. All of the examples are stand-alone, meaning only one C file is required to run the application, with the exception of samples that include file access to external files. For the latter type of samples, the external file referred to in the sample is required as well.

File header

Every example file has a header at the beginning of the file. This header states the file name of the example, a small description about the example and how it should be used and a list of required emWin add-ons that are necessary to run the example.

File        : GUI_VNC_FileTransfer.c
Purpose     : Sample that demonstrates how to use a VNC server with
              emWin and use it for file transfer.
Requirements: WindowManager - ( )
              MemoryDevices - ( )
              AntiAliasing  - ( )
              VNC-Server    - (x)
              PNG-Library   - ( )
              TrueTypeFonts - ( )

For example, the VNC server add-on is required for the VNC-related emWin examples.

List of examples

2D graphic operations

Name of sample Description
GUI_DIRTYDEVICE_Usage.c Demonstrates how to use DIRTYDEVICES. A DIRTYDEVICE monitors the area on the screen that is 'dirty', meaning the area where screen changes happened.
GUI_Polygon.c Demonstrates how to draw polygons and what can be done with them.
GUI_QRCode.c Shows how to draw a QR code with emWin.
GUI_SPLINE.c Demonstrates how splines can be drawn with emWin.
GUI_YUV_PixelData.c Demonstrates how splines can be drawn with emWin.

Animations

Name of sample Description
GUI_AdvancedAnimation.c This sample demonstrates how more advanced animations can be created with emWin. The advanced animation makes use of slice callbacks, custom position calculation and several animation items.
GUI_SimpleAnimation.c Shows how to perform simple animations using emWin. This example shows the basic steps for creating an animation, such as creating and running it, adding animation items and using a delete callback routine.

Bitmaps and images

Name of sample Description
GUI_CreateBitmapFromStream.c Creates and draws a streamed bitmap from an external .dta file. The example supports both the usage of Windows file system and emFile, if run on a target.
GUI_DrawAnimatedGIFBin.c Draws an animated GIF image after it has been converted into binary form using Bin2C.
GUI_DrawAnimatedSprite.c Draws an animated GIF image after it has been converted into an animated sprite using the Bitmap Converter.
GUI_DrawExternalImage_BMP.c Shows how to draw BMP images in emWin from external memory. Supports both the usage of Windows file system and emFile.
GUI_DrawExternalImage_GIF.c Shows how to draw GIF images in emWin from external memory. Supports both the usage of Windows file system and emFile.
GUI_DrawExternalImage_JPG.c Shows how to draw JPG images in emWin from external memory. Supports both the usage of Windows file system and emFile.
GUI_DrawExternalImage_PNG.c Shows how to draw PNG images in emWin from external memory. Supports both the usage of Windows file system and emFile.
GUI_DrawStreamedBitmap.c Demonstrates how streamed bitmaps can be drawn from external .dta files. Supports both the usage of Windows file system and emFile.
GUI_SerializeBMP.c Example that shows how screenshots can be created by serializing the LCD contents into a .bmp file. Supports both the usage of Windows file system and emFile.

Fonts

Name of sample Description
GUI_SetExternalFont_TTF.c Shows how to create a custom font from an external .ttf file. Supports both the usage of Windows file system and emFile.
GUI_SetExternalFont_XBF.c Shows how to create a custom font from an external .xbf file. Supports both the usage of Windows file system and emFile.
GUI_SetFont_TTF.c Shows how to create a custom font from a .ttf file located in accessible memory.

Timers

Name of sample Description
GUI_Timers.c Demonstrates how to use timers without the use of the WindowManager in emWin.

MultiTouch

Name of sample Description
GUI_MultiTouch.c Demonstrates how to use timers without the use of the WindowManager in emWin.

Dialogs

Name of sample Description
CALENDAR_Usage.c Demonstrates the usage of CALENDAR dialogs.
CHOOSECOLOR_Usage.c Demonstrates the usage of CHOOSECOLOR dialogs.
CHOOSEFILE_Usage.c Demonstrates the usage of CHOOSEFILE dialogs.
DIALOG_CreateDialogs.c Shows how custom dialogs can be created.
GUI_Messagebox.c Demonstrates the usage of MESSAGEBOX dialogs.

Language Support

Name of sample Description
GUI_LANG_BiDiArabic.c Demonstrates how arabic text can be displayed/used via bi-directional text support.
GUI_LANG_ReadCSV.c Shows how to read different languages from a .csv file that has been converted into binary form.
GUI_LANG_ReadCSVEx.c Shows how to read different languages from a .csv file that is located in external memory. Supports both the usage of Windows file system and emFile.
GUI_LANG_Thai.c Demonstrates how thai text can be displayed/used via thai text support.

Memory Devices

Name of sample Description
GUI_MEMDEV_BlurringAndBlending.c Shows how blurring and blending operations are done using memory devices.
GUI_MEMDEV_Container.c Shows how memory devices can be used as a container to pre-load JPEG images (or something else) to avoid flickering.
GUI_MEMDEV_Fading.c Demonstrates how a fading animation between two windows can be executed using memory devices.
GUI_MEMDEV_Rotate.c Shows how to rotate images using memory devices.
GUI_MEMDEV_SerializeBMP.c Shows how bitmap files can be created from the contents of a memory device. Supports both the usage of Windows file system and emFile.

Movies

Name of sample Description
GUI_MOVIE_CreateMovie.c Demonstrates how to display an emWin movie from accessable memory.
GUI_MOVIE_CreateMovieEx.c Demonstrates how to display an emWin movie from external memory.

VNC

Name of sample Description
GUI_VNC_FileTransfer.c Shows how to use a VNC server with emWin to transfer files.
GUI_VNC_StartServer.c Shows how to use a VNC server with emWin.

Widgets

General

Name of sample Description
WIDGET_CustomScrollbar.c Explains how the SCROLLBAR of a widget can be customized and manipulated.
WIDGET_CustomCallback.c Explains how the callback of a widget can be overwritten.
WIDGET_OwnerDraw.c Shows how OwnerDraw routines can be set for widgets that support OwnerDraw.
WIDGET_ReactOnMessages.c Demonstrates how the application can react on messages sent by widgets.
WIDGET_SkinningProps.c Shows how the appearance of widgets can be changed using skinning properties. This can only be done for widgets that support skinning.
WIDGET_SkinningRoutine.c Shows how the appearance of widgets can be changed using a skinning routine. This can only be done for widgets that support skinning.

BUTTON widget

Name of sample Description
BUTTON_Custom.c Custom drawing of a BUTTON widget.
BUTTON_Usage.c Usage of a BUTTON widget.

CHECKBOX widget

Name of sample Description
CHECKBOX_Custom.c Custom drawing of a CHECKBOX widget.
CHECKBOX_Usage.c Usage of a CHECKBOX widget.

DROPDOWN widget

Name of sample Description
DROPDOWN_Custom.c Custom drawing of a DROPDOWN widget.
DROPDOWN_Usage.c Usage of a DROPDOWN widget.

FRAMEWIN widget

Name of sample Description
FRAMEWIN_Custom.c Custom drawing of a FRAMEWIN widget.
FRAMEWIN_Usage.c Usage of a FRAMEWIN widget.

GRAPH widget

Name of sample Description
GRAPH_Custom.c Custom drawing of a GRAPH widget.
GRAPH_Usage.c Usage of a GRAPH widget.

ICONVIEW widget

Name of sample Description
ICONVIEW_Custom.c Custom drawing of a ICONVIEW widget.
ICONVIEW_Usage.c Usage of a ICONVIEW widget.

LISTBOX widget

Name of sample Description
LISTBOX_Custom.c Custom drawing of a LISTBOX widget.
LISTBOX_Usage.c Usage of a LISTBOX widget.

LISTVIEW widget

Name of sample Description
LISTVIEW_Usage.c Usage of a LISTVIEW widget.
LISTVIEW_Custom.c Custom drawing of a LISTVIEW widget.

LISTWHEEL widget

Name of sample Description
LISTWHEEL_Usage.c Usage of a LISTWHEEL widget.
LISTWHEEL_Custom.c Custom drawing of a LISTWHEEL widget.

MULTIPAGE widget

Name of sample Description
MULTIPAGE_Custom.c Custom drawing of a MULTIPAGE widget.
MULTIPAGE_Usage.c Usage of a MULTIPAGE widget.

PROGBAR widget

Name of sample Description
PROGBAR_Custom.c Custom drawing of a PROGBAR widget.
PROGBAR_Usage.c Usage of a PROGBAR widget.

RADIO widget

Name of sample Description
RADIO_Custom.c Custom drawing of a RADIO widget.
RADIO_Usage.c Usage of a RADIO widget.

ROTARY widget

Name of sample Description
ROTARY_Usage.c Usage and custom drawing of a ROTARY widget.

SLIDER widget

Name of sample Description
SLIDER_Custom.c Custom drawing of a SLIDER widget.
SLIDER_Usage.c Usage of a SLIDER widget.

SPINBOX widget

Name of sample Description
SPINBOX_Custom.c Custom drawing of a SPINBOX widget.
SPINBOX_Usage.c Usage of a SPINBOX widget.

SWIPELIST widget

Name of sample Description
SWIPELIST_Custom.c Custom drawing of a SWIPELIST widget.
SWIPELIST_Usage.c Usage of a SWIPELIST widget.

SWITCH widget

Name of sample Description
SWITCH_Usage.c Usage and custom drawing of a SWITCH widget.

TREEVIEW widget

Name of sample Description
TREEVIEW_Custom.c Custom drawing of a TREEVIEW widget.
TREEVIEW_Usage.c Usage of a TREEVIEW widget.