diff options
author | Tim Moore <timoore@redhat.com> | 2009-12-04 17:12:06 +0100 |
---|---|---|
committer | Tim Moore <timoore@redhat.com> | 2009-12-04 17:12:06 +0100 |
commit | 2ebfefae53de7d6c001554a159dbcc8edfac9ec7 (patch) | |
tree | 9b1b4bb2aedbf6a6b8fb682bee77e6cf6409b0dd | |
parent | 52cf0905d93c33f7d6f768478572ea08df4c8af0 (diff) | |
download | systemtap-steved-2ebfefae53de7d6c001554a159dbcc8edfac9ec7.tar.gz systemtap-steved-2ebfefae53de7d6c001554a159dbcc8edfac9ec7.tar.xz systemtap-steved-2ebfefae53de7d6c001554a159dbcc8edfac9ec7.zip |
hover text on the additional graphs
* grapher/Graph.cxx (window2GraphCoords): Take the entire graph's
position into account too.
* grapher/GraphWidget.cxx (GraphWidget): Hook up the data dialog's OK
button.
(onDataDialogOpen): If a data set doesn't have a title, use it's
name (key) instead.
-rw-r--r-- | grapher/Graph.cxx | 2 | ||||
-rw-r--r-- | grapher/GraphWidget.cxx | 10 |
2 files changed, 10 insertions, 2 deletions
diff --git a/grapher/Graph.cxx b/grapher/Graph.cxx index 57f1dc9a..b3429ef7 100644 --- a/grapher/Graph.cxx +++ b/grapher/Graph.cxx @@ -210,6 +210,6 @@ namespace systemtap double& xgraph, double& ygraph) { xgraph = x -_xOffset; - ygraph = -y + _yOffset + _graphHeight; + ygraph = -(y - _graphY) + _yOffset + _graphHeight; } } diff --git a/grapher/GraphWidget.cxx b/grapher/GraphWidget.cxx index e37485b8..3d38627f 100644 --- a/grapher/GraphWidget.cxx +++ b/grapher/GraphWidget.cxx @@ -53,6 +53,11 @@ namespace systemtap button->signal_clicked() .connect(sigc::mem_fun(*this, &GraphWidget::onDataDialogCancel), false); + // XXX + _refXmlDataDialog->get_widget("okbutton1", button); + button->signal_clicked() + .connect(sigc::mem_fun(*this, &GraphWidget::onDataDialogCancel), + false); _refXmlDataDialog->get_widget("button1", button); button->signal_clicked() .connect(sigc::mem_fun(*this, &GraphWidget::onDataAdd), false); @@ -263,7 +268,10 @@ namespace systemtap { Gtk::TreeModel::iterator litr = _listStore->append(); Gtk::TreeModel::Row row = *litr; - row[_dataColumns._dataName] = (*itr)->title; + if (!(*itr)->title.empty()) + row[_dataColumns._dataName] = (*itr)->title; + else + row[_dataColumns._dataName] = (*itr)->name; row[_dataColumns._graphData] = *itr; } } |