Patchwork [bitbake-devel,7/9] lib/bb/ui/crumbs/persistenttooltip: ensure a reasonable minimum size

login
register
mail settings
Submitter Joshua Lock
Date March 24, 2012, 12:23 a.m.
Message ID <e750e728f211db865fcd1740cc1fa19a23485128.1332545580.git.josh@linux.intel.com>
Download mbox | patch
Permalink /patch/24417/
State Accepted
Commit 637ea3671dda9c5a1065f992fd9ee87d63043cf4
Headers show

Comments

Joshua Lock - March 24, 2012, 12:23 a.m.
The persistent tooltip looks a little weird when it's too small, request
that the toolkit and WM give it a reasonable minimum size.

Signed-off-by: Joshua Lock <josh@linux.intel.com>
---
 lib/bb/ui/crumbs/persistenttooltip.py |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
Dongxiao Xu - March 24, 2012, 1:03 a.m.
On Fri, 2012-03-23 at 17:23 -0700, Joshua Lock wrote:
> The persistent tooltip looks a little weird when it's too small, request
> that the toolkit and WM give it a reasonable minimum size.
> 
> Signed-off-by: Joshua Lock <josh@linux.intel.com>

Acked-by: Dongxiao Xu <dongxiao.xu@intel.com>

> ---
>  lib/bb/ui/crumbs/persistenttooltip.py |    3 +++
>  1 files changed, 3 insertions(+), 0 deletions(-)
> 
> diff --git a/lib/bb/ui/crumbs/persistenttooltip.py b/lib/bb/ui/crumbs/persistenttooltip.py
> index e184062..69e059b 100644
> --- a/lib/bb/ui/crumbs/persistenttooltip.py
> +++ b/lib/bb/ui/crumbs/persistenttooltip.py
> @@ -73,6 +73,9 @@ class PersistentTooltip(gtk.Window):
>          self.set_position(gtk.WIN_POS_MOUSE)
>          self.set_opacity(0.95)
>  
> +        # Ensure a reasonable minimum size
> +        self.set_geometry_hints(self, 100, 50)
> +
>          # Draw our label and close buttons
>          hbox = gtk.HBox(False, 0)
>          hbox.show()

Patch

diff --git a/lib/bb/ui/crumbs/persistenttooltip.py b/lib/bb/ui/crumbs/persistenttooltip.py
index e184062..69e059b 100644
--- a/lib/bb/ui/crumbs/persistenttooltip.py
+++ b/lib/bb/ui/crumbs/persistenttooltip.py
@@ -73,6 +73,9 @@  class PersistentTooltip(gtk.Window):
         self.set_position(gtk.WIN_POS_MOUSE)
         self.set_opacity(0.95)
 
+        # Ensure a reasonable minimum size
+        self.set_geometry_hints(self, 100, 50)
+
         # Draw our label and close buttons
         hbox = gtk.HBox(False, 0)
         hbox.show()