##// END OF EJS Templates
pyqt4 verification
José Chávez -
r1102:6934ad3ac023
parent child
Show More
@@ -11,7 +11,6 Install system dependencies, clone the latest version from [git](http://jro-dev.
11 ### Linux based system
11 ### Linux based system
12 ```
12 ```
13 $ sudo apt-get install python-pip python-dev gfortran libpng-dev freetype* libblas-dev liblapack-dev libatlas-base-dev python-qt4 python-tk libssl-dev libhdf5-dev
13 $ sudo apt-get install python-pip python-dev gfortran libpng-dev freetype* libblas-dev liblapack-dev libatlas-base-dev python-qt4 python-tk libssl-dev libhdf5-dev
14 $ sudo pip install numpy
15 $ git clone http://jro-dev.igp.gob.pe/rhodecode/schain/
14 $ git clone http://jro-dev.igp.gob.pe/rhodecode/schain/
16 $ cd schain
15 $ cd schain
17 $ sudo pip install ./
16 $ sudo pip install ./
@@ -40,6 +39,13 if ```pip install ./``` does not work, install a proper python enviroment, and r
40 $ brew install python
39 $ brew install python
41 ```
40 ```
42
41
42 ### GUI Installation
43
44 ```
45 $ sudo apt-get install python-pip python-dev gfortran libpng-dev freetype* libblas-dev liblapack-dev libatlas-base-dev python-qt4 python-tk libssl-dev libhdf5-dev
46 $ (virtual) bash link_PyQt4.sh
47 ```
48
43
49
44 ## First Script
50 ## First Script
45
51
@@ -1,12 +1,22
1 #!/usr/bin/env python
1 #!/usr/bin/env python
2 import os, sys
2 import os
3 import sys
4 from schainpy.utils import log
5
6 try:
3 from PyQt4 import QtCore, QtGui
7 from PyQt4 import QtCore, QtGui
4 from PyQt4.QtGui import QApplication
8 from PyQt4.QtGui import QApplication
9 except:
10 log.error(
11 'You should install PtQt4 module in order to run the GUI. See the README.')
12 sys.exit()
13
5
14
6 from schainpy.gui.viewcontroller.initwindow import InitWindow
15 from schainpy.gui.viewcontroller.initwindow import InitWindow
7 from schainpy.gui.viewcontroller.basicwindow import BasicWindow
16 from schainpy.gui.viewcontroller.basicwindow import BasicWindow
8 from schainpy.gui.viewcontroller.workspace import Workspace
17 from schainpy.gui.viewcontroller.workspace import Workspace
9
18
19
10 def main():
20 def main():
11
21
12 app = QtGui.QApplication(sys.argv)
22 app = QtGui.QApplication(sys.argv)
@@ -25,5 +35,6 def main():
25 MainGUI.show()
35 MainGUI.show()
26 sys.exit(app.exec_())
36 sys.exit(app.exec_())
27
37
38
28 if __name__ == "__main__":
39 if __name__ == "__main__":
29 main()
40 main()
@@ -4,9 +4,11 Created on Jul 16, 2014
4 @author: Miguel Urco
4 @author: Miguel Urco
5 '''
5 '''
6
6
7 import os
7 from setuptools import setup, Extension
8 from setuptools import setup, Extension
8 from setuptools.command.build_ext import build_ext as _build_ext
9 from setuptools.command.build_ext import build_ext as _build_ext
9 from schainpy import __version__
10 from schainpy import __version__
11 from schainpy.utils import log
10
12
11
13
12 class build_ext(_build_ext):
14 class build_ext(_build_ext):
@@ -18,6 +20,14 class build_ext(_build_ext):
18 self.include_dirs.append(numpy.get_include())
20 self.include_dirs.append(numpy.get_include())
19
21
20
22
23 try:
24 from PyQt4 import QtCore, QtGui
25 from PyQt4.QtGui import QApplication
26 except:
27 log.warning(
28 'You should install PtQt4 module in order to run the GUI. See the README.')
29
30
21 setup(name="schainpy",
31 setup(name="schainpy",
22 version=__version__,
32 version=__version__,
23 description="Python tools to read, write and process Jicamarca data",
33 description="Python tools to read, write and process Jicamarca data",
General Comments 0
You need to be logged in to leave comments. Login now