[Lazarus] New high DPI features in 1.7

Ondrej Pokorny lazarus at kluug.net
Fri Dec 9 12:41:37 CET 2016


On 09.12.2016 12:38, Erwin van den Bosch via Lazarus wrote:
> Op 9-12-2016 om 12:18 schreef Ondrej Pokorny via Lazarus:
>> On 09.12.2016 11:52, Erwin van den Bosch via Lazarus wrote:
>>> Thanks for the good work Ondrej! A big step forward. I will test it 
>>> in the next few days and hopefully can give some feedback.
>>>
>>> Although this is a step forward I think working with pixels is 
>>> something from the past as with the Sinclair ZX81 (where you have 
>>> 64x48 pixels) or Commodore 64.  (320x200px!) :-) But today's 
>>> computers still thinking in pixels not in size. And working with 
>>> just pixels might work if our screens will always be 1024x768 pixels 
>>> with size of 15".
>>
>> If you want pixel perfect drawing, you have to use pixels :(
>>
>> Ondrej
>
> When you introduce DPI of a screen and scaling you lost the pixel 
> perfect drawing too. :(

No :)

> Example: scaling from 96 to 120 dpi = x 1.25
> So 7 px * 1.25 = 8.75 = 9
>     21 px * 1.25 = 26.25 = 26
>     22 px * 1.25 = 27.5 = 28
> How to get pixel 27?

Easily - use pixel value 27 after scaling.

Ondrej


More information about the Lazarus mailing list