diff --git a/sysprof.c b/sysprof.c index 5dbb3d9e..9e87341e 100644 --- a/sysprof.c +++ b/sysprof.c @@ -1327,23 +1327,6 @@ on_screenshot_close_button_clicked (GtkWidget *widget, update_sensitivity (app); } -/* If the samples label bounces around in size, this can cause the - * entire toolbar to be repeatedly redrawn, consuming significant CPU and - * distorting the profile. Constraining the label to only grow wider - * means that the toolbar will only be redrawn a few times as we gain - * more digits. - */ -static void -on_samples_label_size_request (GtkWidget *widget, - GtkRequisition *requistion, - Application *app) -{ - if (app->samples_label_width >= requistion->width) - requistion->width = app->samples_label_width; - else if (requistion->width > app->samples_label_width) - app->samples_label_width = requistion->width; -} - static void on_samples_label_style_set (GtkWidget *widget, GtkStyle *previous_style, @@ -1469,8 +1452,6 @@ connect_signals (Application *app) { app->descendants_view, "row-collapsed", on_descendants_row_expanded_or_collapsed, app }, { app->screenshot_window, "delete_event", on_screenshot_window_delete, app }, { app->screenshot_close_button, "clicked", on_screenshot_close_button_clicked, app }, - { app->samples_label, "size-request", on_samples_label_size_request, app }, - { app->samples_label, "style-set", on_samples_label_style_set, app }, }; int i; diff --git a/sysprof.glade b/sysprof.glade index f9210e70..63e9ac2d 100644 --- a/sysprof.glade +++ b/sysprof.glade @@ -18,6 +18,7 @@ GDK_WINDOW_TYPE_HINT_NORMAL GDK_GRAVITY_NORTH_WEST True + False @@ -28,6 +29,8 @@ True + GTK_PACK_DIRECTION_LTR + GTK_PACK_DIRECTION_LTR @@ -413,22 +416,107 @@ False - + True - Samples: 0 - False - False - GTK_JUSTIFY_LEFT - False - False - 0.5 - 0.5 - 6 - 0 - PANGO_ELLIPSIZE_NONE - -1 - False - 0 + False + False + GTK_POS_TOP + False + False + + + + True + Samples: 0 + False + False + GTK_JUSTIFY_RIGHT + False + False + 1 + 0.5 + 6 + 0 + PANGO_ELLIPSIZE_NONE + -1 + False + 0 + + + False + True + + + + + + True + label2 + False + False + GTK_JUSTIFY_LEFT + False + False + 0.5 + 0.5 + 0 + 0 + PANGO_ELLIPSIZE_NONE + -1 + False + 0 + + + tab + + + + + + True + Samples: 8888888 + False + False + GTK_JUSTIFY_LEFT + False + False + 0.5 + 0.5 + 0 + 0 + PANGO_ELLIPSIZE_NONE + -1 + False + 0 + + + False + True + + + + + + True + label3 + False + False + GTK_JUSTIFY_LEFT + False + False + 0.5 + 0.5 + 0 + 0 + PANGO_ELLIPSIZE_NONE + -1 + False + 0 + + + tab + + @@ -592,6 +680,7 @@ GDK_WINDOW_TYPE_HINT_UTILITY GDK_GRAVITY_NORTH_WEST True + False