Book a Demo

Author Topic: Display of element compartments  (Read 3655 times)

GrahamL

  • EA User
  • **
  • Posts: 111
  • Karma: +2/-0
    • View Profile
Display of element compartments
« on: February 23, 2021, 03:20:32 am »
Hi
Is it possible to change the order in which compartments are displayed?
I have a package diagram on which the contents of the package are displayed and the notes compartment is displayed below this.
What I would like is for the notes compartment to be displayed first.
Is this possible

Thanks

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Display of element compartments
« Reply #1 on: February 23, 2021, 04:38:58 am »
No, except you write a shape script. That however will most likely be very tedious and not give you good results.

q.

GrahamL

  • EA User
  • **
  • Posts: 111
  • Karma: +2/-0
    • View Profile
Re: Display of element compartments
« Reply #2 on: February 23, 2021, 04:42:05 am »
Thanks for confirming my suspicioms >:(

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: Display of element compartments
« Reply #3 on: February 23, 2021, 07:40:08 am »
I guess in that case you have to blame OMG. PP. 99 of UML 2.5 reads

Quote
Some compartments in Classifier shapes are mandatory and shall be supported by tools that exhibit concrete syntax conformance. Others are optional, in the sense that a conforming tool may not support such compartments.

Any compartment may be suppressed. A separator line is not drawn for a suppressed compartment. If a compartment is suppressed, no inference may be drawn about the presence or absence of elements in it.

The compartment named “attributes” contains notation for the Properties that are reached via the attribute property. The attributes compartment is mandatory and always appears above other compartments, if it is not suppressed.

The compartment named “operations” contains notation for Operations. The operations compartment is mandatory and always appears below the attributes compartment, if it is not suppressed. The operations compartment is used for Classifiers that own Operations, including Class (see 11.4), DataType (see 10.2) and Interface (see 10.4).

q.

Jayson

  • EA User
  • **
  • Posts: 363
  • Karma: +1/-0
    • View Profile
Re: Display of element compartments
« Reply #4 on: February 24, 2021, 01:48:10 pm »
In fairness, custom shape scripts to do this isn't THAT onerous - especially if you have a copy of qwerty's e-book (I recommend all of them).
However, probably still not worth the hassle for such a minor outcome.