Update examples in datatip help pages. 89/16289/2
Adeline CARNIS [Mon, 30 Mar 2015 14:26:56 +0000 (16:26 +0200)]
Change-Id: I9346915d0149346cd8439468d0bd163d11cd0482

scilab/modules/graphics/help/en_US/datatips/datatipSetStyle.xml
scilab/modules/graphics/help/en_US/datatips/datatips.xml
scilab/modules/graphics/help/ja_JP/datatips/datatipSetStyle.xml
scilab/modules/graphics/help/ja_JP/datatips/datatips.xml

index 59128d3..4d596be 100644 (file)
     clf();plot(x,sinc(x),x,sinc(x.^2));
     e=gce();e=e.children;
     d1=datatipCreate(e(1),540);
-    function str=mydisplay(pt),str=msprintf('%0.2g', pt(1)),endfunction
+    function str=mydisplay(h)
+               pt = h.data;
+               str=msprintf('%0.2g \n %0.2g', pt(1), pt(2))
+       endfunction
     datatipSetDisplay(d1,"mydisplay")
     datatipSetStyle(e(1),2,%f)
     datatipSetOrientation(d1,"upper left");
             clf();plot(x,sinc(x),x,sinc(x.^2));
             e=gce();e=e.children;
             d1=datatipCreate(e(1),540);
-            function str=mydisplay(pt),str=msprintf('%0.2g', pt(1)),endfunction
+            function str=mydisplay(h)
+                       pt = h.data;
+                       str=msprintf('%0.2g \n %0.2g', pt(1), pt(2))
+                       endfunction
             datatipSetDisplay(d1,"mydisplay")
             datatipSetStyle(e(1),2,%f)
             datatipSetOrientation(d1,"upper left");
index f4779aa..145936f 100644 (file)
@@ -62,8 +62,9 @@
     t=datatipCreate(p2,[0.8 0.4]);
     datatipSetOrientation(t,"upper left")
   
-    function str=myfmt(pt)
-      str = msprintf('sinc\n%s', sci2exp(round(pt*10)/10))
+    function str=myfmt(h)
+               pt = h.data;
+               str = msprintf('sinc\n%s', sci2exp(round(pt*10)/10))
     endfunction
     datatipSetDisplay(t,"myfmt")
     
@@ -84,8 +85,9 @@
             t=datatipCreate(p2,[0.8 0.4]);
             datatipSetOrientation(t,"upper left")
             
-            function str=myfmt(pt)
-            str = msprintf('sinc\n%s', sci2exp(round(pt*10)/10))
+            function str=myfmt(h)
+            pt = h.data;
+                       str = msprintf('sinc\n%s', sci2exp(round(pt*10)/10))
             endfunction
             datatipSetDisplay(t,"myfmt")
         </scilab:image>
index 04cdc50..ca1b002 100644 (file)
 
     d1=datatipCreate(e(1),540);
 
-    function str=mydisplay(pt),str=msprintf('%0.2g', pt(1)),endfunction
+    function str=mydisplay(h)
+       
+       pt = h.data;
+       
+       str=msprintf('%0.2g \n %0.2g', pt(1), pt(2))
+               
+       endfunction
 
     datatipSetDisplay(d1,"mydisplay")
 
             
             d1=datatipCreate(e(1),540);
             
-            function str=mydisplay(pt),str=msprintf('%0.2g', pt(1)),endfunction
+            function str=mydisplay(h)
+                       
+                       pt = h.data;
+                       
+                       str=msprintf('%0.2g \n %0.2g', pt(1), pt(2))
+               
+                       endfunction
             
             datatipSetDisplay(d1,"mydisplay")
             
index 25e6f1e..998c217 100644 (file)
 
   
 
-    function str=myfmt(pt)
+    function str=myfmt(h)
 
-      str = msprintf('sinc\n%s', sci2exp(round(pt*10)/10))
+      pt = h.data;
+         
+         str = msprintf('sinc\n%s', sci2exp(round(pt*10)/10))
 
     endfunction
 
             
             
             
-            function str=myfmt(pt)
+            function str=myfmt(h)
+                       
+                       pt = h.data;
             
             str = msprintf('sinc\n%s', sci2exp(round(pt*10)/10))