| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
#ifndef WINDOW_H |
| 20 |
#define WINDOW_H |
| 21 |
#include <locale.h> |
| 22 |
#include <QtGui> |
| 23 |
#include <QtNetwork> |
| 24 |
#include "chgl.h" |
| 25 |
#include "codeeditor.h" |
| 26 |
#include "qpeakview.h" |
| 27 |
#include "psewidget.h" |
| 28 |
#include "historywidget.h" |
| 29 |
#include "fourxle.h" |
| 30 |
#include "itsme.h" |
| 31 |
#include "opengltestwidget.h" |
| 32 |
#ifndef nullptr |
| 33 |
#define nullptr NULL |
| 34 |
#endif |
| 35 |
#if defined _MSC_VER && _MSC_VER == 1500 |
| 36 |
#ifndef fmin |
| 37 |
#define fmin(x, y) (((x) < (y)) ? (x) : (y)) |
| 38 |
#endif |
| 39 |
#define round(x) (x<0?ceil((x)-0.5):floor((x)+0.5)) |
| 40 |
#endif |
| 41 |
#undef vc7hack1 |
| 42 |
#ifdef _MSC_VER |
| 43 |
#include <float.h> |
| 44 |
#define std_isfinite _finite |
| 45 |
#define vc7hack1 1 |
| 46 |
#else |
| 47 |
#define std_isfinite std::isfinite |
| 48 |
#endif |
| 49 |
|
| 50 |
#ifndef FONTFAM |
| 51 |
#if defined Q_WS_WIN || defined Q_OS_WIN |
| 52 |
#define FONTFAM "Droid Sans Mono" |
| 53 |
#elif defined Q_WS_MAC || defined Q_OS_MAC |
| 54 |
#define FONTFAM "Monaco" |
| 55 |
#else |
| 56 |
#define FONTFAM "Droid Sans Mono" |
| 57 |
#endif |
| 58 |
#endif |
| 59 |
|
| 60 |
#include "calculator.h" |
| 61 |
#include "dsrgui.h" |
| 62 |
#include "listfile.h" |
| 63 |
#define SX_LINE_LENGTH 80 |
| 64 |
|
| 65 |
|
| 66 |
|
| 67 |
|
| 68 |
|
| 69 |
class Window : public QMainWindow { |
| 70 |
Q_OBJECT |
| 71 |
public: |
| 72 |
|
| 73 |
Window(PlayOpenGL *_chgl=nullptr); |
| 74 |
virtual ~Window(); |
| 75 |
|
| 76 |
static int Version(); |
| 77 |
QString theIconPath; |
| 78 |
QString CurrentCellString; |
| 79 |
bool restraintsOrConstraints(); |
| 80 |
int MaxNumberOfPeaks; |
| 81 |
int wght_max_cycls; |
| 82 |
static QString programName(){return QString(PROGRAM_NAME);} |
| 83 |
|
| 84 |
PlayOpenGL *chgl = nullptr; |
| 85 |
PlayOpenGL *ogl; |
| 86 |
OpenGLTestWidget *tgl = nullptr; |
| 87 |
QTextEdit *extraOutPut; |
| 88 |
CodeEditor *editor; |
| 89 |
CodeEditor *xlPutor; |
| 90 |
QSettings *einstellung; |
| 91 |
#if (QT_VERSION >=0x050000) |
| 92 |
QScreen *screen; |
| 93 |
#endif |
| 94 |
QDockWidget *dock, *renamDock, *qPeakDock, *histDock; |
| 95 |
QDockWidget *shxEditorDock,*shxOutputDock,*infotainmentDock; |
| 96 |
QAction *enterRenameMode; |
| 97 |
QAction *showQPeakLegend; |
| 98 |
QAction *openAct; |
| 99 |
QAction *screenshotAct; |
| 100 |
QAction *objExport; |
| 101 |
QAction *separateLabelFile; |
| 102 |
|
| 103 |
QAction *belocube; |
| 104 |
QAction *actionUniq; |
| 105 |
QAction *actionSearch; |
| 106 |
QAction *actionNext; |
| 107 |
QAction *actionPrev; |
| 108 |
QAction *actionSave; |
| 109 |
QAction *actionSaveAs; |
| 110 |
QAction *actionUndo; |
| 111 |
QAction *actionRedo; |
| 112 |
QAction *actionCut; |
| 113 |
QAction *actionCopy; |
| 114 |
QAction *actionPaste; |
| 115 |
QAction *actionQPeakLimit; |
| 116 |
QAction *actionHFix; |
| 117 |
QAction *wghtRefineAct; |
| 118 |
QAction *actionEP; |
| 119 |
QAction *actionEM; |
| 120 |
QAction *togAtom; |
| 121 |
QAction *togBond; |
| 122 |
QAction *togLabel; |
| 123 |
|
| 124 |
|
| 125 |
|
| 126 |
QAction *togBackGr; |
| 127 |
QAction *togDepthCueing; |
| 128 |
QAction *actionPovRay; |
| 129 |
QAction *actionExportCC; |
| 130 |
QAction *killQs; |
| 131 |
QAction *killHs; |
| 132 |
QAction *astdlg; |
| 133 |
QAction *equivHighlighting; |
| 134 |
QAction *wghtAct; |
| 135 |
QAction *sinaAct; |
| 136 |
QAction *squeezeAct; |
| 137 |
QAction *recalcSDM; |
| 138 |
QAction *renamUpdateAct; |
| 139 |
QAction *cntrPlot; |
| 140 |
QAction *useNativeDlg; |
| 141 |
QAction *darkTheme; |
| 142 |
QAction *switch2HKLF5; |
| 143 |
QAction *switch2HKLF4; |
| 144 |
QAction *symmElementsAct; |
| 145 |
QTextBrowser *brs; |
| 146 |
QProcess *runffmpeg; |
| 147 |
QLineEdit *ffmpegedt,*mp4file; |
| 148 |
QString fffn; |
| 149 |
QLabel *ffl; |
| 150 |
QString oldFileName; |
| 151 |
QProgressBar *bar; |
| 152 |
QPushButton *closeFF ; |
| 153 |
QDialog *extraOutput; |
| 154 |
|
| 155 |
QToolBar *editToolBar, |
| 156 |
*refineToolBar, |
| 157 |
*bottomToolBar, |
| 158 |
*fito, |
| 159 |
*vito, |
| 160 |
*extraTB; |
| 161 |
QMenu *runMenu; |
| 162 |
QMenu *fileMenu, |
| 163 |
*editMenu, |
| 164 |
*dialogMenu, |
| 165 |
*viewMenu, |
| 166 |
*packMenu, |
| 167 |
*extraMenu; |
| 168 |
|
| 169 |
QCheckBox *qGrowPeak; |
| 170 |
QCheckBox *search4duplicates; |
| 171 |
QToolButton *zoomIn; |
| 172 |
QToolButton *zoomOut; |
| 173 |
QToolButton *homeMe; |
| 174 |
QToolButton *quickReLoadButton; |
| 175 |
QSpinBox *lodsp; |
| 176 |
QCheckBox *sr_same; |
| 177 |
QCheckBox *sr_simu; |
| 178 |
QCheckBox *sr_rigu; |
| 179 |
QCheckBox *sr_alter_name; |
| 180 |
QCheckBox *sr_ExyzAadp_ifclose; |
| 181 |
bool notRefine; |
| 182 |
bool shaderInfo = false; |
| 183 |
int tbiconSize; |
| 184 |
QHash<QString,QVariant> myHash; |
| 185 |
QAction *refineAct; |
| 186 |
QAction *refineActAnis; |
| 187 |
QAction *refineActActa; |
| 188 |
QAction *refineActExti; |
| 189 |
QAction *refineActConf; |
| 190 |
QAction *clearVoro; |
| 191 |
FourXle *fxle; |
| 192 |
|
| 193 |
|
| 194 |
|
| 195 |
|
| 196 |
|
| 197 |
QList<double> fvar; |
| 198 |
QMap<int,int> fvarCntr; |
| 199 |
bool isLabelInUse(); |
| 200 |
QString dirName; |
| 201 |
QString lastDirName; |
| 202 |
QString actionInfo; |
| 203 |
void setFocus(bool b){focusSet=b;} |
| 204 |
bool isFocusSet() {return focusSet;} |
| 205 |
int getFvarCntr(int fvar); |
| 206 |
int getFvarNr(double v, const QList<double> fv); |
| 207 |
int firstAtomLine; |
| 208 |
int extraIndex; |
| 209 |
bool finWasPressed; |
| 210 |
QAction *ydleStart; |
| 211 |
QAction *ydleStop; |
| 212 |
QSpinBox *lpart; |
| 213 |
QSpinBox *rpart; |
| 214 |
bool canWeSqueeze(); |
| 215 |
int cifCheckSum(const QString &block); |
| 216 |
|
| 217 |
const QRegularExpression buchstaben = QRegularExpression("[A-Za-z]"); |
| 218 |
const QRegularExpression vorneweg = QRegularExpression("[^A-Za-z']+"); |
| 219 |
const QRegularExpression resorins = QRegularExpression("(.res$)|(.ins$)", QRegularExpression::CaseInsensitiveOption); |
| 220 |
const QRegularExpression punkthkl = QRegularExpression(".hkl$",QRegularExpression::CaseInsensitiveOption); |
| 221 |
const QRegularExpression unitinst = QRegularExpression("^UNIT",QRegularExpression::CaseInsensitiveOption); |
| 222 |
const QRegularExpression punktres = QRegularExpression(".res$", QRegularExpression::CaseInsensitiveOption); |
| 223 |
const QRegularExpression punktins = QRegularExpression(".ins$",QRegularExpression::CaseInsensitiveOption); |
| 224 |
const QRegularExpression punktpov = QRegularExpression("(.pov)",QRegularExpression::CaseInsensitiveOption); |
| 225 |
const QRegularExpression leer = QRegularExpression("\\s+"); |
| 226 |
const QRegularExpression numbers = QRegularExpression("\\d+"); |
| 227 |
const QRegularExpression startnumbers = QRegularExpression("^[0-9]+"); |
| 228 |
|
| 229 |
const QRegularExpression nonumbers = QRegularExpression("\\D+"); |
| 230 |
const QRegularExpression commaspace = QRegularExpression(", $"); |
| 231 |
|
| 232 |
|
| 233 |
signals: |
| 234 |
void fileLoaded(void); |
| 235 |
void pipeStatus(const QString& s); |
| 236 |
void movedByUser(); |
| 237 |
|
| 238 |
public slots: |
| 239 |
void loadMolInTest(bool fromloadref=false); |
| 240 |
void qinitres(); |
| 241 |
void addNewScatteringFactor(int oz, bool HisD); |
| 242 |
void addDissorderedMethyl(); |
| 243 |
void addMethyl(); |
| 244 |
void addHydroxyl(); |
| 245 |
void addH43(); |
| 246 |
void addH23(); |
| 247 |
void addH93(); |
| 248 |
void addH163(); |
| 249 |
void addHnonplanarAminR2(); |
| 250 |
void addHnonplanarAminR1(); |
| 251 |
void addMoreQPeaks(); |
| 252 |
void adoptEditToolBar(bool b); |
| 253 |
void aula(); |
| 254 |
void autoHFix(); |
| 255 |
void brwsIcon(); |
| 256 |
void changeFixes(int i); |
| 257 |
void changeEditorFont(); |
| 258 |
void changeElemetofLabel(const QString &pse); |
| 259 |
void changeElement(); |
| 260 |
void changeSelectedElements(); |
| 261 |
void changeIconSize(); |
| 262 |
void changeInvRad(double r); |
| 263 |
void changePlaneTransparence(double t); |
| 264 |
void changeglideVectorThickness(double t); |
| 265 |
void changeaxisThickness(double t); |
| 266 |
void changeplaneFrameThinkness(double t); |
| 267 |
|
| 268 |
void changeQPeakLimit(); |
| 269 |
void changeIndexofLabel(const int i); |
| 270 |
void changeLabelFont(); |
| 271 |
void changeResiPart(); |
| 272 |
void changeScalefactor(); |
| 273 |
void changeSuffixofLabel(int); |
| 274 |
void checkForUpdates(); |
| 275 |
void clipboardDataChanged(); |
| 276 |
void clearStructure(); |
| 277 |
void closeEvent(QCloseEvent *event); |
| 278 |
void configBeLos(); |
| 279 |
void connectEdior(); |
| 280 |
void darkEdit(); |
| 281 |
void brwsEPS(); |
| 282 |
void everyPointOne(); |
| 283 |
void everyAIM(); |
| 284 |
void contourPlot(); |
| 285 |
void nocontourPlot(); |
| 286 |
void delayedLoad(); |
| 287 |
void colorButtonDialog(); |
| 288 |
void convergeWght(); |
| 289 |
bool compareWGHTS(QString w1, QString w2, double &diff, double tolerance = 0.001); |
| 290 |
void complete(); |
| 291 |
void configureBottomToolbar(); |
| 292 |
void copySymmMate(); |
| 293 |
void createCentroid(); |
| 294 |
void deleteAllH(); |
| 295 |
void deleteAllQ(); |
| 296 |
void deleteSelectedAtoms(); |
| 297 |
void displayResiduals(XLOutputParser &lfo, QString s); |
| 298 |
int duplicates(); |
| 299 |
void editorIsVisible(bool); |
| 300 |
void effuenf(); |
| 301 |
void expandAll(); |
| 302 |
void extraSettings(); |
| 303 |
void extraSettingsLast(); |
| 304 |
void exportCoordinates(); |
| 305 |
void exportCC(); |
| 306 |
void exportFMaps(); |
| 307 |
void fileNative(); |
| 308 |
bool fileSave(bool spell=true, bool loadafter=true); |
| 309 |
bool fileSaveAs(); |
| 310 |
void fileSave4hklf5(); |
| 311 |
void fillCell(); |
| 312 |
void showSearch(); |
| 313 |
void findNext(); |
| 314 |
void findPrev(); |
| 315 |
void findInStructure(const QString &info); |
| 316 |
void openIncludeFile(const QString &info); |
| 317 |
void finXL(); |
| 318 |
void fixIt(); |
| 319 |
void foversusfc(); |
| 320 |
void fuse(); |
| 321 |
void go2hklf5(); |
| 322 |
void go2hklf4(); |
| 323 |
void grossRC(const QString &text); |
| 324 |
void grow(); |
| 325 |
void grow_plus(); |
| 326 |
void growQPeaks(bool qpg); |
| 327 |
void hereAreMyKeys(); |
| 328 |
void hideToolz(bool b); |
| 329 |
void hintLhide(); |
| 330 |
void idleRotStart(); |
| 331 |
void idleRotStop(); |
| 332 |
void incResiNr(); |
| 333 |
void decResiNr(); |
| 334 |
void infoKanalNews(const QString& s); |
| 335 |
void inheritLabels(); |
| 336 |
void insertSADI(int selected); |
| 337 |
void insertTwin(); |
| 338 |
void invert(); |
| 339 |
|
| 340 |
void isUpToDate(QNetworkReply* antwort); |
| 341 |
void jnk(); |
| 342 |
void jumpToAtom(int index); |
| 343 |
void linkHelp(); |
| 344 |
void loadAFile(); |
| 345 |
void loadFile(QString fileName, bool fromloadref=false); |
| 346 |
void load_sheldrick(QString fileName, QString &inhalt); |
| 347 |
bool quickReLoad(QString fn, QString &cont); |
| 348 |
void loadLst(); |
| 349 |
void loadrefres(); |
| 350 |
void loadThisFile(); |
| 351 |
void makeItHKLF5(); |
| 352 |
void makeVoro(); |
| 353 |
void clearVoros(); |
| 354 |
void moveSymmMate(); |
| 355 |
void moveSymmMateSel(); |
| 356 |
void obj(); |
| 357 |
void omitRfl(); |
| 358 |
void openFile(); |
| 359 |
void openRecentFile(); |
| 360 |
void openSaveHistory(); |
| 361 |
void outputIsVisible(bool); |
| 362 |
void packInLimits(); |
| 363 |
|
| 364 |
void raiseTaff(); |
| 365 |
void raiseTaz(); |
| 366 |
void redoRename(); |
| 367 |
void removeExtra(QAbstractButton *button); |
| 368 |
void renameRNchanged(int ii); |
| 369 |
void renameThisAtom(); |
| 370 |
void renameThisAtom(int index); |
| 371 |
void rename2ThisAtom(int index); |
| 372 |
void renamUpdate(bool vis); |
| 373 |
void replyFinished(QNetworkReply* antwort); |
| 374 |
void resiSelectorCheck(); |
| 375 |
void rotd(); |
| 376 |
void rotl(); |
| 377 |
void rotr(); |
| 378 |
void rotu(); |
| 379 |
void rufmode(); |
| 380 |
void runShelXL(); |
| 381 |
void runExtra(); |
| 382 |
void runSqueeze(); |
| 383 |
void runXLWGHT(); |
| 384 |
|
| 385 |
void saveScene(); |
| 386 |
void savePovRay(); |
| 387 |
void savePovInc(QString povName); |
| 388 |
void sdm(); |
| 389 |
void selectInStructure(const QString &info); |
| 390 |
void setCalculatorsCurrentCell(); |
| 391 |
void shredCIF(); |
| 392 |
void selectParts(); |
| 393 |
void setShelxlOptions(); |
| 394 |
void setShelxlPath(); |
| 395 |
void setExtraPath(); |
| 396 |
void setDefaultPath(); |
| 397 |
void selOmitG5(); |
| 398 |
void selOmitG10(); |
| 399 |
void updateExtraIcon(); |
| 400 |
void sColorDLG(); |
| 401 |
void setSDMLimit(); |
| 402 |
void setMaxWGHTCycls(); |
| 403 |
void setMonoQ(bool vis); |
| 404 |
void shxActUpdate(bool vis); |
| 405 |
void shxOPTUpdate(bool vis); |
| 406 |
void sina(); |
| 407 |
|
| 408 |
void testOGL(); |
| 409 |
void spellCheck(); |
| 410 |
void closeSR(bool vis); |
| 411 |
void splitRotate(); |
| 412 |
QString strippedName(const QString &fullFileName); |
| 413 |
void styleDialog(); |
| 414 |
void symmElements(bool b); |
| 415 |
void symmetryManager(); |
| 416 |
void testMerohedral(); |
| 417 |
void toggDocWid(bool weg); |
| 418 |
void toggleEQHighlighting(bool); |
| 419 |
void toggleFullScreen(); |
| 420 |
void toggleHFSAO(bool on); |
| 421 |
void togOMIT(bool b); |
| 422 |
void togSop(bool b); |
| 423 |
void togSel(bool b); |
| 424 |
void toggleOrtho(bool ov); |
| 425 |
void undoRename(); |
| 426 |
void uniq(); |
| 427 |
void unique(); |
| 428 |
void updateLabel(); |
| 429 |
void updateLC(); |
| 430 |
void updateRecentFileActions(); |
| 431 |
void updateScaleDlg(); |
| 432 |
void updateSelectResi(); |
| 433 |
void updateSM1(); |
| 434 |
void updateSM2(); |
| 435 |
void updateSM3(const QUrl link); |
| 436 |
void updateSM4(QString s); |
| 437 |
void updateStatusBar(const QString& s) ; |
| 438 |
void updateTieFreeVar(); |
| 439 |
void updateTwinTest(); |
| 440 |
void updateXLput(); |
| 441 |
void updateExtraOutput(); |
| 442 |
void updateExtraSettings(int index); |
| 443 |
void updateExtraSettings(); |
| 444 |
void wasDelete(); |
| 445 |
void worstReflections(); |
| 446 |
void setFFMPEGEXE(); |
| 447 |
void setMP4(); |
| 448 |
void updateOutput(); |
| 449 |
void makeRotMovi(); |
| 450 |
void split(); |
| 451 |
void notsplit(); |
| 452 |
void wasRename(); |
| 453 |
void withdrawres(); |
| 454 |
void zoomin(); |
| 455 |
void zoomout(); |
| 456 |
void calculator(); |
| 457 |
void create_DSRGui(); |
| 458 |
void insertDSRLine(QString dsrline, int position, QVector<int> previousLine); |
| 459 |
void dsrClosed(); |
| 460 |
void aboutXLE(); |
| 461 |
CEnvironment lonesome(QString s,int startNummer); |
| 462 |
void beloWriteCube(); |
| 463 |
static int isacommand(QString command); |
| 464 |
void displayDisagreeableRestraints(); |
| 465 |
void defineBarray(); |
| 466 |
protected: |
| 467 |
void paintEvent(QPaintEvent *event); |
| 468 |
|
| 469 |
void dragEnterEvent(QDragEnterEvent *event); |
| 470 |
void dropEvent(QDropEvent *event); |
| 471 |
void showEvent(QShowEvent * event); |
| 472 |
void hideEvent(QHideEvent * event); |
| 473 |
private: |
| 474 |
friend class AulaWorker; |
| 475 |
bool focusSet; |
| 476 |
bool fullscreen; |
| 477 |
int wght_cycls; |
| 478 |
int ls_cycls; |
| 479 |
bool nowaste; |
| 480 |
QNetworkAccessManager *net; |
| 481 |
QNetworkReply *reply; |
| 482 |
V3 urs; |
| 483 |
QString altText,popel; |
| 484 |
PSEWidget *psew; |
| 485 |
QSpinBox *symmIntBx; |
| 486 |
QSpinBox *symmXBx; |
| 487 |
QSpinBox *symmYBx; |
| 488 |
QSpinBox *symmZBx; |
| 489 |
QSpinBox *symmFrgBx; |
| 490 |
QLineEdit *prosaSymm; |
| 491 |
QTimer prosaTimer; |
| 492 |
QTimer *tim; |
| 493 |
QTextBrowser *OrtepCodesbrowser; |
| 494 |
QLabel *shortestDistanceLabel; |
| 495 |
QPushButton *willpse; |
| 496 |
QPushButton *beloColorButton; |
| 497 |
|
| 498 |
bool machPlatz,FehlerTeufel; |
| 499 |
int hhh; |
| 500 |
|
| 501 |
|
| 502 |
QSignalMapper *dsm; |
| 503 |
HistoryWidget *hw; |
| 504 |
double range,weight; |
| 505 |
int falschAtom; |
| 506 |
QCompleter *completer; |
| 507 |
QString labelPSE,labelSuffix,nextLabel,title; |
| 508 |
int labelIndex; |
| 509 |
QLabel *nextNameL, *hintL; |
| 510 |
QCheckBox *rufModeBox,*indexIncr; |
| 511 |
QSpinBox *resiNrSpin; |
| 512 |
QSpinBox *indexSpin; |
| 513 |
QSpinBox *partSpin; |
| 514 |
QSpinBox *spinSelectPart; |
| 515 |
QCheckBox *inculdePartNull; |
| 516 |
QCheckBox *selectPart; |
| 517 |
QLabel *tieOccL; |
| 518 |
QComboBox *tieType; |
| 519 |
QLabel *tieFVNrL; |
| 520 |
QSpinBox *tieFVNr; |
| 521 |
QLabel *tieUsedL; |
| 522 |
QDoubleSpinBox *tieFix; |
| 523 |
QString FFTErrorString; |
| 524 |
QComboBox *sufixBox; |
| 525 |
QLineEdit *resiResiClass; |
| 526 |
QComboBox *resiResiClassCB; |
| 527 |
QPeakView *qpv; |
| 528 |
CEnvironment undoAtom,redoAtom,deletedAtom,restoredAtom; |
| 529 |
QList<int> undoAtomIndex,redoAtomIndex,gehtMichAn,gehtMichAn2; |
| 530 |
int altursize; |
| 531 |
int mode; |
| 532 |
void getMinMaxSintl(double &smin, double &smax); |
| 533 |
QMenu *recentFilesMenu,*stereoMenu,*moveMenu,*helpMenu,*sortMenu; |
| 534 |
QActionGroup *stereoGroup,*tubeGroup,*sortGroup; |
| 535 |
enum { MaxRecentFiles = 20 }; |
| 536 |
QAction *recentFileActs[MaxRecentFiles]; |
| 537 |
bool otherOpenFiles,doNotAnnoyMe; |
| 538 |
Molecule mole; |
| 539 |
QSpinBox *widthBox; |
| 540 |
QSpinBox *heightBox; |
| 541 |
QDoubleSpinBox *scalefBox; |
| 542 |
QDoubleSpinBox *cStepBx; |
| 543 |
QDialog *scalDlg; |
| 544 |
QTextBrowser *infoKanal; |
| 545 |
QRadioButton *pserbt[111]; |
| 546 |
QGroupBox *sfacBox; |
| 547 |
double scalePic; |
| 548 |
QString saveName,fvarinfo; |
| 549 |
QProcess *shelxl,*extraProc; |
| 550 |
QString shelxlPath, shelxlArgs; |
| 551 |
bool useMyBArray; |
| 552 |
QStringList extraProgramNames,extraProgramPaths,extraOptions,extraExt2; |
| 553 |
QList<Qt::CheckState> extraArguments,extraExtensions, extraDetach, extraResIns, extraOpenFileDialogBefore, extraIconOverlay, extraAbsolutePath; |
| 554 |
|
| 555 |
QLineEdit *extraPath,*extraName,*extraAltExtEdit,*extraArgumentsEdit,*shxPath,*shxOptions; |
| 556 |
QList<int> extraOverlayPointSize; |
| 557 |
QSpinBox *iovlPointSize; |
| 558 |
QComboBox *pgms; |
| 559 |
QToolButton *extraFakeButton; |
| 560 |
QString altExtraIconPath; |
| 561 |
QStringList altExtraIconPaths; |
| 562 |
QDockWidget *helpDock; |
| 563 |
|
| 564 |
|
| 565 |
QWidget *shx_group; |
| 566 |
QMainWindow *shxMW; |
| 567 |
QVBoxLayout *sss; |
| 568 |
QVBoxLayout *hwl; |
| 569 |
QHBoxLayout *nlt; |
| 570 |
QGroupBox *renameBox ; |
| 571 |
QVBoxLayout *rnla; |
| 572 |
QLabel *nliL,*resiResiClassL,*resiNrSpinL,*partSpinL; |
| 573 |
QHBoxLayout *sfacla; |
| 574 |
QScrollArea *qsa,*qsa2; |
| 575 |
|
| 576 |
QAction *pe_stereo; |
| 577 |
QAction *xe_stereo; |
| 578 |
QAction *an_stereo; |
| 579 |
|
| 580 |
QAction *no_stereo; |
| 581 |
QAction *fcvsfoAct, *calcAct, *dsrAct; |
| 582 |
QAction *soact; |
| 583 |
QString shredCIFPath; |
| 584 |
QAction *backColor,*labelColor; |
| 585 |
QVBoxLayout *lt; |
| 586 |
QLabel *sLabel, *fvused; |
| 587 |
QTimer *hidwillpse; |
| 588 |
|
| 589 |
QLabel *indexL,*sufixL; |
| 590 |
QLabel *scalwla, *scalhla, *scalsla, *header; |
| 591 |
QDialogButtonBox *buttonBoxRN; |
| 592 |
QHBoxLayout *indexla; |
| 593 |
QStringList alpha; |
| 594 |
QGridLayout *scalla; |
| 595 |
|
| 596 |
QVBoxLayout *vlt, *resid_layout; |
| 597 |
QTextEdit *resid_label; |
| 598 |
QTextEdit *restr_table; |
| 599 |
|
| 600 |
LstData listf_info; |
| 601 |
QGroupBox *resid_gb; |
| 602 |
QGroupBox *gp;QHBoxLayout *rhla,*rhla2; |
| 603 |
QHBoxLayout *buttomLt; |
| 604 |
QPushButton *showLst; |
| 605 |
QIcon extraIcon; |
| 606 |
QCheckBox *useArgument; |
| 607 |
QCheckBox *omitExtension; |
| 608 |
QCheckBox *absolutePath; |
| 609 |
QCheckBox *detach; |
| 610 |
QCheckBox *copyResIns; |
| 611 |
QCheckBox *openFileDialogBefore; |
| 612 |
QCheckBox *iconOverlay; |
| 613 |
QSize ediSize; |
| 614 |
QPoint ediPos; |
| 615 |
QLabel *lineColumn; |
| 616 |
QGroupBox *navibox,*refineButtonBox,*refineButtonBox2; |
| 617 |
QPushButton *stoppRefinement,*finishRefinement; |
| 618 |
QPushButton *loadRes; |
| 619 |
QPushButton *withdraw; |
| 620 |
QPushButton *pro7; |
| 621 |
QPushButton *stoppRefinement2,*finishRefinement2; |
| 622 |
QPushButton *loadRes2; |
| 623 |
QPushButton *withdraw2; |
| 624 |
QToolButton *spellCheckact,*spellCheckact2; |
| 625 |
QSettings *vis_settings; |
| 626 |
void shx_editor(QString filename); |
| 627 |
double getNumber(double v,const QList<double> fv,double uiso); |
| 628 |
double getNumber(double v,const QList<double> fv,int idx,int &fixFlag); |
| 629 |
MyAtom findOH(V3 donor, V3 acceptor,int dindex,QStringList alab); |
| 630 |
bool maybeSave(); |
| 631 |
bool maybeSave2(); |
| 632 |
bool doWeHaveHKLF5here(QStringList &hk5s); |
| 633 |
bool startFused; |
| 634 |
QStringList hklf5files; |
| 635 |
Calculator *calcmenu; |
| 636 |
DSRGui *dsr; |
| 637 |
QString pngName; |
| 638 |
QScrollArea *qsaPNG ; |
| 639 |
|
| 640 |
QList<bool> twinRedundant; |
| 641 |
QList<bool> twinDone; |
| 642 |
QDialog *twinDlg; |
| 643 |
double rvalue2beat, wr2value2beat; |
| 644 |
QVBoxLayout *twinvbl; |
| 645 |
QGroupBox *twingpx; |
| 646 |
QLabel *twinpatlab; |
| 647 |
|
| 648 |
|
| 649 |
|
| 650 |
|
| 651 |
}; |
| 652 |
class AulaWorker : public QThread { |
| 653 |
Q_OBJECT |
| 654 |
public: |
| 655 |
AulaWorker(Window *parent, bool ur){ |
| 656 |
_w = parent; |
| 657 |
useResis = ur; |
| 658 |
rzeit.start(); |
| 659 |
} |
| 660 |
void run() override { |
| 661 |
|
| 662 |
aula(); |
| 663 |
} |
| 664 |
Window *_w; |
| 665 |
bool saveruf; |
| 666 |
int possible; |
| 667 |
QList<int> chain; |
| 668 |
void aula(); |
| 669 |
bool useResis; |
| 670 |
public slots: |
| 671 |
void finalize(); |
| 672 |
signals: |
| 673 |
void message(const QString &); |
| 674 |
void rename(int); |
| 675 |
private: |
| 676 |
QElapsedTimer rzeit; |
| 677 |
QString all; |
| 678 |
void extendChain(QList<Ring > &rings, QList<int> ¤tChain, QList<QList<int> > &neighbors,QSet<int> &nogo); |
| 679 |
void inventNewLabels(QList<int> &result); |
| 680 |
}; |
| 681 |
#endif |
| 682 |
|