| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | #ifndef INCLUDE_CHANNELMARKER_H
 | 
					
						
							|  |  |  | #define INCLUDE_CHANNELMARKER_H
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #include <QObject>
 | 
					
						
							|  |  |  | #include <QColor>
 | 
					
						
							|  |  |  | #include "util/export.h"
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-08-30 01:26:51 +02:00
										 |  |  | class SDRANGEL_API ChannelMarker : public QObject { | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | 	Q_OBJECT | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | public: | 
					
						
							| 
									
										
										
										
											2015-05-11 03:27:31 +02:00
										 |  |  | 	typedef enum sidebands_e | 
					
						
							|  |  |  | 	{ | 
					
						
							|  |  |  | 		dsb, | 
					
						
							|  |  |  | 		lsb, | 
					
						
							| 
									
										
										
										
											2017-03-16 11:49:14 +01:00
										 |  |  | 		usb, | 
					
						
							|  |  |  | 		vusb, //!< USB with vestigial LSB
 | 
					
						
							|  |  |  | 		vlsb  //!< LSB with vestigial USB
 | 
					
						
							| 
									
										
										
										
											2015-05-11 03:27:31 +02:00
										 |  |  | 	} sidebands_t; | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | 	ChannelMarker(QObject* parent = NULL); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 	void setTitle(const QString& title); | 
					
						
							|  |  |  | 	const QString& getTitle() const { return m_title; } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 	void setCenterFrequency(int centerFrequency); | 
					
						
							|  |  |  | 	int getCenterFrequency() const { return m_centerFrequency; } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 	void setBandwidth(int bandwidth); | 
					
						
							|  |  |  | 	int getBandwidth() const { return m_bandwidth; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-03-16 11:49:14 +01:00
										 |  |  |     void setOppositeBandwidth(int bandwidth); | 
					
						
							|  |  |  |     int getOppositeBandwidth() const { return m_oppositeBandwidth; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-05-12 21:50:02 +02:00
										 |  |  | 	void setLowCutoff(int lowCutoff); | 
					
						
							|  |  |  | 	int getLowCutoff() const { return m_lowCutoff; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-05-11 03:27:31 +02:00
										 |  |  | 	void setSidebands(sidebands_t sidebands); | 
					
						
							|  |  |  | 	sidebands_t getSidebands() const { return m_sidebands; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | 	void setVisible(bool visible); | 
					
						
							|  |  |  | 	bool getVisible() const { return m_visible; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-05-11 11:03:01 +02:00
										 |  |  | 	void setHighlighted(bool highlighted); | 
					
						
							|  |  |  | 	bool getHighlighted() const { return m_highlighted; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | 	void setColor(const QColor& color); | 
					
						
							|  |  |  | 	const QColor& getColor() const { return m_color; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-03-16 00:39:49 +01:00
										 |  |  | 	void setMovable(bool movable) { m_movable = movable; } | 
					
						
							|  |  |  | 	bool getMovable() const { return m_movable; } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | protected: | 
					
						
							|  |  |  | 	static QRgb m_colorTable[]; | 
					
						
							|  |  |  | 	static int m_nextColor; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 	QString m_title; | 
					
						
							|  |  |  | 	int m_centerFrequency; | 
					
						
							|  |  |  | 	int m_bandwidth; | 
					
						
							| 
									
										
										
										
											2017-03-16 11:49:14 +01:00
										 |  |  |     int m_oppositeBandwidth; | 
					
						
							| 
									
										
										
										
											2015-05-12 21:50:02 +02:00
										 |  |  | 	int m_lowCutoff; | 
					
						
							| 
									
										
										
										
											2015-05-11 03:27:31 +02:00
										 |  |  | 	sidebands_t m_sidebands; | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | 	bool m_visible; | 
					
						
							| 
									
										
										
										
											2015-05-11 11:03:01 +02:00
										 |  |  | 	bool m_highlighted; | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | 	QColor m_color; | 
					
						
							| 
									
										
										
										
											2017-03-16 00:39:49 +01:00
										 |  |  | 	bool m_movable; | 
					
						
							| 
									
										
										
										
											2014-05-18 16:52:39 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | signals: | 
					
						
							|  |  |  | 	void changed(); | 
					
						
							|  |  |  | }; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #endif // INCLUDE_CHANNELMARKER_H
 |