EDIT widget - background transparency and cursor color

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

    • EDIT widget - background transparency and cursor color

      I have an EDIT widget in my user interface which I would like to have a transparent background. I thought this could be achieved with the following line, but it does not work. I also tried using "GUI_INVALID_COLOR" in place of "GUI_TRANSPARENT".

      EDIT_SetBkColor(hItem, EDIT_CI_ENABLED, GUI_TRANSPARENT);

      Is it the case that this widget simply does not support transparency? Other (opaque) colors seem to work just fine.


      Similarly, I am trying to set a custom color for the cursor line with the following, but the cursor always ends up being white.

      EDIT_SetTextColor(hItem, EDIT_CI_CURSOR, GUI_RED);


      I am able to manipulate other aspects of the widget just fine (text color, mode, cursor blink, etc.)

      emWin version 5.38
    • Hi,

      per default the EDIT widget is not transparent. Try if it works when you set the transparent flag by calling WM_SetHastTrans(hEdit).

      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.