[arch-commits] Commit in qtiplot/trunk (9 files)
Ronald van Haren
ronald at archlinux.org
Thu May 14 10:49:26 UTC 2009
Date: Thursday, May 14, 2009 @ 06:49:26
Author: ronald
Revision: 39252
cleanup & add patches
Added:
qtiplot/trunk/qtiplot.pro.archlinux
qtiplot/trunk/qwtplot3d_gcc.patch
qtiplot/trunk/scriptedit.patch
Modified:
qtiplot/trunk/PKGBUILD
Deleted:
qtiplot/trunk/liborigin-gcc4.3.patch
qtiplot/trunk/qtiplot-0.9.7.3-qwt3d.patch
qtiplot/trunk/qtiplot-nopython.patch
qtiplot/trunk/qtiplot-sip.patch
qtiplot/trunk/qtiplot.archlinux.patch
-----------------------------+
PKGBUILD | 47 +---
liborigin-gcc4.3.patch | 14 -
qtiplot-0.9.7.3-qwt3d.patch | 21 --
qtiplot-nopython.patch | 63 ------
qtiplot-sip.patch | 35 ---
qtiplot.archlinux.patch | 64 ------
qtiplot.pro.archlinux | 226 ++++++++++++++++++++++
qwtplot3d_gcc.patch | 9
scriptedit.patch | 427 ++++++++++++++++++++++++++++++++++++++++++
9 files changed, 681 insertions(+), 225 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2009-05-14 07:45:04 UTC (rev 39251)
+++ PKGBUILD 2009-05-14 10:49:26 UTC (rev 39252)
@@ -3,13 +3,13 @@
# Contributor: damir <damir.archlinux.org>
pkgname=qtiplot
-pkgver=0.9.7.4
-pkgrel=2
+pkgver=0.9.7.7
+pkgrel=1
pkgdesc="Data analysis and scientific plotting - free clone of Origin"
arch=('i686' 'x86_64')
url="http://soft.proindependent.com/qtiplot.html"
-depends=('muparser>=1.30' 'gsl' 'python>=2.6' 'pyqt' 'sip' \
- 'boost>=1.36' 'libgl' 'qwt')
+depends=('muparser>=1.30' 'gsl' 'python>=2.6.2' 'pyqt' 'sip' \
+ 'boost>=1.37' 'libgl' 'qwt')
# build against liborigin provided in the package ...
# build against qwtplot3d provided in the package ...
# as systemwide one doesn't provide all needed functions
@@ -17,31 +17,22 @@
license=('GPL2')
source=("http://soft.proindependent.com/src/qtiplot-$pkgver.tar.bz2" \
- "$pkgname.desktop" "$pkgname.png" \
- "qtiplot-gcc4.3.patch" "liborigin-gcc4.3.patch" \
- "qtiplot.archlinux.patch" "qtiplot-0.9.7.3-qwt3d.patch" \
- "dynamicgsl.patch" "qtiplot-sip.patch" "qtiplot-nopython.patch")
+ "$pkgname.desktop" "$pkgname.png" "qtiplot.pro.archlinux"
+ "qwtplot3d_gcc.patch" "scriptedit.patch")
+md5sums=('c923fb5c5f161e0d6cb31c3beebe6165' '56bd53f4f1367c285086acb969f13348'
+ 'ad8affbd6f0d5cbdcde46c923ee2668a' '7af559c2986f5c65616331dc36859642'
+ 'b326dec9d13f838293b982e76fe9d5d1' 'fd36e086195ca70b4628a14eb2ba4fcd')
-md5sums=('dd149d024501e34cda685023522b4d8d' '56bd53f4f1367c285086acb969f13348'
- 'ad8affbd6f0d5cbdcde46c923ee2668a' '927149a0c3623209d4aaef867031ba76'
- 'ad2333cfb8df37d33a6449c2c49ec945' '4a37f3bbf2cff51dcd93305a920d4415'
- '20ae1d441f299aa2c2c54e3bed3a9786' '2c858d26255ecde7bcd157515ed767d6'
- 'f68e62cd6c6762345f1a123321f49e57' 'b65f2b1266b42b9c298ac4dee3d19c90')
-
build() {
- cd $srcdir/$pkgname-$pkgver
+ cd ${srcdir}/${pkgname}-${pkgver}/qtiplot/src/scripting
+ patch -Np0 -i ${srcdir}/scriptedit.patch || return 1
- # patching
- patch -Np0 < $srcdir/dynamicgsl.patch || return 1
+ cd ${srcdir}/${pkgname}-${pkgver}/3rdparty/qwtplot3d/src
+ patch -Np0 -i ${srcdir}/qwtplot3d_gcc.patch || return 1
- cd $srcdir/$pkgname-$pkgver/$pkgname
- patch -Np0 -i $srcdir/qtiplot-gcc4.3.patch || return 1
- patch -Np0 -i $srcdir/qtiplot-0.9.7.3-qwt3d.patch || return 1
- patch -Np0 -i $srcdir/liborigin-gcc4.3.patch || return 1
- patch -Np0 -i $srcdir/qtiplot.archlinux.patch || return 1
- patch -Np0 -i $srcdir/qtiplot-sip.patch || return 1
- patch -Np2 -i $srcdir/qtiplot-nopython.patch || return 1
+ cd ${srcdir}/${pkgname}-${pkgver}/${pkgname}
+ install -Dm644 ${srcdir}/qtiplot.pro.archlinux qtiplot.pro
sed -i 's#d_python_config_folder + "#"/usr/share/qtiplot#' src/core/ApplicationWindow.cpp
@@ -52,8 +43,8 @@
INSTALL_ROOT=${pkgdir} make install || return 1
# make it nice:
- install -D -m644 $srcdir/$pkgname.png \
- $pkgdir/usr/share/pixmaps/$pkgname.png || return 1
- install -D -m644 $srcdir/$pkgname.desktop \
- $pkgdir/usr/share/applications/$pkgname.desktop || return 1
+ install -D -m644 ${srcdir}/${pkgname}.png \
+ ${pkgdir}/usr/share/pixmaps/${pkgname}.png || return 1
+ install -D -m644 ${srcdir}/${pkgname}.desktop \
+ ${pkgdir}/usr/share/applications/${pkgname}.desktop || return 1
}
Deleted: liborigin-gcc4.3.patch
===================================================================
--- liborigin-gcc4.3.patch 2009-05-14 07:45:04 UTC (rev 39251)
+++ liborigin-gcc4.3.patch 2009-05-14 10:49:26 UTC (rev 39252)
@@ -1,14 +0,0 @@
-# fix gcc-4.3 missing headers
-
-diff -Naur qtiplot-0.9.7.2/3rdparty/liborigin/OriginObj.h qtiplot-0.9.7.2.new/3rdparty/liborigin/OriginObj.h
---- ../3rdparty/liborigin/OriginObj.h 2008-09-21 13:22:33.000000000 -0400
-+++ ../3rdparty/liborigin/OriginObj.h 2008-09-25 10:07:27.000000000 -0400
-@@ -33,6 +33,7 @@
-
- #include <string>
- #include <vector>
-+#include <cstring>
- #include "boost/variant.hpp"
- #include "boost/date_time/posix_time/ptime.hpp"
-
-
Deleted: qtiplot-0.9.7.3-qwt3d.patch
===================================================================
--- qtiplot-0.9.7.3-qwt3d.patch 2009-05-14 07:45:04 UTC (rev 39251)
+++ qtiplot-0.9.7.3-qwt3d.patch 2009-05-14 10:49:26 UTC (rev 39252)
@@ -1,21 +0,0 @@
-diff -Naur qtiplot-0.9.7.3/qtiplot/src/plot3D/Graph3D.cpp qtiplot-0.9.7.3.new/qtiplot/src/plot3D/Graph3D.cpp
---- src/plot3D/Graph3D.cpp 2008-10-20 06:32:35.000000000 -0400
-+++ src/plot3D/Graph3D.cpp 2008-10-24 11:04:56.000000000 -0400
-@@ -777,7 +777,7 @@
- void Graph3D::setNumbersFont(const QFont& font)
- {
- sp->coordinates()->setNumberFont (font);
-- sp->legend()->axis()->setNumberFont (font);
-+ //sp->legend()->axis()->setNumberFont (font);
- sp->makeCurrent();
- sp->updateGL();
- }
-@@ -1570,7 +1570,7 @@
- void Graph3D::setNumbersColor(const QColor& numColor)
- {
- if(numCol != numColor){
-- sp->legend()->axis()->setNumberColor(Qt2GL(numColor));
-+ //sp->legend()->axis()->setNumberColor(Qt2GL(numColor));
- sp->coordinates()->setNumberColor(Qt2GL(numColor));
- numCol = numColor;
- }
Deleted: qtiplot-nopython.patch
===================================================================
--- qtiplot-nopython.patch 2009-05-14 07:45:04 UTC (rev 39251)
+++ qtiplot-nopython.patch 2009-05-14 10:49:26 UTC (rev 39252)
@@ -1,63 +0,0 @@
-Index: qtiplot-0.9.7.4/qtiplot/src/scripting/ScriptEdit.cpp
-===================================================================
---- qtiplot-0.9.7.4.orig/qtiplot/src/scripting/ScriptEdit.cpp
-+++ qtiplot-0.9.7.4/qtiplot/src/scripting/ScriptEdit.cpp
-@@ -28,7 +28,11 @@
- ***************************************************************************/
- #include "ScriptEdit.h"
- #include "Note.h"
-+
-+#ifdef SCRIPTING_PYTHON
- #include "PythonSyntaxHighlighter.h"
-+#endif
-+
- #include "FindReplaceDialog.h"
-
- #include <QAction>
-@@ -58,9 +62,11 @@ ScriptEdit::ScriptEdit(ScriptingEnv *env
- setTextFormat(Qt::PlainText);
- setAcceptRichText (false);
-
-+#ifdef SCRIPTING_PYTHON
- if (scriptEnv->name() == QString("Python"))
- d_highlighter = new PythonSyntaxHighlighter(this);
--
-+#endif
-+
- d_fmt_default.setBackground(palette().brush(QPalette::Base));
- d_fmt_failure.setBackground(QBrush(QColor(255,128,128)));
-
-@@ -142,6 +148,7 @@ void ScriptEdit::customEvent(QEvent *e)
- connect(myScript, SIGNAL(error(const QString&, const QString&, int)), this, SLOT(insertErrorMsg(const QString&)));
- connect(myScript, SIGNAL(print(const QString&)), this, SLOT(scriptPrint(const QString&)));
-
-+#ifdef SCRIPTING_PYTHON
- if (scriptEnv->name() == QString("Python") && !d_highlighter)
- d_highlighter = new PythonSyntaxHighlighter(this);
- else {
-@@ -149,6 +156,7 @@ void ScriptEdit::customEvent(QEvent *e)
- delete d_highlighter;
- d_highlighter = 0;
- }
-+#endif
- }
- }
-
-@@ -585,13 +593,16 @@ void ScriptEdit::setDirPath(const QStrin
-
- void ScriptEdit::rehighlight()
- {
-+#ifdef SCRIPTING_PYTHON
- if (scriptEnv->name() != QString("Python"))
- return;
--
-+#endif
- if (d_highlighter)
- delete d_highlighter;
-
-+#ifdef SCRIPTING_PYTHON
- d_highlighter = new PythonSyntaxHighlighter(this);
-+#endif
- }
-
- void ScriptEdit::showFindDialog(bool replace)
Deleted: qtiplot-sip.patch
===================================================================
--- qtiplot-sip.patch 2009-05-14 07:45:04 UTC (rev 39251)
+++ qtiplot-sip.patch 2009-05-14 10:49:26 UTC (rev 39252)
@@ -1,35 +0,0 @@
---- src/scripting/qti.sip 2009-01-28 01:09:59.409564097 +0100
-+++ src/scripting/qti.sip.new 2009-01-28 01:08:07.552907918 +0100
-@@ -74,8 +74,6 @@
- MdiSubWindow(const MdiSubWindow&);
- };
-
--typedef QList<MdiSubWindow*> MDIWindowList;
--
- class Table: MdiSubWindow
- {
- %TypeHeaderCode
-@@ -1072,7 +1070,7 @@
- Graph3D* plotParametricSurface(const QString&, const QString&, const QString&,
- double, double, double, double, int=40, int=40, bool=true, bool=true) /PyName=plot3D/;
-
-- MDIWindowList windowsList() /PyName=windows/;
-+ QList<MdiSubWindow*> windowsList() /PyName=windows/;
-
- // folders
- Folder *activeFolder() /NoDerived/;
-@@ -1867,7 +1865,7 @@
- #include "src/core/Folder.h"
- %End
- public:
-- MDIWindowList windowsList() /PyName=windows/;
-+ QList<MdiSubWindow*> windowsList() /PyName=windows/;
- // TODO: implement signal Folder::nameChanged and make it update the project explorer; adjust renaming from GUI accordingly
- // void setFolderName(const QString&) /PyName=setName/;
- QString name();
-@@ -1887,4 +1885,4 @@
-
- private:
- Folder(const Folder&);
--};
-+};
Deleted: qtiplot.archlinux.patch
===================================================================
--- qtiplot.archlinux.patch 2009-05-14 07:45:04 UTC (rev 39251)
+++ qtiplot.archlinux.patch 2009-05-14 10:49:26 UTC (rev 39252)
@@ -1,64 +0,0 @@
---- qtiplot.pro.old 2009-02-03 11:25:02.575512255 +0100
-+++ qtiplot.pro 2009-02-03 11:24:53.717052708 +0100
-@@ -20,7 +20,7 @@
- win32:LIBS += ../3rdparty/libpng/libpng.a
-
- # Uncomment the following line if you want to perform a custom installation using the *.path variables defined bellow.
--#CONFIG += CustomInstall
-+CONFIG += CustomInstall
-
- CONFIG += release
- #CONFIG += debug
-@@ -30,13 +30,12 @@
- #!!! Warning: You must modify these paths according to your computer settings
- #############################################################################
-
--INCLUDEPATH += ../3rdparty/muparser/include
--INCLUDEPATH += ../3rdparty/qwtplot3d/include
--INCLUDEPATH += ../3rdparty/qwt/src
-+INCLUDEPATH += /usr/include
-+INCLUDEPATH += /usr/include/qwt
-+INCLUDEPATH += /usr/include/gsl
-+INCLUDEPATH += /usr/include/boost
- INCLUDEPATH += ../3rdparty/liborigin
--INCLUDEPATH += ../3rdparty/gsl/include
--INCLUDEPATH += ../3rdparty/zlib123/include
--INCLUDEPATH += ../3rdparty/boost_1_36_0
-+INCLUDEPATH += ../3rdparty/qwtplot3d/include
-
- ##################### 3rd PARTY LIBRARIES SECTION ###########################
- #!!! Warning: You must modify these paths according to your computer settings
-@@ -45,17 +44,18 @@
- ##################### Linux (Mac OS X) ######################################
-
- # statically link against libraries in 3rdparty
--unix:LIBS += ../3rdparty/muparser/lib/libmuparser.a
--unix:LIBS += ../3rdparty/qwt/lib/libqwt.a
--unix:LIBS += ../3rdparty/gsl/lib/libgsl.a
--unix:LIBS += ../3rdparty/gsl/lib/libgslcblas.a
--unix:LIBS += /usr/local/lib/libboost_date_time-gcc41-mt.a
--unix:LIBS += /usr/local/lib/libboost_thread-gcc41-mt.a
-+#unix:LIBS += ../3rdparty/muparser/lib/libmuparser.a
-+#unix:LIBS += ../3rdparty/qwt/lib/libqwt.a
-+#unix:LIBS += ../3rdparty/gsl/lib/libgsl.a
-+#unix:LIBS += ../3rdparty/gsl/lib/libgslcblas.a
-+#unix:LIBS += /usr/local/lib/libboost_date_time-gcc41-mt.a
-+#unix:LIBS += /usr/local/lib/libboost_thread-gcc41-mt.a
-
- # dynamically link against dependencies if they are installed system-wide
- #unix:LIBS += -lmuparser
- #unix:LIBS += -lqwt
- #unix:LIBS += -lgsl -lgslcblas
-+unix:LIBS += -lmuparser -lqwt $$system(pkg-config --libs gsl) -lz -lboost_date_time -lboost_thread-mt
-
- ##################### Windows ###############################################
-
-@@ -186,7 +186,7 @@
- qtiUtil.py \
- qti_wordlist.txt \
-
-- unix: pythonconfig.path = /usr/local/qtiplot
-+ unix: pythonconfig.path = /usr/share/qtiplot
- win32: pythonconfig.path = $$INSTALLBASE
- DEFINES += PYTHON_CONFIG_PATH="\\\"$$replace(pythonconfig.path," ","\ ")\\\"
- }
Added: qtiplot.pro.archlinux
===================================================================
--- qtiplot.pro.archlinux (rev 0)
+++ qtiplot.pro.archlinux 2009-05-14 10:49:26 UTC (rev 39252)
@@ -0,0 +1,226 @@
+# building without muParser doesn't work yet
+SCRIPTING_LANGS += muParser
+SCRIPTING_LANGS += Python
+
+# a console displaying output of scripts; particularly useful on Windows
+# where running QtiPlot from a terminal is inconvenient
+#DEFINES += SCRIPTING_CONSOLE
+
+# a dialog for selecting the scripting language on a per-project basis
+DEFINES += SCRIPTING_DIALOG
+
+#DEFINES += QTIPLOT_DEMO
+
+# Comment the following lines to disable donations start-up message.
+#DEFINES += QTIPLOT_SUPPORT
+
+# Comment the next line, if you don't have libpng on your system.
+CONFIG += HAVE_LIBPNG
+
+# Uncomment the next line in order to enable export of 2D plots to the EMF file format on Windows. You need EmfEngine on your system.
+#CONFIG += HAVE_EMF
+
+# Uncomment the following line if you want to perform a custom installation using the *.path variables defined bellow.
+CONFIG += CustomInstall
+
+CONFIG += release
+#CONFIG += debug
+#win32: CONFIG += console
+
+##################### 3rd PARTY HEADER FILES SECTION ########################
+#!!! Warning: You must modify these paths according to your computer settings
+#############################################################################
+
+INCLUDEPATH += /usr/include
+INCLUDEPATH += ../3rdparty/qwtplot3d/include
+INCLUDEPATH += ../3rdparty/liborigin
+INCLUDEPATH += /usr/include/qwt
+INCLUDEPATH += /usr/include/gsl
+INCLUDEPATH += /usr/include/boost
+
+##################### 3rd PARTY LIBRARIES SECTION ###########################
+#!!! Warning: You must modify these paths according to your computer settings
+#############################################################################
+
+##################### Linux (Mac OS X) ######################################
+
+# statically link against libraries in 3rdparty
+#unix:LIBS += ../3rdparty/muparser/lib/libmuparser.a
+#unix:LIBS += ../3rdparty/qwt/lib/libqwt.a
+#unix:LIBS += ../3rdparty/gsl/lib/libgsl.a
+#unix:LIBS += ../3rdparty/gsl/lib/libgslcblas.a
+#unix:LIBS += ../3rdparty/boost_1_36_0/lib/libboost_date_time-gcc43-mt-1_36.a
+#unix:LIBS += ../3rdparty/boost_1_36_0/lib/libboost_thread-gcc43-mt-1_36.a
+
+# dynamically link against dependencies if they are installed system-wide
+unix:LIBS += -lmuparser -lqwt $$system(pkg-config --libs gsl) -lz -lboost_date_time -lboost_thread-mt
+
+##################### Windows ###############################################
+
+win32:LIBS += ../3rdparty/muparser/lib/libmuparser.a
+win32:LIBS += ../3rdparty/qwt/lib/libqwt.a
+win32:LIBS += ../3rdparty/gsl/lib/libgsl.a
+win32:LIBS += ../3rdparty/gsl/lib/libgslcblas.a
+win32:LIBS += ../3rdparty/zlib/libz.a
+win32:LIBS += ../3rdparty/boost_1_36_0/lib/libboost_date_time-mgw34-mt.lib
+win32:LIBS += ../3rdparty/boost_1_36_0/lib/libboost_thread-mgw34-mt.lib
+
+#############################################################################
+###################### BASIC PROJECT PROPERTIES #############################
+#############################################################################
+
+QMAKE_PROJECT_DEPTH = 0
+
+TARGET = qtiplot
+TEMPLATE = app
+CONFIG += qt warn_on exceptions opengl thread
+CONFIG += assistant
+
+DEFINES += QT_PLUGIN
+contains(CONFIG, CustomInstall){
+ INSTALLS += target
+ INSTALLS += translations
+ INSTALLS += manual
+ INSTALLS += documentation
+ unix:INSTALLS += man
+
+ unix: INSTALLBASE = /usr
+ win32: INSTALLBASE = C:/QtiPlot
+
+ unix: target.path = $$INSTALLBASE/bin
+ unix: translations.path = $$INSTALLBASE/share/qtiplot/translations
+ unix: manual.path = $$INSTALLBASE/share/doc/qtiplot/manual
+ unix: documentation.path = $$INSTALLBASE/share/doc/qtiplot
+ unix: man.path = $$INSTALLBASE/share/man/man1/
+
+ win32: target.path = $$INSTALLBASE
+ win32: translations.path = $$INSTALLBASE/translations
+ win32: manual.path = $$INSTALLBASE/manual
+ win32: documentation.path = $$INSTALLBASE/doc
+
+ DEFINES += TRANSLATIONS_PATH="\\\"$$replace(translations.path," ","\ ")\\\"
+ DEFINES += MANUAL_PATH="\\\"$$replace(manual.path," ","\ ")\\\"
+ }
+
+win32:DEFINES += QT_DLL QT_THREAD_SUPPORT
+QT += opengl qt3support network svg xml
+
+MOC_DIR = ../tmp/qtiplot
+OBJECTS_DIR = ../tmp/qtiplot
+SIP_DIR = ../tmp/qtiplot
+DESTDIR = ./
+
+#############################################################################
+###################### PROJECT FILES SECTION ################################
+#############################################################################
+
+###################### ICONS ################################################
+INCLUDEPATH += icons/
+HEADERS += icons/pixmaps.h
+HEADERS += icons/axes_icons.h
+win32:RC_FILE = icons/qtiplot.rc
+mac:RC_FILE = icons/qtiplot.icns
+
+###################### TRANSLATIONS #########################################
+
+TRANSLATIONS = translations/qtiplot_de.ts \
+ translations/qtiplot_es.ts \
+ translations/qtiplot_fr.ts \
+ #translations/qtiplot_pt.ts \
+ translations/qtiplot_ro.ts \
+ translations/qtiplot_ru.ts \
+ translations/qtiplot_ja.ts \
+ translations/qtiplot_sv.ts
+
+system(lupdate -verbose qtiplot.pro)
+system(lrelease -verbose qtiplot.pro)
+
+translations.files += translations/qtiplot_de.qm \
+ translations/qtiplot_es.qm \
+ translations/qtiplot_fr.qm \
+ #translations/qtiplot_pt.qm \
+ translations/qtiplot_ru.qm \
+ translations/qtiplot_ja.qm \
+ translations/qtiplot_sv.qm
+
+###################### DOCUMENTATION ########################################
+
+manual.files += ../manual/html \
+ ../manual/qtiplot-manual-en.pdf
+
+documentation.files += ../README.html \
+ ../gpl_licence.txt
+
+unix: man.files += ../qtiplot.1
+
+###############################################################
+##################### Compression (zlib-1.2.3) ################
+###############################################################
+
+SOURCES += ../3rdparty/zlib/minigzip.c
+
+###############################################################
+################# Default Modules #############################
+###############################################################
+
+include(../3rdparty/qwtplot3d/qwtplot3d.pri)
+include(src/analysis/analysis.pri)
+include(src/core/core.pri)
+include(src/lib/libqti.pri)
+include(src/plot2D/plot2D.pri)
+include(src/plot3D/plot3D.pri)
+include(src/matrix/matrix.pri)
+include(src/origin/origin.pri)
+include(src/table/table.pri)
+include(src/scripting/scripting.pri)
+
+###############################################################
+##################### Scripting: PYTHON + SIP + PyQT ##########
+###############################################################
+
+contains(SCRIPTING_LANGS, Python) {
+
+ contains(CONFIG, CustomInstall){
+ INSTALLS += pythonconfig
+ pythonconfig.files += qtiplotrc.py \
+ qtiUtil.py \
+ qti_wordlist.txt \
+
+ unix: pythonconfig.path = /usr/share/qtiplot
+ win32: pythonconfig.path = $$INSTALLBASE
+ DEFINES += PYTHON_CONFIG_PATH="\\\"$$replace(pythonconfig.path," ","\ ")\\\"
+ }
+
+ unix {
+ INCLUDEPATH += $$system(python python-includepath.py)
+ LIBS += $$system(python -c "\"from distutils import sysconfig; print '-lpython'+sysconfig.get_config_var('VERSION')\"")
+ LIBS += -lm
+ system(mkdir -p $${SIP_DIR})
+ system($$system(python python-sipcmd.py) -c $${SIP_DIR} src/scripting/qti.sip)
+ }
+
+ win32 {
+ INCLUDEPATH += $$system(call python-includepath.py)
+ LIBS += $$system(call python-libs-win.py)
+ system($$system(call python-sipcmd.py) -c $${SIP_DIR} src/scripting/qti.sip)
+ }
+}
+
+###############################################################
+
+contains(CONFIG, HAVE_LIBPNG){
+ DEFINES += GL2PS_HAVE_LIBPNG
+}
+
+###############################################################
+
+contains(CONFIG, HAVE_EMF){
+ win32 {
+ DEFINES += EMF_OUTPUT
+ INCLUDEPATH += ../3rdparty/EmfEngine/
+ HEADERS += ../3rdparty/EmfEngine/EmfEngine.h
+ SOURCES += ../3rdparty/EmfEngine/EmfEngine.cpp
+ }
+}
+
+###############################################################
Property changes on: qtiplot/trunk/qtiplot.pro.archlinux
___________________________________________________________________
Added: svn:executable
+ *
Added: qwtplot3d_gcc.patch
===================================================================
--- qwtplot3d_gcc.patch (rev 0)
+++ qwtplot3d_gcc.patch 2009-05-14 10:49:26 UTC (rev 39252)
@@ -0,0 +1,9 @@
+--- qwt3d_function.cpp.old 2009-05-10 17:21:41.757091214 +0200
++++ qwt3d_function.cpp 2009-05-10 17:21:00.747097116 +0200
+@@ -1,5 +1,6 @@
+ #include "qwt3d_surfaceplot.h"
+ #include "qwt3d_function.h"
++#include <cstdio>
+
+ using namespace Qwt3D;
+
Added: scriptedit.patch
===================================================================
--- scriptedit.patch (rev 0)
+++ scriptedit.patch 2009-05-14 10:49:26 UTC (rev 39252)
@@ -0,0 +1,427 @@
+--- ScriptEdit.cpp.bak 2009-05-13 23:14:51.109362860 +0200
++++ ScriptEdit.cpp 2009-05-13 23:14:58.482710429 +0200
+@@ -30,7 +30,7 @@
+ #include "Note.h"
+ #include "PythonSyntaxHighlighter.h"
+ #include "FindReplaceDialog.h"
+-#include <ApplicationWindow.h>
++#include <ApplicationWindow.h>
+
+ #include <QAction>
+ #include <QMenu>
+@@ -39,13 +39,13 @@
+ #include <QMessageBox>
+ #include <QFileDialog>
+ #include <QTextStream>
+-#include <QApplication>
+-#include <QCompleter>
++#include <QApplication>
++#include <QCompleter>
+ #include <QAbstractItemView>
+-#include <QScrollBar>
++#include <QScrollBar>
+ #include <QStringListModel>
+-#include <QShortcut>
+-#include <QDockWidget>
++#include <QShortcut>
++#include <QDockWidget>
+
+ ScriptEdit::ScriptEdit(ScriptingEnv *env, QWidget *parent, const char *name)
+ : QTextEdit(parent, name), scripted(env), d_error(false), d_completer(0),
+@@ -147,69 +147,69 @@
+ connect(myScript, SIGNAL(error(const QString&, const QString&, int)), this, SLOT(insertErrorMsg(const QString&)));
+ connect(myScript, SIGNAL(print(const QString&)), this, SLOT(scriptPrint(const QString&)));
+
+- #ifdef SCRIPTING_PYTHON
+- if (d_highlighter)
+- delete d_highlighter;
+-
+- if (scriptEnv->name() == QString("Python"))
+- d_highlighter = new PythonSyntaxHighlighter(this);
+- else
++ #ifdef SCRIPTING_PYTHON
++ if (d_highlighter)
++ delete d_highlighter;
++
++ if (scriptEnv->name() == QString("Python"))
++ d_highlighter = new PythonSyntaxHighlighter(this);
++ else
+ d_highlighter = 0;
+ #endif
+ }
+ }
+-
+-void ScriptEdit::focusInEvent(QFocusEvent *e)
+-{
+- if (d_completer)
+- d_completer->setWidget(this);
+- QTextEdit::focusInEvent(e);
+-}
++
++void ScriptEdit::focusInEvent(QFocusEvent *e)
++{
++ if (d_completer)
++ d_completer->setWidget(this);
++ QTextEdit::focusInEvent(e);
++}
+
+ void ScriptEdit::keyPressEvent(QKeyEvent *e)
+-{
+- if (d_completer && d_completer->popup()->isVisible()) {
+- // The following keys are forwarded by the completer to the widget
+- switch (e->key()) {
+- case Qt::Key_Enter:
+- case Qt::Key_Return:
+- case Qt::Key_Escape:
+- case Qt::Key_Tab:
+- case Qt::Key_Backtab:
+- e->ignore();
+- return; // let the completer do default behavior
+- default:
+- break;
+- }
+- }
+-
+- QTextEdit::keyPressEvent(e);
+- if (d_completer && !d_completer->popup()->isVisible() && e->key() == Qt::Key_Return)
+- updateIndentation();
+-
+- bool isShortcut = ((e->modifiers() & Qt::ControlModifier) && e->key() == Qt::Key_U); // CTRL+U
+- const bool ctrlOrShift = e->modifiers() & (Qt::ControlModifier | Qt::ShiftModifier);
+- if (!d_completer || (ctrlOrShift && e->text().isEmpty()))
+- return;
+-
+- static QString eow("~!@#$%^&*()_+{}|:\"<>?,./;'[]\\-="); // end of word
+- bool hasModifier = (e->modifiers() != Qt::NoModifier) && !ctrlOrShift;
+- QString completionPrefix = textUnderCursor();
+-
+- if (!isShortcut && (hasModifier || e->text().isEmpty()|| completionPrefix.length() < 2
+- || eow.contains(e->text().right(1)))) {
+- d_completer->popup()->hide();
+- return;
+- }
+-
+- if (completionPrefix != d_completer->completionPrefix()) {
+- d_completer->setCompletionPrefix(completionPrefix);
+- d_completer->popup()->setCurrentIndex(d_completer->completionModel()->index(0, 0));
+- }
+-
+- QRect cr = cursorRect();
+- cr.setWidth(d_completer->popup()->sizeHintForColumn(0)
+- + d_completer->popup()->verticalScrollBar()->sizeHint().width());
++{
++ if (d_completer && d_completer->popup()->isVisible()) {
++ // The following keys are forwarded by the completer to the widget
++ switch (e->key()) {
++ case Qt::Key_Enter:
++ case Qt::Key_Return:
++ case Qt::Key_Escape:
++ case Qt::Key_Tab:
++ case Qt::Key_Backtab:
++ e->ignore();
++ return; // let the completer do default behavior
++ default:
++ break;
++ }
++ }
++
++ QTextEdit::keyPressEvent(e);
++ if (d_completer && !d_completer->popup()->isVisible() && e->key() == Qt::Key_Return)
++ updateIndentation();
++
++ bool isShortcut = ((e->modifiers() & Qt::ControlModifier) && e->key() == Qt::Key_U); // CTRL+U
++ const bool ctrlOrShift = e->modifiers() & (Qt::ControlModifier | Qt::ShiftModifier);
++ if (!d_completer || (ctrlOrShift && e->text().isEmpty()))
++ return;
++
++ static QString eow("~!@#$%^&*()_+{}|:\"<>?,./;'[]\\-="); // end of word
++ bool hasModifier = (e->modifiers() != Qt::NoModifier) && !ctrlOrShift;
++ QString completionPrefix = textUnderCursor();
++
++ if (!isShortcut && (hasModifier || e->text().isEmpty()|| completionPrefix.length() < 2
++ || eow.contains(e->text().right(1)))) {
++ d_completer->popup()->hide();
++ return;
++ }
++
++ if (completionPrefix != d_completer->completionPrefix()) {
++ d_completer->setCompletionPrefix(completionPrefix);
++ d_completer->popup()->setCurrentIndex(d_completer->completionModel()->index(0, 0));
++ }
++
++ QRect cr = cursorRect();
++ cr.setWidth(d_completer->popup()->sizeHintForColumn(0)
++ + d_completer->popup()->verticalScrollBar()->sizeHint().width());
+ d_completer->complete(cr); // popup it up!
+ }
+
+@@ -285,20 +285,20 @@
+ {
+ QString err = message;
+ err.prepend("\n").replace("\n","\n#> ");
+-
+-#ifdef SCRIPTING_CONSOLE
+- QTextEdit *console = scriptEnv->application()->scriptingConsole();
+- console->setPlainText(err);
+- if (!console->isVisible())
+- ((QDockWidget *)console->parent())->show();
+-#elif
+- int start = printCursor.position();
+- printCursor.insertText(err);
+- printCursor.setPosition(start, QTextCursor::KeepAnchor);
+- setTextCursor(printCursor);
+-#endif
+
+- d_error = true;
++#ifdef SCRIPTING_CONSOLE
++ QTextEdit *console = scriptEnv->application()->scriptingConsole();
++ console->setPlainText(err);
++ if (!console->isVisible())
++ ((QDockWidget *)console->parent())->show();
++#else
++ int start = printCursor.position();
++ printCursor.insertText(err);
++ printCursor.setPosition(start, QTextCursor::KeepAnchor);
++ setTextCursor(printCursor);
++#endif
++
++ d_error = true;
+ d_err_message = message;
+ }
+
+@@ -339,8 +339,8 @@
+ }
+
+ void ScriptEdit::execute()
+-{
+- clearErrorHighlighting();
++{
++ clearErrorHighlighting();
+
+ QString fname = "<%1:%2>";
+ fname = fname.arg(name());
+@@ -348,7 +348,7 @@
+ if (codeCursor.selectedText().isEmpty()){
+ codeCursor.movePosition(QTextCursor::StartOfLine, QTextCursor::MoveAnchor);
+ codeCursor.movePosition(QTextCursor::EndOfLine, QTextCursor::KeepAnchor);
+- }
++ }
+ int startLineNumber = lineNumber(codeCursor.selectionStart());
+ fname = fname.arg(startLineNumber);
+
+@@ -363,8 +363,8 @@
+ }
+
+ void ScriptEdit::executeAll()
+-{
+- clearErrorHighlighting();
++{
++ clearErrorHighlighting();
+
+ QString fname = "<%1>";
+ fname = fname.arg(name());
+@@ -377,8 +377,8 @@
+ }
+
+ void ScriptEdit::evaluate()
+-{
+- clearErrorHighlighting();
++{
++ clearErrorHighlighting();
+
+ QString fname = "<%1:%2>";
+ fname = fname.arg(name());
+@@ -386,7 +386,7 @@
+ if (codeCursor.selectedText().isEmpty()){
+ codeCursor.movePosition(QTextCursor::StartOfLine, QTextCursor::MoveAnchor);
+ codeCursor.movePosition(QTextCursor::EndOfLine, QTextCursor::KeepAnchor);
+- }
++ }
+ int startLineNumber = lineNumber(codeCursor.selectionStart());
+ fname = fname.arg(startLineNumber);
+
+@@ -406,7 +406,7 @@
+ if (!strVal.isEmpty())
+ printCursor.insertText("#> " + strVal + "\n");
+ }
+-
++
+ highlightErrorLine(startLineNumber - 2);//we need to substract a line due to __doit__ line prepended to Python scripts.
+ d_error = false;
+ }
+@@ -463,16 +463,16 @@
+ clear();
+ QTextStream ts(&file);
+ ts.setEncoding(QTextStream::UnicodeUTF8);
+-
+- QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));
+- qApp->processEvents(QEventLoop::ExcludeUserInput);
+-
+- blockSignals(true);
+- insertPlainText(ts.readAll());
+- blockSignals(false);
+- textChanged();
+
+- file.close();
++ QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));
++ qApp->processEvents(QEventLoop::ExcludeUserInput);
++
++ blockSignals(true);
++ insertPlainText(ts.readAll());
++ blockSignals(false);
++ textChanged();
++
++ file.close();
+ QApplication::restoreOverrideCursor();
+ return f;
+ }
+@@ -555,40 +555,40 @@
+
+ scriptsDirPath = path;
+ }
+-
+- void ScriptEdit::setCompleter(QCompleter *completer)
+- {
+- if (d_completer)
+- QObject::disconnect(d_completer, 0, this, 0);
+-
+- d_completer = completer;
+-
+- if (!d_completer)
+- return;
+-
+- d_completer->setWidget(this);
+- QObject::connect(d_completer, SIGNAL(activated(const QString&)),
+- this, SLOT(insertCompletion(const QString&)));
+- }
+-
+- void ScriptEdit::insertCompletion(const QString& completion)
+- {
+- if (d_completer->widget() != this)
++
++ void ScriptEdit::setCompleter(QCompleter *completer)
++ {
++ if (d_completer)
++ QObject::disconnect(d_completer, 0, this, 0);
++
++ d_completer = completer;
++
++ if (!d_completer)
++ return;
++
++ d_completer->setWidget(this);
++ QObject::connect(d_completer, SIGNAL(activated(const QString&)),
++ this, SLOT(insertCompletion(const QString&)));
++ }
++
++ void ScriptEdit::insertCompletion(const QString& completion)
++ {
++ if (d_completer->widget() != this)
+ return;
+
+- QTextCursor tc = textCursor();
+- int extra = completion.length() - d_completer->completionPrefix().length();
+- tc.movePosition(QTextCursor::Left);
+- tc.movePosition(QTextCursor::EndOfWord);
+- tc.insertText(completion.right(extra));
+- setTextCursor(tc);
+- }
+-
+- QString ScriptEdit::textUnderCursor() const
+- {
+- QTextCursor tc = textCursor();
+- tc.select(QTextCursor::WordUnderCursor);
+- return tc.selectedText();
++ QTextCursor tc = textCursor();
++ int extra = completion.length() - d_completer->completionPrefix().length();
++ tc.movePosition(QTextCursor::Left);
++ tc.movePosition(QTextCursor::EndOfWord);
++ tc.insertText(completion.right(extra));
++ setTextCursor(tc);
++ }
++
++ QString ScriptEdit::textUnderCursor() const
++ {
++ QTextCursor tc = textCursor();
++ tc.select(QTextCursor::WordUnderCursor);
++ return tc.selectedText();
+ }
+
+
+@@ -660,41 +660,41 @@
+ else
+ showFindDialog();
+ }
+-
+-void ScriptEdit::clearErrorHighlighting()
+-{
+- QTextCursor codeCursor = textCursor();
+- codeCursor.movePosition(QTextCursor::Start, QTextCursor::MoveAnchor);
+- codeCursor.movePosition(QTextCursor::End, QTextCursor::KeepAnchor);
+- codeCursor.mergeBlockFormat(d_fmt_default);
+-}
+-
+-void ScriptEdit::highlightErrorLine(int offset)
+-{
+- if (!d_error)
+- return;
+-
+- QTextCursor codeCursor = textCursor();
+- codeCursor.movePosition(QTextCursor::Start, QTextCursor::MoveAnchor);
+-
+- if (scriptEnv->name() == QString("Python")){
+- QRegExp rx("<*>:(\\d+)");
+- rx.indexIn(d_err_message);
+- QStringList list = rx.capturedTexts();
+- int lineNumber = 0;
+- if (!list.isEmpty())
+- lineNumber = list.last().toInt();
+-
+- codeCursor.movePosition(QTextCursor::Down, QTextCursor::MoveAnchor, offset + lineNumber - 1);
+- codeCursor.movePosition(QTextCursor::EndOfLine, QTextCursor::KeepAnchor);
+- } else
+- codeCursor.movePosition(QTextCursor::End, QTextCursor::KeepAnchor);
+-
+- QTextBlockFormat d_fmt_failure;
+- d_fmt_failure.setBackground(QBrush(QColor(255,128,128)));
+- codeCursor.mergeBlockFormat(d_fmt_failure);
+- setTextCursor(codeCursor);
+-}
++
++void ScriptEdit::clearErrorHighlighting()
++{
++ QTextCursor codeCursor = textCursor();
++ codeCursor.movePosition(QTextCursor::Start, QTextCursor::MoveAnchor);
++ codeCursor.movePosition(QTextCursor::End, QTextCursor::KeepAnchor);
++ codeCursor.mergeBlockFormat(d_fmt_default);
++}
++
++void ScriptEdit::highlightErrorLine(int offset)
++{
++ if (!d_error)
++ return;
++
++ QTextCursor codeCursor = textCursor();
++ codeCursor.movePosition(QTextCursor::Start, QTextCursor::MoveAnchor);
++
++ if (scriptEnv->name() == QString("Python")){
++ QRegExp rx("<*>:(\\d+)");
++ rx.indexIn(d_err_message);
++ QStringList list = rx.capturedTexts();
++ int lineNumber = 0;
++ if (!list.isEmpty())
++ lineNumber = list.last().toInt();
++
++ codeCursor.movePosition(QTextCursor::Down, QTextCursor::MoveAnchor, offset + lineNumber - 1);
++ codeCursor.movePosition(QTextCursor::EndOfLine, QTextCursor::KeepAnchor);
++ } else
++ codeCursor.movePosition(QTextCursor::End, QTextCursor::KeepAnchor);
++
++ QTextBlockFormat d_fmt_failure;
++ d_fmt_failure.setBackground(QBrush(QColor(255,128,128)));
++ codeCursor.mergeBlockFormat(d_fmt_failure);
++ setTextCursor(codeCursor);
++}
+
+ ScriptEdit::~ScriptEdit()
+ {
More information about the arch-commits
mailing list