added a case for FOREGROUND_FILL. Fixes the layer new dialog so that it

Tue Jul 28 14:14:43 CDT 1998  Larry Ewing  <lewing@gimp.org>

	* app/drawable.c (drawable_fill): added a case for
	FOREGROUND_FILL.  Fixes the layer new dialog so that it actually
	works with foreground fill selected.
This commit is contained in:
CDT 1998 Larry Ewing 1998-07-28 19:26:36 +00:00 committed by Larry Ewing
parent bea11fc670
commit 46df3df747
2 changed files with 25 additions and 7 deletions

View File

@ -1,3 +1,9 @@
Tue Jul 28 14:14:43 CDT 1998 Larry Ewing <lewing@gimp.org>
* app/drawable.c (drawable_fill): added a case for
FOREGROUND_FILL. Fixes the layer new dialog so that it actually
works with foreground fill selected.
1998-07-28 Tuomas Kuosmanen <tigert@gimp.org>
* app/file_new_dialog.c

View File

@ -35,17 +35,29 @@ drawable_fill (GimpDrawable *drawable, int fill_type){
guchar r,g,b,a;
a=255;
switch(fill_type){
case FOREGROUND_FILL:
palette_get_foreground(&r, &g, &b);
break;
case BACKGROUND_FILL:
palette_get_background(&r, &g, &b);
break;
palette_get_background(&r, &g, &b);
break;
case WHITE_FILL:
r=g=b=255;
break;
r=g=b=255;
break;
case TRANSPARENT_FILL:
a=r=g=b=0;
break;
a=r=g=b=0;
break;
case NO_FILL:
return;
return;
default:
g_warning ("drawable_fill called with unknown fill type");
a=r=g=b=0;
break;
}
gimp_drawable_fill(drawable,r,g,b,a);
drawable_update (drawable, 0, 0,