Skip to content

Commit 67fbe9d

Browse files
Add the grid colors to theme. (#4990)
1 parent 2029055 commit 67fbe9d

File tree

4 files changed

+20
-4
lines changed

4 files changed

+20
-4
lines changed

source/MRViewer/MRColorTheme.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525

2626
#ifdef __EMSCRIPTEN__
2727

28-
extern "C"
28+
extern "C"
2929
{
3030
// 0 - dark
3131
// 1 - light
@@ -369,7 +369,9 @@ const char* ColorTheme::getRibbonColorTypeName( RibbonColorsType type )
369369
"GradBtnSecStyleActiveStart",
370370
"GradBtnSecStyleEnd",
371371
"GradBtnSecStyleHoverEnd",
372-
"GradBtnSecStyleActiveEnd"
372+
"GradBtnSecStyleActiveEnd",
373+
374+
"Grid",
373375
};
374376
return colorNames[int( type )];
375377
}
@@ -462,7 +464,7 @@ void ColorTheme::resetImGuiStyle()
462464
style.AntiAliasedLines = false;
463465

464466
style.WindowBorderSize = 1.0f;
465-
467+
466468
if ( auto menu = getViewerInstance().getMenuPlugin() )
467469
{
468470
auto scaling = menu->menu_scaling();

source/MRViewer/MRColorTheme.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,8 @@ class ColorTheme
140140
GradBtnSecStyleHoverEnd,
141141
GradBtnSecStyleActiveEnd,
142142

143+
Grid,
144+
143145
Count
144146
};
145147
// Getter and setter for ribbon colors
@@ -192,4 +194,4 @@ class ColorTheme
192194
ChangedSignal changedSignal_;
193195
};
194196

195-
}
197+
}

source/MRViewer/MRDarkTheme.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -367,6 +367,12 @@
367367
"b": 0,
368368
"g": 171,
369369
"r": 46
370+
},
371+
"Grid": {
372+
"a": 220,
373+
"b": 255,
374+
"g": 255,
375+
"r": 255
370376
}
371377
},
372378
"Viewport Colors": {

source/MRViewer/MRLightTheme.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,12 @@
369369
"b": 0,
370370
"g": 171,
371371
"r": 46
372+
},
373+
"Grid": {
374+
"a": 255,
375+
"b": 0,
376+
"g": 0,
377+
"r": 0
372378
}
373379
},
374380
"Viewport Colors": {

0 commit comments

Comments
 (0)