use of net.sf.latexdraw.model.api.shape.ArrowableSingleShape in project latexdraw by arnobl.
the class TestParsingArrow method testArrowheadLeftNone.
@ParameterizedTest
@MethodSource("cmds")
public void testArrowheadLeftNone(final Tuple<String, String> cmd) {
parser(cmd.a + "{<-}" + cmd.b);
final ArrowableSingleShape line = (ArrowableSingleShape) parsedShapes.get(0);
assertEquals(ArrowStyle.LEFT_ARROW, line.getArrowStyle(0));
assertEquals(ArrowStyle.NONE, line.getArrowStyle(1));
}
use of net.sf.latexdraw.model.api.shape.ArrowableSingleShape in project latexdraw by arnobl.
the class TestParsingArrow method testArrowCNone.
@ParameterizedTest
@MethodSource("cmds")
public void testArrowCNone(final Tuple<String, String> cmd) {
parser(cmd.a + "{C-}" + cmd.b);
final ArrowableSingleShape line = (ArrowableSingleShape) parsedShapes.get(0);
assertEquals(ArrowStyle.SQUARE_END, line.getArrowStyle(0));
assertEquals(ArrowStyle.NONE, line.getArrowStyle(1));
}
use of net.sf.latexdraw.model.api.shape.ArrowableSingleShape in project latexdraw by arnobl.
the class TestParsingArrow method testNoneRightSquareBracket.
@ParameterizedTest
@MethodSource("cmds")
public void testNoneRightSquareBracket(final Tuple<String, String> cmd) {
parser(cmd.a + "{-[}" + cmd.b);
final ArrowableSingleShape line = (ArrowableSingleShape) parsedShapes.get(0);
assertEquals(ArrowStyle.NONE, line.getArrowStyle(0));
assertEquals(ArrowStyle.LEFT_SQUARE_BRACKET, line.getArrowStyle(1));
}
use of net.sf.latexdraw.model.api.shape.ArrowableSingleShape in project latexdraw by arnobl.
the class TestParsingArrow method testParamArrowsizeDim.
@ParameterizedTest
@MethodSource("cmds")
public void testParamArrowsizeDim(final Tuple<String, String> cmd) {
parser(cmd.a + "[arrows=<->, arrowsize=2cm]" + cmd.b);
final ArrowableSingleShape line = (ArrowableSingleShape) parsedShapes.get(0);
assertEquals(2d * Shape.PPC, line.getArrowSizeDim(), 0.0001);
assertEquals(0d, line.getArrowSizeNum(), 0.0001);
}
use of net.sf.latexdraw.model.api.shape.ArrowableSingleShape in project latexdraw by arnobl.
the class TestParsingArrow method testNoneArrowheadRight.
@ParameterizedTest
@MethodSource("cmds")
public void testNoneArrowheadRight(final Tuple<String, String> cmd) {
parser(cmd.a + "{->}" + cmd.b);
final ArrowableSingleShape line = (ArrowableSingleShape) parsedShapes.get(0);
assertEquals(ArrowStyle.RIGHT_ARROW, line.getArrowStyle(1));
assertEquals(ArrowStyle.NONE, line.getArrowStyle(0));
}
Aggregations