Opened 7 years ago

Closed 7 years ago

#4490 closed defect (fixed)

Display issues with Modelica Trunk

Reported by: ceraolo Owned by: adeas31
Priority: high Milestone: 1.12.0
Component: OMEdit Version:
Keywords: Cc:

Description

MSL trunk contains changes in the way some icons are displayed.
For instance MSL 3.2.2 RealExpression icon contains:

        Rectangle(
          extent={{-100,40},{100,-40}},
          lineColor={0,0,0},
          lineThickness=5.0,
          fillColor={235,235,235},
          fillPattern=FillPattern.Solid,
          borderPattern=BorderPattern.Raised),

Since lineTickness=0.5 was too big this code has been changed into:

       Rectangle(
          extent={{-100,40},{100,-40}},
          fillColor={235,235,235},
          fillPattern=FillPattern.Solid,
          borderPattern=BorderPattern.Raised),

But this is badly displayed by OMEdit: the rectangle border line is partially displayed, depending on the position of the component on screen and the zoom level. In some cases no rectangle is visible.
The final result is ugly (compare MSL.png with trunk.png)
Since AFAIK all the models involved by this recent modifications have borderPattern=BorderPattern.Raised, maybe the issue depends on this parameter?
Is this an OMEdit or a MSL (trunk) issue?

Attachments (2)

Trunk.png (22.5 KB) - added by ceraolo 7 years ago.
MSL.png (19.2 KB) - added by ceraolo 7 years ago.

Download all attachments as: .zip

Change History (7)

Changed 7 years ago by ceraolo

Changed 7 years ago by ceraolo

comment:1 Changed 7 years ago by adeas31

  • Component changed from *unknown* to OMEdit
  • Owner changed from somebody to adeas31
  • Status changed from new to accepted

This is an OMEdit issue.

I think we should use anti-aliasing to avoid such issues with lines of very small thickness.

comment:2 Changed 7 years ago by ceraolo

Just a curiosity,
since no value is explicitly set, thickness is the same as other standard components such s blocks, shouldn't it? Why the issue shows up only here?

comment:3 Changed 7 years ago by adeas31

I guess its because of different scaling we get from the its extents. Mostly others are squares.

comment:4 Changed 7 years ago by ceraolo

But resizing shapes should not resize line thickness. The default line width is 0.25 mm, i.e. one pixel on a standard (96dpi) screen.
Also on Macs, which by standard have 72 dpi, 0.25 mm should correspond, rounding to the nearest integer and without anti-alising, to one pixel.
I suppose here there is something different.

comment:5 Changed 7 years ago by adeas31

  • Resolution set to fixed
  • Status changed from accepted to closed

Fixed in 47db56/OMEdit.

Note: See TracTickets for help on using tickets.