[Kst] kdeextragear-2/kst/kst

George Staikos staikos at kde.org
Tue Jan 11 21:33:42 CET 2005


CVS commit by staikos: 

bye bye kstprintrc.  Settings are lost because I don't see a simple way to
migrate them with kconf_update, and they're not really important anyway.  Now
stored in kstrc [Printing]


  M +8 -8      kst.cpp   1.277


--- kdeextragear-2/kst/kst/kst.cpp  #1.276:1.277
@@ -1098,7 +1098,8 @@ void KstApp::slotFilePrint() {
 
   if (pages > 0) {
-    KConfig cfg("kstprintrc");
+    KConfig cfg("kstrc", false, false); // FIXME: move to KstSettings
     KPrinter printer;
 
+    cfg.setGroup("Printing");
     printer.setOption("kde-pagesize", cfg.readEntry("kde-pagesize", QString::number((int)KPrinter::Letter)));
     printer.setOption("kde-orientation", cfg.readEntry("kde-orientation", "Landscape"));
@@ -1113,5 +1114,4 @@ void KstApp::slotFilePrint() {
     printer.addDialogPage(new KstPrintOptionsPage);
     if (printer.setup(this, i18n("Print"))) {
-      KConfig cfgsave("kstprintrc", false, false);
       QPainter paint(&printer);
       QPaintDeviceMetrics metrics(&printer);
@@ -1126,10 +1126,10 @@ void KstApp::slotFilePrint() {
       slotUpdateStatusMsg(i18n("Printing..."));
 
-      cfgsave.writeEntry("kde-pagesize", printer.option("kde-pagesize"));
-      cfgsave.writeEntry("kde-orientation", printer.option("kde-orientation"));
-      cfgsave.writeEntry("kst-plot-datetime-footer", printer.option("kst-plot-datetime-footer"));
-      cfgsave.writeEntry("kst-plot-maintain-aspect-ratio", printer.option("kst-plot-maintain-aspect-ratio"));
-      cfgsave.writeEntry("kst-plot-curve-width-adjust", printer.option("kst-plot-curve-width-adjust"));
-      cfgsave.writeEntry("kst-plot-monochrome", printer.option("kst-plot-monochrome"));
+      cfg.writeEntry("kde-pagesize", printer.option("kde-pagesize"));
+      cfg.writeEntry("kde-orientation", printer.option("kde-orientation"));
+      cfg.writeEntry("kst-plot-datetime-footer", printer.option("kst-plot-datetime-footer"));
+      cfg.writeEntry("kst-plot-maintain-aspect-ratio", printer.option("kst-plot-maintain-aspect-ratio"));
+      cfg.writeEntry("kst-plot-curve-width-adjust", printer.option("kst-plot-curve-width-adjust"));
+      cfg.writeEntry("kst-plot-monochrome", printer.option("kst-plot-monochrome"));
 
       it = createIterator();




More information about the Kst mailing list