diff --git a/src/texteditor/TextEditorTheme.cpp b/src/texteditor/TextEditorTheme.cpp index a5cc825e..4c054e6c 100644 --- a/src/texteditor/TextEditorTheme.cpp +++ b/src/texteditor/TextEditorTheme.cpp @@ -2,40 +2,40 @@ #include "TextEditorTheme.h" #include - +#define COLOR(X) ((QRgb)0x##X) TextEditorThemePtr TextEditorTheme::Light() { TextEditorThemePtr t = std::make_shared(); - t->fg_default = QColor(0, 0, 0); - t->bg_default = QColor(240, 240, 240); - t->fg_line_number = QColor(96, 96, 96); - t->bg_line_number = QColor(208, 208, 208); - t->fg_cursor = QColor(0, 128, 255); - t->bg_current_line = QColor(192, 192, 192); - t->bg_current_line_number = QColor(176, 176, 176); - t->bg_diff_unknown = QColor(208, 208, 208); - t->bg_diff_line_del = QColor(240, 208, 208); - t->bg_diff_line_add = QColor(192, 240, 192); - t->bg_diff_char_del = QColor(240, 160, 160); - t->bg_diff_char_add = QColor(144, 208, 144); + t->fg_default = COLOR(000000); + t->bg_default = COLOR(f0f0f0); + t->fg_line_number = COLOR(606060); + t->bg_line_number = COLOR(d0d0d0); + t->fg_cursor = COLOR(0050ff); + t->bg_current_line = COLOR(c0c0c0); + t->bg_current_line_number = COLOR(b0b0b0); + t->bg_diff_unknown = COLOR(d0d0d0); + t->bg_diff_line_del = COLOR(f0d0d0); + t->bg_diff_line_add = COLOR(c0f0c0); + t->bg_diff_char_del = COLOR(f090c0); + t->bg_diff_char_add = COLOR(80d0c0); return t; } TextEditorThemePtr TextEditorTheme::Dark() { TextEditorThemePtr t = std::make_shared(); - t->fg_default = QColor(255, 255, 255); - t->bg_default = QColor(48, 48, 48); // t->bg_default = QColor(0, 0, 64); - t->fg_line_number = QColor(176, 176, 176); - t->bg_line_number = QColor(64, 64, 64); - t->fg_cursor = QColor(0, 128, 255); - t->bg_current_line_number = QColor(96, 96, 96); - t->bg_diff_unknown = QColor(0, 0, 0); - t->bg_diff_line_del = QColor(80, 0, 0); - t->bg_diff_line_add = QColor(0, 64, 0); - t->bg_diff_char_del = QColor(160, 0, 0); - t->bg_diff_char_add = QColor(0, 128, 0); + t->fg_default = COLOR(ffffff); + t->bg_default = COLOR(303030); + t->fg_line_number = COLOR(b0b0b0); + t->bg_line_number = COLOR(404040); + t->fg_cursor = COLOR(0050ff); + t->bg_current_line_number = COLOR(606060); + t->bg_diff_unknown = COLOR(000000); + t->bg_diff_line_del = COLOR(500000); + t->bg_diff_line_add = COLOR(004000); + t->bg_diff_char_del = COLOR(c03070); + t->bg_diff_char_add = COLOR(00a040); return t; }