Color for single character on button
Hi everyone! :)
Is there anyway to set a different color to one charater on a button?
Example:
A button with the text: "Start" where all the letters are white except for the letter "a" which is yellow or something.
Thanks.
Re: Color for single character on button
No there isn't. You would have to draw the text yourself, calling DrawString multiple times with a different Pen each time.
Re: Color for single character on button
Thank you for your reply :)
Re: Color for single character on button
Quote:
Originally Posted by
Anderskd1
Hi everyone! :)
Is there anyway to set a different color to one charater on a button?
Example:
A button with the text: "Start" where all the letters are white except for the letter "a" which is yellow or something.
Thanks.
You could do that in WPF, but not so easily in winforms
Re: Color for single character on button
I would also caution you against doing that in any case. I can think of some reasons to do that which might seem appealing, but I had a boss who was red-green color blind and an employee who was totally color blind. Listening to them discuss a colorful interface I had created for an application was...enlightening.
The bottom line is: Think twice before creating an interface that relies too much on color.
Re: Color for single character on button
Quote:
Originally Posted by
Shaggy Hiker
I would also caution you against doing that in any case. I can think of some reasons to do that which might seem appealing, but I had a boss who was red-green color blind and an employee who was totally color blind. Listening to them discuss a colorful interface I had created for an application was...enlightening.
The bottom line is: Think twice before creating an interface that relies too much on color.
That sounds... like something you would not want to be on the receiving end of :D
Re: Color for single character on button
It was actually quite amusing. They both saw the interface, they just saw it differently from each other or any other non-color blind people. I was using colors to group like functionality. They saw the groupings differently from what I had intended. It wasn't unusable, it just wasn't all that it could have been.
Re: Color for single character on button
Quote:
Originally Posted by
Shaggy Hiker
It was actually quite amusing. They both saw the interface, they just saw it differently from each other or any other non-color blind people. I was using colors to group like functionality. They saw the groupings differently from what I had intended. It wasn't unusable, it just wasn't all that it could have been.
I could imagine it being amusing, as long as they did not get mad at you for it :)