[gimp] Bug 635303 - Can't attach a dialog at the bottom of a minimized toolbox
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] Bug 635303 - Can't attach a dialog at the bottom of a minimized toolbox
- Date: Sun, 7 Oct 2012 17:51:02 +0000 (UTC)
commit 74bc0701478184cbf6a0c30908b8fed307894a8b
Author: Michael Natterer <mitch gimp org>
Date: Sun Oct 7 19:49:33 2012 +0200
Bug 635303 - Can't attach a dialog at the bottom of a minimized toolbox
Ensure a minimum size of the drop area and make sure it stays visible
at the bottom of a minimized toolbox. This wastes a few pixels at the
bottom of a toolbox that contains no dockables.
app/widgets/gimppanedbox.c | 12 +++++-------
1 files changed, 5 insertions(+), 7 deletions(-)
---
diff --git a/app/widgets/gimppanedbox.c b/app/widgets/gimppanedbox.c
index a0613f2..cd57c5a 100644
--- a/app/widgets/gimppanedbox.c
+++ b/app/widgets/gimppanedbox.c
@@ -51,11 +51,11 @@
* order to be inserted and get space on their own (rather than
* inserted among others and sharing space)
*/
-#define DROP_AREA_SIZE 5
+#define DROP_AREA_SIZE 6
#define INSERT_INDEX_UNUSED G_MININT
-#define INSTRUCTIONS_TEXT_PADDING 4
+#define INSTRUCTIONS_TEXT_PADDING 6
#define INSTRUCTIONS_TEXT _("You can drop dockable dialogs here")
@@ -147,7 +147,7 @@ gimp_paned_box_init (GimpPanedBox *paned_box)
gtk_label_set_line_wrap (GTK_LABEL (paned_box->p->instructions), TRUE);
gtk_label_set_justify (GTK_LABEL (paned_box->p->instructions),
GTK_JUSTIFY_CENTER);
- gtk_widget_set_size_request (paned_box->p->instructions, 16, 0);
+ gtk_widget_set_size_request (paned_box->p->instructions, 16, DROP_AREA_SIZE);
gimp_label_set_attributes (GTK_LABEL (paned_box->p->instructions),
PANGO_ATTR_STYLE, PANGO_STYLE_ITALIC,
-1);
@@ -259,10 +259,8 @@ gimp_paned_box_get_drop_area_size (GimpPanedBox *paned_box)
else if (orientation == GTK_ORIENTATION_VERTICAL)
drop_area_size = allocation.height;
}
- else
- {
- drop_area_size = DROP_AREA_SIZE;
- }
+
+ drop_area_size = MAX (drop_area_size, DROP_AREA_SIZE);
return drop_area_size;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]