Author Topic: Applying autocolouring from diagram legend based on inherited tagged values  (Read 1882 times)

Sparx_User_J

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Hello All,

I have defined tagged values on classifier blocks, and used them to classify instances on an Internal Block Diagram.

I was hoping that autocolouring function within the diagram legend on the IBD would read the inherited tagged values, and apply colours based on the values.

The tagged values are indeed showing up in the properties of the instances, but the autocolouring is not working as I had hoped, and only works if I manually select the tagged value on the instance.

Is there a way to get this to work? It is very time consuming to add tag values across all instances, whereas applying autocolouring all in one go based on the instance class tagged value would be far quicker.

Thanks, J

---

Edit:

Sparx Version: 15.2.1554
Sparx Edition: Corporate Edition
« Last Edit: February 22, 2024, 10:14:36 pm by Sparx_User_J »

ea0522

  • EA User
  • **
  • Posts: 67
  • Karma: +3/-0
    • View Profile
Hai, I'm not quite sure I understand your problem.

Regarding the auto color function: Did you check the box to have the Legend element do the auto coloring?
To check, double click on the Legend element and check the box in the right upper corner reading "Apply auto color".

Regarding the definition of the possible values available in the Tagged Values referenced by the Legend element, I wrote a script to generate that list automagically. Just let me know when interested.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 12848
  • Karma: +535/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
autocolor will only work on tagged values of the element, not tagged values of the classifier.

Geert

Sparx_User_J

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Hello - thanks for taking the time to provide an answer :)

Yes, I have got the tick applied in the box in the right upper corner reading "Apply auto color". I will try to explain a bit better the context for what I am trying to do.

- Port Library: used to create port classes. Port Type 1, Port Type 2... etc.
- Block Definition Diagrams: used to create the blocks which make up the system. Subsystem 1, Subsystem 2... etc. Port instances from the library are also dragged onto these blocks.
- Internal Block Diagram: used to show the interrelationships between instances of the Subsystems defined in BDDs by adding connectors between ports.

Autocolouring is already working, but only if I manually add a tagged value to each port instance on the IBD, however, I would like it use the tagged value inherited from the blocks in the BDDs.

Geert, thanks for your response. The concept of inheritance would suggest it should work but it seems this isn't a capability of Sparx then?

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 12848
  • Karma: +535/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Geert, thanks for your response. The concept of inheritance would suggest it should work but it seems this isn't a capability of Sparx then?
Yes the "inherited" tags show up on the properties, but they are not actually stored on the element itself.
The legend with auto-color only looks at the tagged values of the element, not at the "inherited" tagged values.

Geert