HypernovaDesktop Components · docs
Binarymission
WinForms › Scroll Bar Marker › ScrollBarRangeMark

ScrollBarRangeMark

class.NET 6 / 8 / 10.NET Framework 4.8Binarymission.WinForms.Controls.MarkerScrollBar

A band on a marker scroll bar covering a stretch of the range, from ScrollBarMarkBase.Value to EndValue – a changed region, a selection, a time window.

public class ScrollBarRangeMark : ScrollBarShapeMark

Inherits from / implements: ScrollBarShapeMark

Remarks

Its length along the bar is worked out from the two values each time it is drawn and written into ScrollBarMarkBase.Size; set only the size across the bar (the width on a vertical bar, the height on a horizontal one). The colour, gradient, shape and border properties work as on ScrollBarShapeMark.

Examples

// Lines 310 to 355 changed since the last commit.
diffBar.ScrollBarMarks.Add(new ScrollBarRangeMark
{
    Value = 310,
    EndValue = 355,
    Size = new SizeF(3, 0),
    Alignment = ScrollBarMarkAlignment.Left,
    StartColor = Color.SeaGreen,
    ToolTipInfo = "Changed: lines 310 to 355",
});
diffBar.Invalidate();

Members at a glance

Properties
EndValueGets or sets where the band ends, in the bar's range units.

Properties

EndValue

public double EndValue

Gets or sets where the band ends, in the bar's range units.

Value
The default is 0. Should be greater than ScrollBarMarkBase.Value; a smaller value gives the band no visible length.