The previous fix also didn't work correctly; we can't use the text color used
in the BTextView as a base. Instead we're now using the correct UI default colors. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16374 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -581,13 +581,13 @@ void
|
|||||||
BTextControl::_UpdateTextViewColors(bool enabled)
|
BTextControl::_UpdateTextViewColors(bool enabled)
|
||||||
{
|
{
|
||||||
rgb_color textColor;
|
rgb_color textColor;
|
||||||
rgb_color color = {0, 0, 0, 255};
|
rgb_color color;
|
||||||
BFont font;
|
BFont font;
|
||||||
|
|
||||||
fText->GetFontAndColor(0, &font, &color);
|
fText->GetFontAndColor(0, &font);
|
||||||
|
|
||||||
if (enabled)
|
if (enabled)
|
||||||
textColor = color;
|
textColor = ui_color(B_DOCUMENT_TEXT_COLOR);
|
||||||
else {
|
else {
|
||||||
textColor = tint_color(ui_color(B_PANEL_BACKGROUND_COLOR),
|
textColor = tint_color(ui_color(B_PANEL_BACKGROUND_COLOR),
|
||||||
B_DISABLED_LABEL_TINT);
|
B_DISABLED_LABEL_TINT);
|
||||||
@@ -596,9 +596,7 @@ BTextControl::_UpdateTextViewColors(bool enabled)
|
|||||||
fText->SetFontAndColor(&font, B_FONT_ALL, &textColor);
|
fText->SetFontAndColor(&font, B_FONT_ALL, &textColor);
|
||||||
|
|
||||||
if (enabled) {
|
if (enabled) {
|
||||||
color.red = 255;
|
color = ui_color(B_DOCUMENT_BACKGROUND_COLOR);
|
||||||
color.green = 255;
|
|
||||||
color.blue = 255;
|
|
||||||
} else {
|
} else {
|
||||||
color = tint_color(ui_color(B_PANEL_BACKGROUND_COLOR),
|
color = tint_color(ui_color(B_PANEL_BACKGROUND_COLOR),
|
||||||
B_LIGHTEN_2_TINT);
|
B_LIGHTEN_2_TINT);
|
||||||
|
|||||||
Reference in New Issue
Block a user