# TextPropLabel backgroundColourId

**URL:** <https://forum.juce.com/t/textproplabel-backgroundcolourid/8866>\
**Category:** General JUCE discussion\
**Created:** [June 20, 2012, 8:43pm UTC](https://forum.juce.com/t/textproplabel-backgroundcolourid/8866 "2012-06-20T20:43:13Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![graeme-2](https://avatars.discourse-cdn.com/v4/letter/g/8baadc/32.png) [@graeme-2](https://forum.juce.com/u/graeme-2)\
**Post date:** [June 20, 2012, 8:43pm UTC](https://forum.juce.com/t/textproplabel-backgroundcolourid/8866/1 "2012-06-20T20:43:13Z")

</div>

Hi Jules, can you change the following constructor to not have a hard coded value for the backgroundColourId?

```auto
    TextPropLabel (TextPropertyComponent& owner_,
                   const int maxChars_, const bool isMultiline_)
        : Label (String::empty, String::empty),
          owner (owner_),
          maxChars (maxChars_),
          isMultiline (isMultiline_)
    {
        setEditable (true, true, false);

        setColour (backgroundColourId, Colours::white);
        setColour (outlineColourId, findColour (ComboBox::outlineColourId));
    }
```

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [June 21, 2012, 11:14am UTC](https://forum.juce.com/t/textproplabel-backgroundcolourid/8866/2 "2012-06-21T11:14:08Z")

</div>

Yeah, I guess that colour should be the same as the ComboBox::backgroundColourId. Although… I’m not sure why I hard-coded it like that, there might actually have been a good reason which I can’t currently remember…

---

<div class="post-metadata">

**Author:** ![graeme-2](https://avatars.discourse-cdn.com/v4/letter/g/8baadc/32.png) [@graeme-2](https://forum.juce.com/u/graeme-2)\
**Post date:** [July 27, 2012, 7:30pm UTC](https://forum.juce.com/t/textproplabel-backgroundcolourid/8866/3 "2012-07-27T19:30:00Z")

</div>

Hi Jules. Shouldn’t the colour id’s here be the ones from Label instead of ComboBox?

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [July 27, 2012, 8:57pm UTC](https://forum.juce.com/t/textproplabel-backgroundcolourid/8866/4 "2012-07-27T20:57:59Z")

</div>

Yes, they should! Thanks!
