v2.0.0
Loading...
Searching...
No Matches
DISPLIB::ChannelLabelPanel Class Reference

Vertical column of channel-name labels synced with ChannelDataView row geometry. More...

#include <channellabelpanel.h>

Signals

void channelScrollRequested (int targetFirst)
void channelBadToggled (int channelIndex, bool bad)

Public Member Functions

 ChannelLabelPanel (QWidget *parent=nullptr)
void setModel (ChannelDataModel *model)
void setFirstVisibleChannel (int ch)
void setVisibleChannelCount (int count)
void setChannelIndices (const QVector< int > &indices)
void setHideBadChannels (bool hide)
void setButterflyMode (bool enabled)
void setVisibleSampleRange (int firstSample, int lastSample)
QSize sizeHint () const override
QSize minimumSizeHint () const override

Protected Member Functions

void paintEvent (QPaintEvent *event) override
void mousePressEvent (QMouseEvent *event) override
void mouseMoveEvent (QMouseEvent *event) override
void mouseReleaseEvent (QMouseEvent *event) override
bool event (QEvent *e) override

Detailed Description

Vertical column of channel-name labels synced with ChannelDataView row geometry.

Listens to the same ChannelDataModel as the central data view; bad channels are greyed and label clicks emit channel selection signals.

Definition at line 56 of file channellabelpanel.h.

Inheritance diagram for DISPLIB::ChannelLabelPanel:
Inheritance graph

Constructor & Destructor Documentation

◆ ChannelLabelPanel()

ChannelLabelPanel::ChannelLabelPanel ( QWidget * parent = nullptr)
explicit

Definition at line 53 of file channellabelpanel.cpp.

Member Function Documentation

◆ channelBadToggled

void DISPLIB::ChannelLabelPanel::channelBadToggled ( int channelIndex,
bool bad )
signal

◆ channelScrollRequested

void DISPLIB::ChannelLabelPanel::channelScrollRequested ( int targetFirst)
signal

Emitted while the user drags vertically on the panel.

Parameters
[in]targetFirstThe desired new first-visible-channel index.

◆ event()

bool ChannelLabelPanel::event ( QEvent * e)
overrideprotected

Definition at line 455 of file channellabelpanel.cpp.

◆ minimumSizeHint()

QSize ChannelLabelPanel::minimumSizeHint ( ) const
override

Definition at line 71 of file channellabelpanel.cpp.

◆ mouseMoveEvent()

void ChannelLabelPanel::mouseMoveEvent ( QMouseEvent * event)
overrideprotected

Definition at line 357 of file channellabelpanel.cpp.

◆ mousePressEvent()

void ChannelLabelPanel::mousePressEvent ( QMouseEvent * event)
overrideprotected

Definition at line 344 of file channellabelpanel.cpp.

◆ mouseReleaseEvent()

void ChannelLabelPanel::mouseReleaseEvent ( QMouseEvent * event)
overrideprotected

Definition at line 390 of file channellabelpanel.cpp.

◆ paintEvent()

void ChannelLabelPanel::paintEvent ( QPaintEvent * event)
overrideprotected

Definition at line 143 of file channellabelpanel.cpp.

◆ setButterflyMode()

void ChannelLabelPanel::setButterflyMode ( bool enabled)

Enable or disable butterfly mode. When active, lanes show type group labels (e.g. "MEG", "EEG") instead of individual channel names.

Parameters
[in]enabledtrue = butterfly mode, false = normal per-channel mode.

Definition at line 124 of file channellabelpanel.cpp.

◆ setChannelIndices()

void ChannelLabelPanel::setChannelIndices ( const QVector< int > & indices)

Restrict the panel to a subset of model channel indices. When indices is empty all model channels are available (no filter). Must be kept in sync with ChannelRhiView::setChannelIndices().

Parameters
[in]indicesOrdered list of model channel indices to display.

Definition at line 86 of file channellabelpanel.cpp.

◆ setFirstVisibleChannel()

void ChannelLabelPanel::setFirstVisibleChannel ( int ch)

Set the index of the first visible channel row (kept in sync with ChannelRhiView).

Definition at line 94 of file channellabelpanel.cpp.

◆ setHideBadChannels()

void ChannelLabelPanel::setHideBadChannels ( bool hide)

Show or hide bad-channel rows. When hide is true, bad channels are removed from the visible row list so the panel stays aligned with the trace view.

Definition at line 114 of file channellabelpanel.cpp.

◆ setModel()

void ChannelLabelPanel::setModel ( ChannelDataModel * model)

Definition at line 78 of file channellabelpanel.cpp.

◆ setVisibleChannelCount()

void ChannelLabelPanel::setVisibleChannelCount ( int count)

Set how many channel rows are simultaneously visible (kept in sync with ChannelRhiView).

Definition at line 104 of file channellabelpanel.cpp.

◆ setVisibleSampleRange()

void ChannelLabelPanel::setVisibleSampleRange ( int firstSample,
int lastSample )

Update the visible sample window used for the per-channel RMS level bar. Call this whenever the horizontal scroll position changes.

Parameters
[in]firstSampleAbsolute first sample in the visible window.
[in]lastSampleAbsolute last sample (exclusive) in the visible window.

Definition at line 134 of file channellabelpanel.cpp.

◆ sizeHint()

QSize ChannelLabelPanel::sizeHint ( ) const
override

Definition at line 64 of file channellabelpanel.cpp.


The documentation for this class was generated from the following files: