Landscape popout minimum width 35% of screen
This commit is contained in:
parent
aaf33dd7c7
commit
0a1fbb7906
@ -261,7 +261,8 @@ class FullscreenPreview(QMainWindow):
|
|||||||
max_h = int(avail.height() * 0.85) # 15% margin top+bottom
|
max_h = int(avail.height() * 0.85) # 15% margin top+bottom
|
||||||
else:
|
else:
|
||||||
max_w = max_h = 9999
|
max_w = max_h = 9999
|
||||||
w = min(self.width(), max_w)
|
min_w = int(max_w * 0.35) if aspect >= 1 else 0 # landscape minimum
|
||||||
|
w = max(min(self.width(), max_w), min_w)
|
||||||
new_h = int(w / aspect)
|
new_h = int(w / aspect)
|
||||||
if new_h > max_h:
|
if new_h > max_h:
|
||||||
new_h = max_h
|
new_h = max_h
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user