From: H.G. Muller Date: Wed, 30 Jun 2010 08:49:12 +0000 (+0200) Subject: Allow -flipBlack to work with font-based piece rendering X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=4810e20e1187226654ceb1b4b05fa1065c6a6cea;p=xboard.git Allow -flipBlack to work with font-based piece rendering In addition the font-based pieces will also be flipped vertically in flipView for variant shogi when -flipBlack is off. --- diff --git a/winboard/winboard.c b/winboard/winboard.c index cbf38fa..bb78522 100644 --- a/winboard/winboard.c +++ b/winboard/winboard.c @@ -2531,6 +2531,9 @@ DrawPieceOnDC(HDC hdc, ChessSquare piece, int color, int sqcolor, int x, int y, SelectObject( tmphdc, hPieceMask[ index ] ); + if(appData.upsideDown ? color==flipView : (flipView && gameInfo.variant == VariantShogi)) + StretchBlt(hdc, x+squareSize, y+squareSize, -squareSize, -squareSize, tmphdc, 0, 0, squareSize, squareSize, SRCAND); + else BitBlt( hdc, x, y, squareSize, squareSize, @@ -2540,6 +2543,9 @@ DrawPieceOnDC(HDC hdc, ChessSquare piece, int color, int sqcolor, int x, int y, SelectObject( tmphdc, hPieceFace[ index ] ); + if(appData.upsideDown ? color==flipView : (flipView && gameInfo.variant == VariantShogi)) + StretchBlt(hdc, x+squareSize, y+squareSize, -squareSize, -squareSize, tmphdc, 0, 0, squareSize, squareSize, SRCPAINT); + else BitBlt( hdc, x, y, squareSize, squareSize,