<div dir="ltr"><div>an idea for supprssing the figure rotation:</div><div> </div><div>- what about using "xgetmouse() ? </div><div> </div><div>normally if one presses the right button (and holds it) the figure is rotated.</div><div> </div><div>having something like: </div><div> </div><div><pre style="font-family:Monospaced;font-style:normal"><span style="color:rgb(50,185,185)">clc</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(0,0,0)">f</span> <span style="color:rgb(92,92,92)">=</span> <span style="color:rgb(174,92,176);text-decoration:underline">gcf</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(74,85,219)">)</span>
<span style="color:rgb(50,185,185)">plot2d</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(74,85,219)">)</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(0,0,0)">ibut</span> <span style="color:rgb(92,92,92)">=</span> <span style="color:rgb(74,85,219)">[</span><span style="color:rgb(188,143,143)">0</span> <span style="color:rgb(188,143,143)">0</span> <span style="color:rgb(92,92,92)">-</span><span style="color:rgb(188,143,143)">1</span><span style="color:rgb(74,85,219)">]</span><span style="color:rgb(0,0,0)">;</span> <span style="color:rgb(100,174,100);font-style:italic">// declaring the ibutton</span>
<span style="color:rgb(160,32,240)">while</span> <span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span> <span style="color:rgb(92,92,92)">==</span> <span style="color:rgb(92,92,92)">-</span><span style="color:rgb(188,143,143)">1</span> <span style="color:rgb(0,0,0)">;</span> <span style="color:rgb(100,174,100);font-style:italic">// --</span><span style="color:rgb(100,174,100);font-style:italic">></span><span style="color:rgb(100,174,100);font-style:italic"> mouse just moving</span>
<span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(92,92,92)">=</span><span style="color:rgb(50,185,185)">xgetmouse</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(74,85,219)">)</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(160,32,240)">if</span> <span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span> <span style="color:rgb(92,92,92)">==</span> <span style="color:rgb(188,143,143)">2</span> <span style="color:rgb(92,92,92)">|</span> <span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span><span style="color:rgb(92,92,92)">==</span><span style="color:rgb(188,143,143)">5</span> <span style="color:rgb(92,92,92)">|</span> <span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span> <span style="color:rgb(92,92,92)">==</span> <span style="color:rgb(188,143,143)">12</span> <span style="color:rgb(92,92,92)">|</span> <span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span> <span style="color:rgb(92,92,92)">==</span> <span style="color:rgb(92,92,92)">-</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(0,0,0)">a</span> <span style="color:rgb(92,92,92)">=</span> <span style="color:rgb(174,92,176);text-decoration:underline">gca</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(74,85,219)">)</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(0,0,0)">a</span><span style="color:rgb(92,92,92)">.</span><span style="color:rgb(170,170,170)">view</span> <span style="color:rgb(92,92,92)">=</span> <span style="color:rgb(188,143,143)">'</span><span style="color:rgb(188,143,143)">2d</span><span style="color:rgb(188,143,143)">'</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(50,185,185)">disp</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span><span style="color:rgb(74,85,219)">)</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(160,32,240)">end</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(160,32,240)">if</span> <span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span> <span style="color:rgb(92,92,92)">==</span> <span style="color:rgb(188,143,143)">3</span>
<span style="color:rgb(174,92,176);text-decoration:underline">close</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(0,0,0)">f</span><span style="color:rgb(74,85,219)">)</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(95,158,160)">return</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(160,32,240)">end</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(0,0,0)">ibut</span><span style="color:rgb(74,85,219)">(</span><span style="color:rgb(188,143,143)">3</span><span style="color:rgb(74,85,219)">)</span> <span style="color:rgb(92,92,92)">=</span><span style="color:rgb(92,92,92)">-</span><span style="color:rgb(188,143,143)">1</span><span style="color:rgb(0,0,0)">;</span>
<span style="color:rgb(160,32,240)">end</span><span style="color:rgb(0,0,0)">;</span></pre></div><div> </div><div><div>will rotate back to 2d view every time the image is rotated by mouse.</div><div>to end the loop click the left mouse button.</div><div> </div><div>Not ideal but maybe a start. </div></div><div> </div><div> Best regards,</div><div>Philipp</div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-05-13 13:54 GMT+02:00 Stefan Du Rietz <span dir="ltr"><<a href="mailto:sdr@durietz.se" target="_blank">sdr@durietz.se</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On 2015-05-13 13:41, <a href="mailto:sgougeon@free.fr" target="_blank">sgougeon@free.fr</a> wrote:<br>
<blockquote style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid" class="gmail_quote"><blockquote style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid" class="gmail_quote">
De: "Stefan Du Rietz"<br>
Envoyé: Mercredi 13 Mai 2015 12:19:01<br>
<br>
Hello all,<br>
can anybody explain this:<br>
I have a figure f with two axes (and some GUIs). When I move the mouse<br>
with the right button pressed, *one* of the axes gets distorted.<br>
</blockquote>
<br>
Right-click rotates interactively the axes on which you have clicked.<br>
To restore it (and all), you may do:<br>
f = gcf();<br>
k = f.children.type=="Axes"<br>
f.children(k).view="2d";<br>
<br>
SG<br>
</blockquote>
<br></span>
Thanks, but it changes the same axes wherever I click! And I would like to prevent the possibility to rotate the axes.<span class="HOEnZb"><font color="#888888"><br>
<br>
Stefan</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
<br>
_______________________________________________<br>
users mailing list<br>
<a href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a><br>
<a href="http://lists.scilab.org/mailman/listinfo/users" target="_blank">http://lists.scilab.org/mailman/listinfo/users</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">There we have the salad.</div>
</div>