webview size in pixels

CidTek

Active Member
Licensed User
Longtime User
Part of the Google maps html spec is stating the size of the map in pixels that you want to display.

Are the height and width properties of a webview created in the designer in DIP (Device Independent Pixels) and do I need to translate that to pixels for Google maps?
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Are the height and width properties of a webview created in the designer in DIP
The values entered in the designer are in pixels. However these values will be scaled automatically based on the target device scale (practically these values are similar to DIP values).

However calling WebView.Height and WebView.Width return the values in pixels.
Note that these properties are only available after the view was added to the layout.
 
Upvote 0
Top