Mozilla.com

  1. MDC
  2. Main Page
  3. DOM
  4. window.resizeTo

« Gecko DOM Reference

Summary

Dynamically resizes window.

Syntax

window.resizeTo(iWidth, iHeight) 

Parameters

  • iWidth is an integer representing the new width in pixels.
  • iHeight is an integer value representing the new height in pixels.

Example

 // function resizes the window to take up one quarter
 // of the available screen.
 function quarter() {
   window.resizeTo(window.screen.availWidth/2,
      window.screen.availHeight/2);
 }

Notes

See also window.resizeBy.

Specification

DOM Level 0. Not part of specification.

Languages

Page last modified 06:32, 27 Feb 2008 by Mattcasey?

Files (0)