Examples of IText


Examples of net.sf.latexdraw.glib.models.interfaces.shape.IText

  }


  @Test
  public void testRPutCoordRotationWText() throws ParseException {
    IText txt = (IText)parser.parsePSTCode("\\rput{W}(1,2){coucou}").get().getShapeAt(0); //$NON-NLS-1$
    assertTrue(PSTParser.errorLogs().isEmpty());
    assertEquals("coucou", txt.getText()); //$NON-NLS-1$
    assertEquals(IShape.PPC, txt.getPosition().getX(), 0.001);
    assertEquals(-2.*IShape.PPC, txt.getPosition().getY(), 0.001);
    assertEquals(Math.toRadians(-90.), txt.getRotationAngle(), 0.001);
  }
View Full Code Here

Examples of net.sf.latexdraw.glib.models.interfaces.shape.IText

  }


  @Test
  public void testRPutCoordRotationNText() throws ParseException {
    IText txt = (IText)parser.parsePSTCode("\\rput{N}(1,2){coucou}").get().getShapeAt(0); //$NON-NLS-1$
    assertTrue(PSTParser.errorLogs().isEmpty());
    assertEquals("coucou", txt.getText()); //$NON-NLS-1$
    assertEquals(IShape.PPC, txt.getPosition().getX(), 0.001);
    assertEquals(-2.*IShape.PPC, txt.getPosition().getY(), 0.001);
    assertEquals(0., txt.getRotationAngle(), 0.001);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.