Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2014-04

Retina Font Rendering not working anymore in Lazarus Trunk

5 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Michael Ring

I realized a few weeks ago that fonts inside of lazarus started to look ugly again on my Macbook Pro Retina, it seems that even though the App has the retina flag set the fonts are rendered in 1920x1080 (My screen resolution) and do not look smooth anymore.

Any ideas?

Michael

Reply by email

Joost van der Sluis
to Michael Ring
Michael Ring wrote
I realized a few weeks ago that fonts inside of lazarus started to look ugly again on my Macbook Pro Retina, it seems that even though the App has the retina flag set the fonts are rendered in 1920x1080 (My screen resolution) and do not look smooth anymore.

But it did work in the past? Maybe you can confirm that by re-installing an older version again.

And if no-one here answers, the best thing to do is to open a bug-report. So that this will not be forgotten.

Joost.

Reply by email

Michael Ring
to Joost van der Sluis

Yes, it worked like a charm, super crisp fonts, now the fonts look pretty ugly, they are still anti-aliased but resolution is not as high as before.

Will create a bug for this, thank you for your answer.

Michael

Joost van der Sluis wrote 21 lines
On 09/04/14 10:00, Michael Ring wrote: > I realized a few weeks ago that fonts inside of lazarus started to look > ugly again on my Macbook Pro Retina, it seems that even though the App > has the retina flag set the fonts are rendered in 1920x1080 (My screen > resolution) and do not look smooth anymore. But it did work in the past? Maybe you can confirm that by re-installing an older version again. And if no-one here answers, the best thing to do is to open a bug-report. So that this will not be forgotten. Joost. -- _______________________________________________ Lazarus mailing list http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply by email

Michael Ring
to Michael Ring

Long time since last post but I finally managed to get retina support to work again.

I am not sure if Apple has dropped support for retina rendering in carbon apps or if something inside of lazarus changed, right now there are two paths to get super crisp fonts back:

Install qt4 and qt4pas, then recompile lazarus from svn trunk:

make clean all CPU_TARGET=x86_64 LCL_PLATFORM=qt
sudo rm -rf /usr/local/share/lazarus
sudo make install CPU_TARGET=x86_64 LCL_PLATFORM=qt

and perhaps:

lazbuild --build-ide= --ws=qt --cpu=x86_64 --compiler=ppcx64

other way is to recompile lazarus with LCL_PLATFORM=cocoa, but unfortunately cocoa is not really usable at the moment, lots of crashes, but better than the last time I checked.

it is necessary to compile in x86_64 because the packages provided by qt only seem to include the x86_64 version of qt.

compiling for x86_64 works nearly perfect now, I needed to comment out one function that does not seem to exist on x86_64:

Index: lcl/include/sysenvapis_mac.inc
===================================================================
--- lcl/include/sysenvapis_mac.inc    (revision 45676)
+++ lcl/include/sysenvapis_mac.inc    (working copy)
@@ -11,7 +11,7 @@
    url := CFURLCreateWithBytes(nil, @AURL[1], Length(AURL),
kCFStringEncodingUTF8, nil);
    if not Assigned(url) then
      Exit(False);
-  Result := LSOpenCFURLRef(url, nil) = 0;
+//  Result := LSOpenCFURLRef(url, nil) = 0;
    CFRelease(url);
  end;

I am testing now for stability issues, so far no major problems (but I am only using a small part of lazarus)

Michael Ring wrote 38 lines
Yes, it worked like a charm, super crisp fonts, now the fonts look pretty ugly, they are still anti-aliased but resolution is not as high as before. Will create a bug for this, thank you for your answer. Michael Am 17.04.14 17:23, schrieb Joost van der Sluis: > On 09/04/14 10:00, Michael Ring wrote: >> I realized a few weeks ago that fonts inside of lazarus started to look >> ugly again on my Macbook Pro Retina, it seems that even though the App >> has the retina flag set the fonts are rendered in 1920x1080 (My screen >> resolution) and do not look smooth anymore. > > But it did work in the past? Maybe you can confirm that by > re-installing an older version again. > > And if no-one here answers, the best thing to do is to open a > bug-report. So that this will not be forgotten. > > Joost. > > > -- > _______________________________________________ > Lazarus mailing list > > http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus > -- _______________________________________________ Lazarus mailing list http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply by email

zeljko
to Michael Ring
Michael Ring wrote 43 lines
Long time since last post but I finally managed to get retina support to work again. I am not sure if Apple has dropped support for retina rendering in carbon apps or if something inside of lazarus changed, right now there are two paths to get super crisp fonts back: Install qt4 and qt4pas, then recompile lazarus from svn trunk: make clean all CPU_TARGET=x86_64 LCL_PLATFORM=qt sudo rm -rf /usr/local/share/lazarus sudo make install CPU_TARGET=x86_64 LCL_PLATFORM=qt and perhaps: lazbuild --build-ide= --ws=qt --cpu=x86_64 --compiler=ppcx64 other way is to recompile lazarus with LCL_PLATFORM=cocoa, but unfortunately cocoa is not really usable at the moment, lots of crashes, but better than the last time I checked. it is necessary to compile in x86_64 because the packages provided by qt only seem to include the x86_64 version of qt. compiling for x86_64 works nearly perfect now, I needed to comment out one function that does not seem to exist on x86_64: Index: lcl/include/sysenvapis_mac.inc =================================================================== --- lcl/include/sysenvapis_mac.inc (revision 45676) +++ lcl/include/sysenvapis_mac.inc (working copy) @@ -11,7 +11,7 @@ url := CFURLCreateWithBytes(nil, @AURL[1], Length(AURL), kCFStringEncodingUTF8, nil); if not Assigned(url) then Exit(False); - Result := LSOpenCFURLRef(url, nil) = 0; +// Result := LSOpenCFURLRef(url, nil) = 0; CFRelease(url); end; I am testing now for stability issues, so far no major problems (but I am only using a small part of lazarus)

That's not only problem with qt-cocoa. Another problem is that sometimes mouse hangs (no respond to clicks) after modal from modal form is opened and closed. I suspect qt internal implementation
(qapplication_enter_modal_sys (or similar name)) where private variable is used to check mouse down/up.

zeljko

Reply by email