Skip to content

Commit

Permalink
Merge branch 'master' into v5
Browse files Browse the repository at this point in the history
  • Loading branch information
nsherry4 committed Aug 29, 2018
2 parents d27bb3a + 36cff58 commit 5ff7ae5
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 10 deletions.
33 changes: 24 additions & 9 deletions Display/src/main/java/peakaboo/display/plot/Plotter.java
Original file line number Diff line number Diff line change
Expand Up @@ -70,38 +70,53 @@ public PlotDrawing draw(PlotData data, PlotSettings settings, Surface context, D
////////////////////////////////////////////////////////////////////
// Colour Selections
////////////////////////////////////////////////////////////////////
Color fitting, fittingStroke, fittingSum;
Color proposed, proposedStroke, proposedSum;
Color selected, selectedStroke;
Color fitting, fittingStroke, fittingSum, fittingLabel;
Color proposed, proposedStroke, proposedSum, proposedLabel;
Color selected, selectedStroke, selectedLabel;

fitting = new Color(0.0f, 0.0f, 0.0f, 0.3f);
fittingStroke = new Color(0.0f, 0.0f, 0.0f, 0.5f);
fittingSum = new Color(0.0f, 0.0f, 0.0f, 0.8f);


// Colour/Monochrome colours for curve fittings
if (settings.monochrome) {
fitting = new Color(0.0f, 0.0f, 0.0f, 0.3f);
fittingStroke = new Color(0.0f, 0.0f, 0.0f, 0.5f);
fittingSum = new Color(0.0f, 0.0f, 0.0f, 0.8f);
fittingLabel = new Color(0.0f, 0.0f, 0.0f, 1.0f);
} else {
fitting = new Color(0.0f, 0.0f, 0.0f, 0.3f);
fittingStroke = new Color(0.0f, 0.0f, 0.0f, 0.5f);
fittingSum = new Color(0.0f, 0.0f, 0.0f, 0.8f);
fittingLabel = fittingStroke;
}


if (settings.monochrome)
{
proposed = new Color(0x50ffffff, true);
proposedStroke = new Color(0x80ffffff, true);
proposedSum = new Color(0xD0ffffff, true);
proposedLabel = new Color(0xFF777777, true);;
}
else
{
proposed = new Color(0x80D32F2F, true);
proposedStroke = new Color(0x80B71C1C, true);
proposedSum = new Color(0xD0B71C1C, true);
proposedLabel = proposedStroke;
}

// Colour/Monochrome colours for highlighted/selected fittings
if (settings.monochrome)
{
selected = new Color(0x50ffffff, true);
selectedStroke = new Color(0x80ffffff, true);
selectedLabel = new Color(0xFF777777, true);
}
else
{
selected = new Color(0x800288D1, true);
selectedStroke = new Color(0xff01579B, true);
selectedLabel = selectedStroke;
}


Expand Down Expand Up @@ -212,14 +227,14 @@ public PlotDrawing draw(PlotData data, PlotSettings settings, Surface context, D
List<FittingLabel> fitLabels = new ArrayList<>();
for (FittingResult fit : data.selectionResults.getFits()) {
if (data.highlightedTransitionSeries.contains(fit.getTransitionSeries())) {
fitLabels.add(new FittingLabel(fit, selectedStroke, data.annotations.get(fit.getTransitionSeries())));
fitLabels.add(new FittingLabel(fit, selectedLabel, data.annotations.get(fit.getTransitionSeries())));
} else {
fitLabels.add(new FittingLabel(fit, fittingStroke, data.annotations.get(fit.getTransitionSeries())));
fitLabels.add(new FittingLabel(fit, fittingLabel, data.annotations.get(fit.getTransitionSeries())));
}

}
for (FittingResult fit : data.proposedResults.getFits()) {
fitLabels.add(new FittingLabel(fit, proposedStroke, data.annotations.get(fit.getTransitionSeries())));
fitLabels.add(new FittingLabel(fit, proposedLabel, data.annotations.get(fit.getTransitionSeries())));
}

if (data.selectionResults != null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,7 @@ public void actionAbout()
contents.licence = StringInput.contents(getClass().getResourceAsStream("/peakaboo/licence.txt"));
contents.credits = StringInput.contents(getClass().getResourceAsStream("/peakaboo/credits.txt"));
contents.logo = logo;
contents.version = Integer.toString(Version.versionNoMajor);
contents.version = Version.versionNoMajor + "." + Version.versionNoMinor;
contents.longVersion = Version.longVersionNo;
contents.releaseDescription = Version.releaseDescription;
contents.date = Version.buildDate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ public class PersistentViewModel {
public PersistentViewModel() {
showElementFitTitles = true;
showAxes = true;
showElementFitMarkers = true;
showIndividualFittings = true;
}

public PersistentViewModel(PersistentViewModel copy) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package peakaboo.controller.settings;

import peakaboo.common.Version;
import peakaboo.controller.plotter.PlotController;
import peakaboo.controller.plotter.data.SavedDataSession;
import peakaboo.controller.plotter.filtering.SavedFilteringSession;
Expand All @@ -20,6 +21,7 @@ public class SavedSession {
public SavedFilteringSession filtering;
public SavedFittingSession fitting;
public SessionViewModel view;
public String version = Version.longVersionNo;


/**
Expand Down

0 comments on commit 5ff7ae5

Please sign in to comment.