📄 canvasview.h
字号:
/*******************************************************************************//* Project: SOFTWARE RADIO - LCM Laboratoire de Communications Mobiles *//* -------------------------------------------------------------------------- *//* Filename: canvasview.h *//* Description: Subclass of QCanvasview, implements mouse click functiona- *//* lities. *//* -------------------------------------------------------------------------- *//* Date: January 09 2003 *//* Version: v1.0 *//* Authors: Braure Jerome, Ferreiro Jose *//* Communication Systems (9th semester) - EPFL *//*******************************************************************************//*******************************************************************************//* This program is free software; you can redistribute it and/or modify it *//* under the terms of the GNU General Public License as published by the Free *//* Software Foundation; either version 2 of the License, or (at your option) *//* any later version. *//*******************************************************************************/#ifndef CANVASWIEW_H#define CANVASWIEW_H#include <qmenubar.h>#include <qpopupmenu.h>#include <qcanvas.h>#include <qcombobox.h>#include <qstring.h>#include <qpixmap.h>#include "mapper.h"#include "module.h"#include "defines.h"#include "show.h"class CanvasView : public QCanvasView { Q_OBJECTpublic: CanvasView(QCanvas* canvas, QWidget* parent, Mapper* mapper);private: void contentsMousePressEvent(QMouseEvent*); void mouseReleaseEvent(QMouseEvent *e); void mouseMoveEvent(QMouseEvent *e); void displayData(int id, int blockType); Mapper* mapper; bool mousePressed; QWidget *window; QComboBox *qcbType; // string holding the name of the variable // that the user wants to see QString variableToDisplay; QPixmap *graphItem; // number of the clicked module Module *selectedModule; // x coordinate of mouse location when user clicks int mousePressX; // y coordinate of mouse location when user clicks int mousePressY; // x coordinate of canvas centering int centeredX; // x coordinate of canvas centering int centeredY; int stfaNumber;public slots: void slotDisplayStatsData(int id); void slotDisplayPortData(int id); void slotConfig(int id); void slotStfaChoosen(int id); void processData(); signals: void moduleSelected (Module*);};#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -