Fix placement of auxiliary IM window for Core Text
[MacVim.git] / src / MacVim / DBPrefsWindowController.h
blob74ca024f1ae99d867d5dfba2425baa6d2612e3b2
1 //
2 // DBPrefsWindowController.h
3 //
4 // Created by Dave Batton
5 // http://www.Mere-Mortal-Software.com/blog/
6 //
7 // Documentation for this class is available here:
8 // http://www.mere-mortal-software.com/blog/details.php?d=2007-03-11
9 //
10 // Copyright 2007. Some rights reserved.
11 // This work is licensed under a Creative Commons license:
12 // http://creativecommons.org/licenses/by/3.0/
14 // 11 March 2007 : Initial 1.0 release
15 // 15 March 2007 : Version 1.1
16 // Resizing is now handled along with the cross-fade by
17 // the NSViewAnimation routine.
18 // Cut the fade time in half to speed up the window resize.
19 // -setupToolbar is now called each time the window opens so
20 // you can configure it differently each time if you want.
21 // Holding down the shift key will now slow down the animation.
22 // This can be disabled by using the new -setShiftSlowsAnimation:
23 // method.
24 // 23 March 2007 : Version 1.1.1
25 // The initial first responder now gets set when the view is
26 // swapped so that the user can tab to the objects displayed
27 // in the window.
28 // Also added a work-around to Cocoa's insistance on drawing
29 // a focus ring around the first toolbar icon when going from
30 // a view with a focusable item to a view without a focusable item.
32 // 31 May 2007 : Version 1.1.2
33 // The window's title bar and toolbar heights are now calculated at
34 // runtime, rather than being hard-coded.
35 // Fixed a redraw problem and a window placement problem associated
36 // with large preference windows.
37 // Added some code to supress compiler warnings from unused parameters.
38 // Fixed a couple of objects that weren't being properly released.
42 #import <Cocoa/Cocoa.h>
45 @interface DBPrefsWindowController : NSWindowController
46 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
47 // 10.6 has turned delegate messages into formal protocols
48 <NSAnimationDelegate, NSToolbarDelegate>
49 #endif
51 NSMutableArray *toolbarIdentifiers;
52 NSMutableDictionary *toolbarViews;
53 NSMutableDictionary *toolbarItems;
55 BOOL _crossFade;
56 BOOL _shiftSlowsAnimation;
58 NSView *contentSubview;
59 NSViewAnimation *viewAnimation;
61 NSString *currentPaneIdentifier;
65 + (DBPrefsWindowController *)sharedPrefsWindowController;
66 + (NSString *)nibName;
68 - (void)setupToolbar;
69 - (void)addView:(NSView *)view label:(NSString *)label;
70 - (void)addView:(NSView *)view label:(NSString *)label image:(NSImage *)image;
72 - (BOOL)crossFade;
73 - (void)setCrossFade:(BOOL)fade;
74 - (BOOL)shiftSlowsAnimation;
75 - (void)setShiftSlowsAnimation:(BOOL)slows;
77 - (void)displayViewForIdentifier:(NSString *)identifier animate:(BOOL)animate;
78 - (void)crossFadeView:(NSView *)oldView withView:(NSView *)newView;
79 - (NSRect)frameForView:(NSView *)view;
82 @end