mirror of
https://github.com/jankae/LibreVNA.git
synced 2026-04-06 23:13:43 +00:00
Treeview for markers, added peak table function
This commit is contained in:
parent
8d71cd6541
commit
3358861114
9 changed files with 307 additions and 106 deletions
|
|
@ -580,9 +580,7 @@ void TraceXYPlot::markerDataChanged(TraceMarker *m)
|
|||
void TraceXYPlot::markerSymbolChanged(TraceMarker *m)
|
||||
{
|
||||
auto qwtMarker = markers[m];
|
||||
auto old_sym = qwtMarker->symbol();
|
||||
qwtMarker->setSymbol(nullptr);
|
||||
delete old_sym;
|
||||
|
||||
QwtSymbol *sym=new QwtSymbol;
|
||||
sym->setPixmap(m->getSymbol());
|
||||
|
|
@ -597,6 +595,9 @@ void TraceXYPlot::clicked(const QPointF pos)
|
|||
unsigned int closestDistance = numeric_limits<unsigned int>::max();
|
||||
TraceMarker *closestMarker = nullptr;
|
||||
for(auto m : markers) {
|
||||
if(!m.first->isMovable()) {
|
||||
continue;
|
||||
}
|
||||
auto markerPoint = drawPicker->plotToPixel(m.second->value());
|
||||
auto yDiff = abs(markerPoint.y() - clickPoint.y());
|
||||
auto xDiff = abs(markerPoint.x() - clickPoint.x());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue