Fix frame counter, fps & input display to stand out more with a black overlay, and use the MessageColor config variable instead of being hard coded

This commit is contained in:
andres.delikat 2011-04-21 23:22:33 +00:00
parent d75b99b010
commit ac6ba9ce70
2 changed files with 12 additions and 8 deletions

View File

@ -579,7 +579,7 @@ namespace BizHawk.MultiClient
Global.Game.Name = (Global.Emulator as NES).GameName;
}
Text = DisplayNameForSystem(game.System) + " - " + game.Name + " \\";
Text = DisplayNameForSystem(game.System) + " - " + game.Name;
ResetRewindBuffer();
Global.Config.RecentRoms.Add(file.CanonicalName);
if (File.Exists(game.SaveRamPath))
@ -916,8 +916,6 @@ namespace BizHawk.MultiClient
{
runloop_second = DateTime.Now;
Global.RenderPanel.FPS = runloop_fps;
if(Text.IndexOf('\\') != -1)
Text = Text.Substring(0, Text.IndexOf('\\')) + "\\ " + runloop_fps + " fps";
Global.RenderPanel.FPS = runloop_fps;
runloop_fps = 0;
}

View File

@ -258,19 +258,25 @@ namespace BizHawk.MultiClient
//TODO: If movie loaded use that frame counter, and also display total movie frame count if read-only
if (Global.Config.DisplayFrameCounter)
{
//MessageFont.DrawString(null, MakeFrameCounter(), Global.Config.DispFrameCx+2,
// Global.Config.DispFrameCy+2, new Color4(Color.Black));
MessageFont.DrawString(null, MakeFrameCounter(), Global.Config.DispFrameCx+2,
Global.Config.DispFrameCy+2, new Color4(Color.Black));
MessageFont.DrawString(null, MakeFrameCounter(), Global.Config.DispFrameCx,
Global.Config.DispFrameCy, Color.FromArgb(Global.Config.MessagesColor));
}
if (Global.Config.DisplayInput)
{
string input = MakeInputDisplay();
MessageFont.DrawString(null, input, Global.Config.DispInpx, Global.Config.DispInpy, new Color4(Color.White));
MessageFont.DrawString(null, input, Global.Config.DispInpx+2, Global.Config.DispInpy+2, new Color4(Color.Black));
MessageFont.DrawString(null, input, Global.Config.DispInpx, Global.Config.DispInpy, Color.FromArgb(Global.Config.MessagesColor));
}
if (Global.Config.DisplayFPS)
MessageFont.DrawString(null, FPS.ToString() + " fps", Global.Config.DispFPSx, Global.Config.DispFPSy, new Color4(Color.White));
if (Global.Config.DisplayFPS)
{
MessageFont.DrawString(null, FPS.ToString() + " fps", Global.Config.DispFPSx+2,
Global.Config.DispFPSy+2, new Color4(Color.Black));
MessageFont.DrawString(null, FPS.ToString() + " fps", Global.Config.DispFPSx,
Global.Config.DispFPSy, Color.FromArgb(Global.Config.MessagesColor));
}
}
private string MakeFrameCounter()