How can make the word in Table not-split?

5 ビュー (過去 30 日間)
John
John 2020 年 9 月 25 日
コメント済み: John 2020 年 9 月 29 日
In above table, the word is split. How can keep the words "right" and "left" (and any word) not split?
  2 件のコメント
Walter Roberson
Walter Roberson 2020 年 9 月 25 日
Would I be correct that you are talking about Report Generator product?
John
John 2020 年 9 月 25 日
Hi, Walter:
Yes, as tags indicate. It looks bad. Hope there is a way to make it right.
Thanks.

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

採用された回答

Rhea Chandy
Rhea Chandy 2020 年 9 月 28 日
Hi John,
It’s my understand that you are using Report Generator and you want to avoid hyphenation, i.e. Splitting the words in a table entry. You can use Hyphenation class to specify the hyphenation behaviour of paragraphs and table cells.
h = mlreportgen.dom.Hyphenation(false)
This will disable hyphenation and set the property Value to [].
You can refer to this documentation to learn about Hyphenation class and how to apply it.
  3 件のコメント
Rhea Chandy
Rhea Chandy 2020 年 9 月 29 日
Hi John,
From my understanding, you are using an older release.Before R2020b release, in which, when hyphenation was enabled, a line break and hyphenation character could occur anywhere in a word in a paragraph or table.
This behaviour has been changed in R2020b, in which, when hyphenation is enabled, a line break and hyphenation character occur only at the end of a syllable. If a table cell contains a long sequence of numbers or letters that have no clear syllable breaks, overflow can occur. The table stretches to accommodate the overflow.
This is information is listed in the documentation about Hyphenation class.
John
John 2020 年 9 月 29 日
This is what the link says:
Starting in R2020b:
  • Hyphenation is disabled, by default, for paragraphs and tables.
  • When hyphenation is disabled, where possible, a line break occurs between words. If necessary to prevent overflow, a line break can occur anywhere in a word.
  • When hyphenation is enabled, a line break and hyphenation character occur only at the end of a syllable. If a table cell contains a long sequence of numbers or letters that have no clear syllable breaks, overflow can occur. The table stretches to accommodate the overflow.
Before R2020b:
  • Hyphenation was disabled for paragraphs. Hyphenation was enabled for tables and the default hyphenation character was an empty space.
  • When hyphenation was disabled, a line break occurred only between words, which resulted in an overflow when a word extended past the boundary of a page or table cell.
  • When hyphenation was enabled, a line break and hyphenation character could occur anywhere in a word in a paragraph or table.
It seems that in either version, "When hyphenation was disabled, a line break occurred only between words", and this is what I wanted to break between words.
Anyways, I'll install R2020b and see what's going on.
Thanks.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMATLAB Report Generator についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by