How to prevent line break after blank space when plotting text using annotation textbox?

8 ビュー (過去 30 日間)
if I try to plot this:
x = 'The blank spaces break line';
figure(1)
annotation('textbox',[0.178 0.425 0 0],'String',x);
At every blank space the text breaks to a new line. How to prevent that?

採用された回答

KALYAN ACHARJYA
KALYAN ACHARJYA 2019 年 7 月 5 日
編集済み: KALYAN ACHARJYA 2019 年 7 月 5 日
x = 'The blank spaces break line';
figure(1)
annotation('textbox',[0.1 0.1 .35 .1],'String',x);
%....................^^ Dimension
I have changed it, its now working, more detail dimention example, check here
Hope it helps!
  2 件のコメント
Conrado Neto
Conrado Neto 2019 年 7 月 5 日
Oh, so it is because the annotation textbox had no dimensions, so the text was squeezing itself
thank you very much!
KALYAN ACHARJYA
KALYAN ACHARJYA 2019 年 7 月 5 日
編集済み: KALYAN ACHARJYA 2019 年 7 月 5 日
Welcome @Conrado

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangePrinting and Saving についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by