Why are some characters chopped off on the bottom in plots?

1 回表示 (過去 30 日間)
David Walwark
David Walwark 2020 年 1 月 9 日
コメント済み: David Walwark 2020 年 1 月 18 日
Below is an example of text from a legend. The top line is chopped but the lower line is not.
matlabChoppedLetters.png
Here is some code that can generate the ugliness for you (unless I am mistaken). Just look at the Y-axis text.
figure;
plot([0,1],[0,1])
set(gca,'fontsize',18)
If you increase the fontsize to 19 or larger points then the issue seems to go away. What is going on?
  2 件のコメント
Walter Roberson
Walter Roberson 2020 年 1 月 9 日
Are you using... Ummm, let me think... R2015b?? On Linux??
There was a release which cut off text at the boundary on Linux systems. The easiest fix was to nudge the YLim to go down a bit further.
There was also an old release that the problem happened on Windows, and the solution had to do with changing the figure Renderer property.
David Walwark
David Walwark 2020 年 1 月 18 日
I get these type of artifacts all the time, in previous versions and in 2019b. Should I be trying different renderers?

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

回答 (1 件)

Hiro Yoshino
Hiro Yoshino 2020 年 1 月 9 日
a.PNG
figure;
plot([0,1],[0,1],[0,1],[0,1])
set(gca,'fontsize',18)
legend('nissio', 'pop.');
Mine did work well with R2019b.
  1 件のコメント
David Walwark
David Walwark 2020 年 1 月 9 日
編集済み: David Walwark 2020 年 1 月 9 日
I remarked my entire startup.m, restarted matlab, and ran the code again. I updated the question to reflect Matlab 2019b (on windows 10). Still having this issue.

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

カテゴリ

Help Center および File ExchangeAnnotations についてさらに検索

製品


リリース

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by