Simulink mask display programmatically, how to make line shift?

I use this command to set up mask display programmatically:
set_param( gcbh,'MaskDisplay', ['port_label(''input'', 1, ''in1''); port_label(''output'', 1, ''out1'');'] );
In the mask editor it afterwards appears in one line as:
port_label('input', 1, 'in1'); port_label('output', 1, 'out1');
which is a bit annoying when the block has many ports.
How can I make it appear in multiple lines, like:
port_label('input', 1, 'in1')
port_label('output', 1, 'out1')

 채택된 답변

Fangjun Jiang
Fangjun Jiang 2018년 9월 19일
use char(10),
set_param( gcbh,'MaskDisplay', ['port_label(''input'', 1, ''in1'');',char(10),'port_label(''output'', 1, ''out1'');'] );

추가 답변 (1개)

카테고리

도움말 센터File Exchange에서 Author Block Masks에 대해 자세히 알아보기

제품

릴리스

R2018b

질문:

2018년 9월 19일

답변:

2018년 9월 20일

Community Treasure Hunt

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

Start Hunting!

Translated by