17 |
17 |
18 from PyQt4.QtCore import QFile, QFileInfo, pyqtSignal, QCryptographicHash, QIODevice, \ |
18 from PyQt4.QtCore import QFile, QFileInfo, pyqtSignal, QCryptographicHash, QIODevice, \ |
19 QByteArray, QObject, Qt |
19 QByteArray, QObject, Qt |
20 from PyQt4.QtGui import QCursor, QLineEdit, QToolBar, QDialog, QInputDialog, \ |
20 from PyQt4.QtGui import QCursor, QLineEdit, QToolBar, QDialog, QInputDialog, \ |
21 QApplication, QMenu, QAction |
21 QApplication, QMenu, QAction |
|
22 from PyQt4.Qsci import QsciScintilla |
22 |
23 |
23 from E5Gui.E5Application import e5App |
24 from E5Gui.E5Application import e5App |
24 from E5Gui import E5FileDialog, E5MessageBox |
25 from E5Gui import E5FileDialog, E5MessageBox |
25 |
26 |
26 from Globals import recentNameProject |
27 from Globals import recentNameProject |
399 self.pdata["PROJECTTYPESPECIFICDATA"] = {} |
400 self.pdata["PROJECTTYPESPECIFICDATA"] = {} |
400 self.pdata["CHECKERSPARMS"] = {} |
401 self.pdata["CHECKERSPARMS"] = {} |
401 self.pdata["PACKAGERSPARMS"] = {} |
402 self.pdata["PACKAGERSPARMS"] = {} |
402 self.pdata["DOCUMENTATIONPARMS"] = {} |
403 self.pdata["DOCUMENTATIONPARMS"] = {} |
403 self.pdata["OTHERTOOLSPARMS"] = {} |
404 self.pdata["OTHERTOOLSPARMS"] = {} |
404 self.pdata["EOL"] = [0] |
405 self.pdata["EOL"] = [-1] |
405 |
406 |
406 self.__initDebugProperties() |
407 self.__initDebugProperties() |
407 |
408 |
408 self.pudata = {} |
409 self.pudata = {} |
409 for key in self.__class__.userKeynames: |
410 for key in self.__class__.userKeynames: |
2967 """ |
2968 """ |
2968 Public method to get the EOL-string to be used by the project. |
2969 Public method to get the EOL-string to be used by the project. |
2969 |
2970 |
2970 @return eol string (string) |
2971 @return eol string (string) |
2971 """ |
2972 """ |
2972 return self.eols[self.pdata["EOL"][0]] |
2973 if self.pdata["EOL"][0] >= 0: |
|
2974 return self.eols[self.pdata["EOL"][0]] |
|
2975 else: |
|
2976 eolMode = Preferences.getEditor("EOLMode") |
|
2977 if eolMode == QsciScintilla.EolWindows: |
|
2978 eol = '\r\n' |
|
2979 elif eolMode == QsciScintilla.EolUnix: |
|
2980 eol = '\n' |
|
2981 elif eolMode == QsciScintilla.EolMac: |
|
2982 eol = '\r' |
|
2983 else: |
|
2984 eol = os.linesep |
|
2985 return eol |
2973 |
2986 |
2974 def useSystemEol(self): |
2987 def useSystemEol(self): |
2975 """ |
2988 """ |
2976 Public method to check, if the project uses the system eol setting. |
2989 Public method to check, if the project uses the system eol setting. |
2977 |
2990 |