Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
Widgetset
»
QT
»
Scaling the QT 5 application
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
Forum Rules
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
Help needed compiling
by
broutelichen
[
Today
at 01:49:45 pm]
Status of FPC 3.4.0 or FP...
by
creaothceann
[
Today
at 01:40:21 pm]
ThorVG - test (lightweigh...
by
Zvoni
[
Today
at 01:29:05 pm]
Debian removes FPC/Lazaru...
by
kupferstecher
[
Today
at 11:46:26 am]
Problems in drawing an ar...
by
simsee
[
Today
at 11:34:26 am]
Select rectangle of the i...
by
backprop
[
Today
at 11:20:42 am]
[ANN] fpGUI Toolkit v2.0....
by
Roland57
[
Today
at 11:14:36 am]
The Future of FPC
by
n7800
[
Today
at 11:10:42 am]
Form designer on MAC: Des...
by
tk
[
Today
at 11:07:28 am]
Reverting to Old AnchorDo...
by
CM630
[
Today
at 10:27:21 am]
makefiles
by
Key-Real
[
Today
at 10:04:55 am]
fpGUI Toolkit v2.0.1 has ...
by
PierceNg
[
Today
at 09:13:32 am]
[SOLVED] Sort DBGrid
by
Zvoni
[
Today
at 08:28:39 am]
DCPcrypt v2.0.6 — Cryptog...
by
Okoba
[
Today
at 07:47:36 am]
Old problem returns...
by
Lutz Mändle
[
Today
at 06:56:53 am]
Fixing Lazarus 4.4 IDE la...
by
dbannon
[
Today
at 05:52:05 am]
Strange Error in My Code ...
by
TYDQ
[
Today
at 01:17:35 am]
Fpcupdeluxe
by
creaothceann
[
Today
at 12:09:07 am]
; after then
by
440bx
[February 11, 2026, 10:29:20 pm]
Lazarus for Windows on aa...
by
Wallaby
[February 11, 2026, 10:21:41 pm]
Fast Canvas Library V1.05...
by
backprop
[February 11, 2026, 08:15:33 pm]
TRichMemo EM_FORMATRANGE ...
by
rvk
[February 11, 2026, 07:54:30 pm]
[SOLVED] Lazarus recompil...
by
Hartmut
[February 11, 2026, 06:00:38 pm]
Defining TDBDropDownCombo...
by
1HuntnMan
[February 11, 2026, 04:12:04 pm]
Rolling releases Lazarus[...
by
ALLIGATOR
[February 11, 2026, 03:28:46 pm]
« previous
next »
Print
Pages: [
1
]
Author
Topic: Scaling the QT 5 application (Read 796 times)
7bit
New Member
Posts: 24
Scaling the QT 5 application
«
on:
September 17, 2025, 09:27:46 pm »
My application does not scale when I change the scale of the desktop environment. When I launch my application, the interface does not scale. Although Lazarus IDE with QT5 scales. Everything is working fine in Windows. Maybe something needs to be turned on?
Logged
zeljko
Hero Member
Posts: 1830
Re: Scaling the QT 5 application
«
Reply #1 on:
September 17, 2025, 09:47:38 pm »
Have you turned on scaling in your project options (in that case you'll have Application.Scaled := True in your .lpr file), or just add manually APplication.Scaled := True in your .lpr, before Application.initialize.
Logged
7bit
New Member
Posts: 24
Re: Scaling the QT 5 application
«
Reply #2 on:
September 18, 2025, 06:06:07 am »
Yes. I'm creating a simple QT5 application and it also doesn't scale. I was wrong about Lazarus. It doesn't scale either. This GTK2 build scales, but QT5 does not.
My IDE: Lazarus 4.3 (rev lazarus_4_2-26-g44b59001af) FPC 3.2.3 x86_64-linux-qt5
OS: Alt Workstation 10.4 (Mate Desktop)
Logged
zeljko
Hero Member
Posts: 1830
Re: Scaling the QT 5 application
«
Reply #3 on:
September 18, 2025, 08:06:14 am »
Qt5 > 5.14 and Qt 6 changed how they use scaling. DPI is not relevant anymore but only scale eg 1.5, 2.0 etc. So to test if it'll work for you try this from terminal: export QT_FONT_DPI=96 export QT_SCALE_FACTOR=1.5 ./yourqt5application .
Logged
7bit
New Member
Posts: 24
Re: Scaling the QT 5 application
«
Reply #4 on:
September 18, 2025, 01:18:32 pm »
Thanks! It works. It's just not very nice; the app just scales down the low-resolution icons. When I set QT_FONT_DPI=144 and removed QT_SCALE_FACTOR, the app started using higher-resolution icons. I liked the result.
Logged
zeljko
Hero Member
Posts: 1830
Re: Scaling the QT 5 application
«
Reply #5 on:
September 18, 2025, 03:34:51 pm »
It is pretty messy with scaling qt5 and qt6 nowadays (in LCL perspective). Note that under KDE Plasma 5 I don't have to export anything for qt5 widgetset, but must for qt6. On KDE Plasma 6 is viceversa
Logged
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
Widgetset
»
QT
»
Scaling the QT 5 application
TinyPortal
© 2005-2018