aboutsummaryrefslogtreecommitdiff
path: root/AppKit/GTMUILocalizerAndLayoutTweaker.h
diff options
context:
space:
mode:
authorGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2009-10-30 18:35:16 +0000
committerGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2009-10-30 18:35:16 +0000
commite1c938bc73510d64b908408bf404eb10a419001e (patch)
tree0001b2d01f045c33f33fff7051fceddcc00971a4 /AppKit/GTMUILocalizerAndLayoutTweaker.h
parente1cbd4dc301f0f7e0a0fd7616a958bfaeb615b67 (diff)
[Author: thomasvl]
Add a helper for doing view resizing without resizing subviews. Fix the fixed width call to not change the width. Update the unittest to make sure the fixed width call doesn't change the width. R=stuartmorgan,dmaclach DELTA=41 (30 added, 0 deleted, 11 changed)
Diffstat (limited to 'AppKit/GTMUILocalizerAndLayoutTweaker.h')
-rw-r--r--AppKit/GTMUILocalizerAndLayoutTweaker.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/AppKit/GTMUILocalizerAndLayoutTweaker.h b/AppKit/GTMUILocalizerAndLayoutTweaker.h
index abcb758..3c5c864 100644
--- a/AppKit/GTMUILocalizerAndLayoutTweaker.h
+++ b/AppKit/GTMUILocalizerAndLayoutTweaker.h
@@ -42,7 +42,7 @@
// This checks to see if |view| implements @selector(sizeToFit) and calls it.
// It then checks the class of |view| and does some fixup for known issues
-// where sizeToFit doesn't product a view that meets UI guidelines.
+// where sizeToFit doesn't produce a view that meets UI guidelines.
// Returns the amount the view changed in size.
+ (NSSize)sizeToFitView:(NSView *)view;
@@ -60,13 +60,15 @@
+ (void)wrapButtonTitleForWidth:(NSButton *)button;
+ (void)wrapRadioGroupForWidth:(NSMatrix *)radioGroup;
-// Resizes |window| by |delta| without letting the subviews of |window| get
+// Resizes |window| or |view| by |delta| without letting the subviews get
// resized. Useful when you've done manual tweaking by things like
-// +sizeToFitFixedWidthTextField. The window's origin is not adjusted. Passes
-// |NO| to for -setFrame:display:'s |displayViews| flag on the assumptions
-// the caller is doing all the invals/updates needed.
+// +sizeToFitFixedWidthTextField. The origin is not adjusted. For windows,
+// passes |NO| to for -setFrame:display:'s |displayViews| flag on the
+// assumptions the caller is doing all the invals/updates needed.
+ (void)resizeWindowWithoutAutoResizingSubViews:(NSWindow*)window
delta:(NSSize)delta;
++ (void)resizeViewWithoutAutoResizingSubViews:(NSView*)view
+ delta:(NSSize)delta;
@end