fixed line-endings on *.cs

This commit is contained in:
Bob
2010-03-22 19:28:37 +12:00
parent 15813b04a8
commit dca15cadb9
20 changed files with 944 additions and 944 deletions

View File

@@ -20,34 +20,34 @@
using System.Drawing;
namespace OpenRA.Widgets
{
class LabelWidget : Widget
{
public string Text = "";
public string Align = "Left";
public override void Draw()
{
if (!Visible)
{
base.Draw();
return;
}
Rectangle r = Bounds;
Game.chrome.renderer.Device.EnableScissor(r.Left, r.Top, r.Width, r.Height);
int2 bounds = Game.chrome.renderer.BoldFont.Measure(Text);
int2 position = new int2(Bounds.X,Bounds.Y);
if (Align == "Center")
position = new int2(Bounds.X+Bounds.Width/2, Bounds.Y+Bounds.Height/2) - new int2(bounds.X / 2, bounds.Y/2);
Game.chrome.renderer.BoldFont.DrawText(Game.chrome.rgbaRenderer, Text, position, Color.White);
Game.chrome.renderer.Device.DisableScissor();
base.Draw();
}
}
namespace OpenRA.Widgets
{
class LabelWidget : Widget
{
public string Text = "";
public string Align = "Left";
public override void Draw()
{
if (!Visible)
{
base.Draw();
return;
}
Rectangle r = Bounds;
Game.chrome.renderer.Device.EnableScissor(r.Left, r.Top, r.Width, r.Height);
int2 bounds = Game.chrome.renderer.BoldFont.Measure(Text);
int2 position = new int2(Bounds.X,Bounds.Y);
if (Align == "Center")
position = new int2(Bounds.X+Bounds.Width/2, Bounds.Y+Bounds.Height/2) - new int2(bounds.X / 2, bounds.Y/2);
Game.chrome.renderer.BoldFont.DrawText(Game.chrome.rgbaRenderer, Text, position, Color.White);
Game.chrome.renderer.Device.DisableScissor();
base.Draw();
}
}
}