Commit ec7758b8 authored by Marjorie Hahn's avatar Marjorie Hahn
Browse files

Applied font style and font size from IsisPreferences to GUI applications. Fixes #198.

git-svn-id: http://subversion.wr.usgs.gov/repos/prog/isis3/trunk@7706 41f8697f-d340-4b68-9986-7bafba869bb8
parent 7bb5a43d
Loading
Loading
Loading
Loading
+16 −0
Original line number Diff line number Diff line
@@ -8,6 +8,7 @@
#include <QApplication>
#include <QCoreApplication>
#include <QDesktopWidget>
#include <QFont>
#include <QFrame>
#include <QIcon>
#include <QLineEdit>
@@ -93,6 +94,21 @@ namespace Isis {
      QString style = uiPref["GuiStyle"];
      QApplication::setStyle(style);
    }
    
    
    if (uiPref.hasKeyword("GuiFontName")) {
      QString fontString = uiPref["GuiFontName"];
      QFont font = QFont(fontString);
      
      if (uiPref.hasKeyword("GuiFontSize")) {
        int pointSize = uiPref["GuiFontSize"];
        font.setPointSize(pointSize);
      }
      
      QApplication::setFont(font);
    }
    
    
    // Create the main window
    p_gui = new Gui(ui);
    p_gui->show();
+2 −0
Original line number Diff line number Diff line
@@ -83,6 +83,8 @@ namespace Isis {
   *                         instantiated. Fixes #3908.
   *  @history 2017-05-16 Cole Neubauer - Fixed Title not showing in Putty/Xming
   *                         setup. Fixes #4731.
   *  @history 2017-05-19 Marjorie Hahn - Applied font style and font size from the 
   *                         IsisPreferences file. Fixes #198.
   */

  class Gui : public QMainWindow {