Search in sources :

Example 66 with CompositeGUIVoidCommand

use of net.sf.latexdraw.instruments.CompositeGUIVoidCommand in project latexdraw by arnobl.

the class TestPencilFillingStyle method testWidgetsGoodStateWhenGoodPencilUsed.

@Test
public void testWidgetsGoodStateWhenGoodPencilUsed() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesRec, updateIns).execute();
    assertTrue(titledPane.isVisible());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Test(org.junit.Test)

Example 67 with CompositeGUIVoidCommand

use of net.sf.latexdraw.instruments.CompositeGUIVoidCommand in project latexdraw by arnobl.

the class TestPencilFillingStyle method testPickGradEndColourPencil.

@Test
public void testPickGradEndColourPencil() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesRec, selectGradStyle, updateIns).execute();
    Color col = gradEndColButton.getValue();
    pickgradEndCol.execute();
    assertEquals(gradEndColButton.getValue(), pencil.createShapeInstance().getGradColEnd().toJFX());
    assertNotEquals(col, gradEndColButton.getValue());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Color(javafx.scene.paint.Color) Test(org.junit.Test)

Example 68 with CompositeGUIVoidCommand

use of net.sf.latexdraw.instruments.CompositeGUIVoidCommand in project latexdraw by arnobl.

the class TestPencilGridStyle method testPickLineColourPencil.

@Test
public void testPickLineColourPencil() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesGrid, updateIns).execute();
    Color col = colourSubGrid.getValue();
    pickcolourSubGrid.execute();
    assertEquals(colourSubGrid.getValue(), ((IGrid) pencil.createShapeInstance()).getSubGridColour().toJFX());
    assertNotEquals(col, colourSubGrid.getValue());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Color(javafx.scene.paint.Color) IGrid(net.sf.latexdraw.models.interfaces.shape.IGrid) Test(org.junit.Test)

Example 69 with CompositeGUIVoidCommand

use of net.sf.latexdraw.instruments.CompositeGUIVoidCommand in project latexdraw by arnobl.

the class TestPencilGridStyle method testWidgetsGoodStateWhenGoodPencilUsed.

@Test
public void testWidgetsGoodStateWhenGoodPencilUsed() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesGrid, updateIns).execute();
    assertTrue(mainPane.isVisible());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Test(org.junit.Test)

Example 70 with CompositeGUIVoidCommand

use of net.sf.latexdraw.instruments.CompositeGUIVoidCommand in project latexdraw by arnobl.

the class TestPencilLineStyle method testWidgetsGoodStateWhenNotThicknessablePencil.

@Test
public void testWidgetsGoodStateWhenNotThicknessablePencil() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesText, updateIns).execute();
    assertFalse(thicknessField.isVisible());
    assertTrue(lineColButton.isVisible());
    assertFalse(lineColButton.isDisabled());
    assertFalse(lineCB.isVisible());
    assertFalse(bordersPosCB.isVisible());
    assertFalse(frameArcField.isVisible());
    assertFalse(showPoints.isVisible());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Test(org.junit.Test)

Aggregations

CompositeGUIVoidCommand (net.sf.latexdraw.instruments.CompositeGUIVoidCommand)218 Test (org.junit.Test)218 ArrowStyle (net.sf.latexdraw.models.interfaces.shape.ArrowStyle)34 IArrowableSingleShape (net.sf.latexdraw.models.interfaces.shape.IArrowableSingleShape)34 Color (javafx.scene.paint.Color)20 PlotStyle (net.sf.latexdraw.models.interfaces.shape.PlotStyle)12 IGrid (net.sf.latexdraw.models.interfaces.shape.IGrid)4 PlottingStyle (net.sf.latexdraw.models.interfaces.shape.PlottingStyle)4 AxesStyle (net.sf.latexdraw.models.interfaces.shape.AxesStyle)2 BorderPos (net.sf.latexdraw.models.interfaces.shape.BorderPos)2 FillingStyle (net.sf.latexdraw.models.interfaces.shape.FillingStyle)2 IDot (net.sf.latexdraw.models.interfaces.shape.IDot)2 LineStyle (net.sf.latexdraw.models.interfaces.shape.LineStyle)2 TicksStyle (net.sf.latexdraw.models.interfaces.shape.TicksStyle)2 DotStyle (net.sf.latexdraw.models.interfaces.shape.DotStyle)1