char* MakeEvalTitle( char * title)
{
- int score = currPvInfo[ currCurrent ].score;
- int depth = currPvInfo[ currCurrent ].depth;
+ int score, depth;
static char buf[MSG_SIZ];
+ if( currCurrent <0 ) return title; // currCurrent = -1 crashed WB on start without ini file!
+ score = currPvInfo[ currCurrent ].score;
+ depth = currPvInfo[ currCurrent ].depth;
+
if( depth <=0 ) return title;
if( currCurrent & 1 ) score = -score; /* Flip score for black */
snprintf(buf, MSG_SIZ, "%s {%s%.2f/%-2d %d}", title, score>0 ? "+" : " ", score/100., depth, (currPvInfo[currCurrent].time+50)/100);
// the initial brush selection is useless? BkMode needed for dotted line and text
static void DrawAxis()
{
- int cy = nHeightPB / 2;
+ int cy = nHeightPB / 2, space = nHeightPB/(6 + appData.zoom);
-// SelectObject( hdcPB, GetStockObject(NULL_BRUSH) );
-
-// SetBkMode( hdcPB, TRANSPARENT );
-
DrawAxisSegmentHoriz( +5, TRUE );
- DrawAxisSegmentHoriz( +3, FALSE );
- DrawAxisSegmentHoriz( +1, FALSE );
+ DrawAxisSegmentHoriz( +3, space >= 20 );
+ DrawAxisSegmentHoriz( +1, space >= 20 && space*appData.zoom >= 40 );
DrawAxisSegmentHoriz( 0, TRUE );
- DrawAxisSegmentHoriz( -1, FALSE );
- DrawAxisSegmentHoriz( -3, FALSE );
+ DrawAxisSegmentHoriz( -1, space >= 20 && space*appData.zoom >= 40 );
+ DrawAxisSegmentHoriz( -3, space >= 20 );
DrawAxisSegmentHoriz( -5, TRUE );
DrawLine( MarginX + MarginW, cy, nWidthPB - MarginW, cy, PEN_BLACK ); // x-axis