Created
July 7, 2009 00:58
-
-
Save geoffreyd/141799 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
frameworks/sproutcore/frameworks/foundation/views/view.js: line 1371 | |
/** | |
The layout describes how you want your view to be positions on the | |
screen. You can define the following properties: | |
- left: the left edge | |
- top: the top edge | |
- right: the right edge | |
- bottom: the bottom edge | |
- height: the height | |
- width: the width | |
- centerX: an offset from center X | |
- centerY: an offset from center Y | |
- minWidth: a minimum width | |
- minHeight: a minimum height | |
- maxWidth: a maximum width | |
- maxHeight: a maximum height | |
Note that you can only use certain combinations to set layout. For | |
example, you may set left/right or left/width, but not left/width/right, | |
since that combination doesn't make sense. | |
Likewise, you may set a minWidth/minHeight, or maxWidth/maxHeight, but | |
if you also set the width/height explicitly, then those constraints won't | |
matter as much. | |
Layout is designed to maximize reliance on the browser's rendering | |
engine to keep your app up to date. | |
@test in layoutStyle | |
*/ | |
layout: { top: 0, left: 0, bottom: 0, right: 0 }, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment