1. A system for smooth zooming in web applications, comprising: one or more computer processors; a structured document defining a plurality of display elements, the plurality of display elements including a resizable container element and a scalable element defined to be located at least partially within the resizable container element when rendered; a rendering component, executed at the one or more computer processors, the rendering component operable to receive the structured document as an input, execute a rendering function that calculates a display position for each of the plurality of display elements, and define rendered content based at least in part on the display position for each of the plurality of display elements; a display component, executed at the one or more computer processors, the display component operable to output a viewable area of the rendered content; and a scaling component, executed at the one or more computer processors, the scaling component operable to receive a scaling input, redefine the scalable element based at least in part on the scaling input, determine whether the resizable container element will be located within the viewable area if the size of the resizable container element is changed so that the resizable container element completely contains the scalable element, redefine the size of the resizable container element if it will be located within the viewable area, and maintain the size of the resizable container element if it will not be located within the viewable area.