If you want to consider changing background color that takes into
consideration the theme background (e.g. dark or light themes), this code
(see it on GitHub)
<https://github.com/moosetechnology/Moose-Easy/blob/f7967b310021147792858c576a41a31bdf35d7fd/src/Moose-Easy/MooseEasyFamixMakerPresenter.class.st#L279>
can
adapt to it:

normalColor := Smalltalk ui theme backgroundColor.
green := normalColor mixed: 0.8 with: Color green.
red := normalColor mixed: 0.8 with: Color red.

I didn't really test it with all possibilities of themes, however.

On Thu, 19 Dec 2019 at 12:58, Hilaire <hila...@drgeo.eu> wrote:

> You should use TextMorph.
>
> What about:
>
> || t |
> t := TextMorph new.
> t backgroundColor: Color blue.
> t contents: 'Hello'.
> t lock.
> t openInWorld||
> |
>
> Le 19/12/2019 à 15:28, Kasper Osterbye a écrit :
> > I was struggling for weeks (not every day, but still) to find out how
> > to change the system to be able to give background color to text.
> >
> --
> Dr. Geo
> http://drgeo.eu
>
>
>
>

-- 
Christopher Fuhrman, P.Eng., PhD

*Professeur au Département de génie logiciel et des technologies de
l'informationÉTS (École de technologie supérieure)*

Reply via email to