⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 draw.hxx

📁 GNU/LINUX编程指南+源代码 对于初学者非常有用 吐血推荐
💻 HXX
字号:
// Draw.hxx//// Simple example showing Qt's event methods that are inhereted from QWidget//// This example is derived from the QT connect.cpp example, so the following// copyright is in effect:/****************************************************************************** $Id: qt/examples/drawlines/connect.cpp   2.2.0   edited 2000-08-31 $**** Copyright (C) 1992-2000 Trolltech AS.  All rights reserved.**** This file is part of an example program for Qt.  This example** program may be used, distributed and modified without limitation.*******************************************************************************/#ifndef __DRAW_HXX#define __DRAW_HXX#include <qwidget.h>#include <qpainter.h>#include <qapplication.h>class DrawWidget : public QWidget{public:  DrawWidget(QWidget *parent=0, const char *name=0);  ~DrawWidget();protected:  void  paintEvent(QPaintEvent *);  void  mousePressEvent(QMouseEvent *);  void  mouseMoveEvent(QMouseEvent *);private:  QPoint     *points;                         // point array  QColor     *color;                          // color value  int         count;                          // count = number of points};#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -