Package org.emftrace.emffit.ui.commands.hypertexts

Examples of org.emftrace.emffit.ui.commands.hypertexts.SetHypertextTextElementVisibleContentCommand


  }


  @Override
  protected void setLinkCaptionAtModel(int offset, String newCaption) {
    new SetHypertextTextElementVisibleContentCommand(hypertext, offset, newCaption).runWithoutUnicaseCommand();
  }
View Full Code Here


   *            the offset of the link
   * @param newCaption
   *            the new text for the link
   */
  protected void setLinkCaptionAtModel(int offset, String newCaption) {
    new SetHypertextTextElementVisibleContentCommand(hypertext, offset,
        newCaption).run();
  }
View Full Code Here

   
    hypertext.getContent().add(term1);
    hypertext.getContent().add(link);
    hypertext.getContent().add(term2);
   
    new SetHypertextTextElementVisibleContentCommand(hypertext, 4, "newlink").runWithoutUnicaseCommand();
   
    assertEquals(3, hypertext.getContent().size());
    assertEquals("foo ", hypertext.getContent().get(0).getVisibleContent());
    assertEquals("newlink", hypertext.getContent().get(1).getVisibleContent());
    assertEquals(" bar", hypertext.getContent().get(2).getVisibleContent());
   
    new SetHypertextTextElementVisibleContentCommand(hypertext, 5, " newbar").runWithoutUnicaseCommand();
   
    assertEquals(3, hypertext.getContent().size());
    assertEquals("foo ", hypertext.getContent().get(0).getVisibleContent());
    assertEquals("newlink", hypertext.getContent().get(1).getVisibleContent());
    assertEquals(" newbar", hypertext.getContent().get(2).getVisibleContent());
View Full Code Here

TOP

Related Classes of org.emftrace.emffit.ui.commands.hypertexts.SetHypertextTextElementVisibleContentCommand

Copyright © 2018 www.massapicom. 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.