synchronize LAMMPS-GUI with upstream
This commit is contained in:
@ -190,8 +190,6 @@ set(PROJECT_SOURCES
|
|||||||
fileviewer.h
|
fileviewer.h
|
||||||
preferences.cpp
|
preferences.cpp
|
||||||
preferences.h
|
preferences.h
|
||||||
runwham.cpp
|
|
||||||
runwham.h
|
|
||||||
setvariables.cpp
|
setvariables.cpp
|
||||||
setvariables.h
|
setvariables.h
|
||||||
slideshow.h
|
slideshow.h
|
||||||
@ -281,7 +279,7 @@ if(APPLE)
|
|||||||
MACOSX_BUNDLE_BUNDLE_VERSION ${PROJECT_VERSION}
|
MACOSX_BUNDLE_BUNDLE_VERSION ${PROJECT_VERSION}
|
||||||
MACOSX_BUNDLE_SHORT_VERSION_STRING ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}
|
MACOSX_BUNDLE_SHORT_VERSION_STRING ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}
|
||||||
MACOSX_BUNDLE_ICON_FILE lammps.icns
|
MACOSX_BUNDLE_ICON_FILE lammps.icns
|
||||||
MACOSX_BUNDLE_COPYRIGHT "(c) 2003 - 2024, The LAMMPS Developers"
|
MACOSX_BUNDLE_COPYRIGHT "(c) 2003 - 2025, The LAMMPS Developers"
|
||||||
MACOSX_BUNDLE TRUE
|
MACOSX_BUNDLE TRUE
|
||||||
)
|
)
|
||||||
# additional targets to populate the bundle tree and create the .dmg image file
|
# additional targets to populate the bundle tree and create the .dmg image file
|
||||||
|
|||||||
@ -55,12 +55,19 @@
|
|||||||
</provides>
|
</provides>
|
||||||
|
|
||||||
<releases>
|
<releases>
|
||||||
<release version="1.6.12" timestamp="1734890080">
|
<release version="1.6.13" timestamp="1743734509">
|
||||||
|
<description>
|
||||||
|
Change working directory to user's home dir if initial directory is "/" or the Application folder
|
||||||
|
Add preferences option to set https proxy, if not already set via environment variable
|
||||||
|
</description>
|
||||||
|
</release>
|
||||||
|
<release version="1.6.12" timestamp="1734890080">
|
||||||
<description>
|
<description>
|
||||||
Update Tutorial menu entries to cover all 8 tutorials
|
Update Tutorial menu entries to cover all 8 tutorials
|
||||||
Highlight warnings and error messages in Output window
|
Highlight warnings and error messages in Output window
|
||||||
Make Tutorial wizards more compact
|
Make Tutorial wizards more compact
|
||||||
Include download and compilation of WHAM software from Alan Grossfield
|
Include download and compilation of WHAM software from Alan Grossfield
|
||||||
|
Add entry to Run menu to restart the LAMMPS instance
|
||||||
Use mutex to avoid corruption of thermo data
|
Use mutex to avoid corruption of thermo data
|
||||||
</description>
|
</description>
|
||||||
</release>
|
</release>
|
||||||
|
|||||||
@ -22,7 +22,6 @@
|
|||||||
#include "lammpsrunner.h"
|
#include "lammpsrunner.h"
|
||||||
#include "logwindow.h"
|
#include "logwindow.h"
|
||||||
#include "preferences.h"
|
#include "preferences.h"
|
||||||
#include "runwham.h"
|
|
||||||
#include "setvariables.h"
|
#include "setvariables.h"
|
||||||
#include "slideshow.h"
|
#include "slideshow.h"
|
||||||
#include "stdcapture.h"
|
#include "stdcapture.h"
|
||||||
@ -216,7 +215,6 @@ LammpsGui::LammpsGui(QWidget *parent, const QString &filename) :
|
|||||||
connect(ui->actionRun_File, &QAction::triggered, this, &LammpsGui::run_file);
|
connect(ui->actionRun_File, &QAction::triggered, this, &LammpsGui::run_file);
|
||||||
connect(ui->actionStop_LAMMPS, &QAction::triggered, this, &LammpsGui::stop_run);
|
connect(ui->actionStop_LAMMPS, &QAction::triggered, this, &LammpsGui::stop_run);
|
||||||
connect(ui->actionRestart_LAMMPS, &QAction::triggered, this, &LammpsGui::restart_lammps);
|
connect(ui->actionRestart_LAMMPS, &QAction::triggered, this, &LammpsGui::restart_lammps);
|
||||||
// connect(ui->actionRun_WHAM, &QAction::triggered, this, &LammpsGui::run_wham);
|
|
||||||
connect(ui->actionSet_Variables, &QAction::triggered, this, &LammpsGui::edit_variables);
|
connect(ui->actionSet_Variables, &QAction::triggered, this, &LammpsGui::edit_variables);
|
||||||
connect(ui->actionImage, &QAction::triggered, this, &LammpsGui::render_image);
|
connect(ui->actionImage, &QAction::triggered, this, &LammpsGui::render_image);
|
||||||
connect(ui->actionLAMMPS_Tutorial, &QAction::triggered, this, &LammpsGui::tutorial_web);
|
connect(ui->actionLAMMPS_Tutorial, &QAction::triggered, this, &LammpsGui::tutorial_web);
|
||||||
@ -1863,13 +1861,6 @@ void LammpsGui::edit_variables()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void LammpsGui::run_wham()
|
|
||||||
{
|
|
||||||
RunWHAM do_run(this);
|
|
||||||
do_run.setFont(font());
|
|
||||||
do_run.exec();
|
|
||||||
}
|
|
||||||
|
|
||||||
void LammpsGui::findandreplace()
|
void LammpsGui::findandreplace()
|
||||||
{
|
{
|
||||||
FindAndReplace find(ui->textEdit, this);
|
FindAndReplace find(ui->textEdit, this);
|
||||||
|
|||||||
@ -112,7 +112,6 @@ private slots:
|
|||||||
void run_buffer() { do_run(true); }
|
void run_buffer() { do_run(true); }
|
||||||
void run_file() { do_run(false); }
|
void run_file() { do_run(false); }
|
||||||
void restart_lammps() { lammps.close(); };
|
void restart_lammps() { lammps.close(); };
|
||||||
void run_wham();
|
|
||||||
|
|
||||||
void edit_variables();
|
void edit_variables();
|
||||||
void render_image();
|
void render_image();
|
||||||
|
|||||||
@ -75,8 +75,6 @@
|
|||||||
<addaction name="actionRun_File"/>
|
<addaction name="actionRun_File"/>
|
||||||
<addaction name="actionStop_LAMMPS"/>
|
<addaction name="actionStop_LAMMPS"/>
|
||||||
<addaction name="actionRestart_LAMMPS"/>
|
<addaction name="actionRestart_LAMMPS"/>
|
||||||
<!-- <addaction name="separator"/>
|
|
||||||
<addaction name="actionRun_WHAM"/> -->
|
|
||||||
<addaction name="separator"/>
|
<addaction name="separator"/>
|
||||||
<addaction name="actionSet_Variables"/>
|
<addaction name="actionSet_Variables"/>
|
||||||
<addaction name="separator"/>
|
<addaction name="separator"/>
|
||||||
@ -298,14 +296,6 @@
|
|||||||
<string>Restart &LAMMPS</string>
|
<string>Restart &LAMMPS</string>
|
||||||
</property>
|
</property>
|
||||||
</action>
|
</action>
|
||||||
<!-- <action name="actionRun_WHAM">
|
|
||||||
<property name="icon">
|
|
||||||
<iconset theme=":/icons/system-run.png"/>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Run &WHAM Utility</string>
|
|
||||||
</property>
|
|
||||||
</action> -->
|
|
||||||
<action name="actionImage">
|
<action name="actionImage">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset theme=":/icons/emblem-photos.png"/>
|
<iconset theme=":/icons/emblem-photos.png"/>
|
||||||
|
|||||||
@ -121,7 +121,6 @@ void LogWindow::stop_run()
|
|||||||
|
|
||||||
void LogWindow::next_warning()
|
void LogWindow::next_warning()
|
||||||
{
|
{
|
||||||
auto *doc = document();
|
|
||||||
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
|
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
|
||||||
auto regex = QRegExp(QStringLiteral("^(ERROR|WARNING).*$"));
|
auto regex = QRegExp(QStringLiteral("^(ERROR|WARNING).*$"));
|
||||||
#else
|
#else
|
||||||
|
|||||||
@ -1,87 +0,0 @@
|
|||||||
/* ----------------------------------------------------------------------
|
|
||||||
LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
|
|
||||||
https://www.lammps.org/, Sandia National Laboratories
|
|
||||||
LAMMPS development team: developers@lammps.org
|
|
||||||
|
|
||||||
Copyright (2003) Sandia Corporation. Under the terms of Contract
|
|
||||||
DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
|
|
||||||
certain rights in this software. This software is distributed under
|
|
||||||
the GNU General Public License.
|
|
||||||
|
|
||||||
See the README file in the top-level LAMMPS directory.
|
|
||||||
------------------------------------------------------------------------- */
|
|
||||||
|
|
||||||
#include "runwham.h"
|
|
||||||
|
|
||||||
#include <QDialogButtonBox>
|
|
||||||
#include <QGridLayout>
|
|
||||||
#include <QIcon>
|
|
||||||
#include <QLabel>
|
|
||||||
#include <QLineEdit>
|
|
||||||
#include <QPushButton>
|
|
||||||
#include <QSizePolicy>
|
|
||||||
|
|
||||||
RunWHAM::RunWHAM(QWidget *parent) : QDialog(parent)
|
|
||||||
{
|
|
||||||
int irow = 0;
|
|
||||||
auto *layout = new QGridLayout;
|
|
||||||
auto *top = new QLabel("Run WHAM Utility:");
|
|
||||||
layout->addWidget(top, irow++, 0, 1, 2, Qt::AlignHCenter);
|
|
||||||
|
|
||||||
auto *label = new QLabel("Units: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
auto *field = new QLineEdit("real");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
label = new QLabel("Mininum value: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
field = new QLineEdit("");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
label = new QLabel("Maximum value: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
field = new QLineEdit("");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
label = new QLabel("Number of bins: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
field = new QLineEdit("50");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
label = new QLabel("Tolerance: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
field = new QLineEdit("1.0e-8");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
label = new QLabel("Temperature: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
field = new QLineEdit("300.0");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
label = new QLabel("Metadata file: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
field = new QLineEdit("");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
label = new QLabel("Output file: ");
|
|
||||||
layout->addWidget(label, irow, 0, 1, 1, Qt::AlignLeft);
|
|
||||||
field = new QLineEdit("");
|
|
||||||
layout->addWidget(field, irow++, 1, 1, 1);
|
|
||||||
|
|
||||||
auto *buttonBox = new QDialogButtonBox(QDialogButtonBox::Cancel);
|
|
||||||
auto *add = new QPushButton("&Run WHAM");
|
|
||||||
add->setObjectName("run_wham");
|
|
||||||
buttonBox->addButton(add, QDialogButtonBox::ActionRole);
|
|
||||||
connect(add, &QPushButton::released, this, &RunWHAM::accept);
|
|
||||||
connect(buttonBox, &QDialogButtonBox::rejected, this, &QDialog::reject);
|
|
||||||
|
|
||||||
layout->addWidget(buttonBox, irow++, 0, 1, 2, Qt::AlignHCenter);
|
|
||||||
setLayout(layout);
|
|
||||||
setWindowIcon(QIcon(":/icons/lammps-icon-128x128.png"));
|
|
||||||
setWindowTitle("LAMMPS-GUI - Run WHAM Utility");
|
|
||||||
resize(300, 200);
|
|
||||||
}
|
|
||||||
|
|
||||||
void RunWHAM::accept()
|
|
||||||
{
|
|
||||||
// assemble command line and run WHAM
|
|
||||||
fprintf(stderr, "Running WHAM\n");
|
|
||||||
QDialog::accept();
|
|
||||||
}
|
|
||||||
|
|
||||||
// Local Variables:
|
|
||||||
// c-basic-offset: 4
|
|
||||||
// End:
|
|
||||||
@ -1,34 +0,0 @@
|
|||||||
/* -*- c++ -*- ----------------------------------------------------------
|
|
||||||
LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
|
|
||||||
https://www.lammps.org/, Sandia National Laboratories
|
|
||||||
LAMMPS development team: developers@lammps.org
|
|
||||||
|
|
||||||
Copyright (2003) Sandia Corporation. Under the terms of Contract
|
|
||||||
DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
|
|
||||||
certain rights in this software. This software is distributed under
|
|
||||||
the GNU General Public License.
|
|
||||||
|
|
||||||
See the README file in the top-level LAMMPS directory.
|
|
||||||
------------------------------------------------------------------------- */
|
|
||||||
|
|
||||||
#ifndef RUN_WHAM_H
|
|
||||||
#define RUN_WHAM_H
|
|
||||||
|
|
||||||
#include <QDialog>
|
|
||||||
|
|
||||||
class RunWHAM : public QDialog {
|
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
|
||||||
explicit RunWHAM(QWidget *parent = nullptr);
|
|
||||||
~RunWHAM() = default;
|
|
||||||
|
|
||||||
private slots:
|
|
||||||
void accept() override;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// Local Variables:
|
|
||||||
// c-basic-offset: 4
|
|
||||||
// End:
|
|
||||||
Reference in New Issue
Block a user