anchor.diff:          end;
     end;
   
  +  // set the scrollbar width/height space
  +  if showV then
  +    Dec(HWidth, FVScrollBar.Width);
     if showH then
  -    FHScrollBar.Visible := true
  -  else
  -  begin
  -    FHScrollBar.Visible := false;
  -    if Hfits then
  -    begin
  -      FFirstCol := 0;
  -      FXOffset := 0;
  -    end;
  -    // if horizontal doesn't fit and no scrollbar, do not change firstcol/xoffset
  -  end;
  +    Dec(VHeight, FHScrollBar.Height);
  +
  +  // show or hide the scrollbars
   
     if showV then
  -    FVScrollBar.Visible := true
  -  else
  -  begin
  -    FVScrollBar.Visible := false;
  -    if Vfits then
  -      FFirstRow := 0;
  -    // if vertical doesn't fit and no scrollbar, do not change firstrow
  -  end;
  -
  -  if FVScrollBar.Visible then
  -  begin
  -    Dec(HWidth, FVScrollBar.Width);
  +  begin
  +    FVScrollBar.Visible := true;
       FVScrollBar.Min         := 0;
       if RowCount > 0 then
         FVScrollBar.SliderSize := VisibleLines / RowCount
  
positive.code:     FVScrollBar.Max         := RowCount-VisibleLines;
      FVScrollBar.Position    := FFirstRow;
      FVScrollBar.RepaintSlider;
    end;
    
    if FHScrollBar.Visible then
    begin
      Dec(VHeight, FHScrollBar.Height);
      FHScrollBar.Min         := 0;
      if go_SmoothScroll in FOptions then
      begin
  
negative.code:       FHScrollBar.SliderSize  := 1 / ColumnCount;
      end;
      FHScrollBar.RepaintSlider;
      FHScrollBar.Top     := Height -FHScrollBar.Height - 2;
      FHScrollBar.Left    := 2;
      FHScrollBar.Width   := HWidth;
    end
    else
    begin
      FHScrollBar.Visible := false;
      if Hfits then
      begin
        FFirstCol := 0;
        FXOffset := 0;
      end;
      // if horizontal doesn't fit and no scrollbar, do not change firstcol/xoffset
    end;
  
    FVScrollBar.UpdateWindowPosition;
    FHScrollBar.UpdateWindowPosition;
  