Closed qissue-bot closed 5 years ago
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2009-07-15T07:54:36.000Z
Hmm, works for me. My 1.1.0 build.
I tested with OTF, TTF (flat), [[PostScript]] (resource fork), and dfont fonts. And both activated by placement in standard font folders and by a font manager (Linotype Fontexplorer (free)).
Original Redmine Comment Author Name: John Tull (John Tull) Original Date: 2009-07-15T10:17:11.000Z
It still is not working for me regardless of a cmake or xcode build. I am using qt-4.5.2, so I am thinking it might have something to do with Qt. Which qt are you using?
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2009-07-15T10:36:36.000Z
4.4.something. I've been holding off on 4.5 until I hear more about whether Qgis is supposed to be compatible with 4.5, or just "it should be, but...". So far I'm just hearing about issues like this one.
Are you using the standard version or the Cocoa version?
Original Redmine Comment Author Name: John Tull (John Tull) Original Date: 2009-07-15T10:39:02.000Z
I am using the carbon version. The Cocoa version had different problems that I could not get past with qgis.
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2009-08-04T04:35:45.000Z
Ah, after updating to Qt 4.5(.2), font selection now does not work for me either.
Original Redmine Comment Author Name: John Tull (John Tull) Original Date: 2009-08-04T14:57:18.000Z
Unfortunately, did not fix this problem.
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2009-08-05T05:11:25.000Z
Here's a possibility: the font selection now uses the system font dialog:
QFileDialog
On Mac, native dialogs are now used when calling show, open, or exec on a QFileDialog, QColorDialog, QPrintDialog, or QFontDialog (i.e not only when using the static functions)
Maybe it's returning the font specification in a Mac-specific form that Qgis doesn't understand?
Original Redmine Comment Author Name: Tom Elwertowski (Tom Elwertowski) Original Date: 2009-08-05T16:57:30.000Z
This appears to be a Qt bug. The new native Mac font dialog seems to work (for some fonts) only in 64-bit builds. The workaround is to used the old non-native font dialog for 32-bit builds.
Fixed by commit:2cb06056 (SVN r11281) (workaround).
Original Redmine Comment Author Name: John Tull (John Tull) Original Date: 2009-08-05T18:37:15.000Z
Great work, Tom. This does get around the issue. I agree that it is probably a qt bug, which has been my hunch. I could not find anything about this on their mail lists.
The same problem exists in the map composer. I've attached the two cpp files with the necessary edits. Not sure how to create the patch file.
I was close to finding this workaround today, but gave up. I was unclear on how to call the [[DoNotUseNativeDialog]] option and gave up. Glad to see your still keeping an eye on mac-related issues. I will look into qt-64 bit, although I hit some other problems when I tried that a month or so back that I cannot recall now.
Original Redmine Comment Author Name: Tom Elwertowski (Tom Elwertowski) Original Date: 2009-08-06T07:04:09.000Z
Attached map composer fixes submitted as .
Original Redmine Comment Author Name: Jürgen Fischer (Jürgen Fischer) Original Date: 2009-08-06T09:27:18.000Z
Replying to [comment:9 jctull]:
The same problem exists in the map composer. I've attached the two cpp files with the necessary edits. Not sure how to create the patch file.
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2010-10-12T05:41:24.000Z
Either it wasn't really fixed, or it's back. Reported in #3105. It goes beyond vectors (maybe this originally did, but noone noticed) -- all layout and map composer font selection seems to be affected.
Now with Qgis 1.5, Qt 4.6 Cocoa, both OSX 10.5 and 10.6.
OSX 10.6 64bit: some fonts work, some fonts snap to another when selected and/or don't display the correct font. I don't see any pattern of kinds of fonts (PS, OTF, TT, Mac) or whether they are loaded directly by the system from standard font folders or from a font manager.
OSX 10.5 32bit: same behavior as this original bug - font is selected in the font dialog, but display doesn't change and font snaps back to Lucida Grande. Though it looks like Qt 4.6 Cocoa now forces the Mac font dialog, whether or not the program asks for it (ie from ).
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2010-10-12T06:10:43.000Z
More:
Also happens with trunk, OSX 10.6.
OSX 10.5 PPC Qt 4.6 Carbon: uses Qgis/Qt font dialog and font selection seems to work.
Original Redmine Comment Author Name: CK - (CK -) Original Date: 2011-02-05T20:07:39.000Z
Hi, I had this and other problems after upgrading to Snow Leopard. Problem is now solved following a 'clean install' of SL. CK
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2011-02-06T07:41:37.000Z
Reinstalling the system is too general, and I've tried it on a clean system.
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2011-02-06T09:12:00.000Z
I've been meaning to poke at this, so here's some more test results. I changed the dialog code to force non-native for all Cocoa Qt, then tried some fonts.
At any time, when a font manager is used (the pro kind that enables fonts in-place instead of copying to standard font folders), Qt ignores the [[DontUseNativeDialog]] flag and shows the native font dialog, with all its problems. Otherwise,
Initially, the Qt font dialog is shown. Font selections don't snap back to other fonts, BUT some fonts still don't work, ie they display as Helvetica.
Once a font is selected and OK'd (back to the map display, but not back to the labeling dialog), one of two things may happen the next time the font dialog is shown:
If the font selected previously was a working font, the Qt font dialog is shown again,
If the font selected previously was not working (displays as Helvetica), the native Mac font dialog is shown.
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2011-02-27T08:08:03.000Z
Looking into this some more, checking things I should have... There is a Qt bug for 4.6.3 for the problem where it sometimes ignores [[DontUseNativeDialog]]. Fixed in 4.7.1.
A couple hits for the selection issue in native dialogs.
One Qt bug seems to be similar, but it's only fixed for Qt 4.8.
Another suggests that if the initial font specified in getFont() is invalid, the dialog always returns the default font, which was the original problem of this Qgis bug report.
I guess I need to look at Qt 4.7 again, I had other issues with that but forgot to write anything down.
Original Redmine Comment Author Name: John Tull (John Tull) Original Date: 2011-03-02T12:20:12.000Z
This problem persists on OS X. - bug update for 1.7 release
Original Redmine Comment Author Name: William Kyngesburye (William Kyngesburye) Original Date: 2011-03-03T09:43:19.000Z
Verified that the [[DontUseNativeDialog]] Qt bug is fixed in 4.7.1, so Qgis can force the Qt font dialog starting with Qt 4.7.1. commit:e4389418 (SVN r15324) forces the Qt font dialog for Qt Cocoa. With Qt 4.5-4.6 it will try, though generally fail, to do so, but that's all it can do.
Font selection is still problematic, though it's also probably a Qt bug. But I think I now have the pattern for what fonts can't be used. Although all fonts can be selected in the Qt font dialog, some display with the default font (ie Helvetica). These include all non-roman OTF fonts, like CJK and symbol fonts. some examples:
CJK/symbol fonts that work because they're TT or PS fonts:
Closing as fixed, though it's only fixed as far as it can be within QGIS (dialog only for Qt 4.7.1+, font display works within limits).
Author Name: John Tull (John Tull) Original Redmine Issue: 1752, https://issues.qgis.org/issues/1752
Original Assignee: Tom Elwertowski
When changing the font settings for labels in the properties dialog for a vector layer, the font selector is brought up but changes to the fonts make no effect on the label display. Looking at the qgs file, the fonts stay on their default of Lucinda Grande 12.