Bug 110732 - Clicking on x-axis numbers brings you to the y-axis settings tab
Summary: Clicking on x-axis numbers brings you to the y-axis settings tab
Status: RESOLVED FIXED
Alias: None
Product: kst
Classification: Applications
Component: general (show other bugs)
Version: 1.x
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: kst
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-14 00:01 UTC by Matthew Truch
Modified: 2005-08-15 19:09 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Matthew Truch 2005-08-14 00:01:22 UTC
Version:           1.2.0_devel (using KDE KDE 3.4.0)
OS:                Linux

Clicking on the x-axis numbers incorrectly takes you to the y-axis settings tab.  Instead, it should bring you to the x-axis settings tab.
Comment 1 Andrew Walker 2005-08-15 19:09:04 UTC
SVN commit 449469 by arwalker:

BUG:110732 Set page correctly when displaying plot edit dialog resulting from the user clicking somewhere on a plot.

 M  +9 -3      kst2dplot.cpp  
 M  +6 -6      kstplotdialog_i.h  


--- trunk/extragear/graphics/kst/kst/kst2dplot.cpp #449468:449469
@@ -4289,13 +4289,19 @@
     } else if (plot_and_axis_rect.contains(e->pos())) {
       if (_draggableLabel == -1) {
         ParentApp->plotDialog()->show_I(static_cast<KstViewWidget*>(view)->viewObject()->tagName(), tagName());
-        ParentApp->plotDialog()->TabWidget->setCurrentPage(LIMITS_TAB);
+        if (e->pos().y() > plot_rect.bottom() && e->pos().x() < plot_rect.left()) { 
+          ParentApp->plotDialog()->TabWidget->setCurrentPage(RANGE_TAB);
+        } else if (e->pos().y() > plot_rect.bottom()) {
+          ParentApp->plotDialog()->TabWidget->setCurrentPage(X_AXIS_TAB);
+        } else {
+          ParentApp->plotDialog()->TabWidget->setCurrentPage(Y_AXIS_TAB);
+        }
       }
       return;
     } else if (win_rect.contains(e->pos())) {
       if (_draggableLabel == -1) {
         ParentApp->plotDialog()->show_I(static_cast<KstViewWidget*>(view)->viewObject()->tagName(), tagName());
-        ParentApp->plotDialog()->TabWidget->setCurrentPage(LABELS_TAB);
+        ParentApp->plotDialog()->TabWidget->setCurrentPage(APPEARANCE_TAB);
       }
       return;
     }
@@ -4472,7 +4478,7 @@
       KstApp::inst()->labelDialog()->showI(this, i_label, x, y);
     } else if (legendUnder(e)) {
       KstApp::inst()->plotDialog()->show_I(static_cast<KstViewWidget*>(view)->viewObject()->tagName(), tagName());
-      KstApp::inst()->plotDialog()->TabWidget->setCurrentPage(LEGEND_TAB);
+      KstApp::inst()->plotDialog()->TabWidget->setCurrentPage(APPEARANCE_TAB);
     } else if (type == KstApp::GFX_LABEL && plotregion.contains(e->pos()) && _draggableLabel == -1) {
       KstApp::inst()->labelDialog()->showI(this, -1, x, y);
     }
--- trunk/extragear/graphics/kst/kst/kstplotdialog_i.h #449468:449469
@@ -23,12 +23,12 @@
 class KstLabel;
 class KMdiChildView;
 
-#define CONTENT_TAB   0
-#define LABELS_TAB    1
-#define LEGEND_TAB    1
-#define AXES_TAB      2
-#define LIMITS_TAB    3
-#define MARKERS_TAB   4
+#define CONTENT_TAB     0
+#define APPEARANCE_TAB  1
+#define X_AXIS_TAB      2
+#define Y_AXIS_TAB      3
+#define RANGE_TAB       4
+#define MARKERS_TAB     5
 
 class KstPlotDialogI : public KstPlotDialog {
   Q_OBJECT