Viewport"

From Documentation
(Created page with "{{ZKComponentReferencePageHeader}} = Viewport Content = The default viewport content generated in ZK when using tablet device is: <source lang="xml"> <meta name="viewport" conte...")
 
Line 16: Line 16:
 
== XML processing instruction ==
 
== XML processing instruction ==
 
  since 6.5.0
 
  since 6.5.0
User can keep the default setting and assign custom viewport on specific pages by overwrite viewport content in [[ZUML_Reference/ZUML/Processing_Instructions/page|page instruction]] as follows:
+
User can keep the default setting and assign custom viewport on specific pages by overwriting viewport content in [[ZUML_Reference/ZUML/Processing_Instructions/page|page instruction]] as follows:
 
<source lang="xml">
 
<source lang="xml">
 
<?page viewport="width=device-width, initial-scale=1.0"?>
 
<?page viewport="width=device-width, initial-scale=1.0"?>

Revision as of 09:39, 7 September 2012

Viewport Content

The default viewport content generated in ZK when using tablet device is:

<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />

Customize

User can specify viewport setting by library properties or XML processing instruction.

Library Properties

since 6.5.0

The default value of org.zkoss.zul.tablet.meta.viewport.disabled property is false. If it is set to true, ZK won't render viewport content for all pages. Thus, user can specify viewport on each ZUL page by meta instruction.

XML processing instruction

since 6.5.0

User can keep the default setting and assign custom viewport on specific pages by overwriting viewport content in page instruction as follows:

<?page viewport="width=device-width, initial-scale=1.0"?>

Version History

Last Update : 2012/09/07


Version Date Content
6.5.0 September, 2012 new added configuration


Copyright © Potix Corporation. This article is licensed under GNU Free Documentation License.