LISTBOX set background colour

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • LISTBOX set background colour

      Hi,

      I'm struggling to change the background colour for a listbox element (part of a dropdown), I'm specifying my own owner draw function to try to do this however it doesn't seem to work as expected. Initially I had tried to set the colour defaults for the LISTBOX widget but that has not worked.

      Can someone help me change the background colour of the currently selected listbox element in a dropdown?

      Many Thanks,
      Peter.
    • Hi,

      If its about the LISTBOX of DROPDOWN widget, try to use DROPDOWN_SetBkColor(hItem, DROPDOWN_CI_SELFOCUS, GUI_RED).
      Please refer to the emWin user manual (DROPDOWN API description) for further information.

      Regards,
      Sven
      Please read the forum rules before posting.

      Keep in mind, this is *not* a support forum.
      Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
      Should you be entitled to support you can contact us via our support system: segger.com/ticket/

      Or you can contact us via e-mail.