Commit 7ffc4b97 authored by Krzysztof Nowinski's avatar Krzysztof Nowinski

Axes3D and 3DAnnotations GUI changes induced by text2D parameters/GUI change

parent 77e76fad
......@@ -80,7 +80,8 @@ public class Axes3D extends VisualizationModule
if (fromInput)
return;
fromGUI = true;
startAction();
if (inField != null)
startAction();
}
});
SwingInstancer.swingRunAndWait(new Runnable()
......
......@@ -92,6 +92,7 @@ public class GUI extends javax.swing.JPanel
private String path = null;
private String lastPath = null;
private JFileChooser fileChooser = new JFileChooser();
private FontParams fontParams = new FontParams();
/**
* Creates new form GUI
......@@ -106,12 +107,13 @@ public class GUI extends javax.swing.JPanel
annotationTableModel.addTableModelListener(new MyTableModelListener(annoTable));
annoTable.getTableHeader().setReorderingAllowed(false);
fontGUI.setParams(fontParams);
fontGUI.getParams().addChangeListener(new ChangeListener() {
fontParams.addChangeListener(new ChangeListener() {
@Override
public void stateChanged(ChangeEvent e) {
fontParamsChanged(fontGUI.getParams());
fontParamsChanged();
}
});
}
......@@ -333,9 +335,15 @@ public class GUI extends javax.swing.JPanel
fontGUI.updateGUI(p);
}
private void fontParamsChanged(FontParams fontParams)
private void fontParamsChanged()
{
parameters.set(FONT_PARAMS_THREE_DIMENSIONAL, fontParams.isThreeDimensional(), FONT_PARAMS_PRECISION, fontParams.getPrecision(), FONT_PARAMS_COLOR, fontParams.getColor().getRGB(), FONT_PARAMS_BRIGHTNESS, fontGUI.getColorEditor().getBrightness(), FONT_PARAMS_GLYPHS_SIZE, fontParams.getSize(), FONT_PARAMS_FONT_NAME, fontParams.getFontName(), FONT_PARAMS_FONT_TYPE, fontParams.getFontType());
parameters.set(FONT_PARAMS_THREE_DIMENSIONAL, fontParams.isThreeDimensional(),
FONT_PARAMS_PRECISION, fontParams.getPrecision(),
FONT_PARAMS_COLOR, fontParams.getColor().getRGB(),
FONT_PARAMS_BRIGHTNESS, fontGUI.getColorEditor().getBrightness(),
FONT_PARAMS_GLYPHS_SIZE, fontParams.getSize(),
FONT_PARAMS_FONT_NAME, fontParams.getFontName(),
FONT_PARAMS_FONT_TYPE, fontParams.getFontType());
}
private void updateParams()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment