Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Graphiti » Multiple textfields in AddFeature
Multiple textfields in AddFeature [message #1210462] Tue, 26 November 2013 01:44 Go to next message
Soeren M is currently offline Soeren MFriend
Messages: 77
Registered: September 2011
Member
Hey all,

I want two editable textfields in my Shape(attachment), so I've created it like this:

...
Shape shapeName = peCreateService.createShape(containerShape, false);
Shape shapeDelay = peCreateService.createShape(containerShape, false);

// create and set text graphics algorithm
Text name = gaService.createText(shapeName, addedClass.getName());
name.setValue("name");
gaService.setLocationAndSize(name, 0, 0, width, 20);

Text delay = gaService.createText(shapeDelay, addedClass.getName());
delay.setValue("delay");
gaService.setLocationAndSize(delay, 0, height - 20, width, 20);

IDirectEditingInfo directEditingInfo = ...



Is that the correct way? And if so, how do I edit both?
With the DirectEditingFeature I am able to select on by one, but just the upper textfield gets updated, even if I edit the lower one.
I am a bit confused that I didnt find sth simliar, but maybe my search skills are just bad.

Thanks
  • Attachment: asd.png
    (Size: 1.04KB, Downloaded 173 times)
Re: Multiple textfields in AddFeature [message #1213510 is a reply to message #1210462] Wed, 27 November 2013 09:14 Go to previous message
Soeren M is currently offline Soeren MFriend
Messages: 77
Registered: September 2011
Member
Short answer: No its not.

Its a little bit embarrassing, but until now I obv ignored the correct workflow with Graphiti; Ive never created my own EMF-Model.
But in this use case I had to and thats the simple "solution".
Previous Topic:Parent/Child hierarchy for shapes and GraphicsAlgorithm
Next Topic:Transaction use in Graphiti
Goto Forum:
  


Current Time: Thu Mar 28 08:26:37 GMT 2024

Powered by FUDForum. Page generated in 0.02412 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top