Opened 8 years ago

Last modified 3 years ago

#4410 accepted defect

moving a replaceable object in the block diagram duplicates the graphical annotation in text view

Reported by: Andrea Bartolini Owned by: Adrian Pop
Priority: critical Milestone:
Component: OMEdit Version: v1.12.0
Keywords: Cc: Adrian Pop

Description

consider the following model (also attached):

package test
  partial model A
    annotation(
      Diagram,
      Icon(graphics = {Rectangle(extent = {{-100, 100}, {100, -100}}), Text(origin = {2, -1}, extent = {{-32, 41}, {32, -41}}, textString = "A")}));
  end A;

  model B
    extends A;
  end B;

model C
  replaceable B b1 constrainedby A annotation(
    Placement(visible = true, transformation(origin = {0, 0}, extent = {{-10, -10}, {10, 10}}, rotation = 0)));
end C;

end test;

now open the model C and move the model B in the block diagram, the graphical annotation in the text view is duplicated as follows:

model C
  replaceable test.B b1 annotation(
      Placement(visible = true, transformation(origin = {-24, 0}, extent = {{-10, -10}, {10, 10}}, rotation = 0))) constrainedby A annotation(
    Placement(visible = true, transformation(origin = {0, 0}, extent = {{-10, -10}, {10, 10}}, rotation = 0)));
end C; 

this behavior seems depend from the presence of the clause "constrainedby"

OMEdit 1.12.0~dev-290-g1b6ac20
Connected to OpenModelica 1.12.0~dev-703-g46bfb1f

sysop: linux Ubuntu 16.04

Attachments (1)

test.mo (441 bytes ) - added by Andrea Bartolini 8 years ago.

Download all attachments as: .zip

Change History (10)

by Andrea Bartolini, 8 years ago

Attachment: test.mo added

comment:1 by Adeel Asghar, 8 years ago

Cc: Adrian Pop added

comment:2 by Adrian Pop, 8 years ago

Owner: changed from Adeel Asghar to Adrian Pop
Status: newaccepted

comment:3 by spinnau@…, 8 years ago

This can also be reproduced with older versions (tested with OMEdit v1.10.0-dev.162+ga6abbd9 Connected to OMCompiler v1.11.0-dev.16+g6312752).

If the constrainedby A clause will be added after the annotation, then the described duplication does not occur.

comment:4 by Adeel Asghar, 7 years ago

Milestone: 1.12.01.13.0

comment:5 by Francesco Casella, 6 years ago

Milestone: 1.13.01.14.0

Rescheduled to 1.14.0 after 1.13.0 releasee

comment:6 by Francesco Casella, 5 years ago

Milestone: 1.14.01.16.0

Releasing 1.14.0 which is stable and has many improvements w.r.t. 1.13.2. This issue is rescheduled to 1.16.0

comment:7 by Francesco Casella, 4 years ago

Milestone: 1.16.01.17.0

Retargeted to 1.17.0 after 1.16.0 release

comment:8 by Francesco Casella, 4 years ago

Milestone: 1.17.01.18.0

Retargeted to 1.18.0 because of 1.17.0 timed release.

comment:9 by Francesco Casella, 3 years ago

Milestone: 1.18.0

Ticket retargeted after milestone closed

Note: See TracTickets for help on using tickets.