Skip to content
This repository has been archived by the owner on Dec 20, 2021. It is now read-only.

addcheckBox()

Mammad900 edited this page Feb 27, 2021 · 2 revisions

addcheckBox(page, X, Y, text, size, checked, checkColor, textcolor, boxColor, boxBorder, enabled, visible )

Summary

Adds a check-box to the application user interface.

Parameters

  1. Page (int) : The number of the page which contains the new check-box
  2. X (unsigned int) : The X position of the new check-box in pixels
  3. Y (unsigned int) : The Y position of the new check-box in pixels
  4. text (String) : Text shown beside the box
  5. size (int) optional : One of the constants listed later to be used as the size of the check-box Default: SIZE12PT28PX
  6. checked (bool) optional: If true, the check-box is checked. Default: false
  7. checkColor (unsigned int) optional: A 16-bit number representing the color for the tick. Default: black (TFT_BLACK)
  8. textColor (unsigned int) optional: A 16-bit number representing the text color of the check-box. Default: white (TFT_WHITE)
  9. boxColor (unsigned int) optional: A 16-bit number representing the background color for the box. Default: white (TFT_WHITE)
  10. boxBorder (unsigned int) optional: A 16-bit number representing the border color for the box. Default: black (TFT_BLACK)
  11. enabled (bool) _optional: If false, the check-box is darkened. Default: true
  12. visible (bool) optional: If false, the check-box is hidden (invisible). Default: true

Values for Size

  • SIZE9PT18PX or 18: 9pt (FreeSans9pt7b) text and 18px box
  • SIZE12PT28PX or 28: 12pt (FreeSans12pt7b) text and 28px box
  • SIZE18PT42PX or 42: 18pt (FreeSans18pt7b) text and 42px box
  • SIZE24PT56PX or 42: 24pt (FreeSans24pt7b) text and 56px box

See this

Returns

The index of the new check-box

Clone this wiki locally