After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 571360 - Bad appearance for GtkEntry with progress
Bad appearance for GtkEntry with progress
Status: RESOLVED FIXED
Product: gtk-engines
Classification: Deprecated
Component: clearlooks
unspecified
Other Linux
: Normal major
: ---
Assigned To: gtk-engines maintainers
gtk-engines maintainers
Depends on: 546285
Blocks:
 
 
Reported: 2009-02-11 21:53 UTC by Luca Ferretti
Modified: 2009-04-04 13:20 UTC
See Also:
GNOME target: ---
GNOME version: 2.25/2.26


Attachments
GtkEntry test application in Clearlooks (22.12 KB, image/png)
2009-02-11 21:57 UTC, Luca Ferretti
Details
Small implementation (11.62 KB, image/png)
2009-02-12 00:23 UTC, Andrea Cimitan
Details
quick gimp touchup (22.57 KB, image/png)
2009-02-12 13:43 UTC, Luca Ferretti
Details
Glitches in previous example code (21.99 KB, image/png)
2009-02-12 13:45 UTC, Luca Ferretti
Details

Description Luca Ferretti 2009-02-11 21:53:59 UTC
GTK+ 2.15/16 introduces the ability to put a progress in a GtkEntry.

Unfortunately the appearence in Clearlooks is really bad (I've not tested other default themes, sorry), see the attached screeenshot.

By now the only application using this GtkEntry feature is Epiphany, but could be good fix it ASAP, for 2.26 release (this is the reason I've set severity:major).
Comment 1 Luca Ferretti 2009-02-11 21:57:39 UTC
Created attachment 128496 [details]
GtkEntry test application in Clearlooks

See the bad white/double border around progress in bottom GtkEntry
Comment 2 Andrea Cimitan 2009-02-11 22:41:15 UTC
Any idea/mockup for the look?
Comment 3 Andrea Cimitan 2009-02-12 00:23:18 UTC
Created attachment 128507 [details]
Small implementation

Ideas?

Index: engines/clearlooks/src/clearlooks_style.c
===================================================================
--- engines/clearlooks/src/clearlooks_style.c	(revisione 1305)
+++ engines/clearlooks/src/clearlooks_style.c	(copia locale)
@@ -848,6 +848,24 @@
 		                                       x, y, width, height,
 		                                       10 - (int)(elapsed * 10.0) % 10);
 	}
+	else if (DETAIL ("entry-progress"))
+	{
+		/* Draw the progresbar inside the entry,
+		 * we should manage this clearlooks_draw.c
+		 * Temporary here only for testing.
+		 */
+	
+		cairo_rectangle (cr, x+1, y+1, width-2, height-2);
+		cairo_set_source_rgba (cr, colors->spot[1].r,
+		                           colors->spot[1].g,
+		                           colors->spot[1].b, 0.5);
+		cairo_fill (cr);
+		cairo_rectangle (cr, x+1.5, y+1.5, width-3, height-3);
+		cairo_set_source_rgba (cr, colors->spot[2].r,
+		                           colors->spot[2].g,
+		                           colors->spot[2].b, 0.5);
+		cairo_stroke (cr);
+	}
 	else if (DETAIL ("optionmenu"))
 	{
 		WidgetParameters params;
Comment 4 Benjamin Berg 2009-02-12 13:29:09 UTC
This will only be available with GTK+ 2.16, which will not happen for 2.26. So while it would be nice to have for 2.26, it "only" needs to be done for 2.28.
Comment 5 Luca Ferretti 2009-02-12 13:43:02 UTC
Created attachment 128558 [details]
quick gimp touchup

Your idea is great, but I'm for something without white padding and borders on top and bottom.

A really really soft gradient, providing a little "volume" to progress, could be explored too..
Comment 6 Luca Ferretti 2009-02-12 13:45:15 UTC
Created attachment 128559 [details]
Glitches in previous example code

To reproduce:
 1) launch gtk+/tests/testentryicons
 2) increase from 0.00 to X.XX the progress entrues using Properties button
 3) decrease the progress to 0.00

OK, it's very rare, I know :D
Comment 7 Luca Ferretti 2009-02-12 13:53:25 UTC
(In reply to comment #4)
> This will only be available with GTK+ 2.16, which will not happen for 2.26. So
> while it would be nice to have for 2.26, it "only" needs to be done for 2.28.
> 

No, GTK 2.16 will be used in GNOME 2.26
Comment 8 Luca Ferretti 2009-02-12 14:06:41 UTC
Just for reference: similar stuff in iPod/iPhoneTouch

http://www.spirituality.org.za/uploaded_images/MTN-South-Africa-iPhone-safari-loading-702411.jpg
Comment 9 Andrea Cimitan 2009-02-12 18:56:59 UTC
(In reply to comment #5)
> Created an attachment (id=128558) [edit]
> quick gimp touchup
> 
> Your idea is great, but I'm for something without white padding and borders on
> top and bottom.
> 
> A really really soft gradient, providing a little "volume" to progress, could
> be explored too..
> 

It can't be implemented
Comment 10 Benjamin Berg 2009-02-19 17:27:39 UTC
Well, I think that my patch from bug #546285 should go into GTK+, then we should be able to properly theme the GtkEntry progress drawing.
Comment 11 Benjamin Berg 2009-04-04 13:20:28 UTC
This has already been (mostly) fixed in gtk-engines 2.18.0. If there should be any more improvements or there are some issues, please open new bugs.