mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#1226 Show the complete text in the summary plot tooltip text
This commit is contained in:
parent
b6b544f13f
commit
ad5e18afa6
@ -258,7 +258,14 @@ QPointF RiuSummaryQwtPlot::closestCurvePoint(const QPoint& cursorPosition, QStri
|
||||
if (timeString)
|
||||
{
|
||||
const QwtScaleDraw* timeAxisScaleDraw = axisScaleDraw(QwtPlot::xBottom);
|
||||
if (timeAxisScaleDraw)
|
||||
auto dateScaleDraw = dynamic_cast<const QwtDateScaleDraw*>(timeAxisScaleDraw) ;
|
||||
|
||||
if (dateScaleDraw)
|
||||
{
|
||||
QDateTime date = dateScaleDraw->toDateTime(samplePoint.x());
|
||||
*timeString = date.toString("hh:mm dd.MMMM.yyyy");
|
||||
}
|
||||
else if (timeAxisScaleDraw)
|
||||
{
|
||||
*timeString = timeAxisScaleDraw->label(samplePoint.x()).text();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user