1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-22 14:08:06 +01:00

- API change in WINGs for WMDraw*String().

WMDrawString() and WMDrawImageString() now take WMColor instead of GC as
  arguments. WMDrawImageString() receives 2 colors (text & background).
  This is to allow easy extension for Xft/Xrender and hide X low level details
- Added alpha channel to WMColor. 2 new functions also:
  WMCreateRGBAColor() and WMSetColorAlpha()
- Miscelaneous code cleanups in wtext.c
- Removed obsoleted acconfig.h and implemented its functionality using
  AC_DEFINE and AC_DEFINE_UNQUOTED as autoconf 2.5x recommends.
  This will definitely enforce the need to use autoconf 2.5x
This commit is contained in:
dan
2002-10-08 08:26:06 +00:00
parent e98da5a628
commit a2b404b5b3
58 changed files with 554 additions and 601 deletions

View File

@@ -289,14 +289,11 @@ updateDockNumbers(WScreen *scr)
{
int length;
char *ws_numbers;
GC numbers_gc;
XGCValues my_gc_values;
unsigned long my_v_mask = (GCForeground);
WAppIcon *dicon = scr->dock->icon_array[0];
my_gc_values.foreground = scr->white_pixel;
numbers_gc = XCreateGC(dpy, dicon->icon->core->window,
my_v_mask, &my_gc_values);
WMColor *black, *white;
black = WMBlackColor(scr->wmscreen);
white = WMWhiteColor(scr->wmscreen);
ws_numbers = wmalloc(20);
snprintf(ws_numbers, 20, "%i [ %i ]", scr->current_workspace+1,
@@ -306,15 +303,14 @@ updateDockNumbers(WScreen *scr)
XClearArea(dpy, dicon->icon->core->window, 2, 2, 50,
WMFontHeight(scr->icon_title_font)+1, False);
XSetForeground(dpy, numbers_gc, scr->black_pixel);
WMDrawString(scr->wmscreen, dicon->icon->core->window, numbers_gc,
WMDrawString(scr->wmscreen, dicon->icon->core->window, black,
scr->icon_title_font, 4, 3, ws_numbers, length);
XSetForeground(dpy, numbers_gc, scr->white_pixel);
WMDrawString(scr->wmscreen, dicon->icon->core->window, numbers_gc,
WMDrawString(scr->wmscreen, dicon->icon->core->window, white,
scr->icon_title_font, 3, 2, ws_numbers, length);
XFreeGC(dpy, numbers_gc);
WMReleaseColor(black);
WMReleaseColor(white);
wfree(ws_numbers);
}
#endif /* WS_INDICATOR */