gx_progress_bar.h 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. /**************************************************************************/
  2. /* */
  3. /* Copyright (c) Microsoft Corporation. All rights reserved. */
  4. /* */
  5. /* This software is licensed under the Microsoft Software License */
  6. /* Terms for Microsoft Azure RTOS. Full text of the license can be */
  7. /* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA */
  8. /* and in the root directory of this software. */
  9. /* */
  10. /**************************************************************************/
  11. /**************************************************************************/
  12. /**************************************************************************/
  13. /** */
  14. /** GUIX Component */
  15. /** */
  16. /** Progress Bar Management (Progress Bar) */
  17. /** */
  18. /**************************************************************************/
  19. /**************************************************************************/
  20. /**************************************************************************/
  21. /* */
  22. /* COMPONENT DEFINITION RELEASE */
  23. /* */
  24. /* gx_progress_bar.h PORTABLE C */
  25. /* 6.0 */
  26. /* AUTHOR */
  27. /* */
  28. /* Kenneth Maxwell, Microsoft Corporation */
  29. /* */
  30. /* DESCRIPTION */
  31. /* */
  32. /* This file defines the GUIX progress bar widget, */
  33. /* including all data types and external references. It is assumed */
  34. /* that gx_api.h and gx_port.h have already been included. */
  35. /* */
  36. /* RELEASE HISTORY */
  37. /* */
  38. /* DATE NAME DESCRIPTION */
  39. /* */
  40. /* 05-19-2020 Kenneth Maxwell Initial Version 6.0 */
  41. /* */
  42. /**************************************************************************/
  43. #ifndef GX_PROGRESS_BAR_H
  44. #define GX_PROGRESS_BAR_H
  45. /* Define progress bar management function prototypes. */
  46. #define GX_SEGMENT_BORDER_INTERVAL 1
  47. #define GX_SEGMENT_INTERVAL 1
  48. VOID _gx_progress_bar_background_draw(GX_PROGRESS_BAR *progress_bar);
  49. UINT _gx_progress_bar_create(GX_PROGRESS_BAR *progress_bar, GX_CONST GX_CHAR *name, GX_WIDGET *parent,
  50. GX_PROGRESS_BAR_INFO *progress_bar_info, ULONG style,
  51. USHORT progress_bar_id, GX_CONST GX_RECTANGLE *size);
  52. VOID _gx_progress_bar_draw(GX_PROGRESS_BAR *progress_bar);
  53. UINT _gx_progress_bar_event_process(GX_PROGRESS_BAR *progress_bar, GX_EVENT *event_ptr);
  54. UINT _gx_progress_bar_font_set(GX_PROGRESS_BAR *progress_bar, GX_RESOURCE_ID font_id);
  55. UINT _gx_progress_bar_info_set(GX_PROGRESS_BAR *progress_bar, GX_PROGRESS_BAR_INFO *info);
  56. UINT _gx_progress_bar_pixelmap_set(GX_PROGRESS_BAR *progress_bar, GX_RESOURCE_ID pixelmap);
  57. UINT _gx_progress_bar_range_set(GX_PROGRESS_BAR *progress_bar, INT min_value, INT max_value);
  58. UINT _gx_progress_bar_text_color_set(GX_PROGRESS_BAR *progress_bar, GX_RESOURCE_ID normal_text_color_id,
  59. GX_RESOURCE_ID selected_text_color_id, GX_RESOURCE_ID disabled_text_color_id);
  60. VOID _gx_progress_bar_text_draw(GX_PROGRESS_BAR *progress_bar);
  61. UINT _gx_progress_bar_value_set(GX_PROGRESS_BAR *progress_bar, INT new_value);
  62. UINT _gxe_progress_bar_create(GX_PROGRESS_BAR *progress_bar, GX_CONST GX_CHAR *name, GX_WIDGET *parent,
  63. GX_PROGRESS_BAR_INFO *progress_bar_info, ULONG style,
  64. USHORT progress_bar_id, GX_CONST GX_RECTANGLE *size,
  65. UINT progress_bar_control_block_size);
  66. /* Define error checking shells for API services. These are only referenced by the
  67. application. */
  68. UINT _gxe_progress_bar_event_process(GX_PROGRESS_BAR *progress_bar, GX_EVENT *event_ptr);
  69. UINT _gxe_progress_bar_font_set(GX_PROGRESS_BAR *progress_bar, GX_RESOURCE_ID font_id);
  70. UINT _gxe_progress_bar_info_set(GX_PROGRESS_BAR *progress_bar, GX_PROGRESS_BAR_INFO *info);
  71. UINT _gxe_progress_bar_pixelmap_set(GX_PROGRESS_BAR *progress_bar, GX_RESOURCE_ID pixelmap);
  72. UINT _gxe_progress_bar_range_set(GX_PROGRESS_BAR *progress_bar, INT min_value, INT max_value);
  73. UINT _gxe_progress_bar_text_color_set(GX_PROGRESS_BAR *progress_bar, GX_RESOURCE_ID normal_text_color_id,
  74. GX_RESOURCE_ID selected_text_color_id, GX_RESOURCE_ID disabled_text_color_id);
  75. UINT _gxe_progress_bar_value_set(GX_PROGRESS_BAR *progress_bar, INT new_value);
  76. #endif