Bug introduced in 10.4 or earlier and persisting through v11.3 (misleading documentation inconsistency)
According to the documentation it is a basic unit for size spec. WindowSize
and ImageSize
says:
I think the reasoning below proves that documentation is not correct in this fundamental matter:
Assuming PP is this the same what Wikipedia calls Point(in typography)?
Assuming: PP is this the same what
dot
fromdpi - dots per inch
isThe relation between pixel and PP is:
(1.) ==>
1 pp = 1/72inch
that and (2.) ==> relation 'pp:px' is
1:1
only for72 dpi
screensI have
96 dpi
screen (according to facts and to what MMA saysLast /@ CurrentValue[$FrontEnd, {"ScreenInformation"}]
)with
2560 x 1440
resolution thenCreateDocument[{}, WindowSize -> {2560, 200}]
should not have full screen width? Right? It could have had if I had 72dpi screen.
Worth to mention that for fonts MMA by default assumes you have 72 dpi
screen: Fontsize is too small. Is that the case for everything else too?
That would be a very logical explanation (disappointing though), my tests are confirming that:
Framed[Grid[{{
"This Framed is 30pp tall:"
Framed[{}, ImageMargins -> 0, ImageSize -> {Automatic, 30}],
#
}},
Alignment -> {Left, Center}, Spacings -> {0, 0}
], FrameMargins -> 0] & /@ {
Style["Öj - 30pp font and default assumed 72dpi", FontSize -> 30],
Style["Öj - 30pp font and automatic dpi ", FontSize -> 30,
FontProperties -> {"ScreenResolution" -> Automatic}]
} // Column
So the first line shows that ImageSize and FontSize are consistent. And since font is ignoring your dpi then ImageSize is consistent in ignoring ;-).
This is a mess. What can I do? Changing global Magnification
is not an option because your user get used to default font sizes in Input/Output etc, yet I want to display well sized Labels and Grids in GUI. Moreover, WindowSize
will not be affected by Magnification
.
For fonts I can define styles with FontProperties -> {"ScreenResolution" -> Automatic}
inside but how can I establish a proper interpretation of ImageSize
and friends?
Do I have to CurrentValue["ScreenResolution"][[1]] / 72
prefix everywhere? :D
Related topics:
AbsoluteThickness
and other commands use this unit, and it is already supported in SVG/CSS. $\endgroup$