Compare commits
3 Commits
1376b4667e
...
cf97a70b2c
| Author | SHA1 | Date |
|---|---|---|
|
|
cf97a70b2c | |
|
|
a603f321b1 | |
|
|
da2cefa0a9 |
|
|
@ -103,4 +103,3 @@ ENV/
|
||||||
# mypy
|
# mypy
|
||||||
.mypy_cache/
|
.mypy_cache/
|
||||||
.vscode/settings.json
|
.vscode/settings.json
|
||||||
**/.DS_Store
|
|
||||||
|
|
|
||||||
|
|
@ -179,7 +179,6 @@ class CompleterView(QTreeView):
|
||||||
self.set_font_size(_font.px_size)
|
self.set_font_size(_font.px_size)
|
||||||
self.setIndentation(_font.px_size)
|
self.setIndentation(_font.px_size)
|
||||||
self.setFont(_font.font)
|
self.setFont(_font.font)
|
||||||
# tell Qt our size hint changed so it recalculates layout
|
|
||||||
self.updateGeometry()
|
self.updateGeometry()
|
||||||
|
|
||||||
def resize_to_results(
|
def resize_to_results(
|
||||||
|
|
@ -659,7 +658,6 @@ class SearchWidget(QtWidgets.QWidget):
|
||||||
if hasattr(self.view, 'update_fonts'):
|
if hasattr(self.view, 'update_fonts'):
|
||||||
self.view.update_fonts()
|
self.view.update_fonts()
|
||||||
|
|
||||||
# tell Qt our size hint changed so it recalculates layout
|
|
||||||
self.updateGeometry()
|
self.updateGeometry()
|
||||||
|
|
||||||
def focus(self) -> None:
|
def focus(self) -> None:
|
||||||
|
|
|
||||||
|
|
@ -191,17 +191,11 @@ class DpiAwareFont:
|
||||||
# apply zoom level multiplier
|
# apply zoom level multiplier
|
||||||
font_size = int(font_size * zoom_level)
|
font_size = int(font_size * zoom_level)
|
||||||
|
|
||||||
ftype: str = f'{type(self)!r}'
|
log.debug(
|
||||||
log.info(
|
f"screen:{screen.name()}\n"
|
||||||
f'screen: {screen.name()}\n'
|
f"pDPI: {pdpi}, lDPI: {ldpi}, scale: {scale}\n"
|
||||||
f'pDPI: {pdpi!r}\n'
|
f"zoom_level: {zoom_level}\n"
|
||||||
f'lDPI: {ldpi!r}\n'
|
f"\nOur best guess font size is {font_size}\n"
|
||||||
f'scale: {scale!r}\n'
|
|
||||||
f'{ftype}._font_inches={self._font_inches!r}\n'
|
|
||||||
f'zoom_level: {zoom_level!r}\n'
|
|
||||||
f'\n'
|
|
||||||
f"Our best guess for an auto-font-size is,\n"
|
|
||||||
f'font_size: {font_size!r}\n'
|
|
||||||
)
|
)
|
||||||
# apply the size
|
# apply the size
|
||||||
self._set_qfont_px_size(font_size)
|
self._set_qfont_px_size(font_size)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue