Svg path is not working in ios.

Discussion in 'iOS Apps' started by thangiavel, Sep 5, 2011.

Thread Status:
Not open for further replies.
  1. thangiavel, Sep 5, 2011
    Last edited: Sep 5, 2011

    thangiavel macrumors newbie

    Joined:
    Sep 5, 2011
    #1
    i am new to iPhone app development ..i am trying to run the svg documet using the code bellow....

    SVGDocument *document = [SVGDocument documentNamed:mad:"sun.svg"];

    [self.view.layer addSublayer:[document layerTree]];



    actually my svg documet is this ....

    <?xml version="1.0" encoding="utf-8"?>
    <!-- Generator: Adobe Illustrator 14.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 43363) -->
    <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
    <svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
    width="595.28px" height="841.89px" viewBox="0 0 595.28 841.89" enable-background="new 0 0 595.28 841.89" xml:space="preserve">
    <path id="quadcurveABC" d="M 100 350 q 150 -300 300 0"
    stroke="blue" stroke-width="5" fill="none" />
    </svg>


    when i try to run the app ,it does not displays the path.....


    it works if i try to run the svg code given bellow,

    <svg xmlns="http://www.w3.org/2000/svg" version="1.1">
    <circle cx="100" cy="50" r="40" stroke="black"
    stroke-width="2" fill="red" />
    </svg>

    but it does not work with the svg paths .i think so...please help me .......
     
  2. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #2
    One thread is enough thanks! Please post any replies here
     
Thread Status:
Not open for further replies.

Share This Page