From: Arun Persaud Date: Sat, 29 Aug 2009 06:34:23 +0000 (-0700) Subject: fixed background color of squares with pieces; some cleanup X-Git-Tag: gtk-20091122~36 X-Git-Url: http://winboard.nl/cgi-bin?p=xboard.git;a=commitdiff_plain;h=22b91d2842033a4360cb3881f1d9bede15fcebb0 fixed background color of squares with pieces; some cleanup --- diff --git a/xboard.c b/xboard.c index 6f6a37c..2859a26 100644 --- a/xboard.c +++ b/xboard.c @@ -842,15 +842,6 @@ DropMenuEnables dmEnables[] = { { 'Q', "Queen" } }; -Arg shellArgs[] = { - { XtNwidth, 0 }, - { XtNheight, 0 }, - { XtNminWidth, 0 }, - { XtNminHeight, 0 }, - { XtNmaxWidth, 0 }, - { XtNmaxHeight, 0 } -}; - Arg layoutArgs[] = { { XtNborderWidth, 0 }, { XtNdefaultDistance, 0 }, @@ -867,25 +858,6 @@ Arg boardArgs[] = { { XtNheight, 0 } }; -Arg titleArgs[] = { - { XtNjustify, (XtArgVal) XtJustifyRight }, - { XtNlabel, (XtArgVal) "..." }, - { XtNresizable, (XtArgVal) True }, - { XtNresize, (XtArgVal) False } -}; - -Arg messageArgs[] = { - { XtNjustify, (XtArgVal) XtJustifyLeft }, - { XtNlabel, (XtArgVal) "..." }, - { XtNresizable, (XtArgVal) True }, - { XtNresize, (XtArgVal) False } -}; - -Arg timerArgs[] = { - { XtNborderWidth, 0 }, - { XtNjustify, (XtArgVal) XtJustifyLeft } -}; - XtResource clientResources[] = { { "whitePieceColor", "whitePieceColor", XtRString, sizeof(String), XtOffset(AppDataPtr, whitePieceColor), XtRString, @@ -3683,6 +3655,10 @@ static void DrawPiece(piece, square_color, x, y, dest) int square_color, x, y; Drawable dest; { + /* redraw background, since piece might be transparent in some areas */ + BlankSquare(x,y,square_color,piece,dest); + + /* draw piece */ gdk_draw_pixbuf(GDK_WINDOW(GUI_Board->window),NULL, GDK_PIXBUF(SVGpieces[piece]),0,0,x,y,-1,-1, GDK_RGB_DITHER_NORMAL, 0, 0); diff --git a/xengineoutput.c b/xengineoutput.c index 77d5bf3..eea9818 100644 --- a/xengineoutput.c +++ b/xengineoutput.c @@ -144,7 +144,7 @@ extern int opponentKibitzes; /* Imports from winboard.c */ //extern HWND engineOutputDialog; -extern Arg layoutArgs[2], formArgs[2], messageArgs[4]; +extern Arg layoutArgs[2], formArgs[2]; //extern WindowPlacement wpEngineOutput;