-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add assert condition block #3985
Add assert condition block #3985
Conversation
mestinso
commented
May 11, 2022
•
edited
Loading
edited
- Block is useful for applying asserts via graphical layer (rather than via equations)
c845f9c
to
2525db4
Compare
f4360cc
to
9831065
Compare
The block has been restructured based on the previous discussion. Note that the initial scale of the block is 0.04 to be in alignment with the default height of the BooleanExpression block, which this block is expected to be paired with typically. See the picture below (top is the default rather than the bottom): |
9831065
to
509b2ec
Compare
Instead of using unusual That said, I think I'd prefer the full 20x20 size, although the text assert should probably be made smaller to look nice. |
A couple notes here:
I'm open to changes, but just wanted to make you aware of why I made the choices I did. Basically they aren't new choices, just following previous examples and choices already made. |
An option for icon could be to disable the icon of partial model in extends clause by |
OK, thanks for explaining the design. Matching the style of
The problem with the |
- Block is useful for applying asserts via graphical layer (rather than via equations)
509b2ec
to
fd38d41
Compare
Ok, so based on the discussion I went ahead and removed the initial scale annotation. Now by default the scale will match the 2nd example in the picture above. I think the PR should be good to go at this point unless any additional concerns. |
Co-authored-by: Henrik Tidefelt <henrikt@wolfram.com>
Co-authored-by: Henrik Tidefelt <henrikt@wolfram.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Function and icon seems fine. Just leaving some suggestions about wording.
@beutlich Is it allowed to link to |
I have changed the default of |
And you're sure it wouldn't make more sense to use the same default as the Modelica language |
@henrikt-ma No, I'm not. :-( I'll revert this. |
This reverts commit 8fea091.
@beutlich How about #3985 (comment) ? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The general idea is good, but I would like to change the message and the test-case as indicated.
Co-authored-by: Hans Olsson <HansOlsson@users.noreply.github.com>
Co-authored-by: Henrik Tidefelt <henrikt@wolfram.com>
Made the minor changes as requested (documentation paragraph changes, removal of getInstanceName(), and changing the wording from terminate to abort). Let me know if anything else, otherwise, looking to approve and merge this this here. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fine to me.