# Is it possible to use colors as text?

**URL:** <https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848>\
**Category:** Questions about Thunkable X\
**Created:** [June 6, 2021, 5:22am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848 "2021-06-06T05:22:10Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 5:22am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/1 "2021-06-06T05:22:10Z")

</div>

For an app of mine, I’m allowing the users to choose ‘pawns’, just differently coloured circle emojis. But some phones may not accept all the emojis, so I want to have 3 sliders for RGB, and then keep setting a label’s background color to the generated output. Can I use this background color like text?

_set button1’s text to join (button1’s text + newline + generate rgb pawn)_

I’m unable to find alternatives to the emojis I used.

Thanks!

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 6, 2021, 5:35am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/2 "2021-06-06T05:35:55Z")

</div>

You can [set background colors from text values](https://docs.thunkable.com/colour) but I don’t really understand this:

> [@codeswept](#):
>
> _set button1’s text to join (button1’s text + newline + generate rgb pawn)_

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 7:18am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/3 "2021-06-06T07:18:26Z")

</div>

By that, I mean I want to set a button’s text to  
join- button 1’s text, then a newline block, and generate rib pawn is the name of the variable I’m going to set the slider-generated rgb value as.

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 6, 2021, 7:21am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/4 "2021-06-06T07:21:17Z")

</div>

Oh, okay, I wasn’t sure what `generate rib pawn` referred to but now I get it.

Assuming you can get the value from each slider, you should be able to join those values into a text string that specifies a color as shown in the link I posted above.

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 7:22am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/5 "2021-06-06T07:22:03Z")

</div>

But won’t the text string appear like a text string instead of a block of color?

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 7:22am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/6 "2021-06-06T07:22:49Z")

</div>

Or does Thunkable recognize rgba(value, value,value,1) and convert it into color?

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 6, 2021, 7:23am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/7 "2021-06-06T07:23:26Z")

</div>

It will. I’m confused by your first post because you mention background color but then you say you’d like to set the button’s _text_. Did you mean the button’s background color?

I guess what would help here is for you to share an example of a correctly formatted output. What are you hoping to be able to display?

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 6, 2021, 7:24am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/8 "2021-06-06T07:24:02Z")

</div>

> [@codeswept](#):
>
> Or does Thunkable recognize rgba(value, value,value,1) and convert it into color?

It does if you assign that text string to something that expects a color such as a component’s text color or background color property.

That’s exactly what the documentation link I posted shows. Have you read over that?

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 7:25am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/9 "2021-06-06T07:25:36Z")

</div>

OK, i guess i wasn’t clear enough. What I want to do is assign a certain color **as a block of color** to a button’s text. I think you are familiar with the color picker method of using 3 sliders. I want to join a block of color along with text and display it as a button’s text. Long story short, I want to display color as text.

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 6, 2021, 7:28am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/10 "2021-06-06T07:28:19Z")

</div>

I think I understand. So you want the button’s text to be something like this:

![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/5/f/5f7e28fd593331e54e0530462034ba3eececcc6c.png)

That’s not possible. You would need two components to display the text and the color.

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 7:29am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/11 "2021-06-06T07:29:09Z")

</div>

[https://www.google.com/url?sa=i&url=https%3A%2F%2Fwww.alamy.com%2Fstock-photo-ludo-board-game-detail-with-dice-and-game-piece-horizontal-137457425.html&psig=AOvVaw1Iv7oJ0NE-mTuQbUfnuKoe&ust=1623050832320000&source=images&cd=vfe&ved=0CAIQjRxqFwoTCNDqqdq9gvECFQAAAAAdAAAAABAD](https://www.google.com/url?sa=i&url=https%3A%2F%2Fwww.alamy.com%2Fstock-photo-ludo-board-game-detail-with-dice-and-game-piece-horizontal-137457425.html&psig=AOvVaw1Iv7oJ0NE-mTuQbUfnuKoe&ust=1623050832320000&source=images&cd=vfe&ved=0CAIQjRxqFwoTCNDqqdq9gvECFQAAAAAdAAAAABAD)  
I got this image from the web. You’ll notice that there’s a yellow pawn piece on the board. I want to allow the users to use sliders to generate their own color (like in the Aloha chat app). And I want to display that block of color along with some other text on a button.

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 6, 2021, 7:32am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/12 "2021-06-06T07:32:24Z")

</div>

Is there a reason you can’t use the slider values to set the button’s background color and then set the button’s text to whatever text string you want? The text would overlay the background color just like a normal button instead of having a newline to separate the text from the color, as you suggested.

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 7:32am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/13 "2021-06-06T07:32:40Z")

</div>

Oh, ok. That’s exactly what I wanted, but now I’ll have to find something else. I want to display the pawn pieces as text, so I allowed the user to pick from colorful circle emojis. ⚫ 🟤 🟢 🔵 🟠 🟣 🔴 🟡 When I Live Tested my app on the phone, I realized that most of the emojis weren’t supported. Now, I have to search for some other emojis that appear as text.

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 6, 2021, 7:34am UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/14 "2021-06-06T07:34:09Z")

</div>

Oh, I’m making some of my cells with different background colors, as in they are color coded to show the users something. If I land on one of those color coded cells, then my color of my piece will hide the original color-code background. That’s a nice idea though.

---

<div class="post-metadata">

**Author:** ![lina.adams123b](https://avatars.discourse-cdn.com/v4/letter/l/8e8cbc/32.png) [@lina.adams123b](https://community.thunkable.com/u/lina.adams123b)\
**Post date:** [June 12, 2021, 12:04pm UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/15 "2021-06-12T12:04:16Z")

</div>

I like your idea it’s interesting,it’s gives me some ideas for my apps. Hope you will implement it successfully.

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [June 12, 2021, 12:04pm UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/16 "2021-06-12T12:04:58Z")

</div>

Thanks! I’m still using emojis, but hope to find a different way soon.

---

<div class="post-metadata">

**Author:** ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)\
**Post date:** [November 8, 2024, 1:22pm UTC](https://community.thunkable.com/t/is-it-possible-to-use-colors-as-text/1327848/17 "2024-11-08T13:22:06Z")

</div>


