Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Epsilon » Using 2 labels on a node [GMF editor]
Using 2 labels on a node [GMF editor] [message #1747300] Fri, 11 November 2016 19:19 Go to next message
Gonçalo Miguéis is currently offline Gonçalo MiguéisFriend
Messages: 1
Registered: November 2016
Junior Member
Hello there.

i'm trying to find a way to have two labels on a node in a GMF editor.
I'm allready showing a label from the emf file that represents the name. I want this to be locked (with the type of the node) and have another one to represent a id (or another name) that its changeable. The second one i don't have any ideia how to create it.
I found a link that was helpfull ( but i wasn't still able to create it correctly. I allready have a eol file that changes some names from the editor and the folder aswell, i reckon this might be the file in which i should be able to do it but i just can't understand how :c
Re: Using 2 labels on a node [GMF editor] [message #1747428 is a reply to message #1747300] Mon, 14 November 2016 15:40 Go to previous message
Dimitris Kolovos is currently offline Dimitris KolovosFriend
Messages: 1612
Registered: July 2009
Location: York, UK
Senior Member


Adding a new label above the generated one using a polishing transformation should do the trick. Minimal example follows:

@namespace(uri="people", prefix="people")
package people;

class World {
	val Person[*] people;

class Person {
	attr String name;

var label : new GmfGraph!Label;
label.text = "Person";
		children.add(0, label);

Previous Topic:Visualize the generated model as UML diagram no as ecore
Next Topic:Provide getter for thrown object in EolUserException
Goto Forum:

Current Time: Fri Nov 16 11:39:02 GMT 2018

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

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

Back to the top