1.1 --- a/texteditor.cpp Sat Mar 31 09:28:27 2007 +0000
1.2 +++ b/texteditor.cpp Thu May 17 20:19:03 2007 +0000
1.3 @@ -56,23 +56,23 @@
1.4 setInactive();
1.5
1.6 // Load Settings
1.7 - resize (settings.value ( "/noteeditor/geometry/size", QSize(450,600)).toSize());
1.8 - move (settings.value ( "/noteeditor/geometry/pos", QPoint (250,50)).toPoint());
1.9 + resize (settings.value ( "/satellite/noteeditor/geometry/size", QSize(450,600)).toSize());
1.10 + move (settings.value ( "/satellite/noteeditor/geometry/pos", QPoint (250,50)).toPoint());
1.11
1.12 - if (settings.value ( "/noteeditor/showWithMain",true).toBool())
1.13 - setShowWithMain(true);
1.14 + if (settings.value ( "/satellite/noteeditor/showWithMain",true).toBool())
1.15 + show();
1.16 else
1.17 - setShowWithMain(false);
1.18 + hide();
1.19
1.20 varFont.fromString( settings.value
1.21 - ("/noteeditor/fonts/varFont",
1.22 + ("/satellite/noteeditor/fonts/varFont",
1.23 "Nimbus Sans l,14,-1,5,48,0,0,0,0,0").toString()
1.24 );
1.25 fixedFont.fromString (settings.value(
1.26 - "/noteeditor/fonts/fixedFont",
1.27 + "/satellite/noteeditor/fonts/fixedFont",
1.28 "Courier,14,-1,5,48,0,0,0,1,0").toString()
1.29 );
1.30 - QString s=settings.value ("/noteeditor/fonts/fonthintDefault","variable").toString();
1.31 + QString s=settings.value ("/satellite/noteeditor/fonts/fonthintDefault","variable").toString();
1.32 if (s == "fixed")
1.33 {
1.34 actionSettingsFonthintDefault->setOn (true);
1.35 @@ -85,7 +85,7 @@
1.36 filenameHint="";
1.37
1.38 // Restore position of toolbars
1.39 - restoreState (settings.value("/noteeditor/state",0).toByteArray());
1.40 + restoreState (settings.value("/satellite/noteeditor/state",0).toByteArray());
1.41
1.42 // Save settings in vymrc
1.43 settings.setValue("/mainwindow/printerName",printer->printerName());
1.44 @@ -96,20 +96,20 @@
1.45 {
1.46 if (printer) delete printer;
1.47 // Save Settings
1.48 - settings.setValue( "/noteeditor/geometry/size", size() );
1.49 - settings.setValue( "/noteeditor/geometry/pos", pos() );
1.50 - settings.setValue ("/noteeditor/state",saveState(0));
1.51 + settings.setValue( "/satellite/noteeditor/geometry/size", size() );
1.52 + settings.setValue( "/satellite/noteeditor/geometry/pos", pos() );
1.53 + settings.setValue ("/satellite/noteeditor/state",saveState(0));
1.54
1.55 - settings.setValue( "/noteeditor/showWithMain",showWithMain());
1.56 + settings.setValue( "/satellite/noteeditor/showWithMain",isVisible());
1.57
1.58 QString s;
1.59 if (actionSettingsFonthintDefault->isOn() )
1.60 s="fixed";
1.61 else
1.62 s="variable";
1.63 - settings.setValue( "/noteeditor/fonts/fonthintDefault",s );
1.64 - settings.setValue("/noteeditor/fonts/varFont", varFont.toString() );
1.65 - settings.setValue("/noteeditor/fonts/fixedFont", fixedFont.toString() );
1.66 + settings.setValue( "/satellite/noteeditor/fonts/fonthintDefault",s );
1.67 + settings.setValue("/satellite/noteeditor/fonts/varFont", varFont.toString() );
1.68 + settings.setValue("/satellite/noteeditor/fonts/fixedFont", fixedFont.toString() );
1.69
1.70
1.71 }
1.72 @@ -122,16 +122,6 @@
1.73 return true;
1.74 }
1.75
1.76 -void TextEditor::setShowWithMain(bool v)
1.77 -{
1.78 - showwithmain=v;
1.79 -}
1.80 -
1.81 -bool TextEditor::showWithMain()
1.82 -{
1.83 - return showwithmain;
1.84 -}
1.85 -
1.86 void TextEditor::setFontHint (const QString &fh)
1.87 {
1.88 if (fh=="fixed")
1.89 @@ -499,7 +489,7 @@
1.90 void TextEditor::closeEvent( QCloseEvent* ce )
1.91 {
1.92 ce->accept(); // TextEditor can be reopened with show()
1.93 - showwithmain=false;
1.94 + hide();
1.95 emit (windowClosed() );
1.96 return;
1.97 }