コード例 #1
0
ファイル: sampling.cpp プロジェクト: Aconex/pcp
void
SamplingItem::updateCursor(const QPointF &p, int)
{
    QString title = my.chart->YAxisTitle();

    my.info.sprintf("[%.2f", (float)p.y());
    if (title != QString::null) {
	my.info.append(" ");
	my.info.append(title);
    }
    my.info.append(" at ");
    my.info.append(timeHiResString(p.x()));
    my.info.append("]");

    pmchart->setValueText(my.info);
}
コード例 #2
0
ファイル: tracing.cpp プロジェクト: goodwinos/pcp
TracingEvent::TracingEvent(QmcEventRecord const &record, pmID pmid, int inst)
{
    my.timestamp = pmtimevalToReal(record.timestamp());
    my.missed = record.missed();
    my.flags = record.flags();
    my.pmid = pmid;
    my.inst = inst;
    my.spanID = record.identifier();
    my.rootID = record.parent();

    // details displayed about this record (on selection)
    my.description.append(timeHiResString(my.timestamp));
    my.description.append(": flags=");
    my.description.append(pmEventFlagsStr(record.flags()));
    if (record.missed()> 0) {
	my.description.append(" (");
	my.description.append(QString::number(record.missed()));
	my.description.append(" missed)");
    }
    my.description.append("\n");
    record.parameterSummary(my.description, inst);
}