diff options
author | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
---|---|---|
committer | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
commit | 33058f2b292b3a581333bdfb21b8f671898c5060 (patch) | |
tree | 51c3e392513ec574331b2d3f85c394445ea803c6 /files/zh-cn/web/api/dompoint/x | |
parent | 8b66d724f7caf0157093fb09cfec8fbd0c6ad50a (diff) | |
download | translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.gz translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.bz2 translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.zip |
initial commit
Diffstat (limited to 'files/zh-cn/web/api/dompoint/x')
-rw-r--r-- | files/zh-cn/web/api/dompoint/x/index.html | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/files/zh-cn/web/api/dompoint/x/index.html b/files/zh-cn/web/api/dompoint/x/index.html new file mode 100644 index 0000000000..d695b9d1a6 --- /dev/null +++ b/files/zh-cn/web/api/dompoint/x/index.html @@ -0,0 +1,45 @@ +--- +title: DOMPoint.x +slug: Web/API/DOMPoint/x +translation_of: Web/API/DOMPoint/x +--- +<div>{{APIRef("DOM")}}</div> + +<p><span class="seoSummary"><code><strong>DOMPoint</strong></code> 的 x 属性表示该点的水平坐标。</span> 通常, <code>x</code> 的正值表示右边,负值表示左边,除非改变了默认的轴方向。</p> + +<h2 id="语法">语法</h2> + +<pre class="syntaxbox">var <em>xPos</em> = <em>DOMPoint</em>.x;</pre> + +<h3 id="值">值</h3> + +<p>双精度浮点值,表示该点的 x 坐标值。这个值的类型并没有严格限制,意味着它可以是 {{jsxref("NaN")}} 或 {{jsxref("Infinity", "±Infinity")}}。</p> + +<h2 id="规范">规范</h2> + +<table class="standard-table"> + <tbody> + <tr> + <th scope="col">Specification</th> + <th scope="col">Status</th> + <th scope="col">Comment</th> + </tr> + <tr> + <td>{{SpecName('Geometry Interfaces', '#dom-dompoint-x', 'x')}}</td> + <td>{{Spec2('Geometry Interfaces')}}</td> + <td>Initial definition</td> + </tr> + </tbody> +</table> + +<h2 id="浏览器兼容性">浏览器兼容性</h2> + + + +<p>{{Compat("api.DOMPointReadOnly.x")}}</p> + +<h2 id="相关链接">相关链接</h2> + +<ul> + <li>其他坐标属性:{{domxref("DOMPoint.y", "y")}},{{domxref("DOMPoint.z", "z")}},透视值 {{domxref("DOMPoint.w", "w")}}.</li> +</ul> |