Does Android support SVG (natively)?
I found old answers here or on the web, but I don’t understand the current situation.
Please give a reference if possibile.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
That depends on what you mean by “Android”, “SVG”, and “natively”.
Android is a mobile operating system. It has multiple versions.
SVG is a standard. It has multiple versions.
“Natively” could mean anything from “I can decode SVG through some Java classes” to “the stock Android Web browser can render SVG”.
I can tell you that the stock Android Web browser renders this Web page fine on Android 3.2 and Android 4.0, but fails on Android 2.3.
I can tell you that there is no SVG parser set of Java classes, and that
ImageViewand similar widgets have no ability to work with SVG directly. You may be able to useWebViewto display someSVG, given that the stock browser seems to support it on newer Android versions, though it’s conceivable that the SVG support is via some plugin that is not automatically available toWebView.I cannot tell you what version of SVG is supported by the browser, as that does not appear to be documented. You would need to run some tests and see if it supports the particular SVG structures that you wish to use.