Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
General
»
How do you get pixels per millimeter in linux?
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
overloading issues fpc3.2...
by
Martin_fr
[
Today
at 04:27:25 pm]
FPC Unleashed (inline var...
by
creaothceann
[
Today
at 04:06:46 pm]
Can I get the position an...
by
CM630
[
Today
at 03:36:42 pm]
Seeking advice on setting...
by
schuler
[
Today
at 03:36:28 pm]
AI assisted translation o...
by
schuler
[
Today
at 03:27:56 pm]
Ann: DeCoperators
by
DomingoGP
[
Today
at 03:23:39 pm]
Error: Compilation raised...
by
marcov
[
Today
at 02:44:06 pm]
Ann: Deinline: a de-inlin...
by
LeP
[
Today
at 02:18:12 pm]
Translate .lfm file in a ...
by
tprud
[
Today
at 12:24:06 pm]
TLazSerial : serial port ...
by
CM630
[
Today
at 09:50:34 am]
I hope FreePascal can sup...
by
xiyi0616
[
Today
at 05:49:05 am]
[Solved] Help needed comp...
by
landolfi
[
Today
at 02:45:10 am]
Delimited text - how find...
by
Remy Lebeau
[
Today
at 02:26:15 am]
DataPort or Synpase stat...
by
eldonfsr
[April 16, 2026, 11:32:18 pm]
[FPC 3.2.4, Windows] PTC ...
by
Fred vS
[April 16, 2026, 08:26:24 pm]
Cannot build Units for Si...
by
NormanDunbar
[April 16, 2026, 07:39:07 pm]
IDE: Property editor does...
by
dsiders
[April 16, 2026, 07:04:22 pm]
What is wrong with this c...
by
OH1KH
[April 16, 2026, 04:32:48 pm]
[work arounded]Naming dae...
by
LeP
[April 16, 2026, 03:36:10 pm]
Lazarus Bugfix Release 4....
by
Jonax
[April 16, 2026, 03:06:25 pm]
CudaText editor (written ...
by
AlexTP
[April 16, 2026, 10:43:12 am]
C header function with on...
by
440bx
[April 16, 2026, 09:13:38 am]
(Solved)TUpDown KeyDown ...
by
LeP
[April 15, 2026, 11:21:09 pm]
Zipper: Addition of mult...
by
marcov
[April 15, 2026, 10:35:15 pm]
GTK3: FillRect() mispaint...
by
baldzhang
[April 15, 2026, 06:32:52 pm]
« previous
next »
Print
Pages: [
1
]
Author
Topic: How do you get pixels per millimeter in linux? (Read 1153 times)
jianwt
Full Member
Posts: 164
How do you get pixels per millimeter in linux?
«
on:
January 16, 2023, 01:24:37 pm »
Google Translate
Novice seeking advice
In windows, you can use GetDeviceCaps(Frm.Canvas.Handle, LOGPIXELSX) * 10/254 to get the pixel width per millimeter.
So how do you get pixels per millimeter in linux?
Logged
wp
Hero Member
Posts: 13487
Re: How do you get pixels per millimeter in linux?
«
Reply #1 on:
January 16, 2023, 01:41:40 pm »
ScreenInfo.PixelsPerInchX and .PixelsPerInchY in unit Graphics, or Screen.PixelsPerInch or Monitor.PixelsPerInch in unit Forms.
Logged
jianwt
Full Member
Posts: 164
Re: How do you get pixels per millimeter in linux?
«
Reply #2 on:
January 16, 2023, 02:22:36 pm »
Thank you very much。
Logged
Thaddy
Hero Member
Posts: 18972
Glad to be alive.
Re: How do you get pixels per millimeter in linux?
«
Reply #3 on:
January 16, 2023, 04:37:36 pm »
pixels per inch are not pixels per millimeter.
Pixels per Centimeter: pixelsperinch/2.54
Pixels per MilliMeter: pixelsperinch/25.4
«
Last Edit: January 16, 2023, 04:41:50 pm by Thaddy
»
Logged
Recovered from removal of tumor in tongue following tongue reconstruction with a part from my leg.
wp
Hero Member
Posts: 13487
Re: How do you get pixels per millimeter in linux?
«
Reply #4 on:
January 16, 2023, 04:45:57 pm »
Thaddy, it is clear from the first post that the OP knows how to convert inches to millimeters.
Logged
wyattwong
Newbie
Posts: 6
Re: How do you get pixels per millimeter in linux?
«
Reply #5 on:
January 16, 2023, 05:48:16 pm »
Thank you
Logged
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
General
»
How do you get pixels per millimeter in linux?
TinyPortal
© 2005-2018