Search in sources :

Example 1 with CompositeGUIVoidCommand

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

the class TestPencilTextStyle method testWidgetsGoodStateWhenBadPencilUsed.

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

Example 2 with CompositeGUIVoidCommand

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

the class TestPencilTextStyle method testSelectBPencil.

@Test
public void testSelectBPencil() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesText, updateIns).execute();
    clickOnbButton.execute();
    assertEquals(TextPosition.BOT, ((IText) pencil.createShapeInstance()).getTextPosition());
    assertTrue(bButton.isSelected());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Test(org.junit.Test)

Example 3 with CompositeGUIVoidCommand

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

the class TestPencilTextStyle method testSelectBLPencil.

@Test
public void testSelectBLPencil() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesText, updateIns).execute();
    clickOnblButton.execute();
    assertEquals(TextPosition.BOT_LEFT, ((IText) pencil.createShapeInstance()).getTextPosition());
    assertTrue(blButton.isSelected());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Test(org.junit.Test)

Example 4 with CompositeGUIVoidCommand

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

the class TestPencilTextStyle method testSelectTLPencil.

@Test
public void testSelectTLPencil() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesText, updateIns).execute();
    clickOntlButton.execute();
    assertEquals(TextPosition.TOP_LEFT, ((IText) pencil.createShapeInstance()).getTextPosition());
    assertTrue(tlButton.isSelected());
}
Also used : CompositeGUIVoidCommand(net.sf.latexdraw.instruments.CompositeGUIVoidCommand) Test(org.junit.Test)

Example 5 with CompositeGUIVoidCommand

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

the class TestPencilTextStyle method testSelectLPencil.

@Test
public void testSelectLPencil() {
    new CompositeGUIVoidCommand(activatePencil, pencilCreatesText, updateIns).execute();
    clickOnlButton.execute();
    assertEquals(TextPosition.LEFT, ((IText) pencil.createShapeInstance()).getTextPosition());
    assertTrue(lButton.isSelected());
}
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