UnHighlighting a subsytem in a Simulink model

조회 수: 10 (최근 30일)
Nataraj
Nataraj 2013년 4월 16일
편집: subhra behera 2021년 8월 18일
Hello everyone,
As a beginner I am struggling with hilite_system functionality of Matlab. In my project I have to highlight certain blocks which I perform using hilite_system. But while unhighlighting these blocks, I have to perform each block individually. Their is an option in the menubar -> View - Remove Highlighting which removes all the highlighting of all the blocks. My question is that can I perform this(removing highlighting of all blocks by one command) via code?
Thanks in advance.
ThN

답변 (2개)

Kaustubha Govind
Kaustubha Govind 2013년 4월 16일
Do you have the path to the block(s) that was used with the hilite_system command? If yes, this might work to undo the highlighting:
>> set_param(gcb,'HiliteAncestors', 'none');
  댓글 수: 1
subhra behera
subhra behera 2021년 8월 18일
편집: subhra behera 2021년 8월 18일
I think the best way is to use
This will remove all highlighting models
>>SLStudio.Utils.RemoveHighlighting(get_param(bdroot,'handle'))

댓글을 달려면 로그인하십시오.


Nataraj
Nataraj 2013년 4월 18일
Hi Kaustubha,
Thankyou very much for the reply. I do use similar trick by if true % hilite_system(handle,'none') end But the problem is that every time I change the hilite, the corresponding blocks pops ups and it is annoying. If you have any other solution let me know.
Thanks in advance. ThN
  댓글 수: 1
P Lepage
P Lepage 2020년 11월 18일
For anyone who might end up on this page in the future, what you can do to avoid this is copy the hilite_system fonction file and comment out the parts where the model screen is resized.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Modeling에 대해 자세히 알아보기

제품

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by