Increase the margins above and below column icons by 1px

This commit is contained in:
Kovid Goyal 2014-08-06 14:59:31 +05:30
parent be9a51f3b2
commit ad58fc7057

View File

@ -134,9 +134,9 @@ class ColumnIcon(object): # {{{
result = icon_bitmaps[0] result = icon_bitmaps[0]
# If the image height is less than the row height, leave it alone # If the image height is less than the row height, leave it alone
# The -2 allows for a pixel above and below. Also ensure that # The -4 allows for a margin above and below. Also ensure that
# it is always a bit positive # it is always a bit positive
rh = max(2, self.model.row_height - 2) rh = max(2, self.model.row_height - 4)
if result.height() > rh: if result.height() > rh:
result = result.scaledToHeight(rh, mode=Qt.SmoothTransformation) result = result.scaledToHeight(rh, mode=Qt.SmoothTransformation)
icon_cache[id_][cache_index] = result icon_cache[id_][cache_index] = result