You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is an issue with the 'FitBoxToText' property of the annotation edit box. If you set this property to the default 'off', the box is positioned appropriately on the figure:
myaxes = axes();
x = 0:10;
plot(x, x);
[normx, normy] = coord2norm(myaxes, 2, 6);
dim = [normx normy .3 .3];
mystr = 'This is plot 1';
annotation('textbox', dim, 'String', mystr);
However, when resizing the border to the text, the annotation object is not repositioned to account for the border change. As this is an internal MATLAB issue this is beyond the scope of the functions in this repo.
Passing normalized coordinates to
annotation
does not produce the axes position for the annotation.For example:
Rather than placing the corner of the text box at
[2, 6]
as desired, the annotation is placed around[2, 9]
.However, the
norm2coord
inverse provides the correct location:hold off
The text was updated successfully, but these errors were encountered: