[gimp] Bug 761998 - MyPaint brush popup out of screen
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] Bug 761998 - MyPaint brush popup out of screen
- Date: Sun, 20 Mar 2016 20:36:05 +0000 (UTC)
commit 9693ab92e735744730ba89ce48126bcf4703ba55
Author: Michael Natterer <mitch gimp org>
Date: Sun Mar 20 21:34:37 2016 +0100
Bug 761998 - MyPaint brush popup out of screen
Add a lame workaround to GimpContainerPopup (default to 6 instead
of 10 rows of items if the view size is >= LARGE).
app/widgets/gimpcontainerpopup.c | 22 ++++++++++++++++++----
1 files changed, 18 insertions(+), 4 deletions(-)
---
diff --git a/app/widgets/gimpcontainerpopup.c b/app/widgets/gimpcontainerpopup.c
index e16e554..f8571d7 100644
--- a/app/widgets/gimpcontainerpopup.c
+++ b/app/widgets/gimpcontainerpopup.c
@@ -295,6 +295,8 @@ gimp_container_popup_create_view (GimpContainerPopup *popup)
{
GimpEditor *editor;
GtkWidget *button;
+ gint rows;
+ gint columns;
popup->editor = g_object_new (GIMP_TYPE_CONTAINER_EDITOR,
"view-type", popup->view_type,
@@ -319,11 +321,23 @@ gimp_container_popup_create_view (GimpContainerPopup *popup)
gtk_widget_show (search_entry);
}
+ /* lame workaround for bug #761998 */
+ if (popup->default_view_size >= GIMP_VIEW_SIZE_LARGE)
+ {
+ rows = 6;
+ columns = 6;
+ }
+ else
+ {
+ rows = 10;
+ columns = 6;
+ }
+
gimp_container_box_set_size_request (GIMP_CONTAINER_BOX (popup->editor->view),
- 6 * (popup->default_view_size +
- 2 * popup->view_border_width),
- 10 * (popup->default_view_size +
- 2 * popup->view_border_width));
+ columns * (popup->default_view_size +
+ 2 * popup->view_border_width),
+ rows * (popup->default_view_size +
+ 2 * popup->view_border_width));
if (GIMP_IS_EDITOR (popup->editor->view))
gimp_editor_set_show_name (GIMP_EDITOR (popup->editor->view), FALSE);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]