public void SetShownVRangeInsideMargins(float min, float max)
{
if (this.m_UpDirection == YDirection.Positive)
{
this.m_Scale.y = -((this.drawRect.height - this.topmargin) - this.bottommargin) / (max - min);
this.m_Translation.y = (this.drawRect.height - (min * this.m_Scale.y)) - this.topmargin;
}
else
{
this.m_Scale.y = ((this.drawRect.height - this.topmargin) - this.bottommargin) / (max - min);
this.m_Translation.y = (-min * this.m_Scale.y) - this.bottommargin;
}
this.EnforceScaleAndRange();
}