Android : Android WebView setInitialScale

on Monday, August 11, 2014


I'm using a WebView which is created once and load many website (while changing the LayoutParams). The WebView is used in a ListView.


But now, I have a problem. On a Nexus 10 the whole website is completely visible, but on my Nexus 7, I only see a part of the pages. I tested it with



WebView.setInitialScale(scaleInPercent);
WebView.loadUrl(url);


but it didn't work. My target API-Level is 19. I checked it in a test app, where main.xml is filling the screen and in it, it worked.


I set the scaleInPercent value to 50 and 140, without any change. Where should I also look at? Is it possible to change the InitalScale after loading one page or can this be set only once?


0 comments:

Post a Comment