Skip to content

Commit d2b5fd4

Browse files
authored
Merge pull request #159 from SCIInstitute/fix_for_240
Fix for 2.4.0
2 parents 5d6e13a + 89ae472 commit d2b5fd4

File tree

6 files changed

+19
-15
lines changed

6 files changed

+19
-15
lines changed

src/CMake/Modules/MacOSXBundleInfo.plist.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
<key>NSHumanReadableCopyright</key>
3434
<string>${MACOSX_BUNDLE_COPYRIGHT}</string>
3535
<key>NSHighResolutionCapable</key>
36-
<true/>
36+
<false/>
3737
<key>CFBundleDocumentTypes</key>
3838
<array>
3939
<dict>

src/Core/TextRenderer/TextRenderer.cc

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -72,13 +72,21 @@ TextRenderer::TextRenderer() :
7272

7373
if (! boost::filesystem::exists(font_path) )
7474
{
75-
// TODO: would it make sense to throw an exception here?
76-
// object will be incompletely constructed if font path cannot be found
77-
//
78-
// alternatively, configure location of font path on program startup, so this check
79-
// does not have to be run every time the object is constructed? (AYK)
80-
CORE_LOG_ERROR( "Unable to locate FreeSerif.ttf in /usr/share/fonts/truetype/freefont or /usr/share/fonts/truetype." );
81-
return;
75+
76+
// alternative path to freefont paths on some other linux distros (CentOS for example)
77+
font_path = "/usr/share/fonts/gnu-free/FreeSerif.ttf";
78+
79+
if (! boost::filesystem::exists(font_path) )
80+
{
81+
82+
// TODO: would it make sense to throw an exception here?
83+
// object will be incompletely constructed if font path cannot be found
84+
//
85+
// alternatively, configure location of font path on program startup, so this check
86+
// does not have to be run every time the object is constructed? (AYK)
87+
CORE_LOG_ERROR( "Unable to locate FreeSerif.ttf in /usr/share/fonts/truetype/freefont or /usr/share/fonts/truetype or /usr/share/fonts/gnu-free." );
88+
return;
89+
}
8290
}
8391
}
8492
this->font_file_.assign( font_path );

src/Interface/Application/GroupButtonMenu.cc

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,8 +237,7 @@ void GroupButtonMenu::prep_for_animation( bool move_time )
237237
if( move_time )
238238
{
239239
this->private_->ui_.facade_->setMinimumSize( this->private_->ui_.group_tools_->size() );
240-
this->private_->ui_.facade_->setPixmap(
241-
QPixmap::grabWidget( this->private_->ui_.group_tools_ ) );
240+
this->private_->ui_.facade_->setPixmap( this->private_->ui_.group_tools_->grab() );
242241
this->private_->ui_.group_tools_->hide();
243242
this->private_->ui_.facade_->show();
244243
}

src/Interface/Application/LayerWidget.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1242,7 +1242,7 @@ void LayerWidget::prep_for_animation( bool move_time )
12421242
if( move_time )
12431243
{
12441244
this->private_->ui_.facade_widget_->setMinimumSize( this->private_->ui_.base_->size() );
1245-
this->private_->ui_.facade_widget_->setPixmap( QPixmap::grabWidget( this ) );
1245+
this->private_->ui_.facade_widget_->setPixmap( this->grab() );
12461246
this->private_->ui_.base_->hide();
12471247
this->private_->ui_.facade_widget_->show();
12481248
}

src/Interface/Application/StyleSheet.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ namespace Seg3D
111111
" border: none;"
112112
"}"
113113
"QDockWidget{"
114+
" background-color: rgb( " BACKGROUND_COLOR ") ;"
114115
" color: rgb( " FONT_COLOR ") ;"
115116
" titlebar-close-icon: url(:/General_Icons/exit.png);"
116117
" titlebar-normal-icon: url(:/General_Icons/maximize.png);"

src/QtUtils/Utils/QtApplication.cc

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,6 @@ class QtWin32ApplicationEventFilter : public QAbstractNativeEventFilter
8080
virtual bool nativeEventFilter(const QByteArray &eventType, void *message, long *) Q_DECL_OVERRIDE
8181
{
8282
#ifdef _WIN32
83-
// test
84-
// should be "windows_generic_MSG" (http://doc.qt.io/qt-5/qwidget.html#nativeEvent)?
85-
std::cerr << "Event type: " << eventType.constData() << std::endl;
86-
// test
8783

8884
MSG* msg = reinterpret_cast< MSG* >( message );
8985
if ( msg->message == WM_ENTERSIZEMOVE )

0 commit comments

Comments
 (0)