Can't zoom in using mouse and figure toolbar (It does not crash though!)
4 views (last 30 days)
Show older comments
Hi all. I am trying to print out something and then zoom in on the graph. But when I hit the magnifier bottom, it selects the magnifier, but the magnifier does not work! (Fig. 1)
Also, when I try to use anything else (e.g. zooming out), it would not work either! (Fig. 2).
This is a piece of code that I am using, and it pauses the code in order to get inputs from the user (I thought it might have caused the problem):
Left = randn(10,1);
figure(1)
plot(Left);
prompt0 = Enter the number:
prompt1 = Enter another number:
kk = input(prompt0);
for ii = 1:kk
LeftHS(ii,:) = input(prompt1);
end
Do you know how I can get those toolbar features working?
Thanks.
1 Comment
Adam
on 21 Feb 2017
Does it work when it isn't waiting for user input? Things that are waiting for user input have a habit of stopping other functionality until they get the user input and can then carry on.
Answers (1)
Jan
on 21 Feb 2017
The problem might be concealed in the statement: "I am trying to print out something". What does this exactly mean? Does the toolbar work before this "trying"?
When you assume, that it might be caused by the input code, check this by using:
LeftHS = rand(10, 5); % Or whatever
2 Comments
Jan
on 21 Feb 2017
Sorry, Milad, I still do not understand, what you are asking for. Do you mean, that the figure toolbad is not working while Matlab waits for an input in the command window? If so, create an inputdlg instead, which 1. looks nicer and 2. does not block the processing queue.
See Also
Categories
Find more on Interactive Control and Callbacks in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!