anchor.diff:      fPosition: Word;
       fFont: TKMFont;
       fRange: TKMRangeInt;
  +    fThumbText: UnicodeString;
  +    fAutoThumbWidth: Boolean;
       procedure SetCaption(const aValue: UnicodeString);
       procedure SetPosition(aValue: Word);
       procedure SetRange(const aRange: TKMRangeInt);
  +    procedure UpdateThumbWidth;
  +    procedure SetThumbText(const Value: UnicodeString);
  +    procedure SetAutoThumbWidth(const aValue: Boolean);
     protected
       function DoHandleMouseWheelByDefault: Boolean; override;
     public
       Step: Byte; //Change Position by this amount each time
  -    ThumbText: UnicodeString;
       ThumbWidth: Word;
       CaptionWidth: Integer;
       SliderFont: TKMFont;
  -
   
       constructor Create(aParent: TKMPanel; aLeft, aTop, aWidth: Integer; aMin, aMax: Word);
   
  
positive.code: end;
  
  
  procedure TKMTrackBar.ResetRange;
  begin
    fRange.Min := MinValue;
  
negative.code: constructor TKMTrackBar.Create(aParent: TKMPanel; aLeft, aTop, aWidth: Integer; aMin, aMax: Word);
  begin
    inherited Create(aParent, aLeft,aTop,aWidth,0);
    Assert(aMax > aMin, 'TKMTrackBar''s minValue >= maxValue');
    fMinValue := aMin;
    fMaxValue := aMax;
    fTrackHeight := 20;
    fRange := KMRange(aMin, aMax); //set Range before position
    Position := (fMinValue + fMaxValue) div 2;
    Caption := '';
    Font := fntMetal;
    SliderFont := fntMetal;
    CaptionWidth := -1;
  
    Step := 1;
    AutoThumbWidth := False;
  
    UpdateThumbWidth;
  end;
  
  
  procedure TKMTrackBar.UpdateThumbWidth;
  begin
    if AutoThumbWidth then
      ThumbWidth := Max(gRes.Fonts[SliderFont].GetTextSize(IntToStr(MaxValue)).X,
                        gRes.Fonts[SliderFont].GetTextSize(ThumbText).X)
    else
      ThumbWidth := gRes.Fonts[SliderFont].GetTextSize(IntToStr(MaxValue)).X;
  
    ThumbWidth := ThumbWidth + 24;
  end;
  
  
  procedure TKMTrackBar.SetAutoThumbWidth(const aValue: Boolean);
  begin
    fAutoThumbWidth := aValue;
    UpdateThumbWidth;
  end;
  
  
  