use of net.sf.latexdraw.models.interfaces.shape.PlotStyle in project latexdraw by arnobl.
the class TestHandPlotStyle method testSelectPOLYGONStyleHand.
@Test
public void testSelectPOLYGONStyleHand() {
new CompositeGUIVoidCommand(activateHand, selectionAddDot, selectionAddPlot, selectionAddPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.POLYGON);
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 testSelectCCURVEStyleHand.
@Test
public void testSelectCCURVEStyleHand() {
new CompositeGUIVoidCommand(activateHand, selectionAddDot, selectionAddPlot, selectionAddPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.CCURVE);
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 testSelectECURVEStyleHand.
@Test
public void testSelectECURVEStyleHand() {
new CompositeGUIVoidCommand(activateHand, selectionAddDot, selectionAddPlot, selectionAddPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.ECURVE);
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 testSelectDOTSStylePencil.
@Test
public void testSelectDOTSStylePencil() {
new CompositeGUIVoidCommand(activatePencil, pencilCreatesPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.DOTS);
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 testSelectLINEStylePencil.
@Test
public void testSelectLINEStylePencil() {
new CompositeGUIVoidCommand(activatePencil, pencilCreatesPlot, updateIns).execute();
PlotStyle style = plotStyleCB.getSelectionModel().getSelectedItem();
selectplotStyleCB.execute(PlotStyle.LINE);
PlotStyle newStyle = plotStyleCB.getSelectionModel().getSelectedItem();
assertEquals(newStyle, ((IPlot) pencil.createShapeInstance()).getPlotStyle());
assertNotEquals(style, newStyle);
}
Aggregations