qwt

Errors while building with QWT

纵饮孤独 提交于 2019-12-08 05:28:28
I get an error undefined reference to `QwtPlot::QwtPlot(QWidget*)' when I try to build my project even though everything seems fine in the setup. In my CmakeLists.txt I have include_directories( [...] ${QWT_INCLUDE_DIR}) which points to where I have my Qwt headers and find_package(Qwt REQUIRED) works because QWT_FOUND is set to True Here's my FindQwt.cmake: #MESSAGE("Searching for QWT") FIND_PATH(QWT_INCLUDE_DIR NAMES qwt.h PATHS /usr/include /usr/local/include "$ENV{LIB_DIR}/include" "$ENV{INCLUDE}" PATH_SUFFIXES qwt-qt4 qwt ) FIND_LIBRARY(QWT_LIBRARY NAMES qwt qwt5 qwt-qt4 qwt5-qt4 PATHS

Errors while building with QWT

流过昼夜 提交于 2019-12-08 03:22:15
问题 I get an error undefined reference to `QwtPlot::QwtPlot(QWidget*)' when I try to build my project even though everything seems fine in the setup. In my CmakeLists.txt I have include_directories( [...] ${QWT_INCLUDE_DIR}) which points to where I have my Qwt headers and find_package(Qwt REQUIRED) works because QWT_FOUND is set to True Here's my FindQwt.cmake: #MESSAGE("Searching for QWT") FIND_PATH(QWT_INCLUDE_DIR NAMES qwt.h PATHS /usr/include /usr/local/include "$ENV{LIB_DIR}/include" "$ENV

Install Qwt on Win7 64bit

主宰稳场 提交于 2019-12-06 00:10:44
I searched around the web but didn't find a solution for my proper problem. Problem: Qwt-installation failes at the nmake -step What I did: -) installed Qt 5.1 ( Qt 5.1.1 for Windows 64-bit (VS 2012, 525 MB) ) (Info)from qt-website -) Downloaded Qwt 6.1.0 files from here -) extracted Files to C:/Qt/Qwt-6.1.0 -) set correct path in qwtconfig.pri -) started MSVC 2012 console (coming with Qt) and run qmake qwt.pro -) tried nmake in same consol (but nmake.exe was not found) --> installed Microsoft Visual 2010 Express from here (automatically installed to 'Program Files (x86)') -) tried again in

Is this method of inter-thread-communication safe?

China☆狼群 提交于 2019-12-05 15:59:53
I have 3 objects(inherited from QObject ) that each contain a separate std::list . Each object gets created in the main gui thread (with no parent) and then is pushed to it's own thread (using Qt's QObject::moveToThread() ). Each thread is hooked up to a gui and messages are sent between the different threads with data. Each thread is to essentially handle it's own list. For example: Obj 1 : Consumer of data. It pop's the front off of its list(if data is present) to use. It also has a SLOT available so that other threads can push data to it. No other object can access this list directly only

Can't generate pdf with acceptable output quality using Qt

不问归期 提交于 2019-12-04 12:06:40
I'm trying to generate a pdf using Qt5 under Windows. My document contains texts, images and charts. As I'm familiar with Qt and Qwt, I believed the best strategy was to create a QWidget with my document layout and simply print it. But I face problems and could not end up with an acceptable result. Here is my MCVE, a simple page document with: A header with title and image A piece of text A simple chart Based on Qt document and How can I print a QWidget in Qt? , I ended up with this code: main.cpp: #include <QApplication> #include <QIcon> #include <QDesktopServices> #include <QWidget> #include

win上傻瓜化安装Qt开发环境

感情迁移 提交于 2019-12-03 22:27:18
win上傻瓜化安装Qt开发环境 古老的 MSYS 搭建的开发环境不仅存在一些兼容性问题,而且还很繁琐,幸好 mingw-build 项目的开发者又做了更进一步的改进,他们开发了 MSYS2 项目。这个项目不仅兼容性更好,而且引入了包管理机制,可以直接从网上下载相关的软件,并解决相关的依赖性问题。 这个项目的主页在 http://sourceforge.net/projects/msys2/ 进入项目主页后,根据你的系统选择 32 位或者 64 位,现在大家使用的系统应该都是 64 位的了。下载好 base 包,然后解压缩到什么地方,一般我都是解压缩到 D 盘的根目录下,然后把 bin 目录加入系统 PATH 。在 MSYS2 根目录下有 3 个 bat 文件,它们是启动 MSYS2 的命令,根据需要启动,如果你不做开发,那么只需要启动 msys2_shell.bat 就足够了;如果你需要软件开发,那么就启动 mingw64_shell.bat ,它会在 MSYS 目录下新建一个 mingw64 的目录,里面存放着 mingw 编译器及其类库。首次运行时会进行一些系统设定,等到命令提示符出现就完成了,此时需要退出 MSYS2 ,然后重新进入。 在 MSYS 窗口左上角点击那个图标,弹出的菜单中有 option ,可以设置 MSYS2 的一些参数

tutorial on graphs plotting qwt [closed]

て烟熏妆下的殇ゞ 提交于 2019-12-03 13:55:23
I am using qt and qwt. I want to plot a graph but I am completely new to it. Can some one please give me a link which explains basic graph plotting using qwt? thanks There is a good start point here also reading this tutorial helped me a lot. maybe you should take a look at documentation too. 来源: https://stackoverflow.com/questions/5393279/tutorial-on-graphs-plotting-qwt

Tool tip to show plot values in Qwt

浪尽此生 提交于 2019-12-03 13:48:16
I have a qwt plot in my application. I want to show a small tool tip to show the value of the point at which mouse is pointed on the curve. I found that I have to use QwtPlotPicker for this, but couldn't find any proper example to implement this in my code. I am new to Qwt so it would be great if anyone could help me solve this problem. Thanks, Rakesh. c_k The author himself says here : A QwtPlotPicker gives you the current position of the mouse ( in screen and plot coordinates ). Then you need to find the closest points of your curves. You can use QwtPlotCurve::closestPoint(), but in most

qwt实时曲线

匿名 (未验证) 提交于 2019-12-03 00:27:02
一、首先要定义和实例化一个QwtPlot,然后是一根曲线QwtPlotCurve,还有就是数据,由于QwtPlot是从设计器拉到界面,IDE做了这个工作就暂时不管了,如果没有IDE可以用代码写的: //曲线 QwtPlotCurve * curve; //X轴 double time[10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}; //Y轴 double val[10] = {3, 5, 8, 7, 2, 0, 7, 9, 1}; //实例化 curve = new QwtPlotCurve("Acc_X"); //加载数据 curve->setSamples(time, val, 10); //加到plot,plot由IDE创建 curve->attach(ui->qwtPlot); 图表显示出来,现在的问题是这是一个静态图标,如何动态显示实时数据呢,我们用定时器模拟产生随机数进行动态数据的展示,如下: //启动定时器,1秒响应,用于模拟产生实时数据 this->startTimer(1000); //定时器事件 void MainWindow::timerEvent( QTimerEvent * ) { //所有数据前移移位,首位被覆盖 for (int i = 0; i < 9; i++) { val[i] = val[i+1]; } /

linux下qwt6.1.2的安装

匿名 (未验证) 提交于 2019-12-02 21:59:42
环境:Qt4.8.3 、 Qwt6.1.2 、64位linux; #make 步骤二.进行环境配置 1.vi /etc/profile 2.添加环境变量 export C_INCLUDE_PATH=/usr/local/qwt-6.1.2/include:$C_INCLUDE_PATH 步骤三.如果完成上述两部之后,打开qtcreator的qtdesiger设计界面找不到qwt的绘图控件,则将解压出的 /qwt-6.1.2/designer/plugins/designer/libqwt_designer_plugin.so 复制到Qt的安装目录下: /usr/lib/qt4/plugins/designer下即可。 此种方式不需要再Qt的.pro文件中添加路径; 如果不行,重启Qt更新环境配置即可。 文章来源: linux下qwt6.1.2的安装