From e7f2c8eca4e43ee3d4ea195a6e1ea76584820045 Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Sat, 31 Oct 2020 17:42:39 +0100 Subject: [PATCH] added a separate style property for tooltip text color --- MLEM.Ui/Elements/Tooltip.cs | 1 + MLEM.Ui/Style/UiStyle.cs | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/MLEM.Ui/Elements/Tooltip.cs b/MLEM.Ui/Elements/Tooltip.cs index 4d71147..5a0a4f6 100644 --- a/MLEM.Ui/Elements/Tooltip.cs +++ b/MLEM.Ui/Elements/Tooltip.cs @@ -70,6 +70,7 @@ namespace MLEM.Ui.Elements { base.InitStyle(style); this.Texture.SetFromStyle(style.TooltipBackground); this.MouseOffset.SetFromStyle(style.TooltipOffset); + this.Paragraph?.TextColor.SetFromStyle(style.TooltipTextColor); } /// diff --git a/MLEM.Ui/Style/UiStyle.cs b/MLEM.Ui/Style/UiStyle.cs index 286cade..18fc30d 100644 --- a/MLEM.Ui/Style/UiStyle.cs +++ b/MLEM.Ui/Style/UiStyle.cs @@ -104,6 +104,10 @@ namespace MLEM.Ui.Style { /// public Vector2 TooltipOffset; /// + /// The color that the text of a should have + /// + public Color TooltipTextColor; + /// /// The texture that the element uses for its background /// public NinePatch ProgressBarTexture;