setup_scr_screen.c 34 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494
  1. /*
  2. * Copyright 2025 NXP
  3. * NXP Proprietary. This software is owned or controlled by NXP and may only be used strictly in
  4. * accordance with the applicable license terms. By expressly accepting such terms or by downloading, installing,
  5. * activating and/or otherwise using the software, you are agreeing that you have read, and that you agree to
  6. * comply with and are bound by, such license terms. If you do not agree to be bound by the applicable license
  7. * terms, then you may not retain, install, activate or otherwise use the software.
  8. */
  9. #include "lvgl.h"
  10. #include <stdio.h>
  11. #include "gui_guider.h"
  12. #include "events_init.h"
  13. #include "widgets_init.h"
  14. #include "custom.h"
  15. void setup_scr_screen(lv_ui *ui)
  16. {
  17. //Write codes screen
  18. ui->screen = lv_obj_create(NULL);
  19. lv_obj_set_size(ui->screen, 480, 480);
  20. lv_obj_set_scrollbar_mode(ui->screen, LV_SCROLLBAR_MODE_OFF);
  21. //Write style for screen, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  22. lv_obj_set_style_bg_opa(ui->screen, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  23. lv_obj_set_style_bg_color(ui->screen, lv_color_hex(0x1F1E23), LV_PART_MAIN|LV_STATE_DEFAULT);
  24. lv_obj_set_style_bg_grad_dir(ui->screen, LV_GRAD_DIR_NONE, LV_PART_MAIN|LV_STATE_DEFAULT);
  25. lv_obj_set_style_bg_image_src(ui->screen, &_main_bg_RGB565A8_480x480, LV_PART_MAIN|LV_STATE_DEFAULT);
  26. lv_obj_set_style_bg_image_opa(ui->screen, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  27. lv_obj_set_style_bg_image_recolor_opa(ui->screen, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  28. //Write codes screen_arc_1
  29. ui->screen_arc_1 = lv_arc_create(ui->screen);
  30. lv_obj_set_pos(ui->screen_arc_1, 70, 62);
  31. lv_obj_set_size(ui->screen_arc_1, 360, 343);
  32. lv_arc_set_mode(ui->screen_arc_1, LV_ARC_MODE_NORMAL);
  33. lv_arc_set_range(ui->screen_arc_1, 0, 100);
  34. lv_arc_set_bg_angles(ui->screen_arc_1, 135, 45);
  35. lv_arc_set_value(ui->screen_arc_1, 70);
  36. lv_arc_set_rotation(ui->screen_arc_1, 0);
  37. //Write style for screen_arc_1, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  38. lv_obj_set_style_bg_opa(ui->screen_arc_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  39. lv_obj_set_style_border_width(ui->screen_arc_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  40. lv_obj_set_style_arc_width(ui->screen_arc_1, 15, LV_PART_MAIN|LV_STATE_DEFAULT);
  41. lv_obj_set_style_arc_opa(ui->screen_arc_1, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  42. lv_obj_set_style_arc_color(ui->screen_arc_1, lv_color_hex(0x0B0C0D), LV_PART_MAIN|LV_STATE_DEFAULT);
  43. lv_obj_set_style_arc_rounded(ui->screen_arc_1, true, LV_PART_MAIN|LV_STATE_DEFAULT);
  44. lv_obj_set_style_radius(ui->screen_arc_1, 6, LV_PART_MAIN|LV_STATE_DEFAULT);
  45. lv_obj_set_style_pad_top(ui->screen_arc_1, 20, LV_PART_MAIN|LV_STATE_DEFAULT);
  46. lv_obj_set_style_pad_bottom(ui->screen_arc_1, 20, LV_PART_MAIN|LV_STATE_DEFAULT);
  47. lv_obj_set_style_pad_left(ui->screen_arc_1, 20, LV_PART_MAIN|LV_STATE_DEFAULT);
  48. lv_obj_set_style_pad_right(ui->screen_arc_1, 20, LV_PART_MAIN|LV_STATE_DEFAULT);
  49. lv_obj_set_style_shadow_width(ui->screen_arc_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  50. //Write style for screen_arc_1, Part: LV_PART_INDICATOR, State: LV_STATE_DEFAULT.
  51. lv_obj_set_style_arc_width(ui->screen_arc_1, 15, LV_PART_INDICATOR|LV_STATE_DEFAULT);
  52. lv_obj_set_style_arc_opa(ui->screen_arc_1, 255, LV_PART_INDICATOR|LV_STATE_DEFAULT);
  53. lv_obj_set_style_arc_color(ui->screen_arc_1, lv_color_hex(0x00d9ff), LV_PART_INDICATOR|LV_STATE_DEFAULT);
  54. lv_obj_set_style_arc_rounded(ui->screen_arc_1, true, LV_PART_INDICATOR|LV_STATE_DEFAULT);
  55. //Write style for screen_arc_1, Part: LV_PART_KNOB, State: LV_STATE_DEFAULT.
  56. lv_obj_set_style_bg_opa(ui->screen_arc_1, 255, LV_PART_KNOB|LV_STATE_DEFAULT);
  57. lv_obj_set_style_bg_color(ui->screen_arc_1, lv_color_hex(0xffffff), LV_PART_KNOB|LV_STATE_DEFAULT);
  58. lv_obj_set_style_bg_grad_dir(ui->screen_arc_1, LV_GRAD_DIR_NONE, LV_PART_KNOB|LV_STATE_DEFAULT);
  59. lv_obj_set_style_pad_all(ui->screen_arc_1, 5, LV_PART_KNOB|LV_STATE_DEFAULT);
  60. //Write codes screen_imgbtn_1
  61. ui->screen_imgbtn_1 = lv_imagebutton_create(ui->screen);
  62. lv_obj_set_pos(ui->screen_imgbtn_1, 199, 293);
  63. lv_obj_set_size(ui->screen_imgbtn_1, 84, 84);
  64. lv_obj_add_flag(ui->screen_imgbtn_1, LV_OBJ_FLAG_CHECKABLE);
  65. lv_imagebutton_set_src(ui->screen_imgbtn_1, LV_IMAGEBUTTON_STATE_RELEASED, &_swtich_RGB565A8_84x84, NULL, NULL);
  66. lv_imagebutton_set_src(ui->screen_imgbtn_1, LV_IMAGEBUTTON_STATE_PRESSED, &_swtich_RGB565A8_84x84, NULL, NULL);
  67. lv_imagebutton_set_src(ui->screen_imgbtn_1, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_swtich_RGB565A8_84x84, NULL, NULL);
  68. ui->screen_imgbtn_1_label = lv_label_create(ui->screen_imgbtn_1);
  69. lv_label_set_text(ui->screen_imgbtn_1_label, "");
  70. lv_label_set_long_mode(ui->screen_imgbtn_1_label, LV_LABEL_LONG_WRAP);
  71. lv_obj_align(ui->screen_imgbtn_1_label, LV_ALIGN_CENTER, 0, 0);
  72. lv_obj_set_style_pad_all(ui->screen_imgbtn_1, 0, LV_STATE_DEFAULT);
  73. //Write style for screen_imgbtn_1, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  74. lv_obj_set_style_text_color(ui->screen_imgbtn_1, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT);
  75. lv_obj_set_style_text_font(ui->screen_imgbtn_1, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT);
  76. lv_obj_set_style_text_opa(ui->screen_imgbtn_1, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  77. lv_obj_set_style_text_align(ui->screen_imgbtn_1, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  78. lv_obj_set_style_shadow_width(ui->screen_imgbtn_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  79. //Write style for screen_imgbtn_1, Part: LV_PART_MAIN, State: LV_STATE_PRESSED.
  80. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_1, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  81. lv_obj_set_style_image_opa(ui->screen_imgbtn_1, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  82. lv_obj_set_style_text_color(ui->screen_imgbtn_1, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED);
  83. lv_obj_set_style_text_font(ui->screen_imgbtn_1, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED);
  84. lv_obj_set_style_text_opa(ui->screen_imgbtn_1, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  85. lv_obj_set_style_shadow_width(ui->screen_imgbtn_1, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  86. //Write style for screen_imgbtn_1, Part: LV_PART_MAIN, State: LV_STATE_CHECKED.
  87. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_1, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  88. lv_obj_set_style_image_opa(ui->screen_imgbtn_1, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  89. lv_obj_set_style_text_color(ui->screen_imgbtn_1, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED);
  90. lv_obj_set_style_text_font(ui->screen_imgbtn_1, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED);
  91. lv_obj_set_style_text_opa(ui->screen_imgbtn_1, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  92. lv_obj_set_style_shadow_width(ui->screen_imgbtn_1, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  93. //Write style for screen_imgbtn_1, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED.
  94. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_1, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  95. lv_obj_set_style_image_opa(ui->screen_imgbtn_1, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  96. //Write codes screen_label_1
  97. ui->screen_label_1 = lv_label_create(ui->screen);
  98. lv_obj_set_pos(ui->screen_label_1, 147, 150);
  99. lv_obj_set_size(ui->screen_label_1, 34, 32);
  100. lv_label_set_text(ui->screen_label_1, "");
  101. lv_label_set_long_mode(ui->screen_label_1, LV_LABEL_LONG_WRAP);
  102. //Write style for screen_label_1, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  103. lv_obj_set_style_border_width(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  104. lv_obj_set_style_radius(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  105. lv_obj_set_style_text_color(ui->screen_label_1, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT);
  106. lv_obj_set_style_text_font(ui->screen_label_1, &lv_font_iconfont_25, LV_PART_MAIN|LV_STATE_DEFAULT);
  107. lv_obj_set_style_text_opa(ui->screen_label_1, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  108. lv_obj_set_style_text_letter_space(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  109. lv_obj_set_style_text_line_space(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  110. lv_obj_set_style_text_align(ui->screen_label_1, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  111. lv_obj_set_style_bg_opa(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  112. lv_obj_set_style_pad_top(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  113. lv_obj_set_style_pad_right(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  114. lv_obj_set_style_pad_bottom(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  115. lv_obj_set_style_pad_left(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  116. lv_obj_set_style_shadow_width(ui->screen_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  117. //Write codes screen_label_2
  118. ui->screen_label_2 = lv_label_create(ui->screen);
  119. lv_obj_set_pos(ui->screen_label_2, 242, 150);
  120. lv_obj_set_size(ui->screen_label_2, 34, 32);
  121. lv_label_set_text(ui->screen_label_2, "");
  122. lv_label_set_long_mode(ui->screen_label_2, LV_LABEL_LONG_WRAP);
  123. //Write style for screen_label_2, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  124. lv_obj_set_style_border_width(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  125. lv_obj_set_style_radius(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  126. lv_obj_set_style_text_color(ui->screen_label_2, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT);
  127. lv_obj_set_style_text_font(ui->screen_label_2, &lv_font_iconfont_25, LV_PART_MAIN|LV_STATE_DEFAULT);
  128. lv_obj_set_style_text_opa(ui->screen_label_2, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  129. lv_obj_set_style_text_letter_space(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  130. lv_obj_set_style_text_line_space(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  131. lv_obj_set_style_text_align(ui->screen_label_2, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  132. lv_obj_set_style_bg_opa(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  133. lv_obj_set_style_pad_top(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  134. lv_obj_set_style_pad_right(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  135. lv_obj_set_style_pad_bottom(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  136. lv_obj_set_style_pad_left(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  137. lv_obj_set_style_shadow_width(ui->screen_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  138. //Write codes screen_label_3
  139. ui->screen_label_3 = lv_label_create(ui->screen);
  140. lv_obj_set_pos(ui->screen_label_3, 181, 155);
  141. lv_obj_set_size(ui->screen_label_3, 71, 20);
  142. lv_label_set_text(ui->screen_label_3, "26°C");
  143. lv_label_set_long_mode(ui->screen_label_3, LV_LABEL_LONG_WRAP);
  144. //Write style for screen_label_3, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  145. lv_obj_set_style_border_width(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  146. lv_obj_set_style_radius(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  147. lv_obj_set_style_text_color(ui->screen_label_3, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT);
  148. lv_obj_set_style_text_font(ui->screen_label_3, &lv_font_montserratMedium_16, LV_PART_MAIN|LV_STATE_DEFAULT);
  149. lv_obj_set_style_text_opa(ui->screen_label_3, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  150. lv_obj_set_style_text_letter_space(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  151. lv_obj_set_style_text_line_space(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  152. lv_obj_set_style_text_align(ui->screen_label_3, LV_TEXT_ALIGN_LEFT, LV_PART_MAIN|LV_STATE_DEFAULT);
  153. lv_obj_set_style_bg_opa(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  154. lv_obj_set_style_pad_top(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  155. lv_obj_set_style_pad_right(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  156. lv_obj_set_style_pad_bottom(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  157. lv_obj_set_style_pad_left(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  158. lv_obj_set_style_shadow_width(ui->screen_label_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  159. //Write codes screen_label_4
  160. ui->screen_label_4 = lv_label_create(ui->screen);
  161. lv_obj_set_pos(ui->screen_label_4, 279, 155);
  162. lv_obj_set_size(ui->screen_label_4, 71, 20);
  163. lv_label_set_text(ui->screen_label_4, "40%");
  164. lv_label_set_long_mode(ui->screen_label_4, LV_LABEL_LONG_WRAP);
  165. //Write style for screen_label_4, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  166. lv_obj_set_style_border_width(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  167. lv_obj_set_style_radius(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  168. lv_obj_set_style_text_color(ui->screen_label_4, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT);
  169. lv_obj_set_style_text_font(ui->screen_label_4, &lv_font_montserratMedium_16, LV_PART_MAIN|LV_STATE_DEFAULT);
  170. lv_obj_set_style_text_opa(ui->screen_label_4, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  171. lv_obj_set_style_text_letter_space(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  172. lv_obj_set_style_text_line_space(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  173. lv_obj_set_style_text_align(ui->screen_label_4, LV_TEXT_ALIGN_LEFT, LV_PART_MAIN|LV_STATE_DEFAULT);
  174. lv_obj_set_style_bg_opa(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  175. lv_obj_set_style_pad_top(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  176. lv_obj_set_style_pad_right(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  177. lv_obj_set_style_pad_bottom(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  178. lv_obj_set_style_pad_left(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  179. lv_obj_set_style_shadow_width(ui->screen_label_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  180. //Write codes screen_label_5
  181. ui->screen_label_5 = lv_label_create(ui->screen);
  182. lv_obj_set_pos(ui->screen_label_5, 165, 208);
  183. lv_obj_set_size(ui->screen_label_5, 132, 72);
  184. lv_label_set_text(ui->screen_label_5, "26");
  185. lv_label_set_long_mode(ui->screen_label_5, LV_LABEL_LONG_WRAP);
  186. //Write style for screen_label_5, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  187. lv_obj_set_style_border_width(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  188. lv_obj_set_style_radius(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  189. lv_obj_set_style_text_color(ui->screen_label_5, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT);
  190. lv_obj_set_style_text_font(ui->screen_label_5, &lv_font_PuHui_ExtraBold_60, LV_PART_MAIN|LV_STATE_DEFAULT);
  191. lv_obj_set_style_text_opa(ui->screen_label_5, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  192. lv_obj_set_style_text_letter_space(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  193. lv_obj_set_style_text_line_space(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  194. lv_obj_set_style_text_align(ui->screen_label_5, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  195. lv_obj_set_style_bg_opa(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  196. lv_obj_set_style_pad_top(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  197. lv_obj_set_style_pad_right(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  198. lv_obj_set_style_pad_bottom(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  199. lv_obj_set_style_pad_left(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  200. lv_obj_set_style_shadow_width(ui->screen_label_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  201. //Write codes screen_label_6
  202. ui->screen_label_6 = lv_label_create(ui->screen);
  203. lv_obj_set_pos(ui->screen_label_6, 252, 238);
  204. lv_obj_set_size(ui->screen_label_6, 71, 22);
  205. lv_label_set_text(ui->screen_label_6, "°C");
  206. lv_label_set_long_mode(ui->screen_label_6, LV_LABEL_LONG_WRAP);
  207. //Write style for screen_label_6, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  208. lv_obj_set_style_border_width(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  209. lv_obj_set_style_radius(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  210. lv_obj_set_style_text_color(ui->screen_label_6, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT);
  211. lv_obj_set_style_text_font(ui->screen_label_6, &lv_font_montserratMedium_25, LV_PART_MAIN|LV_STATE_DEFAULT);
  212. lv_obj_set_style_text_opa(ui->screen_label_6, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  213. lv_obj_set_style_text_letter_space(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  214. lv_obj_set_style_text_line_space(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  215. lv_obj_set_style_text_align(ui->screen_label_6, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  216. lv_obj_set_style_bg_opa(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  217. lv_obj_set_style_pad_top(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  218. lv_obj_set_style_pad_right(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  219. lv_obj_set_style_pad_bottom(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  220. lv_obj_set_style_pad_left(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  221. lv_obj_set_style_shadow_width(ui->screen_label_6, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  222. //Write codes screen_cont_1
  223. ui->screen_cont_1 = lv_obj_create(ui->screen);
  224. lv_obj_set_pos(ui->screen_cont_1, 8, 399);
  225. lv_obj_set_size(ui->screen_cont_1, 226, 72);
  226. lv_obj_set_scrollbar_mode(ui->screen_cont_1, LV_SCROLLBAR_MODE_OFF);
  227. //Write style for screen_cont_1, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  228. lv_obj_set_style_border_width(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  229. lv_obj_set_style_radius(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  230. lv_obj_set_style_bg_opa(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  231. lv_obj_set_style_pad_top(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  232. lv_obj_set_style_pad_bottom(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  233. lv_obj_set_style_pad_left(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  234. lv_obj_set_style_pad_right(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  235. lv_obj_set_style_shadow_width(ui->screen_cont_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  236. //Write codes screen_imgbtn_5
  237. ui->screen_imgbtn_5 = lv_imagebutton_create(ui->screen_cont_1);
  238. lv_obj_set_pos(ui->screen_imgbtn_5, 0, 0);
  239. lv_obj_set_size(ui->screen_imgbtn_5, 100, 50);
  240. lv_obj_add_flag(ui->screen_imgbtn_5, LV_OBJ_FLAG_CHECKABLE);
  241. ui->screen_imgbtn_5_label = lv_label_create(ui->screen_imgbtn_5);
  242. lv_label_set_text(ui->screen_imgbtn_5_label, "");
  243. lv_label_set_long_mode(ui->screen_imgbtn_5_label, LV_LABEL_LONG_WRAP);
  244. lv_obj_align(ui->screen_imgbtn_5_label, LV_ALIGN_CENTER, 0, 0);
  245. lv_obj_set_style_pad_all(ui->screen_imgbtn_5, 0, LV_STATE_DEFAULT);
  246. //Write style for screen_imgbtn_5, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  247. lv_obj_set_style_text_color(ui->screen_imgbtn_5, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT);
  248. lv_obj_set_style_text_font(ui->screen_imgbtn_5, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT);
  249. lv_obj_set_style_text_opa(ui->screen_imgbtn_5, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  250. lv_obj_set_style_text_align(ui->screen_imgbtn_5, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  251. lv_obj_set_style_shadow_width(ui->screen_imgbtn_5, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  252. //Write style for screen_imgbtn_5, Part: LV_PART_MAIN, State: LV_STATE_PRESSED.
  253. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_5, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  254. lv_obj_set_style_image_opa(ui->screen_imgbtn_5, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  255. lv_obj_set_style_text_color(ui->screen_imgbtn_5, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED);
  256. lv_obj_set_style_text_font(ui->screen_imgbtn_5, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED);
  257. lv_obj_set_style_text_opa(ui->screen_imgbtn_5, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  258. lv_obj_set_style_shadow_width(ui->screen_imgbtn_5, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  259. //Write style for screen_imgbtn_5, Part: LV_PART_MAIN, State: LV_STATE_CHECKED.
  260. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_5, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  261. lv_obj_set_style_image_opa(ui->screen_imgbtn_5, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  262. lv_obj_set_style_text_color(ui->screen_imgbtn_5, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED);
  263. lv_obj_set_style_text_font(ui->screen_imgbtn_5, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED);
  264. lv_obj_set_style_text_opa(ui->screen_imgbtn_5, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  265. lv_obj_set_style_shadow_width(ui->screen_imgbtn_5, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  266. //Write style for screen_imgbtn_5, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED.
  267. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_5, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  268. lv_obj_set_style_image_opa(ui->screen_imgbtn_5, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  269. //Write codes screen_label_7
  270. ui->screen_label_7 = lv_label_create(ui->screen);
  271. lv_obj_set_pos(ui->screen_label_7, 109, 350);
  272. lv_obj_set_size(ui->screen_label_7, 71, 20);
  273. lv_label_set_text(ui->screen_label_7, "16°C");
  274. lv_label_set_long_mode(ui->screen_label_7, LV_LABEL_LONG_WRAP);
  275. //Write style for screen_label_7, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  276. lv_obj_set_style_border_width(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  277. lv_obj_set_style_radius(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  278. lv_obj_set_style_text_color(ui->screen_label_7, lv_color_hex(0x9d9191), LV_PART_MAIN|LV_STATE_DEFAULT);
  279. lv_obj_set_style_text_font(ui->screen_label_7, &lv_font_montserratMedium_16, LV_PART_MAIN|LV_STATE_DEFAULT);
  280. lv_obj_set_style_text_opa(ui->screen_label_7, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  281. lv_obj_set_style_text_letter_space(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  282. lv_obj_set_style_text_line_space(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  283. lv_obj_set_style_text_align(ui->screen_label_7, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  284. lv_obj_set_style_bg_opa(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  285. lv_obj_set_style_pad_top(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  286. lv_obj_set_style_pad_right(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  287. lv_obj_set_style_pad_bottom(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  288. lv_obj_set_style_pad_left(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  289. lv_obj_set_style_shadow_width(ui->screen_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  290. //Write codes screen_label_8
  291. ui->screen_label_8 = lv_label_create(ui->screen);
  292. lv_obj_set_pos(ui->screen_label_8, 304, 350);
  293. lv_obj_set_size(ui->screen_label_8, 71, 20);
  294. lv_label_set_text(ui->screen_label_8, "30°C");
  295. lv_label_set_long_mode(ui->screen_label_8, LV_LABEL_LONG_WRAP);
  296. //Write style for screen_label_8, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  297. lv_obj_set_style_border_width(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  298. lv_obj_set_style_radius(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  299. lv_obj_set_style_text_color(ui->screen_label_8, lv_color_hex(0x9d9191), LV_PART_MAIN|LV_STATE_DEFAULT);
  300. lv_obj_set_style_text_font(ui->screen_label_8, &lv_font_montserratMedium_16, LV_PART_MAIN|LV_STATE_DEFAULT);
  301. lv_obj_set_style_text_opa(ui->screen_label_8, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  302. lv_obj_set_style_text_letter_space(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  303. lv_obj_set_style_text_line_space(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  304. lv_obj_set_style_text_align(ui->screen_label_8, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  305. lv_obj_set_style_bg_opa(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  306. lv_obj_set_style_pad_top(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  307. lv_obj_set_style_pad_right(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  308. lv_obj_set_style_pad_bottom(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  309. lv_obj_set_style_pad_left(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  310. lv_obj_set_style_shadow_width(ui->screen_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  311. //Write codes screen_cont_2
  312. ui->screen_cont_2 = lv_obj_create(ui->screen);
  313. lv_obj_set_pos(ui->screen_cont_2, 245, 399);
  314. lv_obj_set_size(ui->screen_cont_2, 226, 72);
  315. lv_obj_set_scrollbar_mode(ui->screen_cont_2, LV_SCROLLBAR_MODE_OFF);
  316. //Write style for screen_cont_2, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  317. lv_obj_set_style_border_width(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  318. lv_obj_set_style_radius(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  319. lv_obj_set_style_bg_opa(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  320. lv_obj_set_style_pad_top(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  321. lv_obj_set_style_pad_bottom(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  322. lv_obj_set_style_pad_left(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  323. lv_obj_set_style_pad_right(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  324. lv_obj_set_style_shadow_width(ui->screen_cont_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  325. //Write codes screen_imgbtn_2
  326. ui->screen_imgbtn_2 = lv_imagebutton_create(ui->screen_cont_2);
  327. lv_obj_set_pos(ui->screen_imgbtn_2, 38, 20);
  328. lv_obj_set_size(ui->screen_imgbtn_2, 31, 31);
  329. lv_obj_add_flag(ui->screen_imgbtn_2, LV_OBJ_FLAG_CHECKABLE);
  330. lv_imagebutton_set_src(ui->screen_imgbtn_2, LV_IMAGEBUTTON_STATE_RELEASED, &_icon_low_fan_sel_RGB565A8_31x31, NULL, NULL);
  331. lv_imagebutton_set_src(ui->screen_imgbtn_2, LV_IMAGEBUTTON_STATE_PRESSED, &_icon_low_fan_RGB565A8_31x31, NULL, NULL);
  332. lv_imagebutton_set_src(ui->screen_imgbtn_2, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_icon_low_fan_RGB565A8_31x31, NULL, NULL);
  333. ui->screen_imgbtn_2_label = lv_label_create(ui->screen_imgbtn_2);
  334. lv_label_set_text(ui->screen_imgbtn_2_label, "");
  335. lv_label_set_long_mode(ui->screen_imgbtn_2_label, LV_LABEL_LONG_WRAP);
  336. lv_obj_align(ui->screen_imgbtn_2_label, LV_ALIGN_CENTER, 0, 0);
  337. lv_obj_set_style_pad_all(ui->screen_imgbtn_2, 0, LV_STATE_DEFAULT);
  338. //Write style for screen_imgbtn_2, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  339. lv_obj_set_style_text_color(ui->screen_imgbtn_2, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT);
  340. lv_obj_set_style_text_font(ui->screen_imgbtn_2, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT);
  341. lv_obj_set_style_text_opa(ui->screen_imgbtn_2, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  342. lv_obj_set_style_text_align(ui->screen_imgbtn_2, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  343. lv_obj_set_style_shadow_width(ui->screen_imgbtn_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  344. //Write style for screen_imgbtn_2, Part: LV_PART_MAIN, State: LV_STATE_PRESSED.
  345. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_2, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  346. lv_obj_set_style_image_opa(ui->screen_imgbtn_2, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  347. lv_obj_set_style_text_color(ui->screen_imgbtn_2, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED);
  348. lv_obj_set_style_text_font(ui->screen_imgbtn_2, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED);
  349. lv_obj_set_style_text_opa(ui->screen_imgbtn_2, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  350. lv_obj_set_style_shadow_width(ui->screen_imgbtn_2, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  351. //Write style for screen_imgbtn_2, Part: LV_PART_MAIN, State: LV_STATE_CHECKED.
  352. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_2, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  353. lv_obj_set_style_image_opa(ui->screen_imgbtn_2, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  354. lv_obj_set_style_text_color(ui->screen_imgbtn_2, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED);
  355. lv_obj_set_style_text_font(ui->screen_imgbtn_2, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED);
  356. lv_obj_set_style_text_opa(ui->screen_imgbtn_2, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  357. lv_obj_set_style_shadow_width(ui->screen_imgbtn_2, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  358. //Write style for screen_imgbtn_2, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED.
  359. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_2, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  360. lv_obj_set_style_image_opa(ui->screen_imgbtn_2, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  361. //Write codes screen_imgbtn_3
  362. ui->screen_imgbtn_3 = lv_imagebutton_create(ui->screen_cont_2);
  363. lv_obj_set_pos(ui->screen_imgbtn_3, 105, 20);
  364. lv_obj_set_size(ui->screen_imgbtn_3, 31, 31);
  365. lv_obj_add_flag(ui->screen_imgbtn_3, LV_OBJ_FLAG_CHECKABLE);
  366. lv_imagebutton_set_src(ui->screen_imgbtn_3, LV_IMAGEBUTTON_STATE_RELEASED, &_icon_mid_fan_RGB565A8_31x31, NULL, NULL);
  367. lv_imagebutton_set_src(ui->screen_imgbtn_3, LV_IMAGEBUTTON_STATE_PRESSED, &_icon_mid_fan_sel_RGB565A8_31x31, NULL, NULL);
  368. lv_imagebutton_set_src(ui->screen_imgbtn_3, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_icon_mid_fan_sel_RGB565A8_31x31, NULL, NULL);
  369. ui->screen_imgbtn_3_label = lv_label_create(ui->screen_imgbtn_3);
  370. lv_label_set_text(ui->screen_imgbtn_3_label, "");
  371. lv_label_set_long_mode(ui->screen_imgbtn_3_label, LV_LABEL_LONG_WRAP);
  372. lv_obj_align(ui->screen_imgbtn_3_label, LV_ALIGN_CENTER, 0, 0);
  373. lv_obj_set_style_pad_all(ui->screen_imgbtn_3, 0, LV_STATE_DEFAULT);
  374. //Write style for screen_imgbtn_3, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  375. lv_obj_set_style_text_color(ui->screen_imgbtn_3, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT);
  376. lv_obj_set_style_text_font(ui->screen_imgbtn_3, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT);
  377. lv_obj_set_style_text_opa(ui->screen_imgbtn_3, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  378. lv_obj_set_style_text_align(ui->screen_imgbtn_3, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  379. lv_obj_set_style_shadow_width(ui->screen_imgbtn_3, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  380. //Write style for screen_imgbtn_3, Part: LV_PART_MAIN, State: LV_STATE_PRESSED.
  381. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_3, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  382. lv_obj_set_style_image_opa(ui->screen_imgbtn_3, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  383. lv_obj_set_style_text_color(ui->screen_imgbtn_3, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED);
  384. lv_obj_set_style_text_font(ui->screen_imgbtn_3, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED);
  385. lv_obj_set_style_text_opa(ui->screen_imgbtn_3, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  386. lv_obj_set_style_shadow_width(ui->screen_imgbtn_3, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  387. //Write style for screen_imgbtn_3, Part: LV_PART_MAIN, State: LV_STATE_CHECKED.
  388. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_3, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  389. lv_obj_set_style_image_opa(ui->screen_imgbtn_3, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  390. lv_obj_set_style_text_color(ui->screen_imgbtn_3, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED);
  391. lv_obj_set_style_text_font(ui->screen_imgbtn_3, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED);
  392. lv_obj_set_style_text_opa(ui->screen_imgbtn_3, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  393. lv_obj_set_style_shadow_width(ui->screen_imgbtn_3, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  394. //Write style for screen_imgbtn_3, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED.
  395. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_3, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  396. lv_obj_set_style_image_opa(ui->screen_imgbtn_3, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  397. //Write codes screen_imgbtn_4
  398. ui->screen_imgbtn_4 = lv_imagebutton_create(ui->screen_cont_2);
  399. lv_obj_set_pos(ui->screen_imgbtn_4, 172, 20);
  400. lv_obj_set_size(ui->screen_imgbtn_4, 31, 31);
  401. lv_obj_add_flag(ui->screen_imgbtn_4, LV_OBJ_FLAG_CHECKABLE);
  402. lv_imagebutton_set_src(ui->screen_imgbtn_4, LV_IMAGEBUTTON_STATE_RELEASED, &_icon_high_fan_RGB565A8_31x31, NULL, NULL);
  403. lv_imagebutton_set_src(ui->screen_imgbtn_4, LV_IMAGEBUTTON_STATE_PRESSED, &_icon_high_fan_sel_RGB565A8_31x31, NULL, NULL);
  404. lv_imagebutton_set_src(ui->screen_imgbtn_4, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_icon_high_fan_sel_RGB565A8_31x31, NULL, NULL);
  405. ui->screen_imgbtn_4_label = lv_label_create(ui->screen_imgbtn_4);
  406. lv_label_set_text(ui->screen_imgbtn_4_label, "");
  407. lv_label_set_long_mode(ui->screen_imgbtn_4_label, LV_LABEL_LONG_WRAP);
  408. lv_obj_align(ui->screen_imgbtn_4_label, LV_ALIGN_CENTER, 0, 0);
  409. lv_obj_set_style_pad_all(ui->screen_imgbtn_4, 0, LV_STATE_DEFAULT);
  410. //Write style for screen_imgbtn_4, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT.
  411. lv_obj_set_style_text_color(ui->screen_imgbtn_4, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT);
  412. lv_obj_set_style_text_font(ui->screen_imgbtn_4, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT);
  413. lv_obj_set_style_text_opa(ui->screen_imgbtn_4, 255, LV_PART_MAIN|LV_STATE_DEFAULT);
  414. lv_obj_set_style_text_align(ui->screen_imgbtn_4, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT);
  415. lv_obj_set_style_shadow_width(ui->screen_imgbtn_4, 0, LV_PART_MAIN|LV_STATE_DEFAULT);
  416. //Write style for screen_imgbtn_4, Part: LV_PART_MAIN, State: LV_STATE_PRESSED.
  417. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_4, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  418. lv_obj_set_style_image_opa(ui->screen_imgbtn_4, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  419. lv_obj_set_style_text_color(ui->screen_imgbtn_4, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED);
  420. lv_obj_set_style_text_font(ui->screen_imgbtn_4, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED);
  421. lv_obj_set_style_text_opa(ui->screen_imgbtn_4, 255, LV_PART_MAIN|LV_STATE_PRESSED);
  422. lv_obj_set_style_shadow_width(ui->screen_imgbtn_4, 0, LV_PART_MAIN|LV_STATE_PRESSED);
  423. //Write style for screen_imgbtn_4, Part: LV_PART_MAIN, State: LV_STATE_CHECKED.
  424. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_4, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  425. lv_obj_set_style_image_opa(ui->screen_imgbtn_4, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  426. lv_obj_set_style_text_color(ui->screen_imgbtn_4, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED);
  427. lv_obj_set_style_text_font(ui->screen_imgbtn_4, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED);
  428. lv_obj_set_style_text_opa(ui->screen_imgbtn_4, 255, LV_PART_MAIN|LV_STATE_CHECKED);
  429. lv_obj_set_style_shadow_width(ui->screen_imgbtn_4, 0, LV_PART_MAIN|LV_STATE_CHECKED);
  430. //Write style for screen_imgbtn_4, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED.
  431. lv_obj_set_style_image_recolor_opa(ui->screen_imgbtn_4, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  432. lv_obj_set_style_image_opa(ui->screen_imgbtn_4, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED);
  433. //The custom code of screen.
  434. //Update current screen layout.
  435. lv_obj_update_layout(ui->screen);
  436. }