diff --git a/CadQuery/InitGui.py b/CadQuery/InitGui.py index 75649a5..b39d1b5 100644 --- a/CadQuery/InitGui.py +++ b/CadQuery/InitGui.py @@ -33,7 +33,6 @@ class CadQueryWorkbench (Workbench): def Activated(self): import os, sys - from PySide import QtGui, QtCore import module_locator from Gui import ImportCQ @@ -41,10 +40,12 @@ class CadQueryWorkbench (Workbench): module_base_path = module_locator.module_path() libs_dir_path = os.path.join(module_base_path, 'Libs') libs_path = os.path.join(libs_dir_path, 'libs.zip') + sys.path.insert(0, os.path.join(libs_dir_path, 'cadquery')) sys.path.insert(0, libs_path) import cadquery from pyqode.python.widgets import PyCodeEdit + from PySide import QtGui, QtCore msg = QtGui.QApplication.translate( "cqCodeWidget", diff --git a/CadQuery/Libs/libs.zip b/CadQuery/Libs/libs.zip index 3c664bb..5e7b639 100644 Binary files a/CadQuery/Libs/libs.zip and b/CadQuery/Libs/libs.zip differ diff --git a/CadQuery/Tools/package_libraries.py b/CadQuery/Tools/package_libraries.py index a2f3ee6..885f95f 100644 --- a/CadQuery/Tools/package_libraries.py +++ b/CadQuery/Tools/package_libraries.py @@ -13,10 +13,10 @@ ZIP = os.path.join(os.getcwd(), 'libs.zip') if len(sys.argv) == 2 and sys.argv[1] == 'gen': #--- gen zip file import jedi, pep8, pyqode, pyqode.core, pyqode.python, pyqode.qt, pygments, frosted, pies, builtins, future, \ - docutils, cadquery + docutils from qidle.system import embed_package_into_zip embed_package_into_zip([jedi, pep8, pyqode, pyqode.core, pyqode.python, - pyqode.qt, pygments, frosted, pies, builtins, future, docutils, cadquery], ZIP) + pyqode.qt, pygments, frosted, pies, builtins, future, docutils], ZIP) else: # remove all pyqode path from sys.path (to make sure the package are # imported from the zip archive)