@@ -132,7 +132,12 @@ void QgsComposerLegendWidget::on_mTitleFontButton_clicked()
132
132
if ( mLegend )
133
133
{
134
134
bool ok;
135
+ #if defined(Q_WS_MAC) && QT_VERSION >= 0x040500 && !defined(__LP64__)
136
+ // Native Mac dialog works only for 64 bit Cocoa (observed in Qt 4.5.2, probably a Qt bug)
137
+ QFont newFont = QFontDialog::getFont ( &ok, mLegend ->titleFont (), this , QString (), QFontDialog::DontUseNativeDialog );
138
+ #else
135
139
QFont newFont = QFontDialog::getFont ( &ok, mLegend ->titleFont () );
140
+ #endif
136
141
if ( ok )
137
142
{
138
143
mLegend ->setTitleFont ( newFont );
@@ -147,7 +152,12 @@ void QgsComposerLegendWidget::on_mLayerFontButton_clicked()
147
152
if ( mLegend )
148
153
{
149
154
bool ok;
155
+ #if defined(Q_WS_MAC) && QT_VERSION >= 0x040500 && !defined(__LP64__)
156
+ // Native Mac dialog works only for 64 bit Cocoa (observed in Qt 4.5.2, probably a Qt bug)
157
+ QFont newFont = QFontDialog::getFont ( &ok, mLegend ->layerFont (), this , QString (), QFontDialog::DontUseNativeDialog );
158
+ #else
150
159
QFont newFont = QFontDialog::getFont ( &ok, mLegend ->layerFont () );
160
+ #endif
151
161
if ( ok )
152
162
{
153
163
mLegend ->setLayerFont ( newFont );
@@ -162,7 +172,12 @@ void QgsComposerLegendWidget::on_mItemFontButton_clicked()
162
172
if ( mLegend )
163
173
{
164
174
bool ok;
175
+ #if defined(Q_WS_MAC) && QT_VERSION >= 0x040500 && !defined(__LP64__)
176
+ // Native Mac dialog works only for 64 bit Cocoa (observed in Qt 4.5.2, probably a Qt bug)
177
+ QFont newFont = QFontDialog::getFont ( &ok, mLegend ->itemFont (), this , QString (), QFontDialog::DontUseNativeDialog );
178
+ #else
165
179
QFont newFont = QFontDialog::getFont ( &ok, mLegend ->itemFont () );
180
+ #endif
166
181
if ( ok )
167
182
{
168
183
mLegend ->setItemFont ( newFont );
0 commit comments