[f-spot/FSPOT_0_6_0_STABLE] Adds a thicker border with spacing to filmstrip's thumbnails. Fix bgo#540772.



commit 3c67c4704fbedcedd4de20fcfcbc4372a1fcda79
Author: Matt Perry <perrym3 gmail com>
Date:   Sun Apr 4 18:06:22 2010 +0200

    Adds a thicker border with spacing to filmstrip's thumbnails.
    Fix bgo#540772.

 src/PhotoView.cs         |    3 ++-
 src/Widgets/Filmstrip.cs |   11 ++++++++++-
 2 files changed, 12 insertions(+), 2 deletions(-)
---
diff --git a/src/PhotoView.cs b/src/PhotoView.cs
index 6c79d10..2e5cd10 100644
--- a/src/PhotoView.cs
+++ b/src/PhotoView.cs
@@ -328,11 +328,12 @@ namespace FSpot {
 			photo_view = new PhotoImageView (bp);
 	
 			filmstrip = new Filmstrip (bp);
-			Gdk.Pixbuf bg = new Gdk.Pixbuf (Gdk.Colorspace.Rgb, true, 8, 1, 69);
+			Gdk.Pixbuf bg = new Gdk.Pixbuf (Gdk.Colorspace.Rgb, true, 8, 1, 77);
 			bg.Fill (0x00000000);
 			filmstrip.BackgroundTile = bg;
 			filmstrip.ThumbOffset = 1;
 			filmstrip.Spacing = 4;
+			filmstrip.ThumbSize = 75;
 			PlaceFilmstrip ((Orientation) Preferences.Get <int> (Preferences.FILMSTRIP_ORIENTATION), true);
 	
 			photo_view.PhotoChanged += HandlePhotoChanged;
diff --git a/src/Widgets/Filmstrip.cs b/src/Widgets/Filmstrip.cs
index d6a47bd..074c399 100644
--- a/src/Widgets/Filmstrip.cs
+++ b/src/Widgets/Filmstrip.cs
@@ -649,6 +649,12 @@ namespace FSpot.Widgets
 				FSpot.ColorManagement.ApplyProfile (current, screen_profile);
 			}
 			
+			// Add a four pixel white border around the thumbnail
+			Pixbuf whiteBorder = new Pixbuf (Gdk.Colorspace.Rgb, true, 8, current.Width, current.Height);
+			whiteBorder.Fill (0);
+			current.CopyArea (1, 1, current.Width - 8, current.Height - 8, whiteBorder, 4, 4);
+			current = whiteBorder;
+
 			if (!highlighted)
 				return current;
 
@@ -656,7 +662,10 @@ namespace FSpot.Widgets
 			Gdk.Color color = Style.Background (StateType.Selected);
 			uint ucol = (uint)((uint)color.Red / 256 << 24 ) + ((uint)color.Green / 256 << 16) + ((uint)color.Blue / 256 << 8) + 255;
 			highlight.Fill (ucol);
-			current.CopyArea (1, 1, current.Width - 2, current.Height - 2, highlight, 1, 1);	
+
+			// Add a two pixel highlight around the thumbnail
+			current.CopyArea (2, 2, current.Width - 4, current.Height - 4, highlight, 2, 2);
+
 			return highlight;
 		}
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]