Skip to content

Commit 1eb8ce0

Browse files
authored
Merge pull request #76 from easyScience/0.0.4rc
Release 0.0.4
2 parents 5fc5bd0 + 638858b commit 1eb8ce0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

73 files changed

+3218
-5027
lines changed

.github/workflows/build.yml

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -101,24 +101,24 @@ jobs:
101101
- name: Sign the installer
102102
run: poetry run python ${{ env.SCRIPTS_PATH }}/Signatures.py ${{ secrets.BINARY_SIGN_WIN }} ${{ secrets.CERT_ZIP_PASS }}
103103

104-
- name: Set up screen recording dependencies (macOS)
105-
if: runner.os == 'macOS'
106-
run: |
107-
"/Library/Application Support/VMware Tools/vmware-resolutionSet" 1920 1080
108-
system_profiler SPDisplaysDataType | grep Resolution
109-
110-
- name: Set up screen recording dependencies (Linux)
111-
if: runner.os == 'Linux'
112-
run: |
113-
sudo apt-get install libxkbcommon-x11-0
114-
Xvfb :0 -screen 0 1920x1080x24 -ac &
115-
echo "DISPLAY=:0" >> $GITHUB_ENV
116-
117-
- name: Set up screen recording dependencies (Windows)
118-
if: runner.os == 'Windows'
119-
run: |
120-
Set-DisplayResolution -Width 1920 -Height 1080 -Force
121-
Get-DisplayResolution
104+
#- name: Set up screen recording dependencies (macOS)
105+
# if: runner.os == 'macOS'
106+
# run: |
107+
# "/Library/Application Support/VMware Tools/vmware-resolutionSet" 1920 1080
108+
# system_profiler SPDisplaysDataType | grep Resolution
109+
110+
#- name: Set up screen recording dependencies (Linux)
111+
# if: runner.os == 'Linux'
112+
# run: |
113+
# sudo apt-get install libxkbcommon-x11-0
114+
# Xvfb :0 -screen 0 1920x1080x24 -ac &
115+
# echo "DISPLAY=:0" >> $GITHUB_ENV
116+
117+
#- name: Set up screen recording dependencies (Windows)
118+
# if: runner.os == 'Windows'
119+
# run: |
120+
# Set-DisplayResolution -Width 1920 -Height 1080 -Force
121+
# Get-DisplayResolution
122122

123123
- name: Make dir for .desktop file (Linux)
124124
if: runner.os == 'Linux'
@@ -131,8 +131,8 @@ jobs:
131131
if: runner.os != 'Windows'
132132
run: poetry run python ${{ env.SCRIPTS_PATH }}/RunApp.py --testmode
133133

134-
- name: Rename test videos
135-
run: poetry run python ${{ env.SCRIPTS_PATH }}/CreateTestVideos.py ${{ env.BRANCH_NAME }}
134+
#- name: Rename test videos
135+
# run: poetry run python ${{ env.SCRIPTS_PATH }}/CreateTestVideos.py ${{ env.BRANCH_NAME }}
136136

137137
- name: Create zip archive of offline app installer
138138
run: poetry run python ${{ env.SCRIPTS_PATH }}/ZipArtifacts.py ${{ env.BRANCH_NAME }}

CHANGELOG.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,21 @@
11
# CHANGELOG
22

3-
## 0.0.3
3+
### Changes 0.0.4
44

5-
- Enable reversal of SLD plot
5+
- Add min and max columns to the Analysis tab [da47432](https://github.com/easyScience/EasyReflectometryApp/commit/da47432db1bec0e16e587328a24c23bdd174c099)
6+
- Improvement to Analysis tab to ensure parameters are only listed once [f67eb02](https://github.com/easyScience/EasyReflectometryApp/commit/f67eb023aa18ebed41d5b19c719da5d6896d14b3)
7+
- Introduction of the 'Surfactant Layer' item type [91ef5f1](https://github.com/easyScience/EasyReflectometryApp/commit/91ef5f152af6160a48dc39e3cfaf99447bf06aea) and [dcc9297](https://github.com/easyScience/EasyReflectometryApp/commit/dcc9297946253f74d2101dcc741ad452b850b237)
8+
- Improvements to the efficiency of the Sample tab by divorcing the Materials/Items/Layers where possible [e57e5c3](https://github.com/easyScience/EasyReflectometryApp/commit/e57e5c367da783020a67b2335c32f01317429ae9)
9+
- Refactor of the internal logic proxy object `PyQmlProxy.py` into a variety of `Proxies` [3abdb40](https://github.com/easyScience/EasyReflectometryApp/commit/3abdb40f7b9e5b35754061395c939d61dfc4d9d4)
10+
- Removal of more old EasyDiffraction GUI code [9a41c0f](https://github.com/easyScience/EasyReflectometryApp/commit/9a41c0fbd446344b468c78ec220f02c20f56abc9)
11+
- Solve problem when number of iterations was changed in a RepeatingMultiLayer [9542d4d](https://github.com/easyScience/EasyReflectometryApp/commit/9542d4db07d210d178c61503c66f42a666907a61)
12+
- Enable the data plotted in the Sample tab to be pure reflectometry (i.e. scaling of one, no background or resolution) and deactivation of 'qtcharts' plotting [52accc9](https://github.com/easyScience/EasyReflectometryApp/commit/52accc9a062ad2533679cacf778877c05cebf47e)
13+
- Move to BSD license [413bd9b](https://github.com/easyScience/EasyReflectometryApp/commit/413bd9b93cba04b962386ddcd0b697cc9921345c)
14+
15+
### Changes 0.0.3
16+
17+
- Change name from 'easyReflectometry' to 'EasyReflectometry'
18+
19+
### Changes 0.0.2
20+
21+
- A bug fix to enable multithreaded fitting to work on Windows and Linux

CONTRIBUTING.md

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,58 @@
1+
# Development workflow
12

3+
All development in `EasyReflectometryApp` is done on the `develop` branch of the git repository.
4+
It is advised that this branch will have the most up to date version of `EasyReflectometryApp`.
5+
However, this may include bugs so for production use the [latest release](https://github.com/easyScience/EasyReflectometryApp/releases) is advised.
6+
7+
Development installation instructions are given in the [installation documentation](./INSTALLATION.md).
8+
9+
## Feature/Bug fix contributions
10+
11+
**Note that some features may require contribution to both `EasyReflectometryApp` and [`EasyReflectometryLib`](https://github.com/easyScience/EasyReflectometryLib/).**
12+
If you are interested in contributing a feature or bug fix to `EasyReflectometryApp`, then please fork the Github repository and clone this fork to your local machine and add the upstream repo.
13+
14+
```
15+
git clone [email protected]:<your-github-username>/EasyReflectometryApp.git
16+
git remote add upstream https://github.com/easyScience/EasyReflectometryApp.git
17+
```
18+
19+
With the repository cloned, change to the `develop` branch
20+
21+
```
22+
git checkout -b develop origin/develop
23+
```
24+
25+
From this branch, you should create a feature branch to make the changes/contributions.
26+
27+
```
28+
git branch my-feature-branch
29+
git checkout my-feature-branch
30+
```
31+
32+
Once you have completed the feature and commited your changes, please open a pull request to the original `EasyReflectometryApp` repository and wait for a review.
33+
34+
## Release workflow
35+
36+
Periodically, or after the additional of major new features, there will be stable releases of `EasyReflectometryApp`.
37+
These should be produced firstly by bumping the version number in the `develop` branch appropriately and updating the [CHANGELOG.md](./CHANGELOG.md).
38+
The files where the version numbers should be changed are:
39+
- `pyproject.toml`
40+
- `README.md`
41+
- `INSTALLATION.md`
42+
Once the version number is bumped and the resulting build EasyReflectometry application is tested, a branch should be taken from `develop` for the release candidate.
43+
This branch should be named `<version-number>rc` and a lock file for the poetry package management should be produced and commited to the repository using
44+
45+
```
46+
poetry lock
47+
git add -f package.lock
48+
git commit -m 'Lock package versions'
49+
```
50+
51+
Once the Githib builds have been completed, these should also be tested.
52+
53+
If all is well, then a pull request can be opened to merge the `<version-number>rc` branch into the `main` branch.
54+
With this pull request merged the final version will be built from `main` and the `<version-number>rc` branch can be removed.
55+
The final `main` branch action will then run to build the release version of EasyReflectometry, this will produce a release in the [releases](https://github.com/easyScience/EasyReflectometryApp/releases) section of the Github repository.
56+
Once is it there, the release should be tagged and renamed, this is achieved by selecting the 'edit' button (the pencil).
57+
The tag should be given as `v<version-number>` and the name of the release should be "Version <version-number> (<date>)` and currently (until new tutorials are produced) the tutorial should be removed from the release.
58+
Finally, the release should be published.

EasyReflectometryApp/Gui/Components/AnalysisFitables.qml

Lines changed: 42 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import Gui.Globals 1.0 as ExGlobals
1212
EaComponents.TableView {
1313
id: table
1414

15-
enabled: ExGlobals.Constants.proxy.isFitFinished
15+
enabled: ExGlobals.Constants.proxy.fitter.isFitFinished
1616

1717
maxRowCountShow: 8
1818
defaultInfoText: qsTr("No Parameters Found")
@@ -23,7 +23,7 @@ EaComponents.TableView {
2323
id: fitablesModel
2424

2525
//xml: ExGlobals.Constants.proxy.fitablesListAsXml
26-
xml: ExGlobals.Constants.proxy.parametersAsXml
26+
xml: ExGlobals.Constants.proxy.parameter.parametersAsXml
2727

2828
query: "/root/item"
2929

@@ -34,6 +34,8 @@ EaComponents.TableView {
3434
XmlRole { name: "unit"; query: "unit/string()" }
3535
XmlRole { name: "error"; query: "error/number()" }
3636
XmlRole { name: "fit"; query: "fit/number()" }
37+
XmlRole { name: "min"; query: "min/string()" }
38+
XmlRole { name: "max"; query: "max/string()" }
3739

3840
onStatusChanged: {
3941
if (status === XmlListModel.Ready) {
@@ -62,6 +64,8 @@ EaComponents.TableView {
6264
valueColumn.width -
6365
unitColumn.width -
6466
errorColumn.width -
67+
minColumn.width -
68+
maxColumn.width -
6569
fitColumn.width
6670
headerText: "Label"
6771
text: formatLabel(model.index, model.label)
@@ -71,7 +75,7 @@ EaComponents.TableView {
7175
EaComponents.TableViewTextInput {
7276
id: valueColumn
7377
horizontalAlignment: Text.AlignRight
74-
width: EaStyle.Sizes.fontPixelSize * 4
78+
width: EaStyle.Sizes.fontPixelSize * 3.5
7579
headerText: "Value"
7680
text: {
7781
if (model.label.endsWith('Background')) {
@@ -94,13 +98,33 @@ EaComponents.TableView {
9498
EaComponents.TableViewLabel {
9599
id: errorColumn
96100
horizontalAlignment: Text.AlignRight
97-
width: EaStyle.Sizes.fontPixelSize * 4
101+
width: EaStyle.Sizes.fontPixelSize * 3
98102
headerText: "Error "
99103
text: model.error === 0.0 || model.error > 999999 ? "" : model.error.toFixed(4) + " "
100104
}
101105

106+
EaComponents.TableViewTextInput {
107+
id: minColumn
108+
horizontalAlignment: Text.AlignRight
109+
width: EaStyle.Sizes.fontPixelSize * 3
110+
headerText: "Min "
111+
enabled: model.fit
112+
text: model.fit == false ? '--' : model.min < -999999 ? "-inf" : model.min > 999999 ? "+inf" : model.min
113+
onEditingFinished: editParameterValueMin(model.id, text)
114+
}
115+
116+
EaComponents.TableViewTextInput {
117+
id: maxColumn
118+
horizontalAlignment: Text.AlignRight
119+
width: EaStyle.Sizes.fontPixelSize * 3
120+
headerText: "Max "
121+
enabled: model.fit
122+
text: model.fit == false ? '--' : model.max < -999999 ? "-inf" : model.max > 999999 ? "+inf" : model.max
123+
onEditingFinished: editParameterValueMax(model.id, text)
124+
}
125+
102126
EaComponents.TableViewCheckBox {
103-
enabled: ExGlobals.Constants.proxy.experimentLoaded
127+
enabled: ExGlobals.Constants.proxy.data.experimentLoaded
104128
id: fitColumn
105129
headerText: "Fit"
106130
checked: model.fit
@@ -130,18 +154,27 @@ EaComponents.TableView {
130154
}
131155

132156
function editParameterValue(id, value) {
133-
//ExGlobals.Constants.proxy.editParameter(id, parseFloat(value))
134-
ExGlobals.Constants.proxy.editParameter(id, parseFloat(value))
157+
//ExGlobals.Constants.proxy.parameter.editParameter(id, parseFloat(value))
158+
ExGlobals.Constants.proxy.parameter.editParameter(id, parseFloat(value))
159+
}
160+
161+
function editParameterValueMin(id, value) {
162+
ExGlobals.Constants.proxy.parameter.editParameterMin(id, value)
135163
}
164+
165+
function editParameterValueMax(id, value) {
166+
ExGlobals.Constants.proxy.parameter.editParameterMax(id, value)
167+
}
168+
136169
function editParameterFit(id, value) {
137-
ExGlobals.Constants.proxy.editParameter(id, value)
170+
ExGlobals.Constants.proxy.parameter.editParameter(id, value)
138171
}
139172

140173
function formatLabel(index, label) {
141174
if (index < 0 || typeof label === "undefined")
142175
return ""
143176

144-
const datasetName = ExGlobals.Constants.proxy.experimentDataAsObj[0].name
177+
const datasetName = ExGlobals.Constants.proxy.data.experimentDataAsObj[0].name
145178

146179
// Modify current label
147180
label = label.replace("Instrument.", `Instrument.${datasetName}.`)
@@ -175,14 +208,12 @@ EaComponents.TableView {
175208
if (list[0] === previousList[0]) {
176209
if (ExGlobals.Variables.iconifiedNames) {
177210
list[0] = `<font color=${iconColor} face="${EaStyle.Fonts.iconsFamily}">${list[0]}</font>`
178-
list[0] = list[0].replace("Phases", "gem").replace("Instrument", "microscope")
179211
} else {
180212
list[0] = `<font color=${EaStyle.Colors.themeForegroundMinor}>${list[0]}</font>`
181213
}
182214
} else {
183215
if (ExGlobals.Variables.iconifiedNames) {
184216
list[0] = `<font face="${EaStyle.Fonts.iconsFamily}">${list[0]}</font>`
185-
list[0] = list[0].replace("Phases", "gem").replace("Instrument", "microscope")
186217
} else {
187218
list[0] = `<font color=${EaStyle.Colors.themeForeground}>${list[0]}</font>`
188219
}

0 commit comments

Comments
 (0)