|
From: | H.G. Muller |
Subject: | Re: [XBoard-devel] Board sizing |
Date: | Tue, 5 Apr 2016 23:38:36 +0200 |
User-agent: | Mozilla/5.0 (Windows NT 6.3; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 |
Op 4/5/2016 om 9:55 PM schreef Joshua
Pettus:
I think this is definitely a step in the right direction! Great job! This is weird. What is in the settings file before you open it, for -boardSize and -clockFont for that size? And if you would start an older version (e.g. the latest development release) with those same settings, does it also do this? Could you print the clock font in the function Resize() in gtk/xboard.c like this: if(initialSquareSize != sizeDefaults[h].squareSize) { // boardSize changed initialSquareSize = sizeDefaults[h].squareSize; // used for saving font if(!fontValid[CLOCK_FONT][initialSquareSize]) fontTable[CLOCK_FONT][initialSquareSize] = CLOCK_FONT_NAME; appData.clockFont = InsertPxlSize(fontTable[CLOCK_FONT][initialSquareSize], 2*(sizeDefaults[h].clockFontPxlSize+1)/3); printf("resize square=%d clock font = %s\n", initialSquareSize, appData.clockFont); It could be that we start with some ridiculously large font, and that the font change causes another resize events that makes the font much smaller, and that the widget somehow does not follow the size decrease of the font. Normally it should, however. (Also in the Fonts dialog itself, when you operate the - button.) I never have to do anything special for that; If I make the font in the label widget smaller, the height of the widget decreases. It is just a matter whether the outer window will also shrink, or stay the same leaving a blank area below the board. I have to issue a gtk_window_resize call to shrink it tight around the board, and even that is sometimes ignored. Umm, that reminds me that in any case the menu-bar clipping code needs to be surrounded with an #ifndef OSXAPP, which I did not do... Well, you should be able to shrink the window from the top too. And then you have space to move it up by the title bar, to bring the bottom edge on screen. Plus that the 'ellipsis' mode I set on the clock seems to have solved the problem that the clocks did not want to shrink below the text width. So when the menu bar is also not in the window you should be able to shrink the width of the window as much as you like, and that should eventually bring the bottom edge in view. H.G. |
[Prev in Thread] | Current Thread | [Next in Thread] |