Slider MaxValue Property Delta Engine Documentation

Namespace: DeltaEngine.Scenes.Controls
Assembly: DeltaEngine.Scenes (in DeltaEngine.Scenes.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public int MaxValue { get; set; }

Property Value

Type: Int32
Remarks

Tests: DeltaEngine.Scenes.Tests.Controls.SliderTests
Examples

4 unit tests call DeltaEngine.Scenes.Controls.Slider.MaxValue
[Test, CloseAfterFirstFrame]
public void DefaultProperties()
{
    Assert.IsTrue(slider.IsEnabled);
    Assert.AreEqual(Color.Gray, slider.Color);
    Assert.AreEqual(Color.LightGray, slider.Pointer.Color);
    Assert.AreEqual(0, slider.MinValue);
    Assert.AreEqual(100, slider.Value);
    Assert.AreEqual(100, slider.MaxValue);
}
[Test, ApproveFirstFrameScreenshot]
public void RenderSliderMinusFiveToFive()
{
    slider.MinValue = -5;
    slider.Value = 0;
    slider.MaxValue = 5;
}
[Test, CloseAfterFirstFrame]
public void UpdateValues()
{
    slider.MinValue = 1;
    slider.Value = 2;
    slider.MaxValue = 3;
    Assert.AreEqual(1, slider.MinValue);
    Assert.AreEqual(2, slider.Value);
    Assert.AreEqual(3, slider.MaxValue);
}
See Also