projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
RowItem: Replaced fixed signal heights with extents
[pulseview.git]
/
pv
/
view
/
analogsignal.h
diff --git
a/pv/view/analogsignal.h
b/pv/view/analogsignal.h
index 6f0e49d7409095eb8d381bb5afab941313fec1f5..710639005a615cf485efb53b013ef0d7fecaab8d 100644
(file)
--- a/
pv/view/analogsignal.h
+++ b/
pv/view/analogsignal.h
@@
-37,13
+37,14
@@
namespace view {
class AnalogSignal : public Signal
{
private:
class AnalogSignal : public Signal
{
private:
+ static const int NominalHeight;
static const QColor SignalColours[4];
static const float EnvelopeThreshold;
public:
static const QColor SignalColours[4];
static const float EnvelopeThreshold;
public:
- AnalogSignal(
std::shared_ptr<pv::device::DevInst> dev_inst
,
-
const sr_channel *const probe
,
+ AnalogSignal(
pv::SigSession &session
,
+
std::shared_ptr<sigrok::Channel> channel
,
std::shared_ptr<pv::data::Analog> data);
virtual ~AnalogSignal();
std::shared_ptr<pv::data::Analog> data);
virtual ~AnalogSignal();
@@
-54,6
+55,12
@@
public:
void set_scale(float scale);
void set_scale(float scale);
+ /**
+ * Computes the vertical extents of the contents of this row item.
+ * @return A pair containing the minimum and maximum y-values.
+ */
+ std::pair<int, int> v_extents() const;
+
/**
* Paints the background layer of the signal with a QPainter
* @param p the QPainter to paint into.
/**
* Paints the background layer of the signal with a QPainter
* @param p the QPainter to paint into.