Merge branch 'LightThemeTweaks' of https://github.com/Radiangames/FlaxEngine into Radiangames-LightThemeTweaks
This commit is contained in:
@@ -208,13 +208,20 @@ namespace FlaxEditor.Options
|
||||
|
||||
// If a non-default style was chosen, switch to that style
|
||||
string styleName = themeOptions.SelectedStyle;
|
||||
if (styleName != "Default" && themeOptions.Styles.TryGetValue(styleName, out var style) && style != null)
|
||||
if (styleName != "Default" && styleName != "LightDefault" && themeOptions.Styles.TryGetValue(styleName, out var style) && style != null)
|
||||
{
|
||||
Style.Current = style;
|
||||
}
|
||||
else
|
||||
{
|
||||
Style.Current = CreateDefaultStyle();
|
||||
if (styleName == "LightDefault")
|
||||
{
|
||||
Style.Current = CreateLightStyle();
|
||||
}
|
||||
else
|
||||
{
|
||||
Style.Current = CreateDefaultStyle();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -233,6 +240,7 @@ namespace FlaxEditor.Options
|
||||
Foreground = Color.FromBgra(0xFFFFFFFF),
|
||||
ForegroundGrey = Color.FromBgra(0xFFA9A9B3),
|
||||
ForegroundDisabled = Color.FromBgra(0xFF787883),
|
||||
ForegroundViewport = Color.FromBgra(0xFFFFFFFF),
|
||||
BackgroundHighlighted = Color.FromBgra(0xFF54545C),
|
||||
BorderHighlighted = Color.FromBgra(0xFF6A6A75),
|
||||
BackgroundSelected = Color.FromBgra(0xFF007ACC),
|
||||
@@ -278,6 +286,60 @@ namespace FlaxEditor.Options
|
||||
return style;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates the light style (2nd default).
|
||||
/// </summary>
|
||||
/// <returns>The style object.</returns>
|
||||
public Style CreateLightStyle()
|
||||
{
|
||||
// Metro Style colors
|
||||
var options = Options;
|
||||
var style = new Style
|
||||
{
|
||||
Background = new Color(0.92f, 0.92f, 0.92f, 1f),
|
||||
LightBackground = new Color(0.84f, 0.84f, 0.88f, 1f),
|
||||
DragWindow = new Color(0.0f, 0.26f, 0.43f, 0.70f),
|
||||
Foreground = new Color(0.0f, 0.0f, 0.0f, 1f),
|
||||
ForegroundGrey = new Color(0.30f, 0.30f, 0.31f, 1f),
|
||||
ForegroundDisabled = new Color(0.45f, 0.45f, 0.49f, 1f),
|
||||
ForegroundViewport = new Color(1.0f, 1.0f, 1.0f, 1f),
|
||||
BackgroundHighlighted = new Color(0.59f, 0.59f, 0.64f, 1f),
|
||||
BorderHighlighted = new Color(0.50f, 0.50f, 0.55f, 1f),
|
||||
BackgroundSelected = new Color(0.00f, 0.46f, 0.78f, 0.78f),
|
||||
BorderSelected = new Color(0.11f, 0.57f, 0.88f, 0.65f),
|
||||
BackgroundNormal = new Color(0.67f, 0.67f, 0.75f, 1f),
|
||||
BorderNormal = new Color(0.59f, 0.59f, 0.64f, 1f),
|
||||
TextBoxBackground = new Color(0.75f, 0.75f, 0.81f, 1f),
|
||||
TextBoxBackgroundSelected = new Color(0.73f, 0.73f, 0.80f, 1f),
|
||||
CollectionBackgroundColor = new Color(0.85f, 0.85f, 0.88f, 1f),
|
||||
ProgressNormal = new Color(0.03f, 0.65f, 0.12f, 1f),
|
||||
|
||||
// Fonts
|
||||
FontTitle = options.Interface.TitleFont.GetFont(),
|
||||
FontLarge = options.Interface.LargeFont.GetFont(),
|
||||
FontMedium = options.Interface.MediumFont.GetFont(),
|
||||
FontSmall = options.Interface.SmallFont.GetFont(),
|
||||
|
||||
// Icons
|
||||
ArrowDown = Editor.Icons.ArrowDown12,
|
||||
ArrowRight = Editor.Icons.ArrowRight12,
|
||||
Search = Editor.Icons.Search12,
|
||||
Settings = Editor.Icons.Settings12,
|
||||
Cross = Editor.Icons.Cross12,
|
||||
CheckBoxIntermediate = Editor.Icons.CheckBoxIntermediate12,
|
||||
CheckBoxTick = Editor.Icons.CheckBoxTick12,
|
||||
StatusBarSizeGrip = Editor.Icons.WindowDrag12,
|
||||
Translate = Editor.Icons.Translate32,
|
||||
Rotate = Editor.Icons.Rotate32,
|
||||
Scale = Editor.Icons.Scale32,
|
||||
Scalar = Editor.Icons.Scalar32,
|
||||
|
||||
SharedTooltip = new Tooltip()
|
||||
};
|
||||
|
||||
return style;
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void OnInit()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user