1. Check out our companion app, Forums for Android! Download from Google Play

viewport set webview zoom to fit the application ..

Discussion in 'Application Development' started by ben74, Jul 16, 2013.

  1. ben74

    ben74 New Member
    Thread Starter

    Jul 15, 2013
    Hi, I'm developing a new webview app ( html5 canvas + javascript ) @ this location: paint test

    I'm trying to fit & fix the webview zoom in order to fit it on every possible device ..

    #here is for viewport that only fits with chrome on galaxy note

    <meta name="viewport" content="width=1207,height=631,initial-scale=0.5,minimum-scale=0.5,maximum-scale=1,user-scalable=no">

    ( note : with webview or base android navigator I have to double tap on time to get the zoom at it's correct level ... and have not found this far how to emulate this double tap outside zoom effect .. )

    Java :
    WebView b=(WebView)findViewById(R.id.webview);WebSettings s=b.getSettings();

    Layout :
    <WebView android:id="@+id/webview" android:layout_width="match_parent" android:layout_height="match_parent" />

    & manifest in landscape mode

    As I'm having a wild time trying to fix this, more than 20 hours currently, and having no correct answers at all from stackoverflow I'm asking for help, here currently

    Any advice would be greatly appreciated
    Thanks in advance :) :smokingsomb:


Share This Page