mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-22 05:48:01 +01:00
wmaker: minor fixes for the size of an aperçu
There was a probable bug when reading settings, because the function used was 'getInt' which would try to store the result in a 'char'. As it would be probably easier for user to have the value directly in pixels, the storage is now done in an int so there won't be problem anymore. Changed the behaviour of the constant APERCU_BORDER, which would be assumed to be the size of the border in pixel, but in previous code it was actually the sum of the two border (1 on each side). All maths have been changed to have it as a single border width. Took opportunity to group variable assignation for titleHeight and shortenTitle in a single place, because it is not convenient to have them spread around (one value in the beginning and others later in the code) and using default values prevents some checks that modern compiler can do to help produce safer code. Signed-off-by: Christophe CURIS <christophe.curis@free.fr> Signed-off-by: Carlos R. Mafra <crmafra@gmail.com>
This commit is contained in:
committed by
Carlos R. Mafra
parent
572af55c9f
commit
38d160cb8c
@@ -444,7 +444,7 @@ extern struct WPreferences {
|
||||
char cycle_ignore_minimized; /* Ignore minimized windows when cycling */
|
||||
char strict_windoze_cycle; /* don't close switch panel when shift is released */
|
||||
char panel_only_open; /* Only open the switch panel; don't switch */
|
||||
char apercu_size; /* Size of apercu preview as a multiple of icon size */
|
||||
int apercu_size; /* Size of apercu preview in pixels */
|
||||
|
||||
/* All delays here are in ms. 0 means instant auto-action. */
|
||||
int clip_auto_raise_delay; /* Delay after which the clip will be raised when entered */
|
||||
|
||||
Reference in New Issue
Block a user