Options
All
  • Public
  • Public/Protected
  • All
Menu

Maintains the size of a div element in Internet Explorer. This is a workaround for the right and bottom style being ignored in IE.

If you need a div to cover the scrollwidth and -height of a document, then you can use this class as follows:

example
var resizer = new mxDivResizer(background);
resizer.getDocumentHeight()
{
  return document.body.scrollHeight;
}
resizer.getDocumentWidth()
{
  return document.body.scrollWidth;
}
resizer.resize();

Hierarchy

  • mxDivResizer

Index

Constructors

constructor

  • new mxDivResizer(div: HTMLElement, container?: HTMLElement | Window): mxDivResizer
  • Constructs an object that maintains the size of a div element when the window is being resized. This is only required for Internet Explorer as it ignores the respective stylesheet information for DIV elements.

    Parameters

    • div: HTMLElement

      Reference to the DOM node whose size should be maintained.

    • Optional container: HTMLElement | Window

      Optional Container that contains the div. Default is the window.

    Returns mxDivResizer

Properties

handlingResize

handlingResize: boolean

Boolean specifying if the width should be updated.

resizeHeight

resizeHeight: boolean

Boolean specifying if the height should be updated.

resizeWidth

resizeWidth: boolean

Boolean specifying if the width should be updated.

Methods

getDocumentHeight

  • getDocumentHeight(): number
  • Hook for subclassers to return the height of the document (without scrollbars).

    Returns number

getDocumentWidth

  • getDocumentWidth(): number
  • Hook for subclassers to return the width of the document (without scrollbars).

    Returns number

resize

  • resize(): void

Generated using TypeDoc