<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Le 28/03/2013 14:39, Stephane BECU a
écrit :<br>
</div>
<blockquote
cite="mid:8c20a50dd0a741e2b88aa3220378b9f8@EXCHSRV.maya-technologies.local"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta content="IE=10" http-equiv="X-UA-Compatible">
<meta name="GENERATOR" content="MSHTML 8.00.7601.18035">
<style style="DISPLAY: none" id="owaParaStyle">P {
MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px
}
</style>
<div style="font-family: Tahoma;font-size: 10pt;color:
#000000;margin: 0;">
<p> </p>
<p>Thanks Serge for your reply, but I'm not sure it answered my
problem. In fact I want to know how to calculate the
appropriate coordinates to place the ttext at the relevant
poisiton of my plot... </p>
<p> </p>
</div>
</blockquote>
How do you define "the appropriate coordinates"?<br>
<br>
Please find below an example of string placement<br>
<br>
t=linspace(0,2*%pi,100);<br>
clf;plot(t,sin(t))<br>
//now I want to draw a string at different locations<br>
str="Scilab";<br>
rect=xstringl(0,0,str);<br>
//the lower left corner of the rectangle surrounding the string
positionned at the (3,sin(3)) point<br>
plot(3,sin(3),'xr')<br>
xstring(3,sin(3),str)<br>
e=gce();e.box='on';<br>
//the upper left corner of the rectangle surrounding the string is
positionned at the (3,sin(3)) point<br>
plot(2,sin(2),'xr')<br>
xstring(2,sin(2)-rect(4),str)<br>
e=gce();e.box='on';<br>
<br>
Serge<br>
<blockquote
cite="mid:8c20a50dd0a741e2b88aa3220378b9f8@EXCHSRV.maya-technologies.local"
type="cite">
<div style="font-family: Tahoma;font-size: 10pt;color:
#000000;margin: 0;">
<hr tabindex="-1">
<div id="divRplyFwdMsg"><font style="FONT-SIZE: 11pt"
color="#000000" face="Calibri, sans-serif"><b>De :</b>
<a class="moz-txt-link-abbreviated" href="mailto:users-bounces@lists.scilab.org">users-bounces@lists.scilab.org</a> de la part de Serge Steer<br>
<b>Envoyé :</b> mercredi 27 mars 2013 18:58<br>
<b>À :</b> International users mailing list for Scilab.<br>
<b>Objet :</b> Re: [Scilab-users] X Y coordinates in a
scilab plot<br>
</font><br>
</div>
<div>
<div class="moz-cite-prefix">Le 27/03/2013 14:38, Stephane
BECU a écrit :<br>
</div>
<blockquote type="cite">
<style id="owaParaStyle">P {
MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px
}
</style>
<div style="MARGIN: 0px; FONT-FAMILY: Tahoma; COLOR:
#000000; FONT-SIZE: 10pt">
<p>Hello,</p>
<p> </p>
<p>I'd like to add a characters string in a scilab
plot. Using the "xstring()" function , I have to fix the
positon of the text giving the X Y coordinates of the
left bottom point of the box containing the text. I was
wondring where was the origin position and how to know
which distance should be considered?</p>
<p> </p>
</div>
</blockquote>
The string is supposed enclosed into a rectangle. The
coordinates required for xstring are the coordinates of the
top left corner of the rectangle<br>
If you want to know the actual dimension of the minimal
rectangle containing a string you may use the xstringl
function.<br>
Serge Steer<br>
<blockquote type="cite">
<div style="MARGIN: 0px; FONT-FAMILY: Tahoma; COLOR:
#000000; FONT-SIZE: 10pt">
<p>Thanks for help,</p>
<p> </p>
<p>Stéphane</p>
</div>
<div>
<table style="FONT-FAMILY: verdana,default sans serif;
FONT-SIZE: 11px">
<tbody>
<tr valign="bottom">
<td width="210"><img moz-do-not-send="true"
style="PADDING-BOTTOM: 0px; PADDING-LEFT: 0px;
PADDING-RIGHT: 10px; FLOAT: left; PADDING-TOP:
0px" alt="Maya Technologies"
src="http://mail4.maya-technologies.com/logo.png">
</td>
<td width="230"><b><font color="#59594d">Stephane
BECU</font></b><font color="#59594d"><br>
</font><br>
<font color="#a1d406">Tel:</font><font
color="#59594d"> +33 4 38 49 59 01</font> <br>
<font color="#a1d406">Mobile:</font><font
color="#59594d"> </font><br>
<font color="#a1d406"><a moz-do-not-send="true"
href="http://www.maya-technologies.com">www.maya-technologies.com</a></font><br>
<br>
</td>
<td width="210"><b>Maya technologies</b><br>
La Petite Halle<br>
ZAC Bouchayer Viallet<br>
31, rue Gustave Eiffel<br>
38 000 Grenoble<br>
<br>
</td>
</tr>
</tbody>
</table>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre>_______________________________________________
users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.scilab.org/mailman/listinfo/users">http://lists.scilab.org/mailman/listinfo/users</a>
</pre>
</blockquote>
<br>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:users@lists.scilab.org">users@lists.scilab.org</a>
<a class="moz-txt-link-freetext" href="http://lists.scilab.org/mailman/listinfo/users">http://lists.scilab.org/mailman/listinfo/users</a>
</pre>
</blockquote>
<br>
</body>
</html>