]> git.saurik.com Git - iphone-api.git/blame - UIKit/UIKit.h
This one only took me maybe a half hour to find.
[iphone-api.git] / UIKit / UIKit.h
CommitLineData
2cd8f71b
JF
1#ifndef UIKIT_UIKIT_H_
2#define UIKIT_UIKIT_H_
3
4@class NSString;
5
35e4f7ee 6#import <Foundation/Foundation.h>
dfbdd7ed 7#import <GraphicsServices/GraphicsServices.h>
35e4f7ee
JF
8#import <CoreGraphics/CoreGraphics.h>
9
10typedef double UIAccelerationValue;
2cd8f71b 11
5e6f78ac
JF
12/*XXX:*/typedef struct {
13 struct CGRect _field1;
14 struct CGRect _field2;
15 struct CGRect _field3;
16 struct CGRect _field4;
17 struct CGRect _field5;
18 id _field6;
19 id _field7;
20 unsigned int _field8;
21 unsigned int _field9;
22 unsigned int _field10;
23 id _field11;
24} CDAnonymousStruct9;
25
2cd8f71b
JF
26/*XXX:*/typedef struct {
27 float top;
28 float left;
29 float bottom;
30 float right;
31} CDAnonymousStruct2;
32
dfbdd7ed
JF
33/*XXX:*/typedef struct {
34 unsigned int numberOfRows:7;
35 unsigned int delegateAlertSheetButtonClicked:1;
36 unsigned int delegateDidPresentAlertSheet:1;
37 unsigned int delegateDidDismissAlertSheet:1;
38 unsigned int hideButtonBar:1;
39 unsigned int alertStyle:3;
40 unsigned int dontDimBackground:1;
41 unsigned int dismissSuspended:1;
42 unsigned int dontBlockInteraction:1;
43 unsigned int sheetWasPoppedUp:1;
44 unsigned int animating:1;
45 unsigned int hideWhenDoneAnimating:1;
46 unsigned int layoutWhenDoneAnimating:1;
47 unsigned int titleMaxLineCount:2;
48 unsigned int bodyTextMaxLineCount:3;
49 unsigned int runsModal:1;
50 unsigned int runningModal:1;
51 unsigned int addedTextView:1;
52 unsigned int addedTableShadows:1;
53 unsigned int showOverSBAlerts:1;
54 unsigned int showMinTableContent:1;
55 unsigned int bodyTextTruncated:1;
56 unsigned int orientation:3;
57 unsigned int delegateBodyTextAlignment:1;
58 unsigned int delegateClickedButtonAtIndex:1;
59 unsigned int delegateClickedButtonAtIndex2:1;
60 unsigned int delegateCancel:1;
61 unsigned int delegateCancel2:1;
62 unsigned int delegateWillPresent:1;
63 unsigned int delegateWillPresent2:1;
64 unsigned int delegateDidPresent:1;
65 unsigned int delegateDidPresent2:1;
66 unsigned int delegateWillDismiss:1;
67 unsigned int delegateWillDismiss2:1;
68 unsigned int delegateDidDismiss:1;
69 unsigned int delegateDidDismiss2:1;
70} CDAnonymousStruct7;
71
2cd8f71b
JF
72typedef enum {
73 UIBarButtonItemStylePlain,
74 UIBarButtonItemStyleBordered,
75 UIBarButtonItemStyleDone,
76} UIBarButtonItemStyle;
77
78typedef enum {
79 UIBarStyleDefault,
80 UIBarStyleBlackOpaque,
81 UIBarStyleBlackTranslucent,
82} UIBarStyle;
83
84typedef enum {
85 UIButtonTypeCustom,
86 UIButtonTypeRoundedRect,
87 UIButtonTypeDetailDisclosure,
88 UIButtonTypeInfoLight,
89 UIButtonTypeInfoDark,
90 UIButtonTypeContactAdd,
91} UIButtonType;
92
93enum {
94 UIControlEventTouchDown = 1 << 0,
95 UIControlEventTouchDownRepeat = 1 << 1,
96 UIControlEventTouchDragInside = 1 << 2,
97 UIControlEventTouchDragOutside = 1 << 3,
98 UIControlEventTouchDragEnter = 1 << 4,
99 UIControlEventTouchDragExit = 1 << 5,
100 UIControlEventTouchUpInside = 1 << 6,
101 UIControlEventTouchUpOutside = 1 << 7,
102 UIControlEventTouchCancel = 1 << 8,
103 UIControlEventValueChanged = 1 << 12,
104
105 UIControlEventEditingDidBegin = 1 << 16,
106 UIControlEventEditingChanged = 1 << 17,
107 UIControlEventEditingDidEnd = 1 << 18,
108 UIControlEventEditingDidEndOnExit = 1 << 19,
109
110 UIControlEventAllTouchEvents = 0x00000fff,
111 UIControlEventAllEditingEvents = 0x000f0000,
112 UIControlEventApplicationReserved = 0x0f000000,
113 UIControlEventSystemReserved = 0xf0000000,
114 UIControlEventAllEvents = 0xffffffff,
115}; typedef NSUInteger UIControlEvents;
116
117enum {
118 UIControlStateNormal = 0,
119 UIControlStateHighlighted = 1 << 0,
120 UIControlStateDisabled = 1 << 1,
121 UIControlStateSelected = 1 << 2,
122 UIControlStateApplication = 0x00ff0000,
123 UIControlStateReserved = 0xff000000,
124}; typedef NSUInteger UIControlState;
125
126typedef enum {
127 UIDeviceOrientationUnknown,
128 UIDeviceOrientationPortrait,
129 UIDeviceOrientationPortraitUpsideDown,
130 UIDeviceOrientationLandscapeLeft,
131 UIDeviceOrientationLandscapeRight,
132 UIDeviceOrientationFaceUp,
133 UIDeviceOrientationFaceDown,
134} UIDeviceOrientation;
135
35e4f7ee
JF
136typedef enum {
137 UIGestureAttributeMinDegrees, /*float*/
138 UIGestureAttributeMaxDegrees, /*float*/
139 UIGestureAttributeMinScale, /*float*/
140 UIGestureAttributeMaxScale, /*float*/
141 UIGestureAttributeIsZoomRubberBandEnabled, /*BOOL*/
142 UIGestureAttributeZoomsFromCurrentToMinOrMax, /*BOOL*/
143 UIGestureAttributeVisibleSize, /*CGSize*/
144 UIGestureAttributeUpdatesScroller, /*BOOL*/
145} UIGestureAttribute;
146
2cd8f71b
JF
147typedef enum {
148 UIInterfaceOrientationPortrait = UIDeviceOrientationPortrait,
149 UIInterfaceOrientationPortraitUpsideDown = UIDeviceOrientationPortraitUpsideDown,
150 UIInterfaceOrientationLandscapeLeft = UIDeviceOrientationLandscapeRight,
151 UIInterfaceOrientationLandscapeRight = UIDeviceOrientationLandscapeLeft,
152} UIInterfaceOrientation;
153
35e4f7ee
JF
154typedef enum {
155 UIKeyboardTypeDefault,
156 UIKeyboardTypeASCIICapable,
157 UIKeyboardTypeNumbersAndPunctuation,
158 UIKeyboardTypeURL,
159 UIKeyboardTypeNumberPad,
160 UIKeyboardTypePhonePad,
161 UIKeyboardTypeNamePhonePad,
162 UIKeyboardTypeEmailAddress,
163} UIKeyboardType;
164
5e6f78ac
JF
165typedef enum {
166 UILineBreakModeWordWrap,
167 UILineBreakModeCharacterWrap,
168 UILineBreakModeClip,
169 UILineBreakModeHeadTruncation,
170 UILineBreakModeTailTruncation,
171 UILineBreakModeMiddleTruncation,
172} UILineBreakMode;
173
2cd8f71b
JF
174typedef enum {
175 UINavigationButtonStyleNormal,
176 UINavigationButtonStyleBack,
177 UINavigationButtonStyleHighlighted,
178 UINavigationButtonStyleDestructive
179} UINavigationButtonStyle;
180
e37693b8
JF
181typedef enum {
182 UIProgressIndicatorStyleLargeWhite,
183 UIProgressIndicatorStyleMediumWhite,
184 UIProgressIndicatorStyleMediumBrown,
185 UIProgressIndicatorStyleSmallWhite,
186 UIProgressIndicatorStyleSmallBlack,
187 UIProgressIndicatorStyleTinyWhite,
188} UIProgressIndicatorStyle;
189
35e4f7ee
JF
190typedef enum {
191 UIReturnKeyDefault,
192 UIReturnKeyGo,
193 UIReturnKeyGoogle,
194 UIReturnKeyJoin,
195 UIReturnKeyNext,
196 UIReturnKeyRoute,
197 UIReturnKeySearch,
198 UIReturnKeySend,
199 UIReturnKeyYahoo,
200 UIReturnKeyDone,
201 UIReturnKeyEmergencyCall,
202} UIReturnKeyType;
203
204typedef enum {
205 UISegmentedControlStylePlain,
206 UISegmentedControlStyleBordered,
207 UISegmentedControlStyleBar,
208} UISegmentedControlStyle;
209
dfbdd7ed
JF
210typedef enum {
211 UITableViewCellEditingStyleNone,
212 UITableViewCellEditingStyleDelete,
213 UITableViewCellEditingStyleInsert
214} UITableViewCellEditingStyle;
215
216typedef enum {
217 UITableViewCellSeparatorStyleNone,
218 UITableViewCellSeparatorStyleSingleLine
219} UITableViewCellSeparatorStyle;
2cd8f71b
JF
220
221typedef enum {
dfbdd7ed
JF
222 UITableViewRowAnimationFade,
223 UITableViewRowAnimationRight,
224 UITableViewRowAnimationLeft,
225 UITableViewRowAnimationTop,
226 UITableViewRowAnimationBottom,
227} UITableViewRowAnimation;
228
5e6f78ac
JF
229typedef enum {
230 UITableViewScrollPositionNone,
231 UITableViewScrollPositionTop,
232 UITableViewScrollPositionMiddle,
233 UITableViewScrollPositionBottom,
234} UITableViewScrollPosition;
235
236typedef enum {
237 UITableViewStylePlain,
238 UITableViewStyleGrouped,
239} UITableViewStyle;
240
dfbdd7ed 241typedef enum {
35e4f7ee
JF
242 UITextAlignmentLeft,
243 UITextAlignmentCenter,
244 UITextAlignmentRight,
dfbdd7ed
JF
245} UITextAlignment;
246
35e4f7ee
JF
247typedef enum {
248 UITextAutocapitalizationTypeNone,
249 UITextAutocapitalizationTypeWords,
250 UITextAutocapitalizationTypeSentences,
251 UITextAutocapitalizationTypeAllCharacters,
252} UITextAutocapitalizationType;
253
254typedef enum {
255 UITextAutocorrectionTypeDefault,
256 UITextAutocorrectionTypeNo,
257 UITextAutocorrectionTypeYes,
258} UITextAutocorrectionType;
259
dfbdd7ed
JF
260typedef enum {
261 UITransitionNone = 0,
262 UITransitionPushFromRight = 1,
263 UITransitionPushFromLeft = 2,
264 UITransitionPushFromBottom = 3,
265 UITransitionFade = 6,
266 UITransitionPushFromTop = 7,
2cd8f71b
JF
267} UITransition;
268
269typedef enum {
270 UIViewAnimationCurveEaseInOut,
271 UIViewAnimationCurveEaseIn,
272 UIViewAnimationCurveEaseOut,
273 UIViewAnimationCurveLinear,
274} UIViewAnimationCurve;
275
dfbdd7ed
JF
276enum {
277 UIViewAutoresizingNone = 0,
278 UIViewAutoresizingFlexibleLeftMargin = 1 << 0,
279 UIViewAutoresizingFlexibleWidth = 1 << 1,
280 UIViewAutoresizingFlexibleRightMargin = 1 << 2,
281 UIViewAutoresizingFlexibleTopMargin = 1 << 3,
282 UIViewAutoresizingFlexibleHeight = 1 << 4,
283 UIViewAutoresizingFlexibleBottomMargin = 1 << 5,
284}; typedef NSUInteger UIViewAutoresizing;
285
35e4f7ee
JF
286#import <UIKit/UIAcceleration.h>
287#import <UIKit/UIAccelerometer.h>
288#import <UIKit/UIActionSheet.h>
e129eb2d 289#import <UIKit/UIActionSheet-Private.h>
dfbdd7ed 290#import <UIKit/UIAlertView.h>
2cd8f71b
JF
291#import <UIKit/UIAnimator.h>
292#import <UIKit/UIApplication.h>
293#import <UIKit/UIBarButtonItem.h>
294#import <UIKit/UIBezierPath.h>
295#import <UIKit/UIBezierPath-UIInternal.h>
296#import <UIKit/UIButton.h>
e129eb2d 297#import <UIKit/UIButton-UIButtonPrivate.h>
2cd8f71b
JF
298#import <UIKit/UIColor.h>
299#import <UIKit/UIColor-UIColorSystemColors.h>
e129eb2d 300#import <UIKit/UIControl-UIControlPrivate.h>
5e6f78ac
JF
301#import <UIKit/UICoverFlowLayer.h>
302#import <UIKit/UIDefaultKeyboardInput.h>
dfbdd7ed 303#import <UIKit/UIDevice.h>
5e6f78ac 304#import <UIKit/UIEvent.h>
2cd8f71b
JF
305#import <UIKit/UIFieldEditor.h>
306#import <UIKit/UIFrameAnimation.h>
307#import <UIKit/UIFont.h>
5e6f78ac 308#import <UIKit/UIFormAssistant.h>
2cd8f71b
JF
309#import <UIKit/UIHardware.h>
310#import <UIKit/UIFieldEditor.h>
2cd8f71b 311#import <UIKit/UIImage.h>
e129eb2d 312#import <UIKit/UIImage-UIImageDeprecated.h>
2cd8f71b
JF
313#import <UIKit/UIImage-UIImageInternal.h>
314#import <UIKit/UIImage-UIImagePrivate.h>
315#import <UIKit/UIImageAndTextTableCell.h>
316#import <UIKit/UIImageView.h>
317#import <UIKit/UIKeyboard.h>
318#import <UIKit/UIKeyboardImpl.h>
5e6f78ac
JF
319#import <UIKit/UIKeyboardLayoutRoman.h>
320#import <UIKit/UIKeyboardSublayout.h>
49226a34
JF
321#import <UIKit/UIModalView.h>
322#import <UIKit/UIModalView-Private.h>
2cd8f71b 323#import <UIKit/UINavigationBar.h>
e129eb2d 324#import <UIKit/UINavigationBar-Static.h>
2cd8f71b
JF
325#import <UIKit/UINavigationButton.h>
326#import <UIKit/UINavigationController.h>
327#import <UIKit/UINavigationItem.h>
e129eb2d 328#import <UIKit/UIOldSliderControl.h>
35e4f7ee 329#import <UIKit/UIPreferencesControlTableCell.h>
2cd8f71b
JF
330#import <UIKit/UIPreferencesTable.h>
331#import <UIKit/UIPreferencesTableCell.h>
e129eb2d 332#import <UIKit/UIPreferencesTextTableCell.h>
2cd8f71b
JF
333#import <UIKit/UIProgressBar.h>
334#import <UIKit/UIProgressHUD.h>
e129eb2d 335#import <UIKit/UIProgressHUD-Deprecated.h>
2cd8f71b
JF
336#import <UIKit/UIProgressIndicator.h>
337#import <UIKit/UIPushButton.h>
338#import <UIKit/UIScreen.h>
339#import <UIKit/UISearchField.h>
35e4f7ee 340#import <UIKit/UISegmentedControl.h>
2cd8f71b
JF
341#import <UIKit/UISectionList.h>
342#import <UIKit/UISimpleTableCell.h>
343#import <UIKit/_UISwitchSlider.h>
344#import <UIKit/UITableCell.h>
345#import <UIKit/UITableColumn.h>
346#import <UIKit/UITableView.h>
347#import <UIKit/UITableViewCell.h>
5e6f78ac
JF
348#import <UIKit/UITableViewCell-UITableViewCellInternal.h>
349#import <UIKit/UITableViewCell-UITableViewCellStatic.h>
2cd8f71b
JF
350#import <UIKit/UITableViewController.h>
351#import <UIKit/UITableViewDelegate-Protocol.h>
352#import <UIKit/UITextField.h>
353#import <UIKit/UITextInputTraits.h>
354#import <UIKit/UITextLabel.h>
355#import <UIKit/UITextView.h>
356#import <UIKit/UIThreePartButton.h>
5e6f78ac
JF
357#import <UIKit/UITabBar.h>
358#import <UIKit/UITabBar-UITabBarPrivate.h>
359#import <UIKit/UITabBarItem.h>
2cd8f71b 360#import <UIKit/UIToolbar.h>
e129eb2d 361#import <UIKit/UIToolbar-UIButtonBarPrivate.h>
35e4f7ee 362#import <UIKit/UITouch.h>
2cd8f71b
JF
363#import <UIKit/UITransitionView.h>
364#import <UIKit/UIView-Animation.h>
e129eb2d 365#import <UIKit/UIView-Deprecated.h>
2cd8f71b
JF
366#import <UIKit/UIView-Geometry.h>
367#import <UIKit/UIView-Gestures.h>
368#import <UIKit/UIView-Hierarchy.h>
35e4f7ee 369#import <UIKit/UIView-Internal.h>
2cd8f71b
JF
370#import <UIKit/UIView-Rendering.h>
371#import <UIKit/UIViewController.h>
372#import <UIKit/UIWebDocumentView.h>
373#import <UIKit/UIWebDocumentView-Forms.h>
5e6f78ac 374#import <UIKit/UIWebDocumentView-Interaction.h>
e129eb2d 375#import <UIKit/UIWebDocumentView-Messaging.h>
2cd8f71b
JF
376#import <UIKit/UIWebView.h>
377#import <UIKit/UIWindow.h>
e129eb2d 378#import <UIKit/UIWindow-Static.h>
2cd8f71b 379
dfbdd7ed 380#import <UIKit/NSIndexPath-UITableView.h>
e129eb2d 381
5e6f78ac 382#import <UIKit/NSString-UIKBExtras.h>
2cd8f71b 383#import <UIKit/NSString-UIStringDrawing.h>
e129eb2d 384#import <UIKit/NSString-UIStringDrawingDeprecated.h>
2cd8f71b 385
e37693b8
JF
386#import <UIKit/NSURL-UIKitAdditions.h>
387
35e4f7ee
JF
388@protocol UIApplicationDelegate<NSObject>
389@end
2cd8f71b
JF
390
391#ifdef __cplusplus
392extern "C" {
393#endif
394
395int UIApplicationMain(int argc, char *argv[], NSString *principalClassName, NSString *delegateClassName);
396
35e4f7ee
JF
397UIImage *_UIImageWithName(NSString *name);
398
399NSData *UIImageJPEGRepresentation(UIImage *image);
400NSData *UIImagePNGRepresentation(UIImage *image);
401
2cd8f71b
JF
402CGContextRef UIGraphicsGetCurrentContext(void);
403UIWindow *UIWindowFindWithWindowRef(GSWindowRef window);
404
5e6f78ac
JF
405NSString *UIFormattedPhoneNumberFromString(NSString *string);
406NSString *UIUnformattedPhoneNumberFromString(NSString *string);
407
408void UIRectFill(CGRect rect);
409void UISetColor(CGColorRef color);
410void UISetSystemColor(unsigned color);
411
63e8eac2
JF
412GSFontRef UISystemFontCreate(unsigned size, bool bold);
413GSFontRef UISystemFontForSize(unsigned size);
414GSFontRef UISystemFontBoldForSize(unsigned size);
415
2cd8f71b
JF
416void UIApplicationUseLegacyEvents(BOOL use);
417void UIKeyboardEnableAutomaticAppearance(void);
418void UIKeyboardDisableAutomaticAppearance(void);
419
5e6f78ac
JF
420BOOL UIKeyboardInputModeUsesKBStar(NSString *);
421
e37693b8
JF
422extern NSString * const kUIButtonBarButtonAction;
423extern NSString * const kUIButtonBarButtonInfo;
424extern NSString * const kUIButtonBarButtonInfoOffset;
425extern NSString * const kUIButtonBarButtonSelectedInfo;
426extern NSString * const kUIButtonBarButtonStyle;
427extern NSString * const kUIButtonBarButtonTag;
428extern NSString * const kUIButtonBarButtonTarget;
429extern NSString * const kUIButtonBarButtonTitle;
430extern NSString * const kUIButtonBarButtonTitleVerticalHeight;
431extern NSString * const kUIButtonBarButtonTitleWidth;
432extern NSString * const kUIButtonBarButtonType;
2cd8f71b
JF
433
434extern NSString * const UIKeyboardWillShowNotification;
435extern NSString * const UIKeyboardDidShowNotification;
436extern NSString * const UIKeyboardWillHideNotification;
437extern NSString * const UIKeyboardDidHideNotification;
438extern NSString * const UIKeyboardCenterBeginUserInfoKey;
439extern NSString * const UIKeyboardCenterEndUserInfoKey;
440extern NSString * const UIKeyboardBoundsUserInfoKey;
441
e129eb2d
JF
442extern NSString * const UIWebViewDidReceiveMessageNotification;
443extern NSString * const UIWebViewDidClearMessagesNotification;
444
35e4f7ee
JF
445extern float const UIWebViewGrowsAndShrinksToFitHeight;
446extern float const UIWebViewGrowsAndShrinksToFitWidth;
447extern float const UIWebViewScalesToFitScale;
448
e37693b8
JF
449extern UIApplication * const UIApp;
450
35e4f7ee
JF
451//UIFont *UISystemFontWithSize(CGFloat size);
452
e37693b8
JF
453#ifdef __cplusplus
454}
455#endif
456
2cd8f71b 457#endif//UIKIT_UIKIT_H_