blob: 10fa9652f2246de23fe7895b36d33fd1f04679df (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
---
title: Window.scrollTo()
slug: Web/API/Window/scrollTo
translation_of: Web/API/Window/scrollTo
---
<div>{{ APIRef }}</div>
<h2 id="Summary" name="Summary">요약</h2>
<p><span class="sentence" id="mt1">문서의 지정된 위치로 스크롤합니다.</span></p>
<h2 id="Syntax" name="Syntax">구문</h2>
<pre class="syntaxbox"><code>window.scrollTo(<em>x-좌표</em>, <em>y-좌표</em>)</code></pre>
<h3 id="Parameters" name="Parameters">매개변수</h3>
<ul>
<li><code>x-좌표는 문서의 왼쪽상단부터 시작하는 </code>픽셀단위의 <code>가로축</code>입니다.</li>
<li><code>y-좌표는 문서의 왼쪽상단부터 시작하는 </code>픽셀단위의 세로축입니다.</li>
</ul>
<h2 id="Example" name="Example">예제</h2>
<pre class="brush:js">window.scrollTo( 0, 1000 );</pre>
<h2 id="Notes" name="Notes">노트</h2>
<p>이 함수는 <a href="/en-US/docs/DOM/Window.scroll">window.scroll</a>과 효과적으로 같습니다. 스크롤링 관련 정보는 <a href="/en-US/docs/DOM/Window.scrollBy">window.scrollBy</a>, <a href="/en-US/docs/DOM/Window.scrollByLines">window.scrollByLines</a>, 그리고 <a href="/en-US/docs/DOM/Window.scrollByPages">window.scrollByPages</a>가 있습니다.</p>
<h2 id="Specification" name="Specification">사양</h2>
<table class="standard-table">
<thead>
<tr>
<th scope="col">사양</th>
<th scope="col">상태</th>
<th scope="col">주해</th>
</tr>
</thead>
<tbody>
<tr>
<td>{{ SpecName('CSSOM View', '#dom-window-scroll', 'window.scroll()') }}</td>
<td>{{ Spec2('CSSOM View') }}</td>
<td>Initial definition.</td>
</tr>
</tbody>
</table>
|