39 class ExtProgramToolset : public Toolset |
39 class ExtProgramToolset : public Toolset |
40 { |
40 { |
41 Q_OBJECT |
41 Q_OBJECT |
42 |
42 |
43 public: |
43 public: |
44 ExtProgramToolset (MainWindow* parent); |
44 ExtProgramToolset(MainWindow* parent); |
45 |
45 |
46 Q_INVOKABLE void coverer(); |
46 Q_INVOKABLE void coverer(); |
47 Q_INVOKABLE void edger2(); |
47 Q_INVOKABLE void edger2(); |
48 Q_INVOKABLE void intersector(); |
48 Q_INVOKABLE void intersector(); |
49 Q_INVOKABLE void isecalc(); |
49 Q_INVOKABLE void isecalc(); |
50 Q_INVOKABLE void rectifier(); |
50 Q_INVOKABLE void rectifier(); |
51 Q_INVOKABLE void ytruder(); |
51 Q_INVOKABLE void ytruder(); |
52 |
52 |
53 bool programUsesWine (ExtProgramType program); |
53 bool programUsesWine(ExtProgramType program); |
54 QString externalProgramName (ExtProgramType program); |
54 QString externalProgramName(ExtProgramType program); |
55 QString getPathSetting (ExtProgramType program); |
55 QString getPathSetting(ExtProgramType program); |
56 bool getWineSetting (ExtProgramType program); |
56 bool getWineSetting(ExtProgramType program); |
57 void setPathSetting (ExtProgramType program, QString value); |
57 void setPathSetting(ExtProgramType program, QString value); |
58 void setWineSetting (ExtProgramType program, bool value); |
58 void setWineSetting(ExtProgramType program, bool value); |
59 |
59 |
60 private: |
60 private: |
61 bool checkExtProgramPath(ExtProgramType program); |
61 bool checkExtProgramPath(ExtProgramType program); |
62 bool makeTempFile (class QTemporaryFile& tmp, QString& fname); |
62 bool makeTempFile(class QTemporaryFile& tmp, QString& fname); |
63 bool runExtProgram (ExtProgramType prog, QString argvstr); |
63 bool runExtProgram(ExtProgramType prog, QString argvstr); |
64 QString errorCodeString (ExtProgramType program, class QProcess& process); |
64 QString errorCodeString(ExtProgramType program, class QProcess& process); |
65 void insertOutput (QString fname, bool replace, QList<LDColor> colorsToReplace); |
65 void insertOutput(QString fname, bool replace, QList<LDColor> colorsToReplace); |
66 void writeColorGroup (LDColor color, QString fname); |
66 void writeColorGroup(LDColor color, QString fname); |
67 void writeObjects (const LDObjectList& objects, QFile& f); |
67 void writeObjects(const LDObjectList& objects, QFile& f); |
68 void writeObjects (const LDObjectList& objects, QString fname); |
68 void writeObjects(const LDObjectList& objects, QString fname); |
69 void writeSelection (QString fname); |
69 void writeSelection(QString fname); |
70 |
70 |
71 ExtProgramInfo extProgramInfo[NumExternalPrograms]; |
71 ExtProgramInfo extProgramInfo[NumExternalPrograms]; |
72 }; |
72 }; |