Mercurial > hg > octave-nkf
diff libgui/src/settings-dialog.cc @ 16379:4bb1b82076e5
gui: provide defaults for all values read from the settings file
* files-dockwidget.cc(notice_settings): provide default values for settings
* file-editor-tab.cc(update_lexer,notice_settings): default font is Courier New
instead of Courier
* main-window.cc(notice_settings): provide defaults for terminal font and cursor
* main-window.cc(construct): new default window geometry and widget placement
* resource-manager.cc(do_update_network_settings): default for port setting
* settings-dialog.cc(constructor): provide default values for settings
author | Torsten <ttl@justmail.de> |
---|---|
date | Wed, 27 Mar 2013 19:52:26 +0100 |
parents | 22ab4fe661d7 |
children | 7fa90eb41240 |
line wrap: on
line diff
--- a/libgui/src/settings-dialog.cc +++ b/libgui/src/settings-dialog.cc @@ -66,28 +66,28 @@ ui->general_icon_graphic-> setChecked (widget_icon_set == "GRAPHIC"); ui->general_icon_letter-> setChecked (widget_icon_set == "LETTER"); - ui->useCustomFileEditor->setChecked (settings->value ("useCustomFileEditor").toBool ()); + ui->useCustomFileEditor->setChecked (settings->value ("useCustomFileEditor",false).toBool ()); ui->customFileEditor->setText (settings->value ("customFileEditor").toString ()); ui->editor_showLineNumbers->setChecked (settings->value ("editor/showLineNumbers",true).toBool () ); ui->editor_highlightCurrentLine->setChecked (settings->value ("editor/highlightCurrentLine",true).toBool () ); ui->editor_codeCompletion->setChecked (settings->value ("editor/codeCompletion",true).toBool () ); - ui->editor_fontName->setCurrentFont (QFont (settings->value ("editor/fontName","Courier").toString()) ); + ui->editor_fontName->setCurrentFont (QFont (settings->value ("editor/fontName","Courier New").toString()) ); ui->editor_fontSize->setValue (settings->value ("editor/fontSize",10).toInt ()); ui->editor_longWindowTitle->setChecked (settings->value ("editor/longWindowTitle",false).toBool ()); ui->editor_restoreSession->setChecked (settings->value ("editor/restoreSession",true).toBool ()); - ui->terminal_fontName->setCurrentFont (QFont (settings->value ("terminal/fontName","Courier").toString()) ); + ui->terminal_fontName->setCurrentFont (QFont (settings->value ("terminal/fontName","Courier New").toString()) ); ui->terminal_fontSize->setValue (settings->value ("terminal/fontSize",10).toInt ()); - ui->showFilenames->setChecked (settings->value ("showFilenames").toBool()); - ui->showFileSize->setChecked (settings->value ("showFileSize").toBool()); - ui->showFileType->setChecked (settings->value ("showFileType").toBool()); - ui->showLastModified->setChecked (settings->value ("showLastModified").toBool()); - ui->showHiddenFiles->setChecked (settings->value ("showHiddenFiles").toBool()); - ui->useAlternatingRowColors->setChecked (settings->value ("useAlternatingRowColors").toBool()); - ui->useProxyServer->setChecked (settings->value ("useProxyServer").toBool ()); + ui->showFilenames->setChecked (settings->value ("showFilenames",true).toBool()); + ui->showFileSize->setChecked (settings->value ("showFileSize",false).toBool()); + ui->showFileType->setChecked (settings->value ("showFileType",false).toBool()); + ui->showLastModified->setChecked (settings->value ("showLastModified",false).toBool()); + ui->showHiddenFiles->setChecked (settings->value ("showHiddenFiles",false).toBool()); + ui->useAlternatingRowColors->setChecked (settings->value ("useAlternatingRowColors",true).toBool()); + ui->useProxyServer->setChecked (settings->value ("useProxyServer",false).toBool ()); ui->proxyHostName->setText (settings->value ("proxyHostName").toString ()); - ui->terminal_cursorBlinking->setChecked (settings->value ("terminal/cursorBlinking").toBool ()); + ui->terminal_cursorBlinking->setChecked (settings->value ("terminal/cursorBlinking",true).toBool ()); - QString cursorType = settings->value ("terminal/cursorType").toString (); + QString cursorType = settings->value ("terminal/cursorType","ibeam").toString (); QStringList items; items << QString("0") << QString("1") << QString("2");