Book a Demo

Author Topic: Possiblity to show tagged value groups in different compartments?  (Read 5882 times)

kjourdan

  • EA User
  • **
  • Posts: 71
  • Karma: +0/-0
    • View Profile
I have created a stereotype that has tagged values in groups.  From the Project Browser, the Tagged Values window displays the tags in the groups as desired.  When this class is placed on a class diagram and tags are configured to be displayed, the tags are not compartmentalized.  Is there a way to display the tags on a diagram in groups or separate compartments?

PeterHeintz

  • EA Practitioner
  • ***
  • Posts: 1001
  • Karma: +59/-18
    • View Profile
Re: Possiblity to show tagged value groups in different compartments?
« Reply #1 on: May 24, 2016, 02:26:38 am »
I am not 100% sure, but I think there is no feature for that.
Such stuff works for properies but not for tagged values (99%).
Best regards,

Peter Heintz

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Possiblity to show tagged value groups in different compartments?
« Reply #2 on: May 24, 2016, 08:06:43 am »
There might be some complicated way through add-in and shape script. But out-of-the-box I can't see a way to accomplish that. In most of such cases you have to find a compromise of what would be possible at the extreme side and what is possible with a little effort but still serves the desired purpose.

q.

kjourdan

  • EA User
  • **
  • Posts: 71
  • Karma: +0/-0
    • View Profile
Re: Possiblity to show tagged value groups in different compartments?
« Reply #3 on: May 26, 2016, 09:17:20 pm »
Thanks.  Using ShapeScript with subshapes I was able to place the tags and values in these sub-shapes. Any idea how to print preceeding spaces?  For the subshapes, I can only have one alignment so my heading and data share alignment.  I would like to indent my tagged data from my heading to improve the view but the preceeding spaces are stripped out.
      println("   LowerLimitValue: #TAG:LowerLimitValue#");

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Possiblity to show tagged value groups in different compartments?
« Reply #4 on: May 26, 2016, 10:06:55 pm »
Shape script is very limited. You are probably out of luck here.

q.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Possiblity to show tagged value groups in different compartments?
« Reply #5 on: May 27, 2016, 04:19:56 am »
I think you can add coordinates for the placement of each sub-shape.

Here's an example of one that I use to print info from tags:

Code: [Select]
shape main
{
 // Initialisation Attributes - these must be
// before drawing commands
 noshadow = "true";
 h_align = "left";
 DefSize(340,140);
 Rectangle(0,0,100,100);
 AddSubShape("nameCompartment",90,20,3,0);
 AddSubShape("translations",90,20,3,0);
 //setPen(128,0,0);
 //SetFillColor(128,0,0);
 rectangle(-10,0,-1,100);
 

 shape nameCompartment
 {
h_align = "center";
editablefield = "name";
SetFontColor(128,0,0);
println("[#name#]");
  }
 shape translations
  {
println("[NL]: #TAG:Title NL#");
println("[FR]: #TAG:Title FR#");
  }
 shape borderblock {
  rectangle(-10,0,-1,100);
 }
}

decoration process
{
orientation="ne";
if (HasTag("CustomDevelopment", "True"))
{
setfillcolor(128,0,0);
SetPenColor(128,0,0);

//top of the wrench
startpath();
Moveto( 18,35);
ArcTo(5,5,47,47,4,22,28,45);
LineTo(47,29);
ArcTo(5,5,47,47,47,29,22,4);
lineto(36,18);
lineto(18,35);
EndPath();

fillandstrokepath();
//handle
startpath();
moveto(28,46);
lineto(79,97);
ArcTo(66,66,97,97,79,97,97,79);
lineto(46,28);
EndPath();

fillandstrokepath();
//screwdriver handle
startpath();
Moveto(70,44);
LineTo(97,15);
Lineto(85,3);
Lineto(55,29);
Lineto(58,32);
Lineto(84,8);
// Lineto(86,10);
// Lineto(61,35);
// Lineto(65,39);
Lineto(90,14);
Lineto(92,16);
Lineto(67,41);
Lineto(70,44);
EndPath();
fillandstrokepath();
//screwdriver point
startpath();
MoveTo(35,59);
LineTo(21,74);
LineTo(15,75);
LineTo(4,92);
LineTo(8,96);
LineTo(25,85);
LineTo(25,79);
LineTo(40,65);
LineTo(35,59);
EndPath();

fillandstrokepath();
}
}
 

Geert

kjourdan

  • EA User
  • **
  • Posts: 71
  • Karma: +0/-0
    • View Profile
Re: Possiblity to show tagged value groups in different compartments?
« Reply #6 on: May 30, 2016, 01:04:46 am »
Thanks for the help.  Decided to use left centering and indent my tags by using | character and then spaces.