/[cvs]/nfo/php/libs/com.newsblob.phphtmllib/examples/example7.php
ViewVC logotype

Diff of /nfo/php/libs/com.newsblob.phphtmllib/examples/example7.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by jonen, Sat Feb 22 21:07:21 2003 UTC revision 1.3 by jonen, Sat Sep 20 00:20:55 2003 UTC
# Line 19  Line 19 
19   * Include the phphtmllib libraries   * Include the phphtmllib libraries
20   */   */
21  include_once("includes.inc");  include_once("includes.inc");
22  include_once($phphtmllib."/widgets/SVGDocumentClass.inc");  include_once($phphtmllib."/widgets/svg/SVGDocumentClass.inc");
23    
24  //build the SVG Document object and set the  //build the SVG Document object and set the
25  //width=400, height=200 attributes on the 'svg' root  //width=400, height=200 attributes on the 'svg' root
# Line 42  $g = svg_g("stroke:black", "translate(19 Line 42  $g = svg_g("stroke:black", "translate(19
42  $circle = svg_circle(0,0,50,"blue", "black", 2);  $circle = svg_circle(0,0,50,"blue", "black", 2);
43    
44  //add a neat mouseover to the circle  //add a neat mouseover to the circle
45  $circle->set_tag_attribute("onmouseover=\"evt.target.setAttribute('style', 'stroke:red; stroke-width:2');\"");  $circle->set_tag_attribute("onmouseover", "evt.target.setAttribute('style', 'stroke:red; stroke-width:2');");
46  $circle->set_tag_attribute("onmouseout=\"evt.target.setAttribute('style', '');\"");  $circle->set_tag_attribute("onmouseout", "evt.target.setAttribute('style', '');");
47  $g->add( $circle );  $g->add( $circle );
48  //add it to the image  //add it to the image
49  $svgdoc->add( $g );  $svgdoc->add( $g );
50    
51  $g2 = svg_g("", "translate(100 80)");  $g2 = svg_g("stroke:black", "translate(100 80)");
52  $text = svg_text(0,80,NULL,NULL, "SVG built by");  $text = svg_text(0,80,NULL,NULL, "SVG built by");
53  $text->set_style("font-size:20;");  $text->set_style("font-size:20;");
54    $text->set_collapse();
55  $linktext = svg_text(114,80,NULL,"mylink","phpHtmlLib");  $linktext = svg_text(114,80,NULL,"mylink","phpHtmlLib");
56    
57  //$linktext->set_style("font-size:20;color:#FF0000;text-decoration:underline;");  //$linktext->set_style("font-size:20;color:#FF0000;text-decoration:underline;");

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed