[Kst] branches/work/kst/portto4/kst

Barth Netterfield netterfield at astro.utoronto.ca
Tue Jun 9 00:28:47 CEST 2009


SVN commit 979104 by netterfield:

New tab option in curve placement widget.


 M  +0 -4      devel-docs/Kst2Specs/Bugs  
 M  +5 -0      devel-docs/Kst2Specs/FixedBugs  
 M  +0 -5      devel-docs/Kst2Specs/Wishlist  
 M  +3 -0      src/libkstapp/curvedialog.cpp  
 M  +3 -0      src/libkstapp/equationdialog.cpp  
 M  +3 -0      src/libkstapp/histogramdialog.cpp  
 M  +3 -0      src/libkstapp/imagedialog.cpp  
 M  +3 -0      src/libkstapp/powerspectrumdialog.cpp  
 M  +9 -0      src/widgets/curveplacement.cpp  
 M  +1 -1      src/widgets/curveplacement.h  
 M  +2 -2      src/widgets/curveplacement.ui  


--- branches/work/kst/portto4/kst/devel-docs/Kst2Specs/Bugs #979103:979104
@@ -15,10 +15,6 @@
 
 ------------
 
-Image dialog 'smart' range calculations seem to be... odd.
-
-------------
-
 Shared axis zoom usage problem:
 Create a shared axis zoom box with multiple plots in a column.
   -there is no option to indicate or change whether the plots are tied.
--- branches/work/kst/portto4/kst/devel-docs/Kst2Specs/FixedBugs #979103:979104
@@ -731,3 +731,8 @@
 re-narrowed since it believes it is as small as it can get.  (It's the
 list of tabs on the left which is doing the growing.)
 
+----------
+
+Placement widget (eg, in the curve dialog)  needs a create in new tab option.
+  1.x had a 'create new tab' button.  This is similar, but does
+the creation of the new tab after apply, and uses a default name rather than popping up a new dialog.
--- branches/work/kst/portto4/kst/devel-docs/Kst2Specs/Wishlist #979103:979104
@@ -3,12 +3,7 @@
 New Plot Label size mode: autoshrink.
   Add a an option to plot labels: autoshrink.  If selected, the font size used for the axis labels will reduced to the largest size (<= the current size) for which the labels don't overlap or are not truncated (only text width is considered.).  The resizing is dynamic.  If the window geometry or the label values change so that the label would fit at a larger size, the size is raised.
  - Last step after base/offset & reduced ticks.
-----------
 
-Placement widget (eg, in the curve dialog)  needs a create in new tab option.
-  1.x had a 'create new tab' button.  This is similar, but does
-the creation of the new tab after apply, and uses a default name rather than popping up a new dialog.
-
 ---------
 When a new plot is added to an tab which already has plots in it (eg, from the Placement widget), then the label font sizes should be based on the label font sizes of the plots already in the tab.  (either 'vote' or use the first one).
 All font properties replicated.  Use the first one.
--- branches/work/kst/portto4/kst/src/libkstapp/curvedialog.cpp #979103:979104
@@ -408,6 +408,9 @@
       plotItem = static_cast<PlotItem*>(_curveTab->curvePlacement()->existingPlot());
       break;
     }
+  case CurvePlacement::NewPlotNewTab:
+    _document->createView();
+    // fall through to case NewPlot.
   case CurvePlacement::NewPlot:
     {
       CreatePlotForCurve *cmd = new CreatePlotForCurve();
--- branches/work/kst/portto4/kst/src/libkstapp/equationdialog.cpp #979103:979104
@@ -325,6 +325,9 @@
       plotItem = static_cast<PlotItem*>(_equationTab->curvePlacement()->existingPlot());
       break;
     }
+  case CurvePlacement::NewPlotNewTab:
+    _document->createView();
+    // fall through to case NewPlot.
   case CurvePlacement::NewPlot:
     {
       CreatePlotForCurve *cmd = new CreatePlotForCurve();
--- branches/work/kst/portto4/kst/src/libkstapp/histogramdialog.cpp #979103:979104
@@ -391,6 +391,9 @@
       plotItem = static_cast<PlotItem*>(_histogramTab->curvePlacement()->existingPlot());
       break;
     }
+  case CurvePlacement::NewPlotNewTab:
+    _document->createView();
+    // fall through to case NewPlot.
   case CurvePlacement::NewPlot:
     {
       CreatePlotForCurve *cmd = new CreatePlotForCurve();
--- branches/work/kst/portto4/kst/src/libkstapp/imagedialog.cpp #979103:979104
@@ -463,6 +463,9 @@
       plotItem = static_cast<PlotItem*>(_imageTab->curvePlacement()->existingPlot());
       break;
     }
+  case CurvePlacement::NewPlotNewTab:
+    _document->createView();
+    // fall through to case NewPlot.
   case CurvePlacement::NewPlot:
     {
       CreatePlotForCurve *cmd = new CreatePlotForCurve();
--- branches/work/kst/portto4/kst/src/libkstapp/powerspectrumdialog.cpp #979103:979104
@@ -247,6 +247,9 @@
       plotItem = static_cast<PlotItem*>(_powerSpectrumTab->curvePlacement()->existingPlot());
       break;
     }
+  case CurvePlacement::NewPlotNewTab:
+    _document->createView();
+    // fall through to case NewPlot.
   case CurvePlacement::NewPlot:
     {
       CreatePlotForCurve *cmd = new CreatePlotForCurve();
--- branches/work/kst/portto4/kst/src/widgets/curveplacement.cpp #979103:979104
@@ -33,6 +33,10 @@
   _layoutGroup->setEnabled(_newPlot->isChecked());
   _gridColumns->setEnabled(_customGrid->isChecked());
   _gridColumnsLabel->setEnabled(_customGrid->isChecked());
+  _newTab->setEnabled(_newPlot->isChecked());
+  if (!_newPlot->isChecked()) {
+    _newTab->setChecked(false);
+  }
 }
 
 
@@ -41,6 +45,8 @@
     return NoPlot;
   else if (_existingPlot->isChecked())
     return ExistingPlot;
+  else if (_newTab->isChecked())
+    return NewPlotNewTab;
   else
     return NewPlot;
 }
@@ -57,6 +63,9 @@
   case NewPlot:
     _newPlot->setChecked(true);
     break;
+  case NewPlotNewTab:
+    _newPlot->setChecked(true);
+    _newTab->setChecked(true);
   default:
     break;
   }
--- branches/work/kst/portto4/kst/src/widgets/curveplacement.h #979103:979104
@@ -24,7 +24,7 @@
 class KST_EXPORT CurvePlacement : public QWidget, public Ui::CurvePlacement {
   Q_OBJECT
   public:
-    enum Place { NewPlot, ExistingPlot, NoPlot };
+    enum Place { NewPlot, ExistingPlot, NoPlot, NewPlotNewTab };
     enum Layout { Auto, Custom, Protect };
     CurvePlacement(QWidget *parent = 0);
     virtual ~CurvePlacement();
--- branches/work/kst/portto4/kst/src/widgets/curveplacement.ui #979103:979104
@@ -179,9 +179,9 @@
        </widget>
       </item>
       <item row="2" column="2">
-       <widget class="QCheckBox" name="newTab">
+       <widget class="QCheckBox" name="_newTab">
         <property name="text">
-         <string>In new tab</string>
+         <string>In ne&amp;w tab</string>
         </property>
        </widget>
       </item>


More information about the Kst mailing list