Correct scrollbar adjustments for row/column titles width.
authorJohn Darrington <john@darrington.wattle.id.au>
Tue, 18 Nov 2008 00:09:57 +0000 (09:09 +0900)
committerJohn Darrington <john@darrington.wattle.id.au>
Tue, 18 Nov 2008 00:09:57 +0000 (09:09 +0900)
lib/gtksheet/gtksheet.c

index b5233db8471b1790baadf51c052ba2d734e042f3..e46edc70d0887a699f47cf4a2cb45e7f06bf5d8c 100644 (file)
@@ -5478,6 +5478,9 @@ adjust_scrollbars (GtkSheet *sheet)
        g_sheet_row_get_height (sheet->row_geometry, last_row)
        ;
 
+      if (sheet->column_titles_visible)
+       sheet->vadjustment->upper += sheet->column_title_area.height;
+
       sheet->vadjustment->lower = 0;
       sheet->vadjustment->page_size = height;
 
@@ -5499,6 +5502,9 @@ adjust_scrollbars (GtkSheet *sheet)
        g_sheet_column_get_width (sheet->column_geometry, last_col)
        ;
 
+      if (sheet->row_titles_visible)
+       sheet->hadjustment->upper += sheet->row_title_area.width;
+
       sheet->hadjustment->lower = 0;
       sheet->hadjustment->page_size = width;