From da3fa9fcbbca3cc216c4b3b5c642fb291e5fe3b4 Mon Sep 17 00:00:00 2001 From: Alexander Eckart Date: Fri, 22 Jun 2012 11:23:37 +0200 Subject: [PATCH] fixed horizontal text position for reflections --- Vocaluxe/Menu/CText.cs | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/Vocaluxe/Menu/CText.cs b/Vocaluxe/Menu/CText.cs index c82f2a80..c44b68e3 100644 --- a/Vocaluxe/Menu/CText.cs +++ b/Vocaluxe/Menu/CText.cs @@ -601,7 +601,22 @@ namespace Vocaluxe.Menu if (Reflection) { - CFonts.DrawTextReflection(_Text, _DrawPosition.tH, _DrawPosition.X, _DrawPosition.Y, Z, color, ReflectionSpace, ReflectionHeight); + float sFactor = 0f; + switch (HAlign) + { + case EHAlignment.Top: + sFactor = (Height - _DrawPosition.tH) * 1.5f; + break; + case EHAlignment.Center: + sFactor = (Height - _DrawPosition.tH) * 1.0f; + break; + case EHAlignment.Bottom: + sFactor = (Height - _DrawPosition.tH) * 0.5f; + break; + default: + break; + } + CFonts.DrawTextReflection(_Text, _DrawPosition.tH, _DrawPosition.X, _DrawPosition.Y, Z, color, ReflectionSpace + sFactor, ReflectionHeight); } if (Selected && (CSettings.GameState == EGameState.EditTheme))