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

Update for 0.51.0

This commit is contained in:
dan
1999-01-25 19:06:50 +00:00
parent 3aeb1eb052
commit 416e3a82be
238 changed files with 24235 additions and 11473 deletions

View File

@@ -759,12 +759,28 @@ wFrameWindowPaint(WFrameWindow *fwin)
XSetForeground(dpy, *fwin->title_gc,
fwin->title_pixel[fwin->flags.state]);
wDrawString(fwin->titlebar->window, *fwin->font,
*fwin->title_gc, x,
(*fwin->font)->y + TITLEBAR_EXTRA_HEIGHT/2, title,
titlelen);
#ifdef TITLE_TEXT_SHADOW
if(wPreferences.title_shadow){
int shadowx,shadowy;
XSetForeground(dpy, *fwin->title_gc,
fwin->title_pixel[fwin->flags.state+3]);
for(shadowx=0;shadowx<TITLE_TEXT_SHADOW_WIDTH;shadowx++)
for(shadowy=0;shadowy<TITLE_TEXT_SHADOW_HEIGHT;shadowy++)
wDrawString(fwin->titlebar->window, *fwin->font,
*fwin->title_gc,
x + shadowx + TITLE_TEXT_SHADOW_X_OFFSET,
(*fwin->font)->y + TITLEBAR_EXTRA_HEIGHT/2
+ shadowy + TITLE_TEXT_SHADOW_Y_OFFSET, title,
titlelen);
}
#endif /* TITLE_TEXT_SHADOW */
free(title);
}
}
@@ -900,6 +916,20 @@ wFrameWindowChangeTitle(WFrameWindow *fwin, char *new_title)
}
#ifdef OLWM_HINTS
void
wFrameWindowUpdatePushButton(WFrameWindow *fwin, Bool pushed)
{
fwin->flags.right_button_pushed_in = pushed;
paintButton(fwin->right_button, fwin->title_texture[fwin->flags.state],
fwin->title_pixel[fwin->flags.state],
fwin->rbutton_image, pushed);
}
#endif /* OLWM_HINTS */
/*********************************************************************/
static void
@@ -952,6 +982,7 @@ checkTitleSize(WFrameWindow *fwin)
}
}
static void
paintButton(WCoreWindow *button, WTexture *texture, unsigned long color,
WPixmap *image, int pushed)
@@ -1050,15 +1081,22 @@ handleButtonExpose(WObjDescriptor *desc, XEvent *event)
{
WFrameWindow *fwin = (WFrameWindow*)desc->parent;
WCoreWindow *button = (WCoreWindow*)desc->self;
if (button == fwin->left_button) {
paintButton(button, fwin->title_texture[fwin->flags.state],
fwin->title_pixel[fwin->flags.state],
fwin->lbutton_image, False);
} else {
Bool pushed = False;
#ifdef OLWM_HINTS
if (fwin->flags.right_button_pushed_in)
pushed = True;
#endif
/* emulate the olwm pushpin in the "out" state */
paintButton(button, fwin->title_texture[fwin->flags.state],
fwin->title_pixel[fwin->flags.state],
fwin->rbutton_image, False);
fwin->rbutton_image, pushed);
}
}