use of net.sf.latexdraw.models.interfaces.shape.PlotStyle in project latexdraw by arnobl.
the class TestHandPlotStyle method testSelectCURVEStyleHand.
@Test
public void testSelectCURVEStyleHand() {
new CompositeGUIVoidCommand(activateHand, selectionAddDot, selectionAddPlot, selectionAddPlot, updateIns).execute();
selectplotStyleCB.execute(PlotStyle.ECURVE);
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.CURVE);
PlotStyle newStyle = plotStyleCB.getSelectionModel().getSelectedItem();
assertEquals(plotStyleCB.getSelectionModel().getSelectedItem(), ((IPlot) drawing.getSelection().getShapeAt(1)).getPlotStyle());
assertEquals(plotStyleCB.getSelectionModel().getSelectedItem(), ((IPlot) drawing.getSelection().getShapeAt(2)).getPlotStyle());
assertNotEquals(style, newStyle);
}
use of net.sf.latexdraw.models.interfaces.shape.PlotStyle in project latexdraw by arnobl.
the class TestHandPlotStyle method testSelectDOTSStyleHand.
@Test
public void testSelectDOTSStyleHand() {
new CompositeGUIVoidCommand(activateHand, selectionAddDot, selectionAddPlot, selectionAddPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.DOTS);
PlotStyle newStyle = plotStyleCB.getSelectionModel().getSelectedItem();
assertEquals(plotStyleCB.getSelectionModel().getSelectedItem(), ((IPlot) drawing.getSelection().getShapeAt(1)).getPlotStyle());
assertEquals(plotStyleCB.getSelectionModel().getSelectedItem(), ((IPlot) drawing.getSelection().getShapeAt(2)).getPlotStyle());
assertNotEquals(style, newStyle);
}
use of net.sf.latexdraw.models.interfaces.shape.PlotStyle in project latexdraw by arnobl.
the class TestHandPlotStyle method testSelectLINEStyleHand.
@Test
public void testSelectLINEStyleHand() {
new CompositeGUIVoidCommand(activateHand, selectionAddDot, selectionAddPlot, selectionAddPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.LINE);
PlotStyle newStyle = plotStyleCB.getSelectionModel().getSelectedItem();
assertEquals(plotStyleCB.getSelectionModel().getSelectedItem(), ((IPlot) drawing.getSelection().getShapeAt(1)).getPlotStyle());
assertEquals(plotStyleCB.getSelectionModel().getSelectedItem(), ((IPlot) drawing.getSelection().getShapeAt(2)).getPlotStyle());
assertNotEquals(style, newStyle);
}
use of net.sf.latexdraw.models.interfaces.shape.PlotStyle in project latexdraw by arnobl.
the class TestPencilPlotStyle method testSelectCURVEStylePencil.
@Test
public void testSelectCURVEStylePencil() {
new CompositeGUIVoidCommand(activatePencil, pencilCreatesPlot, updateIns).execute();
selectplotStyleCB.execute(PlotStyle.ECURVE);
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.CURVE);
PlotStyle newStyle = plotStyleCB.getSelectionModel().getSelectedItem();
assertEquals(newStyle, ((IPlot) pencil.createShapeInstance()).getPlotStyle());
assertNotEquals(style, newStyle);
}
use of net.sf.latexdraw.models.interfaces.shape.PlotStyle in project latexdraw by arnobl.
the class TestPencilPlotStyle method testSelectECURVEStylePencil.
@Test
public void testSelectECURVEStylePencil() {
new CompositeGUIVoidCommand(activatePencil, pencilCreatesPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.ECURVE);
PlotStyle newStyle = plotStyleCB.getSelectionModel().getSelectedItem();
assertEquals(newStyle, ((IPlot) pencil.createShapeInstance()).getPlotStyle());
assertNotEquals(style, newStyle);
}
Aggregations