Element Resizer

By Richard Gibson Last update Dec 7, 2005 — Installed 8,779 times. Daily Installs: 0, 1, 2, 3, 0, 3, 1, 0, 3, 1, 2, 0, 2, 1, 2, 2, 0, 3, 2, 2, 3, 0, 5, 2, 2, 1, 2, 2, 1, 1, 3, 2
Script Summary:
Makes user-specifiable elements resizable by mouse and keyboard, either in or out of the page flow or "maximized" above it.
Version: 0.3.1
Recently Updated TopicsPosts
Archived Comments11

this script has 1 topic, 11 posts

This script has no reviews.

*Note to Gmail users*: _wrapping up <iframe></iframe>s does not interact well with Gmail's dynamic use of them. I recommend that you either @exclude *mail.google.com* or that you use the Set Tags command to make sure that <iframe></iframe>s are not resizable. I have chosen the latter for the default settings._

Element Resizer allows you to dynamically resize page elements using either the mouse or the keyboard. The resizable tags can be specified by the Set Tags command, available on Firefox/Greasemonkey under Tools > User Script Commands. When focused (or hovered over), resizable elements will show a resizer handle at each corner. A handle will grow when hovered over, and the side of a resizable element will turn into a blue resizer bar when hovered over.

Resizes are always one of three general types, and can have up to two special behaviors:

In flow
The element stays in the page flow, and other elements are moved/resized as appropriate.
Out of flow
The element "floats" above other content.
Maximized
The element "floats" above other content and does not scroll with the page.
Locked aspect ratio
The aspect ratio (ratio of width to height) of the element does not change.
Centered
The center of the element does not change.

Mouse Resizing

Drag on a handle or a resizer bar to finely control the size of an element, and end the drag to keep the resize or press Escape to cancel it. This resize defaults to out of flow, and is affected by the following modifier keys:

Shift
locked aspect ratio
Control
centered
Alt
in flow

Clicking on a handle or a resizer bar also has an effect. If Shift is held, the element is toggled to/from maximized (if the element is already maximized, it is returned to the resized state, or to reset if there is no non-maximized resized state). If Shift is not held, the element is toggled to/from reset (if the element is already reset, it is returned to the resized state, or to maximized if there is no resized state).

Keyboard Resizing

(Text entry) elements can be resized with the keyboard:

Alt+Enter
in flow height increase
Shift+Alt+Enter
in flow height decrease
Control+Space
in flow width increase
Shift+Control+Space
in flow width decrease
Control+Up
centered out of flow height increase
Control+Down
centered out of flow height decrease
Control+Right
centered out of flow width increase
Control+Left
centered out of flow width decrease
Alt+Minus
toggle reset (defaulting to maximized)
Alt+Plus
toggle maximized (preferring resized over reset)

Restoring Elements

Elements can be restored to their original position and dimensions . To do so, click on a resizer handle or bar while holding Alt; or alternately press Alt+Backspace or Alt+Delete while the element has the focus. Restore all elements with the Restore All command.

Dimensions may be slightly off for elements with intrinsic dimensions, like form elements and inline frames.

h1. Changelog * **0.3.1 (2006-10-13)** ** Fixed: issue with wrapping elements of the invalid <table><form>...</form></table> construct (first reported by private_lock on 2006-10-04; found on "http://single.de/msg.html":http://single.de/msg.html) * **0.3 (2006-06-02)** ** New: allowed differentiation of input tags by type (input:text, input:password, etc.) ** Improved: changed out of flow horizontal keyboard resizing to free up control+left and control+right * **0.2.1 (2005-12-07)** ** Updated: changes for compatibility with Gmail * **0.2 (2005-12-07)** ** New: added "automatic updating":http://userscripts.org/scripts/show/2296 * **0.1 (2005-11-22)** ** original release