开发者

how to embed an SVG enabled webkit webview in an Android app?

Is there a way to embed a customized webkit en开发者_开发技巧gine in an app to add a WebView with SVG support ?


The according Bug Entry mentions some android core dependencies which seem not-so-easy to replace, not sure if all of that could be included in a built to provide exactly a webkit webview with your app.

However, in general one can use another library project to be referenced and included on compilation. And then there is a way to include other JAR files, a way to convert an existing project into a library as well as even a way to butcher an .apk and get the code out (which again you can turn into a libary).

Never done it, but in theory, get a library, .jar or .apk of the browser you want to bundle (as mentioned the beginning seems not the best candidate), look into the original code what is done to instantiate that browsers view in an activity - and off you go.

Would love to hear when you or anybody else has accomplished to do such a thing, i couldn't wait to see if we could bundle it with multitouch enabled (another big drawback in 2.x) for multitouch on the android stock browser on 2.x devices i started a polyfill project out of desparation (which works surprisingly well, but is also way simpler than emulating a complete SVG interpreter), so for matter of SVG and providing the best browser runtime for the job, this would be great.

P.S. There is one completely different workaround depending on what you want to do with SVG. If it's just some small stuff to fill on the screen at times you might check google for "svg polyfill" which leads to a myriad of solutions - i couldn't recommend one straightaway, as those implementations are so different that you should evaluate them with your actual app.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜