diff src/xterm.c @ 112026:b3df357e51ff

Restore x_alloc_lighter_color_for_widget, needed for lwlib * src/xterm.h (x_alloc_lighter_color_for_widget): Restore declaration. * src/xterm.c (x_alloc_lighter_color_for_widget): Restore.
author Andreas Schwab <schwab@linux-m68k.org>
date Tue, 28 Dec 2010 17:34:04 +0100
parents ac49e05bfcf2
children 40af77a50adc
line wrap: on
line diff
--- a/src/xterm.c	Tue Dec 28 17:39:25 2010 +0800
+++ b/src/xterm.c	Tue Dec 28 17:34:04 2010 +0100
@@ -1483,6 +1483,22 @@
 }
 
 
+/* Allocate a color which is lighter or darker than *PIXEL by FACTOR
+   or DELTA.  Try a color with RGB values multiplied by FACTOR first.
+   If this produces the same color as PIXEL, try a color where all RGB
+   values have DELTA added.  Return the allocated color in *PIXEL.
+   DISPLAY is the X display, CMAP is the colormap to operate on.
+   Value is non-zero if successful.  */
+
+int
+x_alloc_lighter_color_for_widget (Widget widget, Display *display, Colormap cmap,
+				  unsigned long *pixel, double factor, int delta)
+{
+  struct frame *f = x_frame_of_widget (widget);
+  return x_alloc_lighter_color (f, display, cmap, pixel, factor, delta);
+}
+
+
 /* Structure specifying which arguments should be passed by Xt to
    cvt_string_to_pixel.  We want the widget's screen and colormap.  */