chore(macos): vendor system-sdk dependency

This commit is contained in:
2024-09-09 03:44:35 -05:00
parent 7f8d05101e
commit a50d52bae5
2634 changed files with 871615 additions and 1 deletions

View File

@@ -0,0 +1,860 @@
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 4A421290-C065-3A5B-A1B6-CFD3089777A2
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 9D2BB9C5-35D3-359E-AB34-EF8E5165F513
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Carbon'
current-version: 165
compatibility-version: 2
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _CarbonVersionNumber, _CarbonVersionString ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 77D1909A-B552-3B89-BAA3-4968DBE58A3E
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 83145A1E-897C-34E0-8378-6F14F11E851E
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/CommonPanels.framework/Versions/A/CommonPanels'
current-version: 101
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ AppKit ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _CCP_FontPanelClose, _CCP_FontPanelGetSelection, _CCP_FontPanelIsVisible,
_CCP_FontPanelOpen, _CCP_FontPanelSelectFonts, _CCP_NPickColor,
_CMCalibrateDisplay, _Call_CommonCocoaPanels_NPickColor, _CommonPanelsVersionNumber,
_CommonPanelsVersionString, _DisposeCalibrateEventUPP, _DisposeCalibrateUPP,
_DisposeCanCalibrateUPP, _DisposeNColorChangedUPP, _FCAddCollection,
_FCAddFontDescriptorToCollection, _FCCopyCollectionNames,
_FCCopyFontDescriptorsInCollection, _FCFontDescriptorCreateWithFontAttributes,
_FCFontDescriptorCreateWithName, _FCRemoveCollection, _FCRemoveFontDescriptorFromCollection,
_FPIsFontPanelVisible, _FPShowHideFontPanel, _GetColor, _GetHandleApplicationEventsUPP,
_GetHandleWinEventsUPP, _InvokeCalibrateEventUPP, _InvokeCalibrateUPP,
_InvokeCanCalibrateUPP, _InvokeNColorChangedUPP, _LoadNSTypographyBundle,
_NPickColor, _NewCalibrateEventUPP, _NewCalibrateUPP, _NewCanCalibrateUPP,
_NewNColorChangedUPP, _SetFontInfoForSelection, _SoftLinkingGetFunctionPointerFromBundleInDirectory,
_UserWantsColorPanelFromCommonCocoaPanels, __SoftLinkingLoadBundleFromLocation,
_gApplicationDeactivated, _gApplicationHandler, _gCallingApp,
_gCallingCCP, _gEventTarget, _gFontPanelInitialized, _gFontPanelRef,
_gHandler, _gNSTypographyBundle, _gSelFontInfo, _kFCFontCGColorAttribute,
_kFCFontFaceAttribute, _kFCFontFamilyAttribute, _kFCFontNameAttribute,
_kFCFontSizeAttribute, _kFCFontVisibleNameAttribute, _kFontPanelATSUFontIDKey,
_kFontPanelAttributeSizesKey, _kFontPanelAttributeTagsKey,
_kFontPanelAttributeValuesKey, _kFontPanelAttributesKey, _kFontPanelBackgroundColorAttributeName,
_kFontPanelDocumentAttributesKey, _kFontPanelFeatureSelectorsKey,
_kFontPanelFeatureTypesKey, _kFontPanelMouseTrackingState,
_kFontPanelVariationAxesKey, _kFontPanelVariationValuesKey ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 6320CF1B-CCD8-336D-ADB8-888AC1D8A1AA
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 7E5988A9-A641-398E-A67D-4B3ED39C3B51
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/HIToolbox'
current-version: 1111.3
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ AGL, AppKit, AppleShareClient, Backup, Dock, Finder, FinderKit,
ImageKit, Printing_UI, QTKit, QTKitServer, RemoteViewServices,
Shortcut, Suggestions, UIKitMacHelper, ViewBridge, loginwindow ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _AEGetInteractionAllowed, _AEGetTheCurrentEvent, _AEInteractWithUser,
_AEProcessAppleEvent, _AEProcessEvent, _AEResetTimer, _AEResumeTheCurrentEvent,
_AESend, _AESetInteractionAllowed, _AESetTheCurrentEvent,
_AESuspendTheCurrentEvent, _AXNotificationHIObjectNotify,
_AXNotificationHIObjectNotifyWithUserInfo, _AXUIElementCreateWithHIObjectAndIdentifier,
_AXUIElementGetHIObject, _AXUIElementGetIdentifier, _AcquireFirstMatchingEventInQueue,
_AcquireRootMenu, _ActivateControl, _ActivateTSMDocument,
_ActivateWindow, _ActiveNonFloatingWindow, _AddDataBrowserItems,
_AddEventTypesToHandler, _AppendDITL, _AppendMenuItemTextWithCFString,
_BeginAppModalStateForWindow, _BeginWindowProxyDrag, _BlockUntilNextEventMatchingListInMode,
_BringToFront, _Button, _CalcMenuSize, _CallNextEventHandler,
_CancelMenuTracking, _ChangeMenuAttributes, _ChangeMenuItemAttributes,
_ChangeWindowAttributes, _CheckEventQueueForUserCancel, _CheckMenuItem,
_ClearKeyboardFocus, _ClearMenuBar, _CollapseAllWindows, _CollapseWindow,
_ConfirmAppShowHideEvent, _ConstrainWindowToScreen, _ConvertEventRefToEventRecord,
_CopyControlTitleAsCFString, _CopyEvent, _CopyEventAs, _CopyEventCGEvent,
_CopyMenuItemData, _CopyMenuItemTextAsCFString, _CopyMenuItems,
_CopyMenuTitleAsCFString, _CopySymbolicHotKeys, _CopyThemeIdentifier,
_CopyWindowTitleAsCFString, _CountDITL, _CountMenuItems, _CreateCheckBoxControl,
_CreateEvent, _CreateEventWithCGEvent, _CreateIconControl,
_CreateLocaleIdentifierForItl0Itl1ResID, _CreateMenuFromNib,
_CreateNewMenu, _CreateNewWindow, _CreateNibReference, _CreateNibReferenceWithCFBundle,
_CreatePushButtonControl, _CreateRootControl, _CreateShrinkToFitEditControl,
_CreateStandardAlert, _CreateStandardSheet, _CreateStandardWindowMenu,
_CreateStaticTextControl, _CreateTypeStringWithOSType, _CreateWindowFromNib,
_CreateWindowGroup, _CreateWindowWithCGSWindow, _DeactivateControl,
_DeactivateTSMDocument, _DebugPrintAllWindowGroups, _DebugPrintControl,
_DebugPrintControlHierarchy, _DebugPrintDialogInfo, _DebugPrintEvent,
_DebugPrintEventQueue, _DebugPrintMainEventQueue, _DebugPrintMenu,
_DebugPrintMenuItem, _DebugPrintMenuList, _DebugPrintTracedEvents,
_DebugPrintWindow, _DebugPrintWindowGroup, _DebugPrintWindowList,
_DebugSetEventTraceEnabled, _DebugTraceEvent, _DebugTraceEventByName,
_DeleteMenu, _DeleteMenuItem, _DeleteMenuItems, _DeleteTSMDocument,
_DetachSheetWindow, _DialogSelect, _DisableControl, _DisableMenuCommand,
_DisableMenuItem, _DisableScreenUpdates, _DisableSecureEventInput,
_DisposeNibReference, _DisposeWindow, _DragWindow, _DrawMenuBar,
_EnableControl, _EnableMenuItem, _EnableScreenUpdates, _EnableSecureEventInput,
_EndAppModalStateForWindow, _EndWindowProxyDrag, _EventAvail,
_FindControlUnderMouse, _FindSpecificEventInQueue, _FindWindow,
_FixTSMDocument, _FlashMenuBar, _FlushEventQueue, _FlushEvents,
_FlushEventsMatchingListFromQueue, _FlushSpecificEventsFromQueue,
_FrontNonFloatingWindow, _FrontWindow, _GetApplicationEventTarget,
_GetApplicationScript, _GetApplicationTextEncoding, _GetBestControlRect,
_GetCFRunLoopFromEventLoop, _GetCarbonAccessibilityCallbacks,
_GetCaretTime, _GetControlBounds, _GetControlByID, _GetControlData,
_GetControlEventTarget, _GetControlFeatures, _GetControlHilite,
_GetControlKind, _GetControlOwner, _GetControlProperty, _GetControlValue,
_GetCurrentButtonState, _GetCurrentEvent, _GetCurrentEventButtonState,
_GetCurrentEventKeyModifiers, _GetCurrentEventLoop, _GetCurrentEventQueue,
_GetCurrentEventTime, _GetCurrentKeyModifiers, _GetDataBrowserItemCount,
_GetDataBrowserItemState, _GetDataBrowserItems, _GetDataBrowserPropertyFlags,
_GetDataBrowserSelectionAnchor, _GetDataBrowserSelectionFlags,
_GetDataBrowserTableViewColumnPosition, _GetDataBrowserTableViewColumnWidth,
_GetDataBrowserTableViewNamedColumnWidth, _GetDataBrowserTableViewRowHeight,
_GetDblTime, _GetDialogFromWindow, _GetDialogItem, _GetDialogItemAsControl,
_GetDialogWindow, _GetEventAttributes, _GetEventClass, _GetEventDispatcherTarget,
_GetEventKind, _GetEventMonitorTarget, _GetEventParameter,
_GetEventRetainCount, _GetEventTime, _GetFrontWindowOfClass,
_GetGrayRgn, _GetIndMenuItemWithCommandID, _GetIndexedSubControl,
_GetItemMark, _GetItlResourceIDsForLocale, _GetKeyboardFocus,
_GetKeys, _GetMBarHeight, _GetMainEventLoop, _GetMainEventQueue,
_GetMenuAttributes, _GetMenuDefinition, _GetMenuEventTarget,
_GetMenuHandle, _GetMenuHeight, _GetMenuID, _GetMenuItemAttributes,
_GetMenuItemBounds, _GetMenuItemCommandID, _GetMenuItemCommandKey,
_GetMenuItemHierarchicalMenu, _GetMenuItemModifiers, _GetMenuItemProperty,
_GetMenuItemRefCon, _GetMenuTitleIcon, _GetMenuTrackingData,
_GetMenuType, _GetMenuWidth, _GetNativeWindowFromWindowRef,
_GetNextMenu, _GetNextWindow, _GetNextWindowOfClass, _GetNumEventsInQueue,
_GetPreviousMenu, _GetPreviousWindow, _GetRootControl, _GetSheetWindowParent,
_GetStandardAlertDefaultParams, _GetSuperControl, _GetSymbolicHotKeyMode,
_GetSystemUIMode, _GetThemeBrushAsColor, _GetThemeMenuBarHeight,
_GetThemeMenuItemExtra, _GetThemeMenuSeparatorHeight, _GetThemeMenuTitleExtra,
_GetThemeMetric, _GetThemeTextColor, _GetThemeTextShadowOutset,
_GetUserFocusEventTarget, _GetUserFocusWindow, _GetWRefCon,
_GetWindowActivationScope, _GetWindowAttributes, _GetWindowBounds,
_GetWindowCancelButton, _GetWindowClass, _GetWindowDefaultButton,
_GetWindowEventTarget, _GetWindowFeatures, _GetWindowGroup,
_GetWindowGroupLevel, _GetWindowGroupOfClass, _GetWindowGroupParent,
_GetWindowIdealUserState, _GetWindowKind, _GetWindowList,
_GetWindowModality, _GetWindowPortBounds, _GetWindowProperty,
_GetWindowRefFromNativeWindow, _GetWindowStandardState, _GetWindowSystemProperty,
_HICopyAccessibilityActionDescription, _HICopyAccessibilityRoleDescription,
_HIDictionaryWindowShow, _HIGetMousePosition, _HIGetScaleFactor,
_HIGrowBoxViewIsTransparent, _HIGrowBoxViewSetTransparent,
_HIMenuCopyFont, _HIMenuCopyParents, _HIMenuGetContentView,
_HIMenuItemViewCancelMenuTracking, _HIMenuItemViewGetEnclosingMenuItem,
_HIMenuSetAttributedItemText, _HIMenuSetFont, _HIMenuSetSelection,
_HIMouseTrackingGetParameters, _HIObjectAddDelegate, _HIObjectCopyClassID,
_HIObjectCopyDelegates, _HIObjectCreate, _HIObjectCreateFromBundle,
_HIObjectDynamicCast, _HIObjectFromEventTarget, _HIObjectGetEventHandlerObject,
_HIObjectGetEventTarget, _HIObjectIsAccessibilityIgnored,
_HIObjectIsArchivingIgnored, _HIObjectIsOfClass, _HIObjectOverrideAccessibilityContainment,
_HIObjectPrintDebugInfo, _HIObjectRegisterSubclass, _HIObjectRemoveDelegate,
_HIObjectSetAccessibilityIgnored, _HIObjectSetAuxiliaryAccessibilityAttribute,
_HIObjectUnregisterClass, _HIPointConvert, _HIRectConvert,
_HIScrollViewCreate, _HIScrollViewGetAllowGrow, _HIScrollViewGetScrollBarAutoHide,
_HIScrollViewSetAllowGrow, _HIScrollViewSetScrollBarAutoHide,
_HISearchFieldChangeAttributes, _HISearchFieldCreate, _HISearchFieldGetAttributes,
_HISearchWindowShow, _HISegmentedViewChangeSegmentAttributes,
_HISegmentedViewGetSegmentBehavior, _HISegmentedViewGetSegmentCommand,
_HISegmentedViewGetSegmentCount, _HISegmentedViewIsSegmentEnabled,
_HISegmentedViewSetSegmentBehavior, _HISegmentedViewSetSegmentCommand,
_HISegmentedViewSetSegmentContentWidth, _HISegmentedViewSetSegmentCount,
_HISegmentedViewSetSegmentEnabled, _HISegmentedViewSetSegmentImage,
_HISizeConvert, _HITextViewCreate, _HITextViewGetTXNObject,
_HIThemeApplyBackground, _HIThemeBeginFocus, _HIThemeBrushCreateCGColor,
_HIThemeDrawBackground, _HIThemeDrawButton, _HIThemeDrawChasingArrows,
_HIThemeDrawFocusRect, _HIThemeDrawFrame, _HIThemeDrawGenericWell,
_HIThemeDrawGrabber, _HIThemeDrawGroupBox, _HIThemeDrawGrowBox,
_HIThemeDrawHeader, _HIThemeDrawMenuBackground, _HIThemeDrawMenuBarBackground,
_HIThemeDrawMenuItem, _HIThemeDrawMenuSeparator, _HIThemeDrawMenuTitle,
_HIThemeDrawPaneSplitter, _HIThemeDrawPlacard, _HIThemeDrawPopupArrow,
_HIThemeDrawScrollBarDelimiters, _HIThemeDrawSegment, _HIThemeDrawSeparator,
_HIThemeDrawTab, _HIThemeDrawTabPane, _HIThemeDrawTextBox,
_HIThemeDrawTickMark, _HIThemeDrawTitleBarWidget, _HIThemeDrawTrack,
_HIThemeDrawTrackTickMarks, _HIThemeDrawWindowFrame, _HIThemeEndFocus,
_HIThemeGetButtonBackgroundBounds, _HIThemeGetButtonContentBounds,
_HIThemeGetButtonShape, _HIThemeGetGrowBoxBounds, _HIThemeGetMenuBackgroundShape,
_HIThemeGetScrollBarTrackRect, _HIThemeGetTabDrawShape, _HIThemeGetTabPaneContentShape,
_HIThemeGetTabPaneDrawShape, _HIThemeGetTabShape, _HIThemeGetTextColorForThemeBrush,
_HIThemeGetTextDimensions, _HIThemeGetTrackBounds, _HIThemeGetTrackDragRect,
_HIThemeGetTrackLiveValue, _HIThemeGetTrackPartBounds, _HIThemeGetTrackParts,
_HIThemeGetTrackThumbPositionFromBounds, _HIThemeGetTrackThumbPositionFromOffset,
_HIThemeGetTrackThumbShape, _HIThemeGetUIFontType, _HIThemeGetWindowRegionHit,
_HIThemeGetWindowShape, _HIThemeHitTestScrollBarArrows, _HIThemeHitTestTrack,
_HIThemeSetFill, _HIThemeSetStroke, _HIThemeSetTextFill, _HIThemeSetTextStroke,
_HIToolbarAppendItem, _HIToolbarChangeAttributes, _HIToolbarCopyItems,
_HIToolbarCreate, _HIToolbarCreateItemWithIdentifier, _HIToolbarGetDisplayMode,
_HIToolbarGetDisplaySize, _HIToolbarItemChangeAttributes,
_HIToolbarItemChangeAttributesInWindow, _HIToolbarItemCopyIdentifier,
_HIToolbarItemCreate, _HIToolbarItemGetCommandID, _HIToolbarItemGetToolbar,
_HIToolbarItemSetCommandID, _HIToolbarItemSetHelpText, _HIToolbarItemSetIconRef,
_HIToolbarItemSetLabel, _HIToolbarItemSetMenu, _HIToolbarRemoveItemAtIndex,
_HIToolbarSetDelegate, _HIToolbarSetDisplayMode, _HIToolbarSetDisplaySize,
_HIViewAddSubview, _HIViewAdvanceFocus, _HIViewApplyLayout,
_HIViewChangeFeatures, _HIViewConvertPoint, _HIViewConvertRect,
_HIViewCopyText, _HIViewCountSubviews, _HIViewCreateOffscreenImage,
_HIViewDisposeTrackingArea, _HIViewDrawCGImage, _HIViewFindByID,
_HIViewFlashDirtyArea, _HIViewGetBounds, _HIViewGetCommandID,
_HIViewGetFeatures, _HIViewGetFirstSubview, _HIViewGetFocus,
_HIViewGetFocusPart, _HIViewGetFrame, _HIViewGetID, _HIViewGetIndexedSubview,
_HIViewGetKind, _HIViewGetLayoutInfo, _HIViewGetMaximum, _HIViewGetMinimum,
_HIViewGetNextView, _HIViewGetOptimalBounds, _HIViewGetRoot,
_HIViewGetSuperview, _HIViewGetThemeTextInfo, _HIViewGetTrackingAreaID,
_HIViewGetValue, _HIViewGetViewForMouseEvent, _HIViewGetViewSize,
_HIViewGetWindow, _HIViewIsActive, _HIViewIsCompositingEnabled,
_HIViewIsDrawingEnabled, _HIViewIsEnabled, _HIViewIsLatentlyVisible,
_HIViewIsLayoutActive, _HIViewIsLayoutLatentlyActive, _HIViewIsVisible,
_HIViewMoveBy, _HIViewNewTrackingArea, _HIViewRegionChanged,
_HIViewRemoveFromSuperview, _HIViewRender, _HIViewResumeLayout,
_HIViewScrollRect, _HIViewSetActivated, _HIViewSetBoundsOrigin,
_HIViewSetCommandID, _HIViewSetDrawingEnabled, _HIViewSetEnabled,
_HIViewSetFocus, _HIViewSetFrame, _HIViewSetHilite, _HIViewSetID,
_HIViewSetLayoutInfo, _HIViewSetMaximum, _HIViewSetMinimum,
_HIViewSetNeedsDisplay, _HIViewSetNeedsDisplayInRect, _HIViewSetNeedsDisplayInShape,
_HIViewSetSubviewsNeedDisplayInShape, _HIViewSetText, _HIViewSetTextFont,
_HIViewSetTextHorizontalFlush, _HIViewSetTextTruncation, _HIViewSetTextVerticalFlush,
_HIViewSetValue, _HIViewSetViewSize, _HIViewSetVisible, _HIViewSetZOrder,
_HIViewSimulateClick, _HIViewSubtreeContainsFocus, _HIViewSuspendLayout,
_HIWindowChangeAttributes, _HIWindowChangeClass, _HIWindowChangeFeatures,
_HIWindowCopyAvailablePositioningShape, _HIWindowFindAtLocation,
_HIWindowFlush, _HIWindowFromCGWindowID, _HIWindowGetAvailablePositioningBounds,
_HIWindowGetBounds, _HIWindowGetCGWindowID, _HIWindowGetGreatestAreaDisplay,
_HIWindowGetScaleMode, _HIWindowIsDocumentModalTarget, _HIWindowSetBottomBarHeight,
_HIWindowTestAttribute, _HMAreHelpTagsDisplayed, _HMGetTagDelay,
_HMInstallControlContentCallback, _HMSetControlHelpContent,
_HMSetHelpTagsDisplayed, _HMSetMenuItemHelpContent, _HMSetTagDelay,
_HandleControlSetCursor, _HideControl, _HideMenuBar, _HideSheetWindow,
_HideWindow, _HiliteControl, _HiliteMenu, _HiliteWindow, _IMKBaselineKey,
_IMKChromaticMarkedTextAttributeName, _IMKDictationHilightAttributeName,
_IMKDictationHilightHypothesisDeltaAttributeName, _IMKDictationInsertionUndoableAttributeName,
_IMKIronwoodTextAlternativeCorrectedKey, _IMKIronwoodTextAlternativeCorrectionIDKey,
_IMKIronwoodTextAlternativeOriginalKey, _IMKIronwoodTextAlternativesAttributeName,
_IMKIronwoodTextAlternativesKey, _IMKLineAscentKey, _IMKLineHeightKey,
_IMKTextOrientationName, _INIT_ScriptHL, _InitDataBrowserCallbacks,
_InitDataBrowserCustomCallbacks, _InsertMenu, _InsertMenuItemTextWithCFString,
_InstallEventHandler, _InstallEventLoopIdleTimer, _InstallEventLoopTimer,
_InstallEventLoopTimerInMode, _InstallInputSourceMgrHandlers,
_InstallStandardEventHandler, _IntlCountResources, _IntlGetIndexedResInfo,
_IntlGetScriptCustomResourceID, _IntlGetValue, _IntlResourceIDToScriptCode,
_IntlSetValue, _InvalMenuBar, _InvalidateMenuBarFilter, _InvalidateMenuItems,
_InvalidateMenuSize, _IsAutomaticControlDragTrackingEnabledForWindow,
_IsCmdChar, _IsControlActive, _IsControlDragTrackingEnabled,
_IsControlHilited, _IsControlVisible, _IsCurrentTSMDocumentUnicode,
_IsDataBrowserItemSelected, _IsEventInInstantMouser, _IsEventInQueue,
_IsMenuBarVisible, _IsMenuItemEnabled, _IsMenuKeyEvent, _IsMenuSizeInvalid,
_IsMouseCoalescingEnabled, _IsSecureEventInputEnabled, _IsShowContextualMenuEvent,
_IsUserCancelEventRef, _IsValidControlHandle, _IsValidMenu,
_IsValidWindowPtr, _IsWindowActive, _IsWindowCollapsed, _IsWindowHilited,
_IsWindowInStandardState, _IsWindowLatentVisible, _IsWindowPathSelectEvent,
_IsWindowToolbarVisible, _IsWindowVisible, _KBGetLayoutType,
_KLCreateKCAPDataForKbdType, _KeyEventMatchesMenuItem, _KeyTranslate,
_LMGetKbdLast, _LMGetKbdType, _LMGetKeyRepThresh, _LMGetKeyThresh,
_LMSetKbdLast, _LMSetKbdType, _LMSetKeyRepThresh, _LMSetKeyThresh,
_LaunchAppleCharacterPalette, _MenuEvent, _MenuSelect, _MoveControl,
_MoveWindow, _MoveWindowStructure, _NMInstall, _NMRemove,
_NewTSMDocument, _OpenThemeResFileMapped, _ParamText, _PopSymbolicHotKeyMode,
_PopUpMenuSelect, _PostEvent, _PostEventToQueue, _PostEventToQueueInternal,
_PostFakeMenuSelectionEvent, _ProcessHICommand, _ProcessInputSourceSwitchEventCandidate,
_ProcessInputSourceSwitchKeySequenceCandidate, _PushSymbolicHotKeyMode,
_QuitAppModalLoopForWindow, _QuitApplicationEventLoop, _QuitEventLoop,
_ReceiveNextEvent, _RegisterEventHotKey, _RegisterSystemToolboxListenerWithOptions,
_ReleaseEvent, _RemoveControlProperty, _RemoveDataBrowserItems,
_RemoveEventFromQueue, _RemoveEventHandler, _RemoveEventLoopTimer,
_RemoveEventParameter, _RemoveEventTypesFromHandler, _RemoveMenuItemProperty,
_RemoveWindowProperty, _RemoveWindowProxy, _RepositionWindow,
_RetainEvent, _RevealDataBrowserItem, _RunAppModalLoopForWindow,
_RunApplicationEventLoop, _RunCurrentEventLoop, _RunStandardAlert,
_SelectWindow, _SendBehind, _SendEventToEventTarget, _SendEventToEventTargetWithOptions,
_SendTextInputEvent, _SendWindowGroupBehind, _SetAnimatedThemeCursor,
_SetApplicationDockTileMenu, _SetAutomaticControlDragTrackingEnabledForWindow,
_SetBevelButtonContentInfo, _SetCocoaAccessibilityCallbacks,
_SetControlAction, _SetControlCommandID, _SetControlData,
_SetControlDragTrackingEnabled, _SetControlFontStyle, _SetControlID,
_SetControlProperty, _SetControlTitleWithCFString, _SetControlValue,
_SetControlVisibility, _SetDataBrowserCallbacks, _SetDataBrowserCustomCallbacks,
_SetDataBrowserItemDataIcon, _SetDataBrowserItemDataText,
_SetDataBrowserPropertyFlags, _SetDataBrowserSelectedItems,
_SetDataBrowserSelectionFlags, _SetDataBrowserSortProperty,
_SetDataBrowserTableViewColumnPosition, _SetDataBrowserTableViewColumnWidth,
_SetDataBrowserTableViewGeometry, _SetDataBrowserTableViewNamedColumnWidth,
_SetDialogItemRectangle, _SetDialogTimeout, _SetEventLoopTimerNextFireTime,
_SetEventParameter, _SetEventTime, _SetItemMark, _SetItemStyle,
_SetKeyboardFocus, _SetMenuBarFromNib, _SetMenuDefinition,
_SetMenuExcludesMarkColumn, _SetMenuItemCommandID, _SetMenuItemCommandKey,
_SetMenuItemHierarchicalMenu, _SetMenuItemIconHandle, _SetMenuItemIndent,
_SetMenuItemKeyGlyph, _SetMenuItemModifiers, _SetMenuItemProperty,
_SetMenuItemRefCon, _SetMenuItemTextWithCFString, _SetMenuTitleIcon,
_SetMenuTitleWithCFString, _SetModalDialogEventMask, _SetMouseCoalescingEnabled,
_SetNextMenu, _SetRootMenu, _SetSystemAppMenuSectionAllowed,
_SetSystemUIMode, _SetThemeCursor, _SetThemeWindowBackground,
_SetUserFocusWindow, _SetWindowActivationScope, _SetWindowAlternateTitle,
_SetWindowBounds, _SetWindowCancelButton, _SetWindowDefaultButton,
_SetWindowGroup, _SetWindowGroupLevel, _SetWindowIdealUserState,
_SetWindowModality, _SetWindowModified, _SetWindowProperty,
_SetWindowProxyAlias, _SetWindowProxyIcon, _SetWindowResizeLimits,
_SetWindowTitleWithCFString, _SetWindowToolbar, _ShowControl,
_ShowHide, _ShowHideWindowToolbar, _ShowMenuBar, _ShowSheetWindow,
_ShowWindow, _SizeControl, _SizeWindow, _StdFilterProc, _SyncWindowToCGSWindow,
_TISCapsLockSwitchShouldKeyboardLayoutUseAlternateForModifiers,
_TISCopyCurrentASCIICapableKeyboardInputSource, _TISCopyCurrentASCIICapableKeyboardLayoutInputSource,
_TISCopyCurrentKeyboardInputSource, _TISCopyCurrentKeyboardLayoutInputSource,
_TISCopyCurrentNonRomanInputSourceForRomanSwitch, _TISCopyInputMethodKeyboardLayoutOverride,
_TISCopyInputSourceForLanguage, _TISCopyInputSourceRefForInputSourceID,
_TISCopyInputSourcesForAttachedKeyboardsFilteredByLocale,
_TISCreateASCIICapableInputSourceList, _TISCreateCompressedInfoStringForInputSource,
_TISCreateDefaultASCIIInputSourceForLocale, _TISCreateInputSourceList,
_TISCreatePrunedPreferredInputSourcesWithABC, _TISCreateSecureKeyboardInputSourceList,
_TISDeselectInputSource, _TISDisableInputSource, _TISEnableInputSource,
_TISEnableInputSourceWithOptions, _TISGetAppleKeyLayoutCount,
_TISGetAppleKeyLayoutIndexForKeyLayoutName, _TISGetAppleKeyLayoutIndexForNumericID,
_TISGetAppleKeyLayoutKLPropertyAtIndex, _TISGetDictationShouldAutoEnable,
_TISGetFnUsageType, _TISGetGestureHandwritingState, _TISGetInputSourceProperty,
_TISHardwareSupportsGestureHandwriting, _TISInputMethodDataFileReaderCreateBasicProperties,
_TISInputMethodDataFileReaderCreatePropertyListAndWordList,
_TISInputSourceGetTypeID, _TISIsKeyboardLayoutCapsLockSwitchAllowed,
_TISIsKeyboardLayoutCapsLockSwitched, _TISIsRomanSwitchAllowed,
_TISIsRomanSwitchEnabled, _TISKeyboardLayoutInputSourceIsQWERTY,
_TISLaunchCharacterPalette, _TISPerformInputMethodDependentBlockDuringWorkBlock,
_TISPrefsCopyCurrentKeyboardLayoutID, _TISPrefsUserSnapshotCopyForMachinePrefs,
_TISRegisterInputSource, _TISSelectInputSource, _TISSetDefaultAsciiCapableKeyboardLayoutInputSource,
_TISSetDictationShouldAutoEnable, _TISSetExtensionsForIntlFileCacheUpdate,
_TISSetGestureHandwritingState, _TISSetInputMethodKeyboardLayoutOverride,
_TISSetRomanSwitchState, _TISUpdateFnUsageType, _TISUpdateIntlFileCache,
_TISUpdaterEnsureKotoeriHiraganaModeForSUMavericks, _TISUpdaterMigrateDictationAutoEnableFromSpeechRecognition,
_TISUpdaterMigrateKotoeriToJapaneseIM, _TISUpdaterMigratePrefsFromByHostDomain,
_TISWriteKeyLayoutCollection, _TSMCanChangeInputSourceEnabledState,
_TSMCopyTextInputGlobalProperty, _TSMCreateInputSourceForKeyboardLayoutRef,
_TSMCreateInputSourceRefForIndex, _TSMCurrentKeyboardInputSourceRefCreate,
_TSMDefaultAsciiCapableKeyboardLayoutCopy, _TSMDeselectInputSource,
_TSMDisableInputSource, _TSMEnableInputSource, _TSMGetActiveDocument,
_TSMGetDeadKeyState, _TSMGetDocumentProperty, _TSMGetInputSourceCount,
_TSMGetInputSourceProperty, _TSMGetIronwoodSessionState, _TSMInvalidateClientGeometry,
_TSMIsInkWithMouseEnabled, _TSMIsInputSourceAsciiCapable,
_TSMIsPressAndHoldActive, _TSMKeyTranslateWithInputSource,
_TSMProcessIronwoodSessionAction, _TSMProcessMouseEvent, _TSMProcessMouseEventWithCompletionHandler,
_TSMProcessRawKeyCode, _TSMProcessRawKeyEvent, _TSMProcessRawKeyEventWithCompletionHandler,
_TSMProcessRawKeyEventWithOptionsAndCompletionHandler, _TSMProcessTabletEvent,
_TSMRecentInputSourcesCreate, _TSMRemoveDocumentProperty,
_TSMSelectInputSource, _TSMSetCurrentAsciiCapableInputSource,
_TSMSetDeadKeyState, _TSMSetDocumentProperty, _TSMSetInkWithMouseEnabled,
_TSMSetInputMethodProperty, _TSMSetTextInputGlobalProperty,
_TSMShouldTextInputMenuBeDisplayed, _TSMUnrestrictInputSourceAccess,
_TSMUpgradePrefBundleIDsToLeopard, _TSMUpgradeScriptMgrPrefsToInputSourcePrefs,
_TXNAdjustCursor, _TXNClear, _TXNCopy, _TXNDataSize, _TXNGetData,
_TXNGetHIRect, _TXNGetIndexedRunInfoFromRange, _TXNGetSelection,
_TXNIsScrapPastable, _TXNPaste, _TXNSelectAll, _TXNSetData,
_TXNSetDataFromCFURLRef, _TXNSetHIRectBounds, _TXNSetSelection,
_TXNSetTXNObjectControls, _TXNShowSelection, _TestWindowLiveResizePerformance,
_TrackWindowProxyFromExistingDrag, _TransitionWindow, _TransitionWindowWithOptions,
_TruncateThemeText, _UnregisterEventHotKey, _UseInputWindow,
_WaitNextEvent, _WindowPathSelect, __AcquireMatchingCGEvent,
__AcquireMatchingCGEventInQueue, __AcquireNextEvent, __BeginAppModalState,
__BeginEventReceiptOnThread, __BlockUntilNextEventMatchingListInModeWithFilter,
__CancelMenuTracking, __CheckForMenuCancelEvent, __CloseMenu,
__ContextualMenuInsertItems, __ConvertMatchingCGEvents, __CopyCGEventAssociatedData,
__CopyMenuItemDataU, __CopyMenuItemTextAsCFStringU, __CountMenuItemsU,
__CreateFlattenedInputSource, __CreateInputModeArrayForInputMethodInUIOrder,
__CreateInputModeArrayForInputMethodInUIOrderWithOptions,
__CreatePrivateDialogRefAndBindToWindowRef, __CreateUnflattenedInputSource,
__DeclineBackgroundMouseMovedEvents, __EndAppModalState, __EndEventReceiptOnThread,
__EventQueueSetEventLimit, __FlattenMenuItems2, __GetActiveSystemUIMode,
__GetActiveSystemUIModeAndOptions, __GetAggregateUIMode, __GetAllEventsOfClass,
__GetCurrentMenuContext, __GetDefaultMenuFont, __GetMenuItemBoundsU,
__GetMenuItemHierarchicalMenuU, __GetMenuMinimumWidth, __GetMenuTitleBounds,
__GetOpenMenuDirection, __GetSymbolicHotKeyValue, __GetSymbolicHotKeyValue2,
__GetWindowCGContext, __GetWindowCGOrderingEnabled, __GetWindowReshapingEnabled,
__GetWindowZOrderingEnabled, __HIBevelButtonRegisterClass,
__HIChasingArrowsRegisterClass, __HICheckBoxRegisterClass,
__HIDisableSuddenTerminationForSendEvent, __HIDisclosureButtonRegisterClass,
__HIDisclosureTriangleRegisterClass, __HIEnableAutomaticTerminationIfRequestedByPlist,
__HIEnableSuddenTerminationForSendEvent, __HIEnableSuddenTerminationIfRequestedByPlist,
__HIFullScreenAnimationFinished, __HIFullScreenAnimationPrepare,
__HIIconViewRegisterClass, __HIIsSuddenTerminationDisabledForSendEvent,
__HIMagnifiedMode, __HIMenuBarGetAppearance, __HIMenuBarGetReveal,
__HIMenuBarGetTransitionDuration, __HIMenuBarPositionLock,
__HIMenuBarPositionUnlock, __HIMenuBarRequestVisibility, __HIMenuBarSetAppearanceOverride,
__HIMenuBarSetAutoHideHeight, __HIMenuBarSetAutoShowDelay,
__HIMenuBarSetTransitionDuration, __HIMenuBarShowAsPopupFromKeyboard,
__HIMenuCopyItemViewClass, __HIMenuCreateConfiguredMarkImage,
__HIMenuDisableAutoDismissal, __HIMenuEnableAutoDismissal,
__HIMenuGetBackgroundBleed, __HIMenuGetCommandKey, __HIMenuGetContentDirectionality,
__HIMenuGetContentSize, __HIMenuGetEffectiveDirectionality,
__HIMenuGetItemView, __HIMenuGetMenuBarHeight, __HIMenuGetMenuBarHeightWithOptions,
__HIMenuGetNewItemsCount, __HIMenuIsCarbonMenuKeyEvent, __HIMenuIsDark,
__HIMenuPerformKeyboardNavigation, __HIMenuSendItemSelectedEvent,
__HIMenuSetCommandKey, __HIMenuSetContentDirectionality, __HIMenuSetContentSize,
__HIMenuSetEventProc, __HIMenuSetIndentWidth, __HIMenuSetItemIndent,
__HIMenuSetItemViewClass, __HIMenuSetNSImageInterface, __HIMenuSetNewItemsCount,
__HIMenuUseBackdrops, __HIMenuViewRegisterClass, __HIPopupButtonRegisterClass,
__HIPresentationInstanceCreateForFullScreenSpace, __HIPresentationInstanceCreateWithFullScreenMode,
__HIPresentationInstanceDisplayDidChange, __HIPresentationInstanceRelease,
__HIPresentationInstanceSetAutoHideHeight, __HIPresentationInstanceSetSpace,
__HIPresentationInstanceSetUIMode, __HIPresentationInstanceStartMenuBarAnimation,
__HIProgressBarRegisterClass, __HIPushButtonRegisterClass,
__HIRadioGroupRegisterClass, __HIRawObjectRegisterClass, __HIRegisterAEWillInteractProc,
__HIRoundButtonRegisterClass, __HIScrollViewRegisterClass,
__HISegmentViewRegisterClass, __HISegmentViewSetIsInset, __HIShrinkToFitEditRegisterClass,
__HISliderRegisterClass, __HIStandardMenuViewRegisterClass,
__HIStaticTextViewRegisterClass, __HIStdAppHandlerRegisterClass,
__HIStdEventLoopRegisterClass, __HITextFieldRegisterClass,
__HITextViewRegisterClass, __HIThemeCreateImage, __HIThemeDrawAppleMenuTitle,
__HIThemeDrawSegment, __HIThemeDrawSelectionMarquee, __HIThemeDrawWell,
__HIThemeGetChasingArrowDimensions, __HIThemeGetLegacyModeEnabled,
__HIThemeGetMenuBarLogoRect, __HIThemeGetMenuCalloutDimensions,
__HIThemeGetWindowGrowSides, __HIThemeGetWindowTitleBaselineOffset,
__HIThemeRefreshPreferences, __HIThemeSetColor, __HIThemeSetDrawingCallback,
__HIThemeSetTextColor, __HIToolbarItemRegisterClass, __HIToolbarViewRegisterClass,
__HIViewAdvanceFocusFollowingView, __HIViewCopyVisibleShape,
__HIViewNotifySetFocusPart, __HIViewRegisterClass, __HIViewScrollRectWithOptions,
__HIWindowFrameViewRegisterClass, __HIWindowSetAutoReleaseFocus,
__HIWindowSetNeedsQDPrepWhenDrawingViews, __HLTBAddEventSourceToMode,
__HLTBRemoveEventSourceFromMode, __HandleHelpSymbolicHotKey,
__HandleMenuSelection, __HandlePopUpMenuSelection7, __HandlePopUpMenuSelectionWithDictionary,
__HiliteMenuTitle, __InstallEventLoopObserver, __InvalidateAllEnabledInputSourceState,
__InvalidateAllInputSourceState, __InvalidateAllSelectedInputSourceState,
__IsFullTabbingEnabled, __IsMenuAlreadyPopulated, __IsMenuItemEnabledU,
__IsSymbolicHotKeyEvent, __LoadPerformanceMenu, __MenuIterCreate,
__MenuIterFirst, __MenuIterNext, __MenuIterRelease, __NotifyEventLoopObservers,
__OpenMenuWithOptions, __OpenSubmenuFromItem, __OpenSubmenuFromItemWithOptions,
__PostCGEventToQueue, __PushMouseCoalescingState, __QuitAppModalLoop,
__RegisterSharedDockClientWithRunLoop, __RemoveCGEventFromQueue,
__RemoveEventLoopObserver, __RemoveMouseCoalescingState, __RequestBackgroundMouseMovedEvents,
__RunAppModalLoop, __SetAppleMenuEnabled, __SetAppleMenuInstallerMode,
__SetBaroloFullScreenModeUIMode, __SetCGEventAssociatedData,
__SetCGEventConversionFilter, __SetDefaultMenuFont, __SetFullTabbingEnabled,
__SetJavaThreadHook, __SetMenuCallout, __SetMenuItemIconSize,
__SetMenuMinimumWidth, __SetMenuTrackingShouldReraiseNSExceptions,
__SetMenuWindowLevel, __SetOpenMenuOrigin, __SetWindowCGOrderingEnabled,
__SetWindowReshapingEnabled, __SetWindowZOrderingEnabled,
__SimulateMenuClosed, __SimulateMenuOpening, __SimulateMenuSelection,
__SimulateMenuSelectionU, __StartSystemUIModeMenuBarAnimation,
__SyncWindowWithCGAfterMove, __TISCopyParentInputMethodForInputSource,
__TISCreateEnabledInputSourcePrefs, __TISGetPhysicalKeyboardLanguage,
__TISRestrictToReadOnlyMachinePrefs, __TISUpdateEnabledInputSourcePrefs,
__TSMCopySelectableInputSourcesInUIOrder, __TSMInvalidateDocumentClient,
__TSMIsRemoteViewAccessoryView, __TSMIsRemoteViewKeyEquivalentHandling,
__TSMParentInputMethodInputSourceForInputModeCreate, __TSMRegisterRemoteViewClient,
__TSMRemoteViewActivationIsOn, __TSMSetRemoteViewActivation,
__TSMSetRemoteViewIsAccessoryView, __TSMSetRemoteViewKeyEquivalentHandling,
__TSMWouldEventBeProcessedByPressAndHold, ___CDCreateScreenFramesDictionaryRepresentation,
___CoreDragAnimateOrderOut, ___CoreDragAutoScaleSourceDragComponents,
___CoreDragBeginDropAnimationTransaction, ___CoreDragBeginFlockingAnimation,
___CoreDragBeginSlideBackAnimation, ___CoreDragBeginUnflockingAnimation,
___CoreDragCancelDropAnimationTransaction, ___CoreDragCancelOutstandingFlockingAnimation,
___CoreDragClearAllImageOverrides, ___CoreDragCommitDropAnimationTransaction,
___CoreDragCreateCFStringFromCGEvent, ___CoreDragCreateDictionaryRepOfLayerTree,
___CoreDragCreateImageData, ___CoreDragCreateImageDataFromCFDictionary,
___CoreDragCreateImageDataWithComponentsBlock, ___CoreDragCreateImageDataWithImage,
___CoreDragGetValueForKey, ___CoreDragHasImageOverrides, ___CoreDragImageDataCreateDictionaryRepresentation,
___CoreDragImageDataDeleteSlotForCAContext, ___CoreDragImageDataGetComponentsBlock,
___CoreDragImageDataGetItemRef, ___CoreDragImageDataSet, ___CoreDragItemGetImageComponents,
___CoreDragItemGetImageData, ___CoreDragItemGetScreenFrame,
___CoreDragItemHasAlternate, ___CoreDragItemSetImageComponents,
___CoreDragReleaseImageData, ___CoreDragResetAutoScaleSourceDragComponents,
___CoreDragSetDestClippingRect, ___CoreDragSetRootCALayer,
___CoreDragSetSourceClippingRect, ___CoreDragSetValueForKey,
___CoreDragSetupDragImageLayers, ___CoreDragUpdateClippingSuperLayer,
___CoreDragUpdateDragLayerContent, ___CoreDragUpdateFlockingFormation,
___CoreDragUpdateLayerPositions, ___DisposeLayerBackedSurfaceAndRender,
___DragInfoCopyFilterParams, ___DragInfoPtrClearAllImageOverrides,
___DragInfoPtrCreateDictionaryRepresentationForImageData,
___DragInfoPtrGetCAContext, ___DragInfoPtrGetComponentDataForItem,
___DragInfoPtrGetImageDataForItem, ___DragInfoPtrHasImageOverrides,
___DragInfoPtrImageDataCount, ___DragInfoPtrMergeRemoteOverrides,
___DragInfoPtrMergeSourceImagesForDestinationContext, ___DragInfoPtrSetDestClippingRect,
___DragInfoPtrSetValueForKey, ___DragInfoSetAlpha, ___InitLayerBackedDragWindow,
_kHIDelegateAfterKey, _kHIDelegateBeforeKey, _kHIObjectCustomDataClassIDKey,
_kHIObjectCustomDataDelegateGroupParametersKey, _kHIObjectCustomDataParameterNamesKey,
_kHIObjectCustomDataParameterTypesKey, _kHIObjectCustomDataParameterValuesKey,
_kHIObjectCustomDataSuperClassIDKey, _kHIObjectInitParamDescription,
_kHIObjectInitParamEventName, _kHIObjectInitParamEventType,
_kHIObjectInitParamUserName, _kHITextViewClassID, _kHIToolboxVersionNumber,
_kHIViewMenuContentID, _kHIViewWindowContentID, _kHIViewWindowGrowBoxID,
_kIMKRequestInputMethodsCheckinEndpoints, _kIMKXPCPrivateRunLoopMode,
_kTISAppleCharacterPaletteInputSourceID, _kTISAppleChineseHandwritingInputSourceID,
_kTISAppleEmojiDFRPaletteInputSourceID, _kTISAppleJapaneseKanaPaletteInputSourceID,
_kTISAppleKeyboardViewerPaletteInputSourceID, _kTISApplePressAndHoldInputSourceID,
_kTISAppleSyntheticRomanModeInputSourceID, _kTISCategoryInkInputSource,
_kTISCategoryKeyboardInputSource, _kTISCategoryPaletteInputSource,
_kTISIterationPropertyPreferredInputSourceLocalePart, _kTISNotifyEnabledKeyboardInputSourcesChanged,
_kTISNotifyEnabledNonKeyboardInputSourcesChanged, _kTISNotifyHandwritingInputSourceChanged,
_kTISNotifyInstalledInputSourcesChanged, _kTISNotifyIronwoodAutoEnableChanged,
_kTISNotifySelectedKeyboardInputSourceChanged, _kTISPlistKeyCapsLockIsSwitch,
_kTISPlistKeyCapsLockIsSwitchToIMRomanMode, _kTISPlistKeyDoubleSpaceSubstitution,
_kTISPlistKeyHandwritingLanguages, _kTISPlistKeyIconLabels,
_kTISPlistKeyIconShouldBeTemplate, _kTISPlistKeyInputSourceID,
_kTISPlistKeyIntendedLanguage, _kTISPlistKeyParticipatesInTouchBar,
_kTISPropertyAlternateIconImage, _kTISPropertyBundleID, _kTISPropertyDataFileProperties,
_kTISPropertyDataFileWordList, _kTISPropertyHandwritingLanguages,
_kTISPropertyHandwritingLocalizedNames, _kTISPropertyIconFamilyOrURL,
_kTISPropertyIconImage, _kTISPropertyIconImageURL, _kTISPropertyIconRef,
_kTISPropertyIconShouldBeTemplate, _kTISPropertyInputModeID,
_kTISPropertyInputSourceCategory, _kTISPropertyInputSourceDoesCapsLockSwitch,
_kTISPropertyInputSourceDoesCapsLockSwitchToRomanMode, _kTISPropertyInputSourceDoubleSpaceSubstitution,
_kTISPropertyInputSourceID, _kTISPropertyInputSourceIconLabels,
_kTISPropertyInputSourceIsASCIICapable, _kTISPropertyInputSourceIsEnableCapable,
_kTISPropertyInputSourceIsEnabled, _kTISPropertyInputSourceIsFromSystem,
_kTISPropertyInputSourceIsInvisible, _kTISPropertyInputSourceIsSelectCapable,
_kTISPropertyInputSourceIsSelected, _kTISPropertyInputSourceLanguages,
_kTISPropertyInputSourceLocalePartsForPreferred, _kTISPropertyInputSourceOverrideCapsLockDelay,
_kTISPropertyInputSourceParticipatesInTouchBar, _kTISPropertyInputSourceType,
_kTISPropertyIntendedLanguage, _kTISPropertyKeyLayoutName,
_kTISPropertyKeyLayoutNumber, _kTISPropertyLocale, _kTISPropertyLocalizedName,
_kTISPropertyRepertoireSetPattern, _kTISPropertyScriptCode,
_kTISPropertyUSBCountry, _kTISPropertyUnicodeKeyLayoutData,
_kTISTypeCharacterPalette, _kTISTypeInk, _kTISTypeKeyboardInputMethodModeEnabled,
_kTISTypeKeyboardInputMethodWithoutModes, _kTISTypeKeyboardInputMode,
_kTISTypeKeyboardLayout, _kTISTypeKeyboardSyntheticRomanMode,
_kTISTypeKeyboardViewer ]
reexports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _ShowHideProcess ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: EE5FA0C7-753F-3232-8D72-F9E834BF16C0
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 3C094BDD-B284-36F4-917D-F3DFB2CD4319
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Help.framework/Versions/A/Help'
current-version: 71
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ PrintingUI ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _AHGotoApplicationHelp, _AHGotoMainTOC, _AHGotoPage, _AHLookupAnchor,
_AHRegisterHelpBook, _AHRegisterHelpBookWithURL, _AHSearch,
_AppendEncodingHint, _CFStringToCString, _CopyBookDetails,
_CreateBookDetailsFromAppBundle, _CreateBookDetailsFromAppBundleAtIndex,
_CreateBookDetailsWithBookNameAndID, _EscapeMacCharacters,
_MacPathToURLPath, _kANCHOR, _kBOOKID, _kDEFAULT_BUNDLE_ID,
_kFILE, _kOPENBOOK, _kSEARCH, _kSEARCHALL, _kSTRING ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 4FFADD43-2EC1-3A67-8C43-5E7EB7D73554
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 963345BE-8865-34F5-9500-6752AF50A1B3
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/ImageCapture.framework/Versions/A/ImageCapture'
current-version: 5
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _ICACloseSession, _ICAConvertJPEGDataToICADataInPlace, _ICAConvertTIFFDataToICADataInPlace,
_ICACopyMatchingDeviceDictionaries, _ICACopyObjectData, _ICACopyObjectPropertyDictionary,
_ICACopyObjectThumbnail, _ICACopyParameterBlockPtrForAsyncCall,
_ICACreateCutsomIconForImageAtPath, _ICACreateJPEGThumbnailDataFromURL,
_ICADictionaryApplierFunction, _ICADoMacho2CFMConversion,
_ICADownloadFile, _ICADownloadFileWithOptions, _ICAElapsedTime,
_ICAGetBehaviorFlags, _ICAGetChildCount, _ICAGetDateFromSeconds,
_ICAGetDateFromSecondsSince1904, _ICAGetDateFromSecondsSince1970,
_ICAGetDeviceList, _ICAGetEXIFDateCStringFromSecondsSince1904,
_ICAGetEXIFDateCStringFromSecondsSince1970, _ICAGetEXIFUTCDateCStringFromSecondsSince1904,
_ICAGetEXIFUTCDateCStringFromSecondsSince1970, _ICAGetICAObjectForFile,
_ICAGetICAObjectFromDict, _ICAGetLongValueFromDict, _ICAGetNthChild,
_ICAGetNthProperty, _ICAGetObjectInfo, _ICAGetObjectRefCon,
_ICAGetParentOfObject, _ICAGetParentOfProperty, _ICAGetPropertyByType,
_ICAGetPropertyCount, _ICAGetPropertyData, _ICAGetPropertyInfo,
_ICAGetPropertyRefCon, _ICAGetRootOfObject, _ICAGetRootOfProperty,
_ICAGetSInt16ValueFromDict, _ICAGetSInt32ValueFromDict, _ICAGetSInt64ValueFromDict,
_ICAGetUTCDateFromDateCString, _ICAGetUTCDateFromSeconds,
_ICAGetUTCDateFromSecondsSince1904, _ICAImportImage, _ICALoadDeviceModule,
_ICAObjectSendMessage, _ICAOpenSession, _ICARegisterEventNotification,
_ICARegisterForEventNotification, _ICAScannerCloseSession,
_ICAScannerGetParameters, _ICAScannerInitialize, _ICAScannerOpenSession,
_ICAScannerSetParameters, _ICAScannerStart, _ICAScannerStatus,
_ICASetBehaviorFlags, _ICASetICAObjectInDict, _ICASetLongValueInDict,
_ICASetObjectRefCon, _ICASetPropertyData, _ICASetPropertyRefCon,
_ICASetSInt16ValueInDict, _ICASetSInt32ValueInDict, _ICASetSInt64ValueInDict,
_ICASetUTF8StringInDict, _ICASharedMemoryCreate, _ICASharedMemoryDestroy,
_ICASharedMemoryMap, _ICASharedMemoryUnmap, _ICAShowDeviceBrowser,
_ICAUnloadDeviceModule, _ICAUpdateDeviceDictionary, _ICAUploadFile,
_ICDBulkNewObject, _ICDBulkNewProperty, _ICDDeviceNotification,
_ICDDeviceRegister, _ICDDeviceUnRegister, _ICDDisposeObject,
_ICDDisposeProperty, _ICDNewObject, _ICDNewProperty, _kICAAddMetaDataToFinderCommentKey,
_kICAAdjustCreationDateKey, _kICAAudioCodecsKey, _kICABIPVersionKey,
_kICABluetoothAddressKey, _kICABluetoothTransportType, _kICABonjourServiceNameKey,
_kICABonjourServiceTypeKey, _kICABonjourTXTRecordKey, _kICACreateCustomIconKey,
_kICACreationDateStringKey, _kICADataPropertyKey, _kICADataSizeKey,
_kICADataTypeKey, _kICADeleteAfterDownloadKey, _kICADeviceBrowserDeviceRefKey,
_kICADeviceCapabilitiesKey, _kICADeviceDatabaseKey, _kICADeviceIconPathKey,
_kICADeviceModulePathKey, _kICADeviceNameKey, _kICADevicePropArtist,
_kICADevicePropBatteryLevel, _kICADevicePropBurstInterval,
_kICADevicePropBurstNumber, _kICADevicePropCaptureDelay, _kICADevicePropCompressionSetting,
_kICADevicePropContrast, _kICADevicePropCopyrightInfo, _kICADevicePropDateTime,
_kICADevicePropDigitalZoom, _kICADevicePropEffectMode, _kICADevicePropExposureBiasCompensation,
_kICADevicePropExposureIndex, _kICADevicePropExposureMeteringMode,
_kICADevicePropExposureProgramMode, _kICADevicePropExposureTime,
_kICADevicePropFNumber, _kICADevicePropFlashMode, _kICADevicePropFocalLength,
_kICADevicePropFocusDistance, _kICADevicePropFocusMeteringMode,
_kICADevicePropFocusMode, _kICADevicePropFunctionalMode, _kICADevicePropImageSize,
_kICADevicePropRGBGain, _kICADevicePropSharpness, _kICADevicePropStillCaptureMode,
_kICADevicePropTimelapseInterval, _kICADevicePropTimelapseNumber,
_kICADevicePropUndefined, _kICADevicePropUploadURL, _kICADevicePropWhiteBalance,
_kICADeviceSharedKey, _kICADeviceTypeCamera, _kICADeviceTypeKey,
_kICADeviceTypeScanner, _kICADeviceUsedKey, _kICADeviceWebSharedKey,
_kICADevicesArrayKey, _kICADirPathKey, _kICADisplayNameKey,
_kICADontEmbedColorSyncProfileKey, _kICAErrorKey, _kICAExecutableArchitectureKey,
_kICAFileCreatorKey, _kICAFileTypeKey, _kICAFileUTTypeKey,
_kICAFireWireGUIDKey, _kICAFireWireTransportType, _kICAIOServicePathKey,
_kICAIPAddressKey, _kICAIPGUIDKey, _kICAIPNameKey, _kICAIPPortKey,
_kICAIconFilePathKey, _kICAInstancesKey, _kICAKeywordsKey,
_kICALockStatusKey, _kICAManualConnectDeviceRefKey, _kICAMediaDurationInSecondsKey,
_kICAMediaFormatsKey, _kICAMediaHeightKey, _kICAMediaMaxDurationKey,
_kICAMediaSizesKey, _kICAMediaWidthKey, _kICAModelNameKey,
_kICAModificationDateStringKey, _kICANotificationClassKey,
_kICANotificationClassPTPStandard, _kICANotificationClassPTPVendor,
_kICANotificationClassProprietary, _kICANotificationDataCookieKey,
_kICANotificationDataKey, _kICANotificationDataSizeKey, _kICANotificationDeviceICAObjectKey,
_kICANotificationDeviceListICAObjectKey, _kICANotificationICAObjectKey,
_kICANotificationImageBytesPerRowKey, _kICANotificationImageDataKey,
_kICANotificationImageDataSizeKey, _kICANotificationImageHeightKey,
_kICANotificationImageKey, _kICANotificationImageNumberOfRowsKey,
_kICANotificationImageStartRowKey, _kICANotificationImageWidthKey,
_kICANotificationNumerOfImagesRemainingKey, _kICANotificationPercentDownloadedKey,
_kICANotificationRawEventKey, _kICANotificationScannerButtonTypeKey,
_kICANotificationScannerDocumentNameKey, _kICANotificationSubTypeDocumentLoaded,
_kICANotificationSubTypeDocumentNotLoaded, _kICANotificationSubTypeKey,
_kICANotificationSubTypePerformOverviewScan, _kICANotificationSubTypeWarmUpDone,
_kICANotificationSubTypeWarmUpStarted, _kICANotificationTypeCaptureComplete,
_kICANotificationTypeDeviceAdded, _kICANotificationTypeDeviceConnectionProgress,
_kICANotificationTypeDeviceInfoChanged, _kICANotificationTypeDevicePropertyChanged,
_kICANotificationTypeDeviceRemoved, _kICANotificationTypeDeviceStatusError,
_kICANotificationTypeDeviceStatusInfo, _kICANotificationTypeDeviceWasReset,
_kICANotificationTypeDownloadProgressStatus, _kICANotificationTypeKey,
_kICANotificationTypeObjectAdded, _kICANotificationTypeObjectInfoChanged,
_kICANotificationTypeObjectRemoved, _kICANotificationTypeProprietary,
_kICANotificationTypeRequestObjectTransfer, _kICANotificationTypeScanProgressStatus,
_kICANotificationTypeScannerButtonPressed, _kICANotificationTypeScannerOverviewOverlayAvailable,
_kICANotificationTypeScannerPageDone, _kICANotificationTypeScannerScanDone,
_kICANotificationTypeScannerSessionClosed, _kICANotificationTypeStoreAdded,
_kICANotificationTypeStoreFull, _kICANotificationTypeStoreInfoChanged,
_kICANotificationTypeStoreRemoved, _kICANotificationTypeTransactionCanceled,
_kICANotificationTypeUnreportedStatus, _kICANotificationVendorErrorCodeKey,
_kICAOBEXVersionKey, _kICAObjectKey, _kICAObjectNameKey, _kICAOrientationKey,
_kICAOverwriteKey, _kICAPhysicalTransportsKey, _kICAPictureFolderKey,
_kICAProtocolKey, _kICARawKey, _kICARefconKey, _kICARemoteDeviceKey,
_kICASCSITransportType, _kICASaveAsFilenameKey, _kICASavedFilenameKey,
_kICAScreenHeightKey, _kICAScreenWidthKey, _kICASoundFolderKey,
_kICAStarRatingKey, _kICASupportedFeaturesKey, _kICASupportingSoftwaresKey,
_kICATCPIPTransportType, _kICATWAINDSPathKey, _kICATWAINTransportType,
_kICATelephoneNetworksKey, _kICAThumbnailPropertyKey, _kICAThumbnailSizeKey,
_kICATransportTypeKey, _kICAUSBLocationIDKey, _kICAUSBProductIDKey,
_kICAUSBTransportType, _kICAUSBVendorIDKey, _kICAUserAssignedDeviceNameKey,
_kICAVendorNameKey, _kICAVideoCodecsKey, _kICAVideoFolderKey,
_kICAWMCVersionKey, _kMetaDataDictionaryKey ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: B93B6A30-0B53-3834-87E8-AB39E50B7FCE
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 4FF5F789-FA55-3B93-816F-2F21BB55AA30
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Ink.framework/Versions/A/Ink'
current-version: 227
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _InkAddStrokeToCurrentPhrase, _InkIsPhraseInProgress, _InkSetApplicationRecognitionMode,
_InkSetApplicationWritingMode, _InkSetDrawingMode, _InkSetPhraseTerminationMode,
_InkStrokeGetPointCount, _InkStrokeGetPoints, _InkStrokeGetTypeID,
_InkTerminateCurrentPhrase, _InkTextAlternatesCount, _InkTextBounds,
_InkTextCopy, _InkTextCreateCFString, _InkTextCreateFromCFData,
_InkTextDraw, _InkTextFlatten, _InkTextGetStroke, _InkTextGetStrokeCount,
_InkTextGetTypeID, _InkTextKeyModifiers, _InkUserWritingMode ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 7094B0DD-B83F-325A-A2DA-0788DC2E02CC
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 63B3CFC6-6CE7-37BE-BFA7-D3871AAB1E5C
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/OpenScripting.framework/Versions/A/OpenScripting'
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _ASCopySourceAttributes, _ASGetSourceStyleNames, _ASGetSourceStyles,
_ASInit, _ASSetSourceAttributes, _ASSetSourceStyles, _OSAAddStorageType,
_OSAAppletShowStartupScreenKey, _OSAAppletStayOpenKey, _OSAAuthorizeEvent,
_OSAAvailableDialectCodeList, _OSAAvailableDialects, _OSACoerceFromDesc,
_OSACoerceToDesc, _OSACompile, _OSACompileExecute, _OSACopyDisplayString,
_OSACopyID, _OSACopyScript, _OSACopyScriptingDefinition, _OSACopyScriptingDefinitionFromFile,
_OSACopyScriptingDefinitionFromURL, _OSACopySourceString,
_OSACopyURLForLibraryInDomainURL, _OSACopyURLForLibraryInFolderURL,
_OSACopyURLForLibraryInScriptURL, _OSACopyURLForLibraryName,
_OSACreateFile, _OSADebuggerCreateSession, _OSADebuggerDisposeCallFrame,
_OSADebuggerDisposeSession, _OSADebuggerGetBreakpoint, _OSADebuggerGetCallFrameState,
_OSADebuggerGetCurrentCallFrame, _OSADebuggerGetDefaultBreakpoint,
_OSADebuggerGetPreviousCallFrame, _OSADebuggerGetSessionState,
_OSADebuggerGetStatementRanges, _OSADebuggerGetVariable, _OSADebuggerSessionStep,
_OSADebuggerSetBreakpoint, _OSADebuggerSetVariable, _OSADisplay,
_OSADispose, _OSADoEvent, _OSADoScript, _OSADoScriptFile,
_OSAExecute, _OSAExecuteEvent, _OSAFindEventHandler, _OSAGenericToRealID,
_OSAGetActiveProc, _OSAGetCreateProc, _OSAGetCreateProgressProc,
_OSAGetCurrentDialect, _OSAGetDefaultScriptingComponent, _OSAGetDialectInfo,
_OSAGetEventHandler, _OSAGetHandler, _OSAGetHandlerNames,
_OSAGetProperty, _OSAGetPropertyNames, _OSAGetReleaseProgressProc,
_OSAGetResumeDispatchProc, _OSAGetScriptDataFromURL, _OSAGetScriptInfo,
_OSAGetScriptingComponent, _OSAGetScriptingComponentFromStored,
_OSAGetSendProc, _OSAGetSource, _OSAGetStorageType, _OSAGetSysTerminology,
_OSAInstallEventHandler, _OSAInstallGestaltValues, _OSAInstallScriptingDescCoercions,
_OSAInstallScriptingEventHandlers, _OSAInstallStdDescCoercions,
_OSAInstallStdEventHandlers, _OSAInstallStdPtrCoercions, _OSAInstallUnitPtrCoercions,
_OSAIsEventAuthorizationRequested, _OSAIsEventAuthorized,
_OSAIsScriptableBundle, _OSAIsScriptableRef, _OSAIsScriptableURL,
_OSALoad, _OSALoadExecute, _OSALoadExecuteFile, _OSALoadFile,
_OSALoadScriptData, _OSALoadScriptDataFromFile, _OSAMakeContext,
_OSARealToGenericID, _OSARecordEvent, _OSARemoveEventHandler,
_OSARemoveStorageType, _OSARequestEventAuthorization, _OSAScriptError,
_OSAScriptingComponentName, _OSASetActiveProc, _OSASetCreateProc,
_OSASetCreateProgressProc, _OSASetCurrentDialect, _OSASetDefaultScriptingComponent,
_OSASetDefaultTarget, _OSASetHandler, _OSASetProperty, _OSASetReleaseProgressProc,
_OSASetResumeDispatchProc, _OSASetScriptInfo, _OSASetSendProc,
_OSAStartRecording, _OSAStopRecording, _OSAStore, _OSAStoreFile,
_OSAStoreScriptDataToFile, _OSAStoreScriptDataToNewFile, __HandleGDUT,
__OSACopyDisplayString, __OSACopyScriptingDefinitionFromFile,
__OSACopySourceString, __OSACreateURL, __OSADoScriptURL, __OSALoadExecuteURL,
__OSALoadURL, __OSAStoreScriptDataToURL, __OSAStoreURL ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 89117C65-4F2D-35B6-AAAF-72F864A8361A
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 8BBA4D72-F069-306E-90D5-EF6B6BE48F91
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Print.framework/Versions/A/Print'
current-version: 272
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 19278940-6BBC-303B-980C-1DB4331DF80F
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 7E410562-7A94-32CF-8FD3-735ABF3BCE07
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/SecurityHI.framework/Versions/A/SecurityHI'
current-version: 55008
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ AppleShareClient ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _DisposeURLNotifyUPP, _DisposeURLSystemEventUPP, _InvokeURLNotifyUPP,
_InvokeURLSystemEventUPP, _KCAddAppleSharePassword, _KCAddGenericPassword,
_KCAddInternetPassword, _KCAddInternetPasswordWithPath, _KCAddItem,
_KCChangeSettings, _KCCreateKeychain, _KCUnlock, _NewURLNotifyUPP,
_NewURLSystemEventUPP, _SecChooseIdentity, _SecChooseIdentityAsSheet,
_SecDisplayCertificate, _SecDisplayCertificateGroup, _SecEditTrust,
_SecEditTrustAsSheet, _kcaddapplesharepassword, _kcaddgenericpassword,
_kcaddinternetpassword, _kcaddinternetpasswordwithpath, _kccreatekeychain,
_kcunlock ]
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 1D7D200D-3537-3095-8F7F-BE03E40FC12C
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: BE259DCA-1DD4-30C8-BBD8-797D9D86272F
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/SpeechRecognition.framework/Versions/A/SpeechRecognition'
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ AppKit, LatentSemanticMapping ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _DisposeSRCallBackUPP, _InvokeSRCallBackUPP, _NewSRCallBackUPP,
_SFSAvatarCaptionVisible, _SFSCopyActiveRecognizer, _SFSCopyCurrentAvatarIdentifier,
_SFSCopyIndAvatarInfo, _SFSCopyIndRecognizerPluginBundleRef,
_SFSCopyNamedAvatarInfo, _SFSCopyProperty, _SFSCountAvatars,
_SFSCountRecognizerPlugins, _SFSCreateSpeechFeedbackService,
_SFSCreateSpeechFeedbackServiceFromRecognizerIdentifier, _SFSDeminimizeFeedbackWindow,
_SFSDeminimizeUtilityWindow, _SFSFeedbackWindowVisible, _SFSGetAvatarExpression,
_SFSGetTargetProcess, _SFSHideAvatarCaption, _SFSHideFeedbackWindow,
_SFSHideRecognizerArea, _SFSHideTextArea, _SFSHideUtilityWindow,
_SFSIsRecognizerAreaVisible, _SFSIsTextAreaVisible, _SFSMinimizeFeedbackWindow,
_SFSMinimizeUtilityWindow, _SFSReleaseSpeechFeedbackService,
_SFSRequestMicrophone, _SFSReturnMicrophone, _SFSSendMessageToRecognizerArea,
_SFSSetActiveRecognizer, _SFSSetAvatarCaption, _SFSSetAvatarExpression,
_SFSSetAvatarSpeakingState, _SFSSetIdentityBadge, _SFSSetMicrophoneMeterStatus,
_SFSSetProperty, _SFSSetRecognizerStartupAction, _SFSSetSpeakableCommandsData,
_SFSShowAvatarCaption, _SFSShowFeedbackWindow, _SFSShowRecognizerArea,
_SFSShowTextArea, _SFSShowUtilityWindow, _SFSSpeakAndDrawString,
_SFSSpeakAndDrawStringUsingVoice, _SFSSpecifyMicrophoneToMeter,
_SFSSpeechBusy, _SFSStopSpeech, _SFSSyncFeedbackWindowWithPrefs,
_SFSUseAvatar, _SFSUseAvatarBundle, _SFSUseRecognizerAreaBundle,
_SFSUtilityWindowVisible, _SRAddLanguageObject, _SRAddText,
_SRCancelRecognition, _SRChangeLanguageObject, _SRCloseRecognitionSystem,
_SRContinueRecognition, _SRCountItems, _SRDrawRecognizedText,
_SRDrawText, _SREmptyLanguageObject, _SRGetIndexedItem, _SRGetLanguageModel,
_SRGetProperty, _SRGetReference, _SRIdle, _SRNewLanguageModel,
_SRNewLanguageObjectFromDataFile, _SRNewLanguageObjectFromHandle,
_SRNewPath, _SRNewPhrase, _SRNewRecognizer, _SRNewWord, _SROpenRecognitionSystem,
_SRProcessBegin, _SRProcessEnd, _SRPutLanguageObjectIntoDataFile,
_SRPutLanguageObjectIntoHandle, _SRReleaseObject, _SRRemoveIndexedItem,
_SRRemoveLanguageObject, _SRSetIndexedItem, _SRSetLanguageModel,
_SRSetProperty, _SRSpeakAndDrawText, _SRSpeakText, _SRSpeechBusy,
_SRStartListening, _SRStopListening, _SRStopSpeech ]
...

View File

@@ -0,0 +1,45 @@
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 77D1909A-B552-3B89-BAA3-4968DBE58A3E
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 83145A1E-897C-34E0-8378-6F14F11E851E
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/CommonPanels.framework/Versions/A/CommonPanels'
current-version: 101
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ AppKit ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _CCP_FontPanelClose, _CCP_FontPanelGetSelection, _CCP_FontPanelIsVisible,
_CCP_FontPanelOpen, _CCP_FontPanelSelectFonts, _CCP_NPickColor,
_CMCalibrateDisplay, _Call_CommonCocoaPanels_NPickColor, _CommonPanelsVersionNumber,
_CommonPanelsVersionString, _DisposeCalibrateEventUPP, _DisposeCalibrateUPP,
_DisposeCanCalibrateUPP, _DisposeNColorChangedUPP, _FCAddCollection,
_FCAddFontDescriptorToCollection, _FCCopyCollectionNames,
_FCCopyFontDescriptorsInCollection, _FCFontDescriptorCreateWithFontAttributes,
_FCFontDescriptorCreateWithName, _FCRemoveCollection, _FCRemoveFontDescriptorFromCollection,
_FPIsFontPanelVisible, _FPShowHideFontPanel, _GetColor, _GetHandleApplicationEventsUPP,
_GetHandleWinEventsUPP, _InvokeCalibrateEventUPP, _InvokeCalibrateUPP,
_InvokeCanCalibrateUPP, _InvokeNColorChangedUPP, _LoadNSTypographyBundle,
_NPickColor, _NewCalibrateEventUPP, _NewCalibrateUPP, _NewCanCalibrateUPP,
_NewNColorChangedUPP, _SetFontInfoForSelection, _SoftLinkingGetFunctionPointerFromBundleInDirectory,
_UserWantsColorPanelFromCommonCocoaPanels, __SoftLinkingLoadBundleFromLocation,
_gApplicationDeactivated, _gApplicationHandler, _gCallingApp,
_gCallingCCP, _gEventTarget, _gFontPanelInitialized, _gFontPanelRef,
_gHandler, _gNSTypographyBundle, _gSelFontInfo, _kFCFontCGColorAttribute,
_kFCFontFaceAttribute, _kFCFontFamilyAttribute, _kFCFontNameAttribute,
_kFCFontSizeAttribute, _kFCFontVisibleNameAttribute, _kFontPanelATSUFontIDKey,
_kFontPanelAttributeSizesKey, _kFontPanelAttributeTagsKey,
_kFontPanelAttributeValuesKey, _kFontPanelAttributesKey, _kFontPanelBackgroundColorAttributeName,
_kFontPanelDocumentAttributesKey, _kFontPanelFeatureSelectorsKey,
_kFontPanelFeatureTypesKey, _kFontPanelMouseTrackingState,
_kFontPanelVariationAxesKey, _kFontPanelVariationValuesKey ]
...

View File

@@ -0,0 +1,216 @@
/*
File: CommonPanels/CMCalibrator.h
Contains: ColorSync Calibration API
Version: CommonPanels-94~674
Copyright: <20> 1998-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __CMCALIBRATOR__
#define __CMCALIBRATOR__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __EVENTS__
#include <HIToolbox/Events.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
typedef CALLBACK_API( void , CalibrateEventProcPtr )(EventRecord * event);
typedef STACK_UPP_TYPE(CalibrateEventProcPtr) CalibrateEventUPP;
/* Interface for new ColorSync monitor calibrators (ColorSync 2.6 and greater) */
enum {
kCalibratorNamePrefix = 'cali'
};
struct CalibratorInfo {
UInt32 dataSize; /* Size of this structure - compatibility */
CMDisplayIDType displayID; /* Contains an hDC on Win32 */
UInt32 profileLocationSize; /* Max size for returned profile location */
CMProfileLocation * profileLocationPtr; /* For returning the profile */
CalibrateEventUPP eventProc; /* Ignored on Win32 */
Boolean isGood; /* true or false */
};
typedef struct CalibratorInfo CalibratorInfo;
typedef CALLBACK_API( Boolean , CanCalibrateProcPtr )(CMDisplayIDType displayID, Str255 errMessage);
typedef CALLBACK_API( OSErr , CalibrateProcPtr )(CalibratorInfo * theInfo);
typedef STACK_UPP_TYPE(CanCalibrateProcPtr) CanCalibrateUPP;
typedef STACK_UPP_TYPE(CalibrateProcPtr) CalibrateUPP;
/*
* NewCalibrateEventUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern CalibrateEventUPP
NewCalibrateEventUPP(CalibrateEventProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewCanCalibrateUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern CanCalibrateUPP
NewCanCalibrateUPP(CanCalibrateProcPtr userRoutine);
/*
* NewCalibrateUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern CalibrateUPP
NewCalibrateUPP(CalibrateProcPtr userRoutine);
/*
* DisposeCalibrateEventUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeCalibrateEventUPP(CalibrateEventUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeCanCalibrateUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeCanCalibrateUPP(CanCalibrateUPP userUPP);
/*
* DisposeCalibrateUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeCalibrateUPP(CalibrateUPP userUPP);
/*
* InvokeCalibrateEventUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeCalibrateEventUPP(
EventRecord * event,
CalibrateEventUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeCanCalibrateUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern Boolean
InvokeCanCalibrateUPP(
CMDisplayIDType displayID,
Str255 errMessage,
CanCalibrateUPP userUPP);
/*
* InvokeCalibrateUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern OSErr
InvokeCalibrateUPP(
CalibratorInfo * theInfo,
CalibrateUPP userUPP);
#if __MACH__
#ifdef __cplusplus
inline CalibrateEventUPP NewCalibrateEventUPP(CalibrateEventProcPtr userRoutine) { return userRoutine; }
inline CanCalibrateUPP NewCanCalibrateUPP(CanCalibrateProcPtr userRoutine) { return userRoutine; }
inline CalibrateUPP NewCalibrateUPP(CalibrateProcPtr userRoutine) { return userRoutine; }
inline void DisposeCalibrateEventUPP(CalibrateEventUPP) { }
inline void DisposeCanCalibrateUPP(CanCalibrateUPP) { }
inline void DisposeCalibrateUPP(CalibrateUPP) { }
inline void InvokeCalibrateEventUPP(EventRecord * event, CalibrateEventUPP userUPP) { (*userUPP)(event); }
inline Boolean InvokeCanCalibrateUPP(CMDisplayIDType displayID, Str255 errMessage, CanCalibrateUPP userUPP) { return (*userUPP)(displayID, errMessage); }
inline OSErr InvokeCalibrateUPP(CalibratorInfo * theInfo, CalibrateUPP userUPP) { return (*userUPP)(theInfo); }
#else
#define NewCalibrateEventUPP(userRoutine) ((CalibrateEventUPP)userRoutine)
#define NewCanCalibrateUPP(userRoutine) ((CanCalibrateUPP)userRoutine)
#define NewCalibrateUPP(userRoutine) ((CalibrateUPP)userRoutine)
#define DisposeCalibrateEventUPP(userUPP)
#define DisposeCanCalibrateUPP(userUPP)
#define DisposeCalibrateUPP(userUPP)
#define InvokeCalibrateEventUPP(event, userUPP) (*userUPP)(event)
#define InvokeCanCalibrateUPP(displayID, errMessage, userUPP) (*userUPP)(displayID, errMessage)
#define InvokeCalibrateUPP(theInfo, userUPP) (*userUPP)(theInfo)
#endif
#endif
/*
* CMCalibrateDisplay()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSErr
CMCalibrateDisplay(CalibratorInfo * theInfo) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __CMCALIBRATOR__ */

View File

@@ -0,0 +1,509 @@
/*
File: CommonPanels/ColorPicker.h
Contains: Color Picker package Interfaces.
Version: CommonPanels-94~674
Copyright: <20> 1987-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __COLORPICKER__
#define __COLORPICKER__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __EVENTS__
#include <HIToolbox/Events.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
#if !__LP64__
enum {
/*Maximum small fract value, as long*/
kMaximumSmallFract = 0x0000FFFF
};
#endif /* !__LP64__ */
/* These are legacy constants. The Color Picker on OS X uses the Cocoa NSColorPanel. */
enum {
kDefaultColorPickerWidth = 383,
kDefaultColorPickerHeight = 238
};
typedef SInt16 DialogPlacementSpec;
enum {
kAtSpecifiedOrigin = 0,
kDeepestColorScreen = 1,
kCenterOnMainScreen = 2
};
/* Since OS X uses the Cocoa NSColorPanel, the flags below are no longer used. */
enum {
kColorPickerDialogIsMoveable = 1,
kColorPickerDialogIsModal = 2,
kColorPickerCanModifyPalette = 4,
kColorPickerCanAnimatePalette = 8,
kColorPickerAppIsColorSyncAware = 16,
kColorPickerInSystemDialog = 32,
kColorPickerInApplicationDialog = 64,
kColorPickerInPickerDialog = 128,
kColorPickerDetachedFromChoices = 256,
kColorPickerCallColorProcLive = 512
};
#if OLDROUTINENAMES
#if !__LP64__
enum {
/*Maximum small fract value, as long*/
MaxSmallFract = 0x0000FFFF
};
#endif /* !__LP64__ */
enum {
kDefaultWidth = 383,
kDefaultHeight = 238
};
/* Since OS X uses the Cocoa NSColorPanel, the flags below are no longer used. */
enum {
DialogIsMoveable = 1,
DialogIsModal = 2,
CanModifyPalette = 4,
CanAnimatePalette = 8,
AppIsColorSyncAware = 16,
InSystemDialog = 32,
InApplicationDialog = 64,
InPickerDialog = 128,
DetachedFromChoices = 256,
CallColorProcLive = 512
};
#endif /* OLDROUTINENAMES */
#if !__LP64__
/* A SmallFract value is just the fractional part of a Fixed number,
which is the low order word. They can be
assigned directly to and from INTEGERs. */
/* Unsigned fraction between 0 and 1 */
typedef unsigned short SmallFract;
struct HSVColor {
SmallFract hue; /* Fraction of circle, red at 0 */
SmallFract saturation; /* 0-1, 0 for gray, 1 for pure color */
SmallFract value; /* 0-1, 0 for black, 1 for max intensity */
};
typedef struct HSVColor HSVColor;
struct HSLColor {
SmallFract hue; /* Fraction of circle, red at 0 */
SmallFract saturation; /* 0-1, 0 for gray, 1 for pure color */
SmallFract lightness; /* 0-1, 0 for black, 1 for white */
};
typedef struct HSLColor HSLColor;
struct CMYColor {
SmallFract cyan;
SmallFract magenta;
SmallFract yellow;
};
typedef struct CMYColor CMYColor;
struct PMColor {
CMProfileHandle profile;
CMColor color;
};
typedef struct PMColor PMColor;
typedef PMColor * PMColorPtr;
#endif /* !__LP64__ */
struct NPMColor {
CMProfileRef profile;
CMColor color;
};
typedef struct NPMColor NPMColor;
typedef NPMColor * NPMColorPtr;
typedef struct OpaquePicker* Picker;
typedef Picker picker;
/* Since OS X uses the Cocoa NSColorPanel, the struct below is no longer used. */
struct PickerMenuItemInfo {
SInt16 editMenuID;
SInt16 cutItem;
SInt16 copyItem;
SInt16 pasteItem;
SInt16 clearItem;
SInt16 undoItem;
};
typedef struct PickerMenuItemInfo PickerMenuItemInfo;
/* The following proc ptr is the only supported way to communicate with the Cocoa NSColorPanel on OS X. */
typedef CALLBACK_API( void , NColorChangedProcPtr )(SRefCon userData, NPMColor *newColor);
typedef STACK_UPP_TYPE(NColorChangedProcPtr) NColorChangedUPP;
/*
* NewNColorChangedUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern NColorChangedUPP
NewNColorChangedUPP(NColorChangedProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeNColorChangedUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeNColorChangedUPP(NColorChangedUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeNColorChangedUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeNColorChangedUPP(
SRefCon userData,
NPMColor * newColor,
NColorChangedUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if __MACH__
#ifdef __cplusplus
inline NColorChangedUPP NewNColorChangedUPP(NColorChangedProcPtr userRoutine) { return userRoutine; }
inline void DisposeNColorChangedUPP(NColorChangedUPP) { }
inline void InvokeNColorChangedUPP(SRefCon userData, NPMColor * newColor, NColorChangedUPP userUPP) { (*userUPP)(userData, newColor); }
#else
#define NewNColorChangedUPP(userRoutine) ((NColorChangedUPP)userRoutine)
#define DisposeNColorChangedUPP(userUPP)
#define InvokeNColorChangedUPP(userData, newColor, userUPP) (*userUPP)(userData, newColor)
#endif
#endif
#if __LP64__
typedef void * ColorChangedUPP;
typedef void * UserEventUPP;
#else
typedef CALLBACK_API( void , ColorChangedProcPtr )(SInt32 userData, PMColor *newColor);
typedef CALLBACK_API( Boolean , UserEventProcPtr )(EventRecord * event);
typedef STACK_UPP_TYPE(ColorChangedProcPtr) ColorChangedUPP;
typedef STACK_UPP_TYPE(UserEventProcPtr) UserEventUPP;
/*
* NewColorChangedUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ColorChangedUPP
NewColorChangedUPP(ColorChangedProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewUserEventUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern UserEventUPP
NewUserEventUPP(UserEventProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeColorChangedUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeColorChangedUPP(ColorChangedUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeUserEventUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeUserEventUPP(UserEventUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeColorChangedUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeColorChangedUPP(
SInt32 userData,
PMColor * newColor,
ColorChangedUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeUserEventUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern Boolean
InvokeUserEventUPP(
EventRecord * event,
UserEventUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if __MACH__
#ifdef __cplusplus
inline ColorChangedUPP NewColorChangedUPP(ColorChangedProcPtr userRoutine) { return userRoutine; }
inline UserEventUPP NewUserEventUPP(UserEventProcPtr userRoutine) { return userRoutine; }
inline void DisposeColorChangedUPP(ColorChangedUPP) { }
inline void DisposeUserEventUPP(UserEventUPP) { }
inline void InvokeColorChangedUPP(SInt32 userData, PMColor * newColor, ColorChangedUPP userUPP) { (*userUPP)(userData, newColor); }
inline Boolean InvokeUserEventUPP(EventRecord * event, UserEventUPP userUPP) { return (*userUPP)(event); }
#else
#define NewColorChangedUPP(userRoutine) ((ColorChangedUPP)userRoutine)
#define NewUserEventUPP(userRoutine) ((UserEventUPP)userRoutine)
#define DisposeColorChangedUPP(userUPP)
#define DisposeUserEventUPP(userUPP)
#define InvokeColorChangedUPP(userData, newColor, userUPP) (*userUPP)(userData, newColor)
#define InvokeUserEventUPP(event, userUPP) (*userUPP)(event)
#endif
#endif
#endif /* __LP64__ */
#if !__LP64__
struct ColorPickerInfo {
PMColor theColor;
CMProfileHandle dstProfile;
UInt32 flags;
DialogPlacementSpec placeWhere;
Point dialogOrigin;
OSType pickerType;
UserEventUPP eventProc;
ColorChangedUPP colorProc;
UInt32 colorProcData;
Str255 prompt;
PickerMenuItemInfo mInfo;
Boolean newColorChosen;
SInt8 filler;
};
typedef struct ColorPickerInfo ColorPickerInfo;
#endif /* !__LP64__ */
struct NColorPickerInfo {
NPMColor theColor;
CMProfileRef dstProfile; /* Currently ignored */
UInt32 flags; /* Currently ignored */
DialogPlacementSpec placeWhere; /* Currently ignored */
Point dialogOrigin; /* Currently ignored */
OSType pickerType; /* Currently ignored */
#if !__LP64__
UserEventUPP eventProc; /* Ignored */
#endif
NColorChangedUPP colorProc;
URefCon colorProcData;
Str255 prompt; /* Currently ignored */
PickerMenuItemInfo mInfo; /* Ignored */
Boolean newColorChosen;
UInt8 reserved; /* Must be 0 */
};
typedef struct NColorPickerInfo NColorPickerInfo;
#if !__LP64__
/*
* Fix2SmallFract()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern SmallFract
Fix2SmallFract(Fixed f) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SmallFract2Fix()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Fixed
SmallFract2Fix(SmallFract s) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* CMY2RGB()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
CMY2RGB(
const CMYColor * cColor,
RGBColor * rColor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* RGB2CMY()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
RGB2CMY(
const RGBColor * rColor,
CMYColor * cColor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* HSL2RGB()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
HSL2RGB(
const HSLColor * hColor,
RGBColor * rColor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* RGB2HSL()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
RGB2HSL(
const RGBColor * rColor,
HSLColor * hColor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* HSV2RGB()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
HSV2RGB(
const HSVColor * hColor,
RGBColor * rColor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* RGB2HSV()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
RGB2HSV(
const RGBColor * rColor,
HSVColor * hColor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* GetColor()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
GetColor(
Point where,
ConstStr255Param prompt,
const RGBColor * inColor,
RGBColor * outColor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if !__LP64__
/*
* PickColor()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in ColorPickerLib 2.0 and later
*/
extern OSErr
PickColor(ColorPickerInfo * theColorInfo) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* NPickColor()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in ColorPickerLib 2.1 and later
*/
extern OSErr
NPickColor(NColorPickerInfo * theColorInfo) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __COLORPICKER__ */

View File

@@ -0,0 +1,51 @@
/*
File: CommonPanels/CommonPanels.h
Contains: Master include for CommonPanels framework
Version: CommonPanels-94~674
Copyright: <20> 2000-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __COMMONPANELS__
#define __COMMONPANELS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __HITOOLBOX__
#include <HIToolbox/HIToolbox.h>
#endif
/*
Color Picker
*/
#ifndef __COLORPICKER__
#include <CommonPanels/ColorPicker.h>
#endif
#ifndef __CMCALIBRATOR__
#include <CommonPanels/CMCalibrator.h>
#endif
/*
Font Panel
*/
#ifndef __FONTPANEL__
#include <CommonPanels/FontPanel.h>
#endif
#endif /* __COMMONPANELS__ */

View File

@@ -0,0 +1,34 @@
/*
File: CommonPanels.r
Contains: Master include for CommonPanels framework
Version: CommonPanels-94~674
Copyright: <20> 2000-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __COMMONPANELS_R__
#define __COMMONPANELS_R__
#ifndef __APPLICATIONSERVICES_R__
#include <ApplicationServices/ApplicationServices.r>
#endif
#ifndef __HITOOLBOX_R__
#include <HIToolbox/HIToolbox.r>
#endif
#ifndef __FONTPANEL_R__
#include <CommonPanels/FontPanel.r>
#endif
#endif /* __COMMONPANELS_R__ */

View File

@@ -0,0 +1,728 @@
/*
File: CommonPanels/FontPanel.h
Contains: Carbon Font Panel package Interfaces.
Version: CommonPanels-94~674
Copyright: <20> 2002-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __FONTPANEL__
#define __FONTPANEL__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#ifndef __CARBON__
#include <Carbon/Carbon.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Font Panel-Related Events
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
* Discussion:
* Event classes
*/
enum {
/*
* Events related to font selection or handling.
*/
kEventClassFont = 'font'
};
/*
* Summary:
* Common command IDs
*/
enum {
/*
* The state of the Font Panel should be toggled, displaying it or
* hiding it as necessary. If the user closes the Font Panel directly
* from the window, the application will receive a
* kEventFontPanelClosed event.
*/
kHICommandShowHideFontPanel = 'shfp'
};
/* Font Events */
/*
* Summary:
* Font events (kEventClassFont)
*
* Discussion:
* When the user closes the Font Panel, a kEventWindowClosed event
* will be detected by the Carbon event handler installed by the
* system. The system then notifies the application that the Font
* Panel has closed by posting a Carbon Event Manager event. This
* allows the application to update any menu items or other controls
* whose state may have to change because the Font Panel has closed.
* kEventWindowClosed has no parameters. When the user selects an
* item in the Font Panel, the system will send a
* kEventFontSelection event to the event target specified when the
* application called SetFontInfoForSelection(). kEventFontSelection
* will contain parameters reflecting the current Font Panel
* selection in all supported formats. Font events are available
* after Mac OS X 10.2 in the Carbon framework.
*/
enum {
/*
* The Font Panel has been closed. The application should update its
* corresponding UI element (e.g., a menu item) accordingly.
*/
kEventFontPanelClosed = 1,
/*
* The user has specified font settings in the Font Panel. The
* application can obtain these settings from the event, in which
* they are stored as parameters. Not all parameters are guaranteed
* to be present; the application should check for all those which it
* recognizes and apply the ones found as appropriate to the target
* text.
*/
kEventFontSelection = 2
};
/*
Parameters for font events:
kEventFontPanelClosed
None.
kEventFontSelection
--> kEventParamATSUFontID typeATSUFontID
--> kEventParamATSUFontSize typeATSUSize
--> kEventParamFMFontFamily typeFMFontFamily
--> kEventParamFMFontSize typeFMFontSize
--> kEventParamFontColor typeFontColor
--> kEventParamDictionary typeCFDictionaryRef
--> kEventParamViewAttributesDictionary typeCFDictionaryRef
A dictionary containing attributes that can be applied to an entire text view. An example of this is the background color to
apply to the view.
*/
enum {
typeCTFontDescriptorRef = typeCFTypeRef, /* CTFontDescriptor reference.*/
typeATSUFontID = typeUInt32, /* ATSUI font ID.*/
typeATSUSize = typeFixed, /* ATSUI font size.*/
typeFMFontFamily = typeSInt16, /* Font family reference.*/
typeFMFontStyle = typeSInt16, /* Quickdraw font style*/
typeFMFontSize = typeSInt16, /* Integer font size.*/
typeFontColor = typeRGBColor, /* Font color spec (optional).*/
kEventParamCTFontDescriptor = 'ctfd', /* typeCTFontDescriptorRef*/
kEventParamATSUFontID = 'auid', /* typeATSUFontID*/
kEventParamATSUFontSize = 'ausz', /* typeATSUSize*/
kEventParamFMFontFamily = 'fmfm', /* typeFMFontFamily*/
kEventParamFMFontStyle = 'fmst', /* typeFMFontStyle*/
kEventParamFMFontSize = 'fmsz', /* typeFMFontSize*/
kEventParamFontColor = 'fclr', /* typeFontColor*/
kEventParamDictionary = 'dict', /* typeCFDictionaryRef*/
kEventParamViewAttributesDictionary = 'dadc' /* typeCFDictionaryRef*/
};
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Key constants to be used to access data inside the dictionary that may
be contained in the kEventFontSelection dictionary. (kEventParamDictionary)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
* kFontPanelATSUFontIDKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelATSUFontIDKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*Value is a CFNumber containing the ATSU Font ID*/
/*
* kFontPanelVariationAxesKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelVariationAxesKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/* Value is a CFDataRef containing one or more ATSUI Variation Axes*/
/*
* kFontPanelVariationValuesKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelVariationValuesKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*Value is a CFDataRef containing one or more ATSU Variation values*/
/*
* kFontPanelFeatureTypesKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelFeatureTypesKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/* Value is a CFDataRef containing one or more ATSUI feature types*/
/*
* kFontPanelFeatureSelectorsKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelFeatureSelectorsKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/* Value is a CFDataRef containing one or more ATSUI feature selectors*/
/*
* kFontPanelAttributesKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelAttributesKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
const <CFString> string kFontPanelAttributesKey = "FontAttributes";
Value is a CFDictionaryRef containing three keyed values. Each value is
a CFDataRef. One CFDataRef contains one or more ATSUAttributeTags.
One CFDataRef contains one or more value sizes for each tag. And the last
CFDataRef contains the actual values. It is important to understand that
these are the actual values and not value ptrs. To pass these values to
ATSUI they must be converted into ptrs. The following code fragment demonstrates
one technique
CFDataRef values;
CFDataRef tags;
CFDataRef sizes;
if ( CFDictionaryGetValueIfPresent( attributesDict, kFontPanelAttributeValuesKey, &values ) &&
CFDictionaryGetValueIfPresent( attributesDict, kFontPanelAttributeTagsKey, &tags )
CFDictionaryGetValueIfPresent( attributesDict, kFontPanelAttributeSizesKey, &sizes ))
{
ItemCount count = CFDataGetLength( tags )/sizeof(ATSUAttributeTag);
CFIndex index;
ATSUAttributeValuePtr valuePtrs = malloc( count * sizeof(ATSUAttributeValuePtr) );
UInt32* sizePtr = (UInt32*)CFDataGetBytePtr(sizes);
UInt32* bytePtr = (UInt32*)CFDataGetBytePtr(values);
for ( index = 0; index < count; index++ )
{
valuePtrs[index] = bytePtr;
bytePtr = (UInt32*)( (UInt8*)bytePtr + sizePtr[index]);
}
verify_noerr( ATSUSetAttributes( someATSUStyle, count, (ATSUAttributeTag*)CFDataGetBytePtr(tags),sizePtr, valuePtrs ) );
free( valuePtrs );
*/
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Keys to access the CFDataRefs inside the attributes dictionary (see above)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
* kFontPanelAttributeTagsKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelAttributeTagsKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*Value is a CFDataRef containing one or more style attribute tags*/
/*
* kFontPanelAttributeSizesKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelAttributeSizesKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*Value is a CFDataRef containing one or more style attribute sizes*/
/*
* kFontPanelAttributeValuesKey
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelAttributeValuesKey AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*Value is a CFDataRef containing one or more style values*/
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Keys to access to access the optional mouse tracking state if the font attribute/feature control is tracking
An application can look for this optional value to aid in supporting undo/redo for a font attribute/feature that is represented by
a control that tracks such as a slider.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
* kFontPanelMouseTrackingState
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelMouseTrackingState AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
The value referenced by this key is a CFNumberRef that will contain one of the following values
from CarbonEvents.h
kEventMouseDown
kEventMouseUp
kEventMouseDragged
*/
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Keys to access the data from the document attributes dictionary (kEventParamViewAttributesDictionary)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
* kFontPanelBackgroundColorAttributeName
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFontPanelBackgroundColorAttributeName AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Other Font Panel Constants
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
Error codes (Font Panel codes in range [-8880,-8899]).
*/
enum {
fontPanelShowErr = -8880, /* Can't display the Font Panel.*/
fontPanelSelectionStyleErr = -8881, /* Bad font selection style info.*/
fontPanelFontSelectionQDStyleVersionErr = -8882 /* Unsupported record version.*/
};
/*
Type of font information passed in SetFontInfoForSelection(). If the client is
sending ATSUI style data, it specifies kFontSelectionATSUIType; if it is
sending Quickdraw style data, it specifies kFontSelectionQDType.
*/
enum {
kFontSelectionATSUIType = 'astl', /* Use ATSUIStyle collection.*/
kFontSelectionQDType = 'qstl', /* Use FontSelectionQDStyle record.*/
kFontSelectionCoreTextType = 'ctfd' /* Use CTFontDescriptorRef.*/
};
/*
Supported versions of the FontSelectionQDStyle record. Clients should always set
the <version> field to one of these values.
*/
enum {
kFontSelectionQDStyleVersionZero = 0
};
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Font Panel Types
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
Record specifying the font information to be specified in the Font
Panel. This record is used if the client is sending Quickdraw style data
(i.e., it specified kFontSelectionQDType in SetFontInfoForSelection()).
*/
struct FontSelectionQDStyle {
UInt32 version; /* Version number of struct.*/
FMFontFamilyInstance instance; /* Font instance data.*/
FMFontSize size; /* Size of font in points.*/
Boolean hasColor; /* true if color info supplied.*/
UInt8 reserved; /* Filler byte.*/
RGBColor color; /* Color specification for font.*/
};
typedef struct FontSelectionQDStyle FontSelectionQDStyle;
typedef FontSelectionQDStyle * FontSelectionQDStylePtr;
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Font Panel Functions
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
* FPIsFontPanelVisible()
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x
* Non-Carbon CFM: not available
*/
extern Boolean
FPIsFontPanelVisible(void) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* FPShowHideFontPanel()
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x
* Non-Carbon CFM: not available
*/
extern OSStatus
FPShowHideFontPanel(void) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* SetFontInfoForSelection()
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x
* Non-Carbon CFM: not available
*/
extern OSStatus
SetFontInfoForSelection(
OSType iStyleType,
UInt32 iNumStyles,
void * iStyles,
EventTargetRef iFPEventTarget) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Font Collection Functions
In 10.3 the ability to create and modify font collections is available. Font
collections are files containing font descriptions. Font descriptions are
encapsulated in the opaque object FCFontDescriptorRef. A FCFontDescriptroRef
is a CFType. To release one call CFRelease.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Font Collection Types
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
typedef struct OpaqueFCFontDescriptorRef* FCFontDescriptorRef;
/*
* FCCopyCollectionNames()
*
* Discussion:
* FCCopyCollectionNames returns a copy of the CFArrayRef containing
* the displayable names of every font collection available to the
* current user.
*
* Result:
* A CFArrayRef containing CFStringRefs where each CFStringRef
* contains a font collection's displayable name. Callers are
* responsible for releasing the returned CFArrayRef. If the
* operation is not successful NULL is returned.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern CFArrayRef
FCCopyCollectionNames(void) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* FCCopyFontDescriptorsInCollection()
*
* Discussion:
* FCCopyFontDescriptorsInCollection copies the fontDescriptors in a
* named collection into an array.
*
* Parameters:
*
* iCollection:
* The name of a collection that descriptors should be copied from.
*
* Result:
* A CFArrayRef containing copies of the FCFontDescriptorRefs
* contained in the name collection. Callers are responsible for
* releasing the returned CFArrayRef. The FCFontDescriptorRefs are
* retained when added to the array and released when the array is
* destroyed. You can access a font descriptor in the array in the
* following manner: fd =
* (FCFontDescriptorRef)CFArrayGetValueAtIndex(array, i);
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern CFArrayRef
FCCopyFontDescriptorsInCollection(CFStringRef iCollection) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* FCAddCollection()
*
* Discussion:
* Add a collection to the font descriptor collections available to
* the current user. If the collection is successfully added noErr
* is returned. If the collection is not added an error code is
* returned.
*
* Parameters:
*
* iCollection:
* the name of the collection to add.
*
* iCollectionOptions:
* currently there are no options. Set to kNilOptions. This
* parameter is available for future expansion.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
FCAddCollection(
CFStringRef iCollection,
OptionBits iCollectionOptions) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* FCRemoveCollection()
*
* Discussion:
* Remove a named collection from the font descriptor collections
* available to the current user. Returns noErr if the collection
* was successfully removed. An appropriate error code is returned
* if the operation was not successful.
*
* Parameters:
*
* iCollection:
* the name of the collection to remove.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
FCRemoveCollection(CFStringRef iCollection) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* FCAddFontDescriptorToCollection()
*
* Discussion:
* Add a font descriptor to the named collection. noErr is returned
* if the font descriptor is added. An error code describing the
* failure is returned if the descriptor is not added.
*
* Parameters:
*
* iDescriptor:
* the font descriptor that should be added. The
* FCFontDescriptorRef is retained when it is added to the
* collection. After calling this function the caller may release
* their copy.
*
* iCollection:
* the name of the collection to which the font descriptor should
* be added.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
FCAddFontDescriptorToCollection(
FCFontDescriptorRef iDescriptor,
CFStringRef iCollection) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* FCRemoveFontDescriptorFromCollection()
*
* Discussion:
* Remove a font descriptor from the named collection. An error is
* returned if the font descriptor can not be removed. noErr is
* returned if the descriptor is removed.
*
* Parameters:
*
* iDescriptor:
* the descriptor that should be removed.
*
* iCollection:
* the name of the collection that the descriptor should be
* removed from.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
FCRemoveFontDescriptorFromCollection(
FCFontDescriptorRef iDescriptor,
CFStringRef iCollection) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Font Descriptor Attribute Keys
Font Descriptors contain font attributes that are set and accessed via a set of
keys. The keys are all constant CFStringRefs.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
/*
* kFCFontFamilyAttribute
*
* Discussion:
* The key for a CFStringRef that contains a font family name (e.g.
* Baskerville).
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFCFontFamilyAttribute AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* kFCFontNameAttribute
*
* Discussion:
* The key for a CFStringRef containing a font name (e.g.
* Baskerville-Italic).
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFCFontNameAttribute AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* kFCFontFaceAttribute
*
* Discussion:
* The key for a CFStringRef containing a face name (e.g. Italic).
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFCFontFaceAttribute AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* kFCFontSizeAttribute
*
* Discussion:
* The key for a CFNumber containg the font size (e.g. 12).
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFCFontSizeAttribute AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* kFCFontVisibleNameAttribute
*
* Discussion:
* The Key for a CFStringRef containing the name that should be used
* in a UI to describe the font.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFCFontVisibleNameAttribute AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* kFCFontCGColorAttribute
*
* Discussion:
* The Key for a CGColorRef containing the fonts color.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const CFStringRef kFCFontCGColorAttribute AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* FCFontDescriptorCreateWithFontAttributes()
*
* Discussion:
* Create a font descriptor using the attributes contained in the
* dictionary.
*
* Parameters:
*
* iAttributes:
* a dictionary containing one or more of the attributes described
* above.
*
* Result:
* A valid FCFontDescriptorRef. NULL if one cannot be created.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern FCFontDescriptorRef
FCFontDescriptorCreateWithFontAttributes(CFDictionaryRef iAttributes) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* FCFontDescriptorCreateWithName()
*
* Discussion:
* Create a font descriptor using a fontname and font size.
*
* Parameters:
*
* iFontName:
* The name of the font (e.g. Baskerville-Italic).
*
* iSize:
* the size of the font. (e.g. 12.0).
*
* Result:
* A valid FCFontDescriptorRef. NULL if one cannot be created.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern FCFontDescriptorRef
FCFontDescriptorCreateWithName(
CFStringRef iFontName,
CGFloat iSize) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __FONTPANEL__ */

View File

@@ -0,0 +1,27 @@
/*
File: FontPanel.r
Contains: Carbon Font Panel package Interfaces.
Version: CommonPanels-94~674
Copyright: <20> 2002-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __FONTPANEL_R__
#define __FONTPANEL_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kHICommandShowHideFontPanel 'shfp'
#endif /* __FONTPANEL_R__ */

View File

@@ -0,0 +1,476 @@
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 6320CF1B-CCD8-336D-ADB8-888AC1D8A1AA
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 7E5988A9-A641-398E-A67D-4B3ED39C3B51
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/HIToolbox'
current-version: 1111.3
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ AGL, AppKit, AppleShareClient, Backup, Dock, Finder, FinderKit,
ImageKit, Printing_UI, QTKit, QTKitServer, RemoteViewServices,
Shortcut, Suggestions, UIKitMacHelper, ViewBridge, loginwindow ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _AEGetInteractionAllowed, _AEGetTheCurrentEvent, _AEInteractWithUser,
_AEProcessAppleEvent, _AEProcessEvent, _AEResetTimer, _AEResumeTheCurrentEvent,
_AESend, _AESetInteractionAllowed, _AESetTheCurrentEvent,
_AESuspendTheCurrentEvent, _AXNotificationHIObjectNotify,
_AXNotificationHIObjectNotifyWithUserInfo, _AXUIElementCreateWithHIObjectAndIdentifier,
_AXUIElementGetHIObject, _AXUIElementGetIdentifier, _AcquireFirstMatchingEventInQueue,
_AcquireRootMenu, _ActivateControl, _ActivateTSMDocument,
_ActivateWindow, _ActiveNonFloatingWindow, _AddDataBrowserItems,
_AddEventTypesToHandler, _AppendDITL, _AppendMenuItemTextWithCFString,
_BeginAppModalStateForWindow, _BeginWindowProxyDrag, _BlockUntilNextEventMatchingListInMode,
_BringToFront, _Button, _CalcMenuSize, _CallNextEventHandler,
_CancelMenuTracking, _ChangeMenuAttributes, _ChangeMenuItemAttributes,
_ChangeWindowAttributes, _CheckEventQueueForUserCancel, _CheckMenuItem,
_ClearKeyboardFocus, _ClearMenuBar, _CollapseAllWindows, _CollapseWindow,
_ConfirmAppShowHideEvent, _ConstrainWindowToScreen, _ConvertEventRefToEventRecord,
_CopyControlTitleAsCFString, _CopyEvent, _CopyEventAs, _CopyEventCGEvent,
_CopyMenuItemData, _CopyMenuItemTextAsCFString, _CopyMenuItems,
_CopyMenuTitleAsCFString, _CopySymbolicHotKeys, _CopyThemeIdentifier,
_CopyWindowTitleAsCFString, _CountDITL, _CountMenuItems, _CreateCheckBoxControl,
_CreateEvent, _CreateEventWithCGEvent, _CreateIconControl,
_CreateLocaleIdentifierForItl0Itl1ResID, _CreateMenuFromNib,
_CreateNewMenu, _CreateNewWindow, _CreateNibReference, _CreateNibReferenceWithCFBundle,
_CreatePushButtonControl, _CreateRootControl, _CreateShrinkToFitEditControl,
_CreateStandardAlert, _CreateStandardSheet, _CreateStandardWindowMenu,
_CreateStaticTextControl, _CreateTypeStringWithOSType, _CreateWindowFromNib,
_CreateWindowGroup, _CreateWindowWithCGSWindow, _DeactivateControl,
_DeactivateTSMDocument, _DebugPrintAllWindowGroups, _DebugPrintControl,
_DebugPrintControlHierarchy, _DebugPrintDialogInfo, _DebugPrintEvent,
_DebugPrintEventQueue, _DebugPrintMainEventQueue, _DebugPrintMenu,
_DebugPrintMenuItem, _DebugPrintMenuList, _DebugPrintTracedEvents,
_DebugPrintWindow, _DebugPrintWindowGroup, _DebugPrintWindowList,
_DebugSetEventTraceEnabled, _DebugTraceEvent, _DebugTraceEventByName,
_DeleteMenu, _DeleteMenuItem, _DeleteMenuItems, _DeleteTSMDocument,
_DetachSheetWindow, _DialogSelect, _DisableControl, _DisableMenuCommand,
_DisableMenuItem, _DisableScreenUpdates, _DisableSecureEventInput,
_DisposeNibReference, _DisposeWindow, _DragWindow, _DrawMenuBar,
_EnableControl, _EnableMenuItem, _EnableScreenUpdates, _EnableSecureEventInput,
_EndAppModalStateForWindow, _EndWindowProxyDrag, _EventAvail,
_FindControlUnderMouse, _FindSpecificEventInQueue, _FindWindow,
_FixTSMDocument, _FlashMenuBar, _FlushEventQueue, _FlushEvents,
_FlushEventsMatchingListFromQueue, _FlushSpecificEventsFromQueue,
_FrontNonFloatingWindow, _FrontWindow, _GetApplicationEventTarget,
_GetApplicationScript, _GetApplicationTextEncoding, _GetBestControlRect,
_GetCFRunLoopFromEventLoop, _GetCarbonAccessibilityCallbacks,
_GetCaretTime, _GetControlBounds, _GetControlByID, _GetControlData,
_GetControlEventTarget, _GetControlFeatures, _GetControlHilite,
_GetControlKind, _GetControlOwner, _GetControlProperty, _GetControlValue,
_GetCurrentButtonState, _GetCurrentEvent, _GetCurrentEventButtonState,
_GetCurrentEventKeyModifiers, _GetCurrentEventLoop, _GetCurrentEventQueue,
_GetCurrentEventTime, _GetCurrentKeyModifiers, _GetDataBrowserItemCount,
_GetDataBrowserItemState, _GetDataBrowserItems, _GetDataBrowserPropertyFlags,
_GetDataBrowserSelectionAnchor, _GetDataBrowserSelectionFlags,
_GetDataBrowserTableViewColumnPosition, _GetDataBrowserTableViewColumnWidth,
_GetDataBrowserTableViewNamedColumnWidth, _GetDataBrowserTableViewRowHeight,
_GetDblTime, _GetDialogFromWindow, _GetDialogItem, _GetDialogItemAsControl,
_GetDialogWindow, _GetEventAttributes, _GetEventClass, _GetEventDispatcherTarget,
_GetEventKind, _GetEventMonitorTarget, _GetEventParameter,
_GetEventRetainCount, _GetEventTime, _GetFrontWindowOfClass,
_GetGrayRgn, _GetIndMenuItemWithCommandID, _GetIndexedSubControl,
_GetItemMark, _GetItlResourceIDsForLocale, _GetKeyboardFocus,
_GetKeys, _GetMBarHeight, _GetMainEventLoop, _GetMainEventQueue,
_GetMenuAttributes, _GetMenuDefinition, _GetMenuEventTarget,
_GetMenuHandle, _GetMenuHeight, _GetMenuID, _GetMenuItemAttributes,
_GetMenuItemBounds, _GetMenuItemCommandID, _GetMenuItemCommandKey,
_GetMenuItemHierarchicalMenu, _GetMenuItemModifiers, _GetMenuItemProperty,
_GetMenuItemRefCon, _GetMenuTitleIcon, _GetMenuTrackingData,
_GetMenuType, _GetMenuWidth, _GetNativeWindowFromWindowRef,
_GetNextMenu, _GetNextWindow, _GetNextWindowOfClass, _GetNumEventsInQueue,
_GetPreviousMenu, _GetPreviousWindow, _GetRootControl, _GetSheetWindowParent,
_GetStandardAlertDefaultParams, _GetSuperControl, _GetSymbolicHotKeyMode,
_GetSystemUIMode, _GetThemeBrushAsColor, _GetThemeMenuBarHeight,
_GetThemeMenuItemExtra, _GetThemeMenuSeparatorHeight, _GetThemeMenuTitleExtra,
_GetThemeMetric, _GetThemeTextColor, _GetThemeTextShadowOutset,
_GetUserFocusEventTarget, _GetUserFocusWindow, _GetWRefCon,
_GetWindowActivationScope, _GetWindowAttributes, _GetWindowBounds,
_GetWindowCancelButton, _GetWindowClass, _GetWindowDefaultButton,
_GetWindowEventTarget, _GetWindowFeatures, _GetWindowGroup,
_GetWindowGroupLevel, _GetWindowGroupOfClass, _GetWindowGroupParent,
_GetWindowIdealUserState, _GetWindowKind, _GetWindowList,
_GetWindowModality, _GetWindowPortBounds, _GetWindowProperty,
_GetWindowRefFromNativeWindow, _GetWindowStandardState, _GetWindowSystemProperty,
_HICopyAccessibilityActionDescription, _HICopyAccessibilityRoleDescription,
_HIDictionaryWindowShow, _HIGetMousePosition, _HIGetScaleFactor,
_HIGrowBoxViewIsTransparent, _HIGrowBoxViewSetTransparent,
_HIMenuCopyFont, _HIMenuCopyParents, _HIMenuGetContentView,
_HIMenuItemViewCancelMenuTracking, _HIMenuItemViewGetEnclosingMenuItem,
_HIMenuSetAttributedItemText, _HIMenuSetFont, _HIMenuSetSelection,
_HIMouseTrackingGetParameters, _HIObjectAddDelegate, _HIObjectCopyClassID,
_HIObjectCopyDelegates, _HIObjectCreate, _HIObjectCreateFromBundle,
_HIObjectDynamicCast, _HIObjectFromEventTarget, _HIObjectGetEventHandlerObject,
_HIObjectGetEventTarget, _HIObjectIsAccessibilityIgnored,
_HIObjectIsArchivingIgnored, _HIObjectIsOfClass, _HIObjectOverrideAccessibilityContainment,
_HIObjectPrintDebugInfo, _HIObjectRegisterSubclass, _HIObjectRemoveDelegate,
_HIObjectSetAccessibilityIgnored, _HIObjectSetAuxiliaryAccessibilityAttribute,
_HIObjectUnregisterClass, _HIPointConvert, _HIRectConvert,
_HIScrollViewCreate, _HIScrollViewGetAllowGrow, _HIScrollViewGetScrollBarAutoHide,
_HIScrollViewSetAllowGrow, _HIScrollViewSetScrollBarAutoHide,
_HISearchFieldChangeAttributes, _HISearchFieldCreate, _HISearchFieldGetAttributes,
_HISearchWindowShow, _HISegmentedViewChangeSegmentAttributes,
_HISegmentedViewGetSegmentBehavior, _HISegmentedViewGetSegmentCommand,
_HISegmentedViewGetSegmentCount, _HISegmentedViewIsSegmentEnabled,
_HISegmentedViewSetSegmentBehavior, _HISegmentedViewSetSegmentCommand,
_HISegmentedViewSetSegmentContentWidth, _HISegmentedViewSetSegmentCount,
_HISegmentedViewSetSegmentEnabled, _HISegmentedViewSetSegmentImage,
_HISizeConvert, _HITextViewCreate, _HITextViewGetTXNObject,
_HIThemeApplyBackground, _HIThemeBeginFocus, _HIThemeBrushCreateCGColor,
_HIThemeDrawBackground, _HIThemeDrawButton, _HIThemeDrawChasingArrows,
_HIThemeDrawFocusRect, _HIThemeDrawFrame, _HIThemeDrawGenericWell,
_HIThemeDrawGrabber, _HIThemeDrawGroupBox, _HIThemeDrawGrowBox,
_HIThemeDrawHeader, _HIThemeDrawMenuBackground, _HIThemeDrawMenuBarBackground,
_HIThemeDrawMenuItem, _HIThemeDrawMenuSeparator, _HIThemeDrawMenuTitle,
_HIThemeDrawPaneSplitter, _HIThemeDrawPlacard, _HIThemeDrawPopupArrow,
_HIThemeDrawScrollBarDelimiters, _HIThemeDrawSegment, _HIThemeDrawSeparator,
_HIThemeDrawTab, _HIThemeDrawTabPane, _HIThemeDrawTextBox,
_HIThemeDrawTickMark, _HIThemeDrawTitleBarWidget, _HIThemeDrawTrack,
_HIThemeDrawTrackTickMarks, _HIThemeDrawWindowFrame, _HIThemeEndFocus,
_HIThemeGetButtonBackgroundBounds, _HIThemeGetButtonContentBounds,
_HIThemeGetButtonShape, _HIThemeGetGrowBoxBounds, _HIThemeGetMenuBackgroundShape,
_HIThemeGetScrollBarTrackRect, _HIThemeGetTabDrawShape, _HIThemeGetTabPaneContentShape,
_HIThemeGetTabPaneDrawShape, _HIThemeGetTabShape, _HIThemeGetTextColorForThemeBrush,
_HIThemeGetTextDimensions, _HIThemeGetTrackBounds, _HIThemeGetTrackDragRect,
_HIThemeGetTrackLiveValue, _HIThemeGetTrackPartBounds, _HIThemeGetTrackParts,
_HIThemeGetTrackThumbPositionFromBounds, _HIThemeGetTrackThumbPositionFromOffset,
_HIThemeGetTrackThumbShape, _HIThemeGetUIFontType, _HIThemeGetWindowRegionHit,
_HIThemeGetWindowShape, _HIThemeHitTestScrollBarArrows, _HIThemeHitTestTrack,
_HIThemeSetFill, _HIThemeSetStroke, _HIThemeSetTextFill, _HIThemeSetTextStroke,
_HIToolbarAppendItem, _HIToolbarChangeAttributes, _HIToolbarCopyItems,
_HIToolbarCreate, _HIToolbarCreateItemWithIdentifier, _HIToolbarGetDisplayMode,
_HIToolbarGetDisplaySize, _HIToolbarItemChangeAttributes,
_HIToolbarItemChangeAttributesInWindow, _HIToolbarItemCopyIdentifier,
_HIToolbarItemCreate, _HIToolbarItemGetCommandID, _HIToolbarItemGetToolbar,
_HIToolbarItemSetCommandID, _HIToolbarItemSetHelpText, _HIToolbarItemSetIconRef,
_HIToolbarItemSetLabel, _HIToolbarItemSetMenu, _HIToolbarRemoveItemAtIndex,
_HIToolbarSetDelegate, _HIToolbarSetDisplayMode, _HIToolbarSetDisplaySize,
_HIViewAddSubview, _HIViewAdvanceFocus, _HIViewApplyLayout,
_HIViewChangeFeatures, _HIViewConvertPoint, _HIViewConvertRect,
_HIViewCopyText, _HIViewCountSubviews, _HIViewCreateOffscreenImage,
_HIViewDisposeTrackingArea, _HIViewDrawCGImage, _HIViewFindByID,
_HIViewFlashDirtyArea, _HIViewGetBounds, _HIViewGetCommandID,
_HIViewGetFeatures, _HIViewGetFirstSubview, _HIViewGetFocus,
_HIViewGetFocusPart, _HIViewGetFrame, _HIViewGetID, _HIViewGetIndexedSubview,
_HIViewGetKind, _HIViewGetLayoutInfo, _HIViewGetMaximum, _HIViewGetMinimum,
_HIViewGetNextView, _HIViewGetOptimalBounds, _HIViewGetRoot,
_HIViewGetSuperview, _HIViewGetThemeTextInfo, _HIViewGetTrackingAreaID,
_HIViewGetValue, _HIViewGetViewForMouseEvent, _HIViewGetViewSize,
_HIViewGetWindow, _HIViewIsActive, _HIViewIsCompositingEnabled,
_HIViewIsDrawingEnabled, _HIViewIsEnabled, _HIViewIsLatentlyVisible,
_HIViewIsLayoutActive, _HIViewIsLayoutLatentlyActive, _HIViewIsVisible,
_HIViewMoveBy, _HIViewNewTrackingArea, _HIViewRegionChanged,
_HIViewRemoveFromSuperview, _HIViewRender, _HIViewResumeLayout,
_HIViewScrollRect, _HIViewSetActivated, _HIViewSetBoundsOrigin,
_HIViewSetCommandID, _HIViewSetDrawingEnabled, _HIViewSetEnabled,
_HIViewSetFocus, _HIViewSetFrame, _HIViewSetHilite, _HIViewSetID,
_HIViewSetLayoutInfo, _HIViewSetMaximum, _HIViewSetMinimum,
_HIViewSetNeedsDisplay, _HIViewSetNeedsDisplayInRect, _HIViewSetNeedsDisplayInShape,
_HIViewSetSubviewsNeedDisplayInShape, _HIViewSetText, _HIViewSetTextFont,
_HIViewSetTextHorizontalFlush, _HIViewSetTextTruncation, _HIViewSetTextVerticalFlush,
_HIViewSetValue, _HIViewSetViewSize, _HIViewSetVisible, _HIViewSetZOrder,
_HIViewSimulateClick, _HIViewSubtreeContainsFocus, _HIViewSuspendLayout,
_HIWindowChangeAttributes, _HIWindowChangeClass, _HIWindowChangeFeatures,
_HIWindowCopyAvailablePositioningShape, _HIWindowFindAtLocation,
_HIWindowFlush, _HIWindowFromCGWindowID, _HIWindowGetAvailablePositioningBounds,
_HIWindowGetBounds, _HIWindowGetCGWindowID, _HIWindowGetGreatestAreaDisplay,
_HIWindowGetScaleMode, _HIWindowIsDocumentModalTarget, _HIWindowSetBottomBarHeight,
_HIWindowTestAttribute, _HMAreHelpTagsDisplayed, _HMGetTagDelay,
_HMInstallControlContentCallback, _HMSetControlHelpContent,
_HMSetHelpTagsDisplayed, _HMSetMenuItemHelpContent, _HMSetTagDelay,
_HandleControlSetCursor, _HideControl, _HideMenuBar, _HideSheetWindow,
_HideWindow, _HiliteControl, _HiliteMenu, _HiliteWindow, _IMKBaselineKey,
_IMKChromaticMarkedTextAttributeName, _IMKDictationHilightAttributeName,
_IMKDictationHilightHypothesisDeltaAttributeName, _IMKDictationInsertionUndoableAttributeName,
_IMKIronwoodTextAlternativeCorrectedKey, _IMKIronwoodTextAlternativeCorrectionIDKey,
_IMKIronwoodTextAlternativeOriginalKey, _IMKIronwoodTextAlternativesAttributeName,
_IMKIronwoodTextAlternativesKey, _IMKLineAscentKey, _IMKLineHeightKey,
_IMKTextOrientationName, _INIT_ScriptHL, _InitDataBrowserCallbacks,
_InitDataBrowserCustomCallbacks, _InsertMenu, _InsertMenuItemTextWithCFString,
_InstallEventHandler, _InstallEventLoopIdleTimer, _InstallEventLoopTimer,
_InstallEventLoopTimerInMode, _InstallInputSourceMgrHandlers,
_InstallStandardEventHandler, _IntlCountResources, _IntlGetIndexedResInfo,
_IntlGetScriptCustomResourceID, _IntlGetValue, _IntlResourceIDToScriptCode,
_IntlSetValue, _InvalMenuBar, _InvalidateMenuBarFilter, _InvalidateMenuItems,
_InvalidateMenuSize, _IsAutomaticControlDragTrackingEnabledForWindow,
_IsCmdChar, _IsControlActive, _IsControlDragTrackingEnabled,
_IsControlHilited, _IsControlVisible, _IsCurrentTSMDocumentUnicode,
_IsDataBrowserItemSelected, _IsEventInInstantMouser, _IsEventInQueue,
_IsMenuBarVisible, _IsMenuItemEnabled, _IsMenuKeyEvent, _IsMenuSizeInvalid,
_IsMouseCoalescingEnabled, _IsSecureEventInputEnabled, _IsShowContextualMenuEvent,
_IsUserCancelEventRef, _IsValidControlHandle, _IsValidMenu,
_IsValidWindowPtr, _IsWindowActive, _IsWindowCollapsed, _IsWindowHilited,
_IsWindowInStandardState, _IsWindowLatentVisible, _IsWindowPathSelectEvent,
_IsWindowToolbarVisible, _IsWindowVisible, _KBGetLayoutType,
_KLCreateKCAPDataForKbdType, _KeyEventMatchesMenuItem, _KeyTranslate,
_LMGetKbdLast, _LMGetKbdType, _LMGetKeyRepThresh, _LMGetKeyThresh,
_LMSetKbdLast, _LMSetKbdType, _LMSetKeyRepThresh, _LMSetKeyThresh,
_LaunchAppleCharacterPalette, _MenuEvent, _MenuSelect, _MoveControl,
_MoveWindow, _MoveWindowStructure, _NMInstall, _NMRemove,
_NewTSMDocument, _OpenThemeResFileMapped, _ParamText, _PopSymbolicHotKeyMode,
_PopUpMenuSelect, _PostEvent, _PostEventToQueue, _PostEventToQueueInternal,
_PostFakeMenuSelectionEvent, _ProcessHICommand, _ProcessInputSourceSwitchEventCandidate,
_ProcessInputSourceSwitchKeySequenceCandidate, _PushSymbolicHotKeyMode,
_QuitAppModalLoopForWindow, _QuitApplicationEventLoop, _QuitEventLoop,
_ReceiveNextEvent, _RegisterEventHotKey, _RegisterSystemToolboxListenerWithOptions,
_ReleaseEvent, _RemoveControlProperty, _RemoveDataBrowserItems,
_RemoveEventFromQueue, _RemoveEventHandler, _RemoveEventLoopTimer,
_RemoveEventParameter, _RemoveEventTypesFromHandler, _RemoveMenuItemProperty,
_RemoveWindowProperty, _RemoveWindowProxy, _RepositionWindow,
_RetainEvent, _RevealDataBrowserItem, _RunAppModalLoopForWindow,
_RunApplicationEventLoop, _RunCurrentEventLoop, _RunStandardAlert,
_SelectWindow, _SendBehind, _SendEventToEventTarget, _SendEventToEventTargetWithOptions,
_SendTextInputEvent, _SendWindowGroupBehind, _SetAnimatedThemeCursor,
_SetApplicationDockTileMenu, _SetAutomaticControlDragTrackingEnabledForWindow,
_SetBevelButtonContentInfo, _SetCocoaAccessibilityCallbacks,
_SetControlAction, _SetControlCommandID, _SetControlData,
_SetControlDragTrackingEnabled, _SetControlFontStyle, _SetControlID,
_SetControlProperty, _SetControlTitleWithCFString, _SetControlValue,
_SetControlVisibility, _SetDataBrowserCallbacks, _SetDataBrowserCustomCallbacks,
_SetDataBrowserItemDataIcon, _SetDataBrowserItemDataText,
_SetDataBrowserPropertyFlags, _SetDataBrowserSelectedItems,
_SetDataBrowserSelectionFlags, _SetDataBrowserSortProperty,
_SetDataBrowserTableViewColumnPosition, _SetDataBrowserTableViewColumnWidth,
_SetDataBrowserTableViewGeometry, _SetDataBrowserTableViewNamedColumnWidth,
_SetDialogItemRectangle, _SetDialogTimeout, _SetEventLoopTimerNextFireTime,
_SetEventParameter, _SetEventTime, _SetItemMark, _SetItemStyle,
_SetKeyboardFocus, _SetMenuBarFromNib, _SetMenuDefinition,
_SetMenuExcludesMarkColumn, _SetMenuItemCommandID, _SetMenuItemCommandKey,
_SetMenuItemHierarchicalMenu, _SetMenuItemIconHandle, _SetMenuItemIndent,
_SetMenuItemKeyGlyph, _SetMenuItemModifiers, _SetMenuItemProperty,
_SetMenuItemRefCon, _SetMenuItemTextWithCFString, _SetMenuTitleIcon,
_SetMenuTitleWithCFString, _SetModalDialogEventMask, _SetMouseCoalescingEnabled,
_SetNextMenu, _SetRootMenu, _SetSystemAppMenuSectionAllowed,
_SetSystemUIMode, _SetThemeCursor, _SetThemeWindowBackground,
_SetUserFocusWindow, _SetWindowActivationScope, _SetWindowAlternateTitle,
_SetWindowBounds, _SetWindowCancelButton, _SetWindowDefaultButton,
_SetWindowGroup, _SetWindowGroupLevel, _SetWindowIdealUserState,
_SetWindowModality, _SetWindowModified, _SetWindowProperty,
_SetWindowProxyAlias, _SetWindowProxyIcon, _SetWindowResizeLimits,
_SetWindowTitleWithCFString, _SetWindowToolbar, _ShowControl,
_ShowHide, _ShowHideWindowToolbar, _ShowMenuBar, _ShowSheetWindow,
_ShowWindow, _SizeControl, _SizeWindow, _StdFilterProc, _SyncWindowToCGSWindow,
_TISCapsLockSwitchShouldKeyboardLayoutUseAlternateForModifiers,
_TISCopyCurrentASCIICapableKeyboardInputSource, _TISCopyCurrentASCIICapableKeyboardLayoutInputSource,
_TISCopyCurrentKeyboardInputSource, _TISCopyCurrentKeyboardLayoutInputSource,
_TISCopyCurrentNonRomanInputSourceForRomanSwitch, _TISCopyInputMethodKeyboardLayoutOverride,
_TISCopyInputSourceForLanguage, _TISCopyInputSourceRefForInputSourceID,
_TISCopyInputSourcesForAttachedKeyboardsFilteredByLocale,
_TISCreateASCIICapableInputSourceList, _TISCreateCompressedInfoStringForInputSource,
_TISCreateDefaultASCIIInputSourceForLocale, _TISCreateInputSourceList,
_TISCreatePrunedPreferredInputSourcesWithABC, _TISCreateSecureKeyboardInputSourceList,
_TISDeselectInputSource, _TISDisableInputSource, _TISEnableInputSource,
_TISEnableInputSourceWithOptions, _TISGetAppleKeyLayoutCount,
_TISGetAppleKeyLayoutIndexForKeyLayoutName, _TISGetAppleKeyLayoutIndexForNumericID,
_TISGetAppleKeyLayoutKLPropertyAtIndex, _TISGetDictationShouldAutoEnable,
_TISGetFnUsageType, _TISGetGestureHandwritingState, _TISGetInputSourceProperty,
_TISHardwareSupportsGestureHandwriting, _TISInputMethodDataFileReaderCreateBasicProperties,
_TISInputMethodDataFileReaderCreatePropertyListAndWordList,
_TISInputSourceGetTypeID, _TISIsKeyboardLayoutCapsLockSwitchAllowed,
_TISIsKeyboardLayoutCapsLockSwitched, _TISIsRomanSwitchAllowed,
_TISIsRomanSwitchEnabled, _TISKeyboardLayoutInputSourceIsQWERTY,
_TISLaunchCharacterPalette, _TISPerformInputMethodDependentBlockDuringWorkBlock,
_TISPrefsCopyCurrentKeyboardLayoutID, _TISPrefsUserSnapshotCopyForMachinePrefs,
_TISRegisterInputSource, _TISSelectInputSource, _TISSetDefaultAsciiCapableKeyboardLayoutInputSource,
_TISSetDictationShouldAutoEnable, _TISSetExtensionsForIntlFileCacheUpdate,
_TISSetGestureHandwritingState, _TISSetInputMethodKeyboardLayoutOverride,
_TISSetRomanSwitchState, _TISUpdateFnUsageType, _TISUpdateIntlFileCache,
_TISUpdaterEnsureKotoeriHiraganaModeForSUMavericks, _TISUpdaterMigrateDictationAutoEnableFromSpeechRecognition,
_TISUpdaterMigrateKotoeriToJapaneseIM, _TISUpdaterMigratePrefsFromByHostDomain,
_TISWriteKeyLayoutCollection, _TSMCanChangeInputSourceEnabledState,
_TSMCopyTextInputGlobalProperty, _TSMCreateInputSourceForKeyboardLayoutRef,
_TSMCreateInputSourceRefForIndex, _TSMCurrentKeyboardInputSourceRefCreate,
_TSMDefaultAsciiCapableKeyboardLayoutCopy, _TSMDeselectInputSource,
_TSMDisableInputSource, _TSMEnableInputSource, _TSMGetActiveDocument,
_TSMGetDeadKeyState, _TSMGetDocumentProperty, _TSMGetInputSourceCount,
_TSMGetInputSourceProperty, _TSMGetIronwoodSessionState, _TSMInvalidateClientGeometry,
_TSMIsInkWithMouseEnabled, _TSMIsInputSourceAsciiCapable,
_TSMIsPressAndHoldActive, _TSMKeyTranslateWithInputSource,
_TSMProcessIronwoodSessionAction, _TSMProcessMouseEvent, _TSMProcessMouseEventWithCompletionHandler,
_TSMProcessRawKeyCode, _TSMProcessRawKeyEvent, _TSMProcessRawKeyEventWithCompletionHandler,
_TSMProcessRawKeyEventWithOptionsAndCompletionHandler, _TSMProcessTabletEvent,
_TSMRecentInputSourcesCreate, _TSMRemoveDocumentProperty,
_TSMSelectInputSource, _TSMSetCurrentAsciiCapableInputSource,
_TSMSetDeadKeyState, _TSMSetDocumentProperty, _TSMSetInkWithMouseEnabled,
_TSMSetInputMethodProperty, _TSMSetTextInputGlobalProperty,
_TSMShouldTextInputMenuBeDisplayed, _TSMUnrestrictInputSourceAccess,
_TSMUpgradePrefBundleIDsToLeopard, _TSMUpgradeScriptMgrPrefsToInputSourcePrefs,
_TXNAdjustCursor, _TXNClear, _TXNCopy, _TXNDataSize, _TXNGetData,
_TXNGetHIRect, _TXNGetIndexedRunInfoFromRange, _TXNGetSelection,
_TXNIsScrapPastable, _TXNPaste, _TXNSelectAll, _TXNSetData,
_TXNSetDataFromCFURLRef, _TXNSetHIRectBounds, _TXNSetSelection,
_TXNSetTXNObjectControls, _TXNShowSelection, _TestWindowLiveResizePerformance,
_TrackWindowProxyFromExistingDrag, _TransitionWindow, _TransitionWindowWithOptions,
_TruncateThemeText, _UnregisterEventHotKey, _UseInputWindow,
_WaitNextEvent, _WindowPathSelect, __AcquireMatchingCGEvent,
__AcquireMatchingCGEventInQueue, __AcquireNextEvent, __BeginAppModalState,
__BeginEventReceiptOnThread, __BlockUntilNextEventMatchingListInModeWithFilter,
__CancelMenuTracking, __CheckForMenuCancelEvent, __CloseMenu,
__ContextualMenuInsertItems, __ConvertMatchingCGEvents, __CopyCGEventAssociatedData,
__CopyMenuItemDataU, __CopyMenuItemTextAsCFStringU, __CountMenuItemsU,
__CreateFlattenedInputSource, __CreateInputModeArrayForInputMethodInUIOrder,
__CreateInputModeArrayForInputMethodInUIOrderWithOptions,
__CreatePrivateDialogRefAndBindToWindowRef, __CreateUnflattenedInputSource,
__DeclineBackgroundMouseMovedEvents, __EndAppModalState, __EndEventReceiptOnThread,
__EventQueueSetEventLimit, __FlattenMenuItems2, __GetActiveSystemUIMode,
__GetActiveSystemUIModeAndOptions, __GetAggregateUIMode, __GetAllEventsOfClass,
__GetCurrentMenuContext, __GetDefaultMenuFont, __GetMenuItemBoundsU,
__GetMenuItemHierarchicalMenuU, __GetMenuMinimumWidth, __GetMenuTitleBounds,
__GetOpenMenuDirection, __GetSymbolicHotKeyValue, __GetSymbolicHotKeyValue2,
__GetWindowCGContext, __GetWindowCGOrderingEnabled, __GetWindowReshapingEnabled,
__GetWindowZOrderingEnabled, __HIBevelButtonRegisterClass,
__HIChasingArrowsRegisterClass, __HICheckBoxRegisterClass,
__HIDisableSuddenTerminationForSendEvent, __HIDisclosureButtonRegisterClass,
__HIDisclosureTriangleRegisterClass, __HIEnableAutomaticTerminationIfRequestedByPlist,
__HIEnableSuddenTerminationForSendEvent, __HIEnableSuddenTerminationIfRequestedByPlist,
__HIFullScreenAnimationFinished, __HIFullScreenAnimationPrepare,
__HIIconViewRegisterClass, __HIIsSuddenTerminationDisabledForSendEvent,
__HIMagnifiedMode, __HIMenuBarGetAppearance, __HIMenuBarGetReveal,
__HIMenuBarGetTransitionDuration, __HIMenuBarPositionLock,
__HIMenuBarPositionUnlock, __HIMenuBarRequestVisibility, __HIMenuBarSetAppearanceOverride,
__HIMenuBarSetAutoHideHeight, __HIMenuBarSetAutoShowDelay,
__HIMenuBarSetTransitionDuration, __HIMenuBarShowAsPopupFromKeyboard,
__HIMenuCopyItemViewClass, __HIMenuCreateConfiguredMarkImage,
__HIMenuDisableAutoDismissal, __HIMenuEnableAutoDismissal,
__HIMenuGetBackgroundBleed, __HIMenuGetCommandKey, __HIMenuGetContentDirectionality,
__HIMenuGetContentSize, __HIMenuGetEffectiveDirectionality,
__HIMenuGetItemView, __HIMenuGetMenuBarHeight, __HIMenuGetMenuBarHeightWithOptions,
__HIMenuGetNewItemsCount, __HIMenuIsCarbonMenuKeyEvent, __HIMenuIsDark,
__HIMenuPerformKeyboardNavigation, __HIMenuSendItemSelectedEvent,
__HIMenuSetCommandKey, __HIMenuSetContentDirectionality, __HIMenuSetContentSize,
__HIMenuSetEventProc, __HIMenuSetIndentWidth, __HIMenuSetItemIndent,
__HIMenuSetItemViewClass, __HIMenuSetNSImageInterface, __HIMenuSetNewItemsCount,
__HIMenuUseBackdrops, __HIMenuViewRegisterClass, __HIPopupButtonRegisterClass,
__HIPresentationInstanceCreateForFullScreenSpace, __HIPresentationInstanceCreateWithFullScreenMode,
__HIPresentationInstanceDisplayDidChange, __HIPresentationInstanceRelease,
__HIPresentationInstanceSetAutoHideHeight, __HIPresentationInstanceSetSpace,
__HIPresentationInstanceSetUIMode, __HIPresentationInstanceStartMenuBarAnimation,
__HIProgressBarRegisterClass, __HIPushButtonRegisterClass,
__HIRadioGroupRegisterClass, __HIRawObjectRegisterClass, __HIRegisterAEWillInteractProc,
__HIRoundButtonRegisterClass, __HIScrollViewRegisterClass,
__HISegmentViewRegisterClass, __HISegmentViewSetIsInset, __HIShrinkToFitEditRegisterClass,
__HISliderRegisterClass, __HIStandardMenuViewRegisterClass,
__HIStaticTextViewRegisterClass, __HIStdAppHandlerRegisterClass,
__HIStdEventLoopRegisterClass, __HITextFieldRegisterClass,
__HITextViewRegisterClass, __HIThemeCreateImage, __HIThemeDrawAppleMenuTitle,
__HIThemeDrawSegment, __HIThemeDrawSelectionMarquee, __HIThemeDrawWell,
__HIThemeGetChasingArrowDimensions, __HIThemeGetLegacyModeEnabled,
__HIThemeGetMenuBarLogoRect, __HIThemeGetMenuCalloutDimensions,
__HIThemeGetWindowGrowSides, __HIThemeGetWindowTitleBaselineOffset,
__HIThemeRefreshPreferences, __HIThemeSetColor, __HIThemeSetDrawingCallback,
__HIThemeSetTextColor, __HIToolbarItemRegisterClass, __HIToolbarViewRegisterClass,
__HIViewAdvanceFocusFollowingView, __HIViewCopyVisibleShape,
__HIViewNotifySetFocusPart, __HIViewRegisterClass, __HIViewScrollRectWithOptions,
__HIWindowFrameViewRegisterClass, __HIWindowSetAutoReleaseFocus,
__HIWindowSetNeedsQDPrepWhenDrawingViews, __HLTBAddEventSourceToMode,
__HLTBRemoveEventSourceFromMode, __HandleHelpSymbolicHotKey,
__HandleMenuSelection, __HandlePopUpMenuSelection7, __HandlePopUpMenuSelectionWithDictionary,
__HiliteMenuTitle, __InstallEventLoopObserver, __InvalidateAllEnabledInputSourceState,
__InvalidateAllInputSourceState, __InvalidateAllSelectedInputSourceState,
__IsFullTabbingEnabled, __IsMenuAlreadyPopulated, __IsMenuItemEnabledU,
__IsSymbolicHotKeyEvent, __LoadPerformanceMenu, __MenuIterCreate,
__MenuIterFirst, __MenuIterNext, __MenuIterRelease, __NotifyEventLoopObservers,
__OpenMenuWithOptions, __OpenSubmenuFromItem, __OpenSubmenuFromItemWithOptions,
__PostCGEventToQueue, __PushMouseCoalescingState, __QuitAppModalLoop,
__RegisterSharedDockClientWithRunLoop, __RemoveCGEventFromQueue,
__RemoveEventLoopObserver, __RemoveMouseCoalescingState, __RequestBackgroundMouseMovedEvents,
__RunAppModalLoop, __SetAppleMenuEnabled, __SetAppleMenuInstallerMode,
__SetBaroloFullScreenModeUIMode, __SetCGEventAssociatedData,
__SetCGEventConversionFilter, __SetDefaultMenuFont, __SetFullTabbingEnabled,
__SetJavaThreadHook, __SetMenuCallout, __SetMenuItemIconSize,
__SetMenuMinimumWidth, __SetMenuTrackingShouldReraiseNSExceptions,
__SetMenuWindowLevel, __SetOpenMenuOrigin, __SetWindowCGOrderingEnabled,
__SetWindowReshapingEnabled, __SetWindowZOrderingEnabled,
__SimulateMenuClosed, __SimulateMenuOpening, __SimulateMenuSelection,
__SimulateMenuSelectionU, __StartSystemUIModeMenuBarAnimation,
__SyncWindowWithCGAfterMove, __TISCopyParentInputMethodForInputSource,
__TISCreateEnabledInputSourcePrefs, __TISGetPhysicalKeyboardLanguage,
__TISRestrictToReadOnlyMachinePrefs, __TISUpdateEnabledInputSourcePrefs,
__TSMCopySelectableInputSourcesInUIOrder, __TSMInvalidateDocumentClient,
__TSMIsRemoteViewAccessoryView, __TSMIsRemoteViewKeyEquivalentHandling,
__TSMParentInputMethodInputSourceForInputModeCreate, __TSMRegisterRemoteViewClient,
__TSMRemoteViewActivationIsOn, __TSMSetRemoteViewActivation,
__TSMSetRemoteViewIsAccessoryView, __TSMSetRemoteViewKeyEquivalentHandling,
__TSMWouldEventBeProcessedByPressAndHold, ___CDCreateScreenFramesDictionaryRepresentation,
___CoreDragAnimateOrderOut, ___CoreDragAutoScaleSourceDragComponents,
___CoreDragBeginDropAnimationTransaction, ___CoreDragBeginFlockingAnimation,
___CoreDragBeginSlideBackAnimation, ___CoreDragBeginUnflockingAnimation,
___CoreDragCancelDropAnimationTransaction, ___CoreDragCancelOutstandingFlockingAnimation,
___CoreDragClearAllImageOverrides, ___CoreDragCommitDropAnimationTransaction,
___CoreDragCreateCFStringFromCGEvent, ___CoreDragCreateDictionaryRepOfLayerTree,
___CoreDragCreateImageData, ___CoreDragCreateImageDataFromCFDictionary,
___CoreDragCreateImageDataWithComponentsBlock, ___CoreDragCreateImageDataWithImage,
___CoreDragGetValueForKey, ___CoreDragHasImageOverrides, ___CoreDragImageDataCreateDictionaryRepresentation,
___CoreDragImageDataDeleteSlotForCAContext, ___CoreDragImageDataGetComponentsBlock,
___CoreDragImageDataGetItemRef, ___CoreDragImageDataSet, ___CoreDragItemGetImageComponents,
___CoreDragItemGetImageData, ___CoreDragItemGetScreenFrame,
___CoreDragItemHasAlternate, ___CoreDragItemSetImageComponents,
___CoreDragReleaseImageData, ___CoreDragResetAutoScaleSourceDragComponents,
___CoreDragSetDestClippingRect, ___CoreDragSetRootCALayer,
___CoreDragSetSourceClippingRect, ___CoreDragSetValueForKey,
___CoreDragSetupDragImageLayers, ___CoreDragUpdateClippingSuperLayer,
___CoreDragUpdateDragLayerContent, ___CoreDragUpdateFlockingFormation,
___CoreDragUpdateLayerPositions, ___DisposeLayerBackedSurfaceAndRender,
___DragInfoCopyFilterParams, ___DragInfoPtrClearAllImageOverrides,
___DragInfoPtrCreateDictionaryRepresentationForImageData,
___DragInfoPtrGetCAContext, ___DragInfoPtrGetComponentDataForItem,
___DragInfoPtrGetImageDataForItem, ___DragInfoPtrHasImageOverrides,
___DragInfoPtrImageDataCount, ___DragInfoPtrMergeRemoteOverrides,
___DragInfoPtrMergeSourceImagesForDestinationContext, ___DragInfoPtrSetDestClippingRect,
___DragInfoPtrSetValueForKey, ___DragInfoSetAlpha, ___InitLayerBackedDragWindow,
_kHIDelegateAfterKey, _kHIDelegateBeforeKey, _kHIObjectCustomDataClassIDKey,
_kHIObjectCustomDataDelegateGroupParametersKey, _kHIObjectCustomDataParameterNamesKey,
_kHIObjectCustomDataParameterTypesKey, _kHIObjectCustomDataParameterValuesKey,
_kHIObjectCustomDataSuperClassIDKey, _kHIObjectInitParamDescription,
_kHIObjectInitParamEventName, _kHIObjectInitParamEventType,
_kHIObjectInitParamUserName, _kHITextViewClassID, _kHIToolboxVersionNumber,
_kHIViewMenuContentID, _kHIViewWindowContentID, _kHIViewWindowGrowBoxID,
_kIMKRequestInputMethodsCheckinEndpoints, _kIMKXPCPrivateRunLoopMode,
_kTISAppleCharacterPaletteInputSourceID, _kTISAppleChineseHandwritingInputSourceID,
_kTISAppleEmojiDFRPaletteInputSourceID, _kTISAppleJapaneseKanaPaletteInputSourceID,
_kTISAppleKeyboardViewerPaletteInputSourceID, _kTISApplePressAndHoldInputSourceID,
_kTISAppleSyntheticRomanModeInputSourceID, _kTISCategoryInkInputSource,
_kTISCategoryKeyboardInputSource, _kTISCategoryPaletteInputSource,
_kTISIterationPropertyPreferredInputSourceLocalePart, _kTISNotifyEnabledKeyboardInputSourcesChanged,
_kTISNotifyEnabledNonKeyboardInputSourcesChanged, _kTISNotifyHandwritingInputSourceChanged,
_kTISNotifyInstalledInputSourcesChanged, _kTISNotifyIronwoodAutoEnableChanged,
_kTISNotifySelectedKeyboardInputSourceChanged, _kTISPlistKeyCapsLockIsSwitch,
_kTISPlistKeyCapsLockIsSwitchToIMRomanMode, _kTISPlistKeyDoubleSpaceSubstitution,
_kTISPlistKeyHandwritingLanguages, _kTISPlistKeyIconLabels,
_kTISPlistKeyIconShouldBeTemplate, _kTISPlistKeyInputSourceID,
_kTISPlistKeyIntendedLanguage, _kTISPlistKeyParticipatesInTouchBar,
_kTISPropertyAlternateIconImage, _kTISPropertyBundleID, _kTISPropertyDataFileProperties,
_kTISPropertyDataFileWordList, _kTISPropertyHandwritingLanguages,
_kTISPropertyHandwritingLocalizedNames, _kTISPropertyIconFamilyOrURL,
_kTISPropertyIconImage, _kTISPropertyIconImageURL, _kTISPropertyIconRef,
_kTISPropertyIconShouldBeTemplate, _kTISPropertyInputModeID,
_kTISPropertyInputSourceCategory, _kTISPropertyInputSourceDoesCapsLockSwitch,
_kTISPropertyInputSourceDoesCapsLockSwitchToRomanMode, _kTISPropertyInputSourceDoubleSpaceSubstitution,
_kTISPropertyInputSourceID, _kTISPropertyInputSourceIconLabels,
_kTISPropertyInputSourceIsASCIICapable, _kTISPropertyInputSourceIsEnableCapable,
_kTISPropertyInputSourceIsEnabled, _kTISPropertyInputSourceIsFromSystem,
_kTISPropertyInputSourceIsInvisible, _kTISPropertyInputSourceIsSelectCapable,
_kTISPropertyInputSourceIsSelected, _kTISPropertyInputSourceLanguages,
_kTISPropertyInputSourceLocalePartsForPreferred, _kTISPropertyInputSourceOverrideCapsLockDelay,
_kTISPropertyInputSourceParticipatesInTouchBar, _kTISPropertyInputSourceType,
_kTISPropertyIntendedLanguage, _kTISPropertyKeyLayoutName,
_kTISPropertyKeyLayoutNumber, _kTISPropertyLocale, _kTISPropertyLocalizedName,
_kTISPropertyRepertoireSetPattern, _kTISPropertyScriptCode,
_kTISPropertyUSBCountry, _kTISPropertyUnicodeKeyLayoutData,
_kTISTypeCharacterPalette, _kTISTypeInk, _kTISTypeKeyboardInputMethodModeEnabled,
_kTISTypeKeyboardInputMethodWithoutModes, _kTISTypeKeyboardInputMode,
_kTISTypeKeyboardLayout, _kTISTypeKeyboardSyntheticRomanMode,
_kTISTypeKeyboardViewer ]
reexports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _ShowHideProcess ]
...

View File

@@ -0,0 +1,427 @@
/*
File: HIToolbox/AEInteraction.h
Contains: AppleEvent functions that deal with Events and interacting with user
Copyright: <20> 2000-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __AEINTERACTION__
#define __AEINTERACTION__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __NOTIFICATION__
#include <HIToolbox/Notification.h>
#endif
#ifndef __EVENTS__
#include <HIToolbox/Events.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/**************************************************************************
AppleEvent callbacks.
**************************************************************************/
typedef CALLBACK_API( Boolean , AEIdleProcPtr )(EventRecord *theEvent, SInt32 *sleepTime, RgnHandle *mouseRgn);
typedef CALLBACK_API( Boolean , AEFilterProcPtr )(EventRecord *theEvent, SInt32 returnID, AETransactionID transactionID, const AEAddressDesc *sender);
typedef STACK_UPP_TYPE(AEIdleProcPtr) AEIdleUPP;
typedef STACK_UPP_TYPE(AEFilterProcPtr) AEFilterUPP;
/**************************************************************************
The next couple of calls are basic routines used to create, send,
and process AppleEvents.
**************************************************************************/
/*
* AESend()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AESend(
const AppleEvent * theAppleEvent,
AppleEvent * reply,
AESendMode sendMode,
AESendPriority sendPriority,
SInt32 timeOutInTicks,
AEIdleUPP idleProc, /* can be NULL */
AEFilterUPP filterProc) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AEProcessAppleEvent()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AEProcessAppleEvent(const EventRecord * theEventRecord) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AEProcessEvent()
*
* Summary:
* Dispatches a Carbon event of type kEventAppleEvent to the
* appropriate AppleEvent handlers.
*
* Discussion:
* This API is similar to AEProcessAppleEvent, but does not require
* the Carbon event to be converted to an EventRecord. Also, unlike
* AEProcessAppleEvent, this API does not require that an event be
* removed from its event queue before processing; the AppleEvent
* will be correctly dispatched even if the Carbon event is still in
* its event queue. Of course, you should still remove the Carbon
* event from its event queue later once you're done handling it,
* and it is also acceptable to remove it from the event queue
* before calling this API.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inEvent:
* A Carbon event of class kEventClassAppleEvent and kind
* kEventAppleEvent.
*
* Result:
* The operating system result code returned by the AppleEvent
* handler, or paramErr if the event passed to this API is not of
* the correct class and kind.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
AEProcessEvent(EventRef inEvent) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
Note: during event processing, an event handler may realize that it is likely
to exceed the client's timeout limit. Passing the reply to this
routine causes a wait event to be generated that asks the client
for more time.
*/
/*
* AEResetTimer()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AEResetTimer(const AppleEvent * reply) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/**************************************************************************
The following three calls are used to allow applications to behave
courteously when a user interaction such as a dialog box is needed.
**************************************************************************/
typedef SInt8 AEInteractAllowed;
enum {
kAEInteractWithSelf = 0,
kAEInteractWithLocal = 1,
kAEInteractWithAll = 2
};
/*
* AEGetInteractionAllowed()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AEGetInteractionAllowed(AEInteractAllowed * level) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AESetInteractionAllowed()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AESetInteractionAllowed(AEInteractAllowed level) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AEInteractWithUser()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AEInteractWithUser(
SInt32 timeOutInTicks,
NMRecPtr nmReqPtr,
AEIdleUPP idleProc) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/**************************************************************************
The following four calls are available for applications which need more
sophisticated control over when and how events are processed. Applications
which implement multi-session servers or which implement their own
internal event queueing will probably be the major clients of these
routines. They can be called from within a handler to prevent the AEM from
disposing of the AppleEvent when the handler returns. They can be used to
asynchronously process the event (as MacApp does).
**************************************************************************/
/*
* AESuspendTheCurrentEvent()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AESuspendTheCurrentEvent(const AppleEvent * theAppleEvent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
Note: The following routine tells the AppleEvent manager that processing
is either about to resume or has been completed on a previously suspended
event. The procPtr passed in as the dispatcher parameter will be called to
attempt to redispatch the event. Several constants for the dispatcher
parameter allow special behavior. They are:
- kAEUseStandardDispatch means redispatch as if the event was just
received, using the standard AppleEvent dispatch mechanism.
- kAENoDispatch means ignore the parameter.
Use this in the case where the event has been handled and no
redispatch is needed.
- non nil means call the routine which the dispatcher points to.
*/
/* Constants for Refcon in AEResumeTheCurrentEvent with kAEUseStandardDispatch */
enum {
kAEDoNotIgnoreHandler = 0x00000000,
kAEIgnoreAppPhacHandler = 0x00000001, /* available only in vers 1.0.1 and greater */
kAEIgnoreAppEventHandler = 0x00000002, /* available only in vers 1.0.1 and greater */
kAEIgnoreSysPhacHandler = 0x00000004, /* available only in vers 1.0.1 and greater */
kAEIgnoreSysEventHandler = 0x00000008, /* available only in vers 1.0.1 and greater */
kAEIngoreBuiltInEventHandler = 0x00000010, /* available only in vers 1.0.1 and greater */
kAEDontDisposeOnResume = (int)0x80000000 /* available only in vers 1.0.1 and greater */
};
/* Constants for AEResumeTheCurrentEvent */
enum {
kAENoDispatch = 0, /* dispatch parameter to AEResumeTheCurrentEvent takes a pointer to a dispatch */
kAEUseStandardDispatch = -1L /* table, or one of these two constants */
};
/*
* AEResumeTheCurrentEvent()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AEResumeTheCurrentEvent(
const AppleEvent * theAppleEvent,
const AppleEvent * reply,
AEEventHandlerUPP dispatcher, /* can be NULL */
SRefCon handlerRefcon) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AEGetTheCurrentEvent()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AEGetTheCurrentEvent(AppleEvent * theAppleEvent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AESetTheCurrentEvent()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
AESetTheCurrentEvent(const AppleEvent * theAppleEvent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/**************************************************************************
AppleEvent callbacks.
**************************************************************************/
/*
* NewAEIdleUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern AEIdleUPP
NewAEIdleUPP(AEIdleProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewAEFilterUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern AEFilterUPP
NewAEFilterUPP(AEFilterProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeAEIdleUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeAEIdleUPP(AEIdleUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeAEFilterUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeAEFilterUPP(AEFilterUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeAEIdleUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern Boolean
InvokeAEIdleUPP(
EventRecord * theEvent,
SInt32 * sleepTime,
RgnHandle * mouseRgn,
AEIdleUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeAEFilterUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern Boolean
InvokeAEFilterUPP(
EventRecord * theEvent,
SInt32 returnID,
AETransactionID transactionID,
const AEAddressDesc * sender,
AEFilterUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if __MACH__
#ifdef __cplusplus
inline AEIdleUPP NewAEIdleUPP(AEIdleProcPtr userRoutine) { return userRoutine; }
inline AEFilterUPP NewAEFilterUPP(AEFilterProcPtr userRoutine) { return userRoutine; }
inline void DisposeAEIdleUPP(AEIdleUPP) { }
inline void DisposeAEFilterUPP(AEFilterUPP) { }
inline Boolean InvokeAEIdleUPP(EventRecord * theEvent, SInt32 * sleepTime, RgnHandle * mouseRgn, AEIdleUPP userUPP) { return (*userUPP)(theEvent, sleepTime, mouseRgn); }
inline Boolean InvokeAEFilterUPP(EventRecord * theEvent, SInt32 returnID, AETransactionID transactionID, const AEAddressDesc * sender, AEFilterUPP userUPP) { return (*userUPP)(theEvent, returnID, transactionID, sender); }
#else
#define NewAEIdleUPP(userRoutine) ((AEIdleUPP)userRoutine)
#define NewAEFilterUPP(userRoutine) ((AEFilterUPP)userRoutine)
#define DisposeAEIdleUPP(userUPP)
#define DisposeAEFilterUPP(userUPP)
#define InvokeAEIdleUPP(theEvent, sleepTime, mouseRgn, userUPP) (*userUPP)(theEvent, sleepTime, mouseRgn)
#define InvokeAEFilterUPP(theEvent, returnID, transactionID, sender, userUPP) (*userUPP)(theEvent, returnID, transactionID, sender)
#endif
#endif
#ifdef __cplusplus
}
#endif
#endif /* __AEINTERACTION__ */

View File

@@ -0,0 +1,747 @@
/*
File: Appearance.r
Contains: Appearance Manager Interfaces.
Copyright: <20> 1994-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __APPEARANCE_R__
#define __APPEARANCE_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kAppearanceEventClass 'appr' /* Event Class */
#define kAEAppearanceChanged 'thme' /* Appearance changed (e.g. platinum to hi-tech) */
#define kAESystemFontChanged 'sysf' /* system font changed */
#define kAESmallSystemFontChanged 'ssfn' /* small system font changed */
#define kAEViewsFontChanged 'vfnt' /* views font changed */
#define kThemeDataFileType 'thme' /* file type for theme files */
#define kThemePlatinumFileType 'pltn' /* file type for platinum appearance */
#define kThemeCustomThemesFileType 'scen' /* file type for user themes */
#define kThemeSoundTrackFileType 'tsnd'
#define kAppearancePartMetaNone 0
#define kAppearancePartMetaDisabled 254
#define kAppearancePartMetaInactive 255
#define kAppearancePartIndicator 129
#define kAppearancePartUpButton 20
#define kAppearancePartDownButton 21
#define kAppearancePartLeftButton 20
#define kAppearancePartRightButton 21
#define kAppearancePartPageUpArea 22
#define kAppearancePartPageDownArea 23
#define kAppearancePartPageLeftArea 22
#define kAppearancePartPageRightArea 23
#define kAppearanceRegionTitleBar 0
#define kAppearanceRegionTitleText 1
#define kAppearanceRegionCloseBox 2
#define kAppearanceRegionZoomBox 3
#define kAppearanceRegionDrag 5
#define kAppearanceRegionGrow 6
#define kAppearanceRegionCollapseBox 7
#define kAppearanceRegionTitleProxyIcon 8 /* Mac OS 8.5 forward */
#define kAppearanceRegionStructure 32
#define kAppearanceRegionContent 33 /* Content area of the window; empty when the window is collapsed */
#define kAppearanceRegionToolbarButton 41
#define kThemeBrushDialogBackgroundActive 1
#define kThemeBrushDialogBackgroundInactive 2
#define kThemeBrushAlertBackgroundActive 3
#define kThemeBrushAlertBackgroundInactive 4
#define kThemeBrushModelessDialogBackgroundActive 5
#define kThemeBrushModelessDialogBackgroundInactive 6
#define kThemeBrushUtilityWindowBackgroundActive 7
#define kThemeBrushUtilityWindowBackgroundInactive 8
#define kThemeBrushListViewSortColumnBackground 9
#define kThemeBrushListViewBackground 10
#define kThemeBrushIconLabelBackground 11
#define kThemeBrushListViewSeparator 12
#define kThemeBrushChasingArrows 13
#define kThemeBrushDragHilite 14
#define kThemeBrushDocumentWindowBackground 15
#define kThemeBrushFinderWindowBackground 16
#define kThemeBrushScrollBarDelimiterActive 17
#define kThemeBrushScrollBarDelimiterInactive 18
#define kThemeBrushFocusHighlight 19
#define kThemeBrushPopupArrowActive 20
#define kThemeBrushPopupArrowPressed 21
#define kThemeBrushPopupArrowInactive 22
#define kThemeBrushAppleGuideCoachmark 23
#define kThemeBrushIconLabelBackgroundSelected 24
#define kThemeBrushStaticAreaFill 25
#define kThemeBrushActiveAreaFill 26
#define kThemeBrushButtonFrameActive 27
#define kThemeBrushButtonFrameInactive 28
#define kThemeBrushButtonFaceActive 29
#define kThemeBrushButtonFaceInactive 30
#define kThemeBrushButtonFacePressed 31
#define kThemeBrushButtonActiveDarkShadow 32
#define kThemeBrushButtonActiveDarkHighlight 33
#define kThemeBrushButtonActiveLightShadow 34
#define kThemeBrushButtonActiveLightHighlight 35
#define kThemeBrushButtonInactiveDarkShadow 36
#define kThemeBrushButtonInactiveDarkHighlight 37
#define kThemeBrushButtonInactiveLightShadow 38
#define kThemeBrushButtonInactiveLightHighlight 39
#define kThemeBrushButtonPressedDarkShadow 40
#define kThemeBrushButtonPressedDarkHighlight 41
#define kThemeBrushButtonPressedLightShadow 42
#define kThemeBrushButtonPressedLightHighlight 43
#define kThemeBrushBevelActiveLight 44
#define kThemeBrushBevelActiveDark 45
#define kThemeBrushBevelInactiveLight 46
#define kThemeBrushBevelInactiveDark 47
#define kThemeBrushNotificationWindowBackground 48
#define kThemeBrushMovableModalBackground 49
#define kThemeBrushSheetBackgroundOpaque 50
#define kThemeBrushDrawerBackground 51
#define kThemeBrushToolbarBackground 52
#define kThemeBrushSheetBackgroundTransparent 53
#define kThemeBrushMenuBackground 54
#define kThemeBrushMenuBackgroundSelected 55
#define kThemeBrushListViewOddRowBackground 56
#define kThemeBrushListViewEvenRowBackground 57
#define kThemeBrushListViewColumnDivider 58
#define kThemeBrushSheetBackground 50
#define kThemeBrushBlack (-1)
#define kThemeBrushWhite (-2)
#define kThemeBrushPrimaryHighlightColor (-3)
#define kThemeBrushSecondaryHighlightColor (-4)
#define kThemeBrushAlternatePrimaryHighlightColor (-5)
#define kThemeTextColorDialogActive 1
#define kThemeTextColorDialogInactive 2
#define kThemeTextColorAlertActive 3
#define kThemeTextColorAlertInactive 4
#define kThemeTextColorModelessDialogActive 5
#define kThemeTextColorModelessDialogInactive 6
#define kThemeTextColorWindowHeaderActive 7
#define kThemeTextColorWindowHeaderInactive 8
#define kThemeTextColorPlacardActive 9
#define kThemeTextColorPlacardInactive 10
#define kThemeTextColorPlacardPressed 11
#define kThemeTextColorPushButtonActive 12
#define kThemeTextColorPushButtonInactive 13
#define kThemeTextColorPushButtonPressed 14
#define kThemeTextColorBevelButtonActive 15
#define kThemeTextColorBevelButtonInactive 16
#define kThemeTextColorBevelButtonPressed 17
#define kThemeTextColorPopupButtonActive 18
#define kThemeTextColorPopupButtonInactive 19
#define kThemeTextColorPopupButtonPressed 20
#define kThemeTextColorIconLabel 21
#define kThemeTextColorListView 22
#define kThemeTextColorDocumentWindowTitleActive 23
#define kThemeTextColorDocumentWindowTitleInactive 24
#define kThemeTextColorMovableModalWindowTitleActive 25
#define kThemeTextColorMovableModalWindowTitleInactive 26
#define kThemeTextColorUtilityWindowTitleActive 27
#define kThemeTextColorUtilityWindowTitleInactive 28
#define kThemeTextColorPopupWindowTitleActive 29
#define kThemeTextColorPopupWindowTitleInactive 30
#define kThemeTextColorRootMenuActive 31
#define kThemeTextColorRootMenuSelected 32
#define kThemeTextColorRootMenuDisabled 33
#define kThemeTextColorMenuItemActive 34
#define kThemeTextColorMenuItemSelected 35
#define kThemeTextColorMenuItemDisabled 36
#define kThemeTextColorPopupLabelActive 37
#define kThemeTextColorPopupLabelInactive 38
#define kThemeTextColorTabFrontActive 39
#define kThemeTextColorTabNonFrontActive 40
#define kThemeTextColorTabNonFrontPressed 41
#define kThemeTextColorTabFrontInactive 42
#define kThemeTextColorTabNonFrontInactive 43
#define kThemeTextColorIconLabelSelected 44
#define kThemeTextColorBevelButtonStickyActive 45
#define kThemeTextColorBevelButtonStickyInactive 46
#define kThemeTextColorNotification 47
#define kThemeTextColorSystemDetail 48
#define kThemeTextColorBlack (-1)
#define kThemeTextColorWhite (-2)
#define kThemeStateInactive 0
#define kThemeStateActive 1
#define kThemeStatePressed 2
#define kThemeStateRollover 6
#define kThemeStateUnavailable 7
#define kThemeStateUnavailableInactive 8
#define kThemeStateDisabled 0
#define kThemeStatePressedUp 2 /* draw with up pressed (increment/decrement buttons) */
#define kThemeStatePressedDown 3 /* draw with down pressed (increment/decrement buttons) */
#define kThemeArrowCursor 0
#define kThemeCopyArrowCursor 1
#define kThemeAliasArrowCursor 2
#define kThemeContextualMenuArrowCursor 3
#define kThemeIBeamCursor 4
#define kThemeCrossCursor 5
#define kThemePlusCursor 6
#define kThemeWatchCursor 7 /* Can Animate */
#define kThemeClosedHandCursor 8
#define kThemeOpenHandCursor 9
#define kThemePointingHandCursor 10
#define kThemeCountingUpHandCursor 11 /* Can Animate */
#define kThemeCountingDownHandCursor 12 /* Can Animate */
#define kThemeCountingUpAndDownHandCursor 13 /* Can Animate */
#define kThemeSpinningCursor 14 /* Can Animate */
#define kThemeResizeLeftCursor 15
#define kThemeResizeRightCursor 16
#define kThemeResizeLeftRightCursor 17
#define kThemeNotAllowedCursor 18 /* available on Mac OS X 10.2 and later */
#define kThemeResizeUpCursor 19
#define kThemeResizeDownCursor 20
#define kThemeResizeUpDownCursor 21
#define kThemePoofCursor 22
#define kThemeMenuBarNormal 0
#define kThemeMenuBarSelected 1
#define kThemeMenuSquareMenuBar 0x01
#define kThemeMenuActive 0
#define kThemeMenuSelected 1
#define kThemeMenuDisabled 3
#define kThemeMenuTypePullDown 0
#define kThemeMenuTypePopUp 1
#define kThemeMenuTypeHierarchical 2
#define kThemeMenuTypeInactive 0x0100
#define kThemeMenuItemPlain 0
#define kThemeMenuItemHierarchical 1 /* item has hierarchical arrow */
#define kThemeMenuItemScrollUpArrow 2 /* for scrollable menus, indicates item is scroller */
#define kThemeMenuItemScrollDownArrow 3
#define kThemeMenuItemAtTop 0x0100 /* indicates item is being drawn at top of menu */
#define kThemeMenuItemAtBottom 0x0200 /* indicates item is being drawn at bottom of menu */
#define kThemeMenuItemHierBackground 0x0400 /* item is within a hierarchical menu */
#define kThemeMenuItemPopUpBackground 0x0800 /* item is within a popped up menu */
#define kThemeMenuItemHasIcon 0x8000 /* add into non-arrow type when icon present */
#define kThemeMenuItemNoBackground 0x4000 /* don't draw the menu background while drawing this item (Mac OS X only) */
#define kThemeMenuItemAlignRight 0x2000 /* right-align the content of this menu item (SnowLeopard and later) */
#define kThemeBackgroundTabPane 1
#define kThemeBackgroundPlacard 2
#define kThemeBackgroundWindowHeader 3
#define kThemeBackgroundListViewWindowHeader 4
#define kThemeBackgroundSecondaryGroupBox 5
#define kThemeBackgroundMetal 6
#define kThemeNameTag 'name' /* Str255 */
#define kThemeVariantNameTag 'varn' /* Str255 */
#define kThemeVariantBaseTintTag 'tint' /* RGBColor (10.1 and later) */
#define kThemeHighlightColorTag 'hcol' /* RGBColor */
#define kThemeScrollBarArrowStyleTag 'sbar' /* ThemeScrollBarArrowStyle */
#define kThemeScrollBarThumbStyleTag 'sbth' /* ThemeScrollBarThumbStyle */
#define kThemeSoundsEnabledTag 'snds' /* Boolean */
#define kThemeDblClickCollapseTag 'coll' /* Boolean */
#define kThemeAppearanceFileNameTag 'thme' /* Str255 */
#define kThemeSystemFontTag 'lgsf' /* Str255 */
#define kThemeSmallSystemFontTag 'smsf' /* Str255 */
#define kThemeViewsFontTag 'vfnt' /* Str255 */
#define kThemeViewsFontSizeTag 'vfsz' /* SInt16 */
#define kThemeDesktopPatternNameTag 'patn' /* Str255 */
#define kThemeDesktopPatternTag 'patt' /* <variable-length data> (flattened pattern) */
#define kThemeDesktopPictureNameTag 'dpnm' /* Str255 */
#define kThemeDesktopPictureAliasTag 'dpal' /* <alias handle> */
#define kThemeDesktopPictureAlignmentTag 'dpan' /* UInt32 (see the Picture Alignments below) */
#define kThemeHighlightColorNameTag 'hcnm' /* Str255 */
#define kThemeExamplePictureIDTag 'epic' /* SInt16 */
#define kThemeSoundTrackNameTag 'sndt' /* Str255 */
#define kThemeSoundMaskTag 'smsk' /* UInt32 */
#define kThemeUserDefinedTag 'user' /* Boolean (this should _always_ be true if present - used by Control Panel). */
#define kThemeSmoothFontEnabledTag 'smoo' /* Boolean */
#define kThemeSmoothFontMinSizeTag 'smos' /* UInt16 (must be >= 12 and <= 24) */
#define kTiledOnScreen 1 /* draws picture repeatedly */
#define kCenterOnScreen 2 /* "actual size", shows pattern on sides or clips picture if necessary */
#define kFitToScreen 3 /* shrinks if necessary */
#define kFillScreen 4 /* messes up aspect ratio if necessary */
#define kUseBestGuess 5 /* heuristically determines the best way to display the picture based on picture and monitor sizes */
#define kThemeCheckBoxClassicX 0 /* check box with an 'X' */
#define kThemeCheckBoxCheckMark 1 /* check box with a real check mark */
#define kThemeScrollBarArrowsSingle 0 /* single arrow on each end */
#define kThemeScrollBarArrowsLowerRight 1 /* double arrows only on right or bottom */
#define kThemeScrollBarThumbNormal 0 /* normal, classic thumb size */
#define kThemeScrollBarThumbProportional 1 /* proportional thumbs */
#define kThemeSystemFont 0
#define kThemeSmallSystemFont 1
#define kThemeSmallEmphasizedSystemFont 2
#define kThemeViewsFont 3
#define kThemeEmphasizedSystemFont 4
#define kThemeApplicationFont 5
#define kThemeLabelFont 6
#define kThemeSystemFontDetail 7
#define kThemeSystemFontDetailEmphasized 8
#define kThemeMenuTitleFont 100
#define kThemeMenuItemFont 101
#define kThemeMenuItemMarkFont 102
#define kThemeMenuItemCmdKeyFont 103
#define kThemeWindowTitleFont 104
#define kThemePushButtonFont 105
#define kThemeUtilityWindowTitleFont 106
#define kThemeAlertHeaderFont 107
#define kThemeToolbarFont 108
#define kThemeMiniSystemFont 109
#define kThemeCurrentPortFont 200
#define kThemeSpecifiedFont 201
#define kPublicThemeFontCount 21
#define kThemeTabNonFront 0
#define kThemeTabNonFrontPressed 1
#define kThemeTabNonFrontInactive 2
#define kThemeTabFront 3
#define kThemeTabFrontInactive 4
#define kThemeTabNonFrontUnavailable 5
#define kThemeTabFrontUnavailable 6
#define kThemeTabNorth 0
#define kThemeTabSouth 1
#define kThemeTabEast 2
#define kThemeTabWest 3
#define kThemeSmallTabHeight 16
#define kThemeLargeTabHeight 21
#define kThemeTabPaneOverlap 3
#define kThemeSmallTabHeightMax 19
#define kThemeLargeTabHeightMax 24
#define kThemeScrollBarMedium 0
#define kThemeScrollBarSmall 1
#define kThemeSliderMedium 2
#define kThemeProgressBarMedium 3
#define kThemeIndeterminateBarMedium 4
#define kThemeRelevanceBar 5
#define kThemeSliderSmall 6
#define kThemeProgressBarLarge 7
#define kThemeIndeterminateBarLarge 8
#define kThemeScrollBarMini 9
#define kThemeSliderMini 10
#define kThemeProgressBarMini 11
#define kThemeIndeterminateBarMini 12
#define kThemeMediumScrollBar 0
#define kThemeSmallScrollBar 1
#define kThemeMediumSlider 2
#define kThemeMediumProgressBar 3
#define kThemeMediumIndeterminateBar 4
#define kThemeSmallSlider 6
#define kThemeLargeProgressBar 7
#define kThemeLargeIndeterminateBar 8
#define kThemeMiniScrollBar 9
#define kThemeMiniSlider 10
#define kThemeMiniProgressBar 11
#define kThemeMiniIndeterminateBar 12
/* track states */
#define kThemeTrackActive 0
#define kThemeTrackDisabled 1
#define kThemeTrackNothingToScroll 2
#define kThemeTrackInactive 3
/* press states (ignored unless track is active) */
#define kThemeLeftOutsideArrowPressed 0x01
#define kThemeLeftInsideArrowPressed 0x02
#define kThemeLeftTrackPressed 0x04
#define kThemeThumbPressed 0x08
#define kThemeRightTrackPressed 0x10
#define kThemeRightInsideArrowPressed 0x20
#define kThemeRightOutsideArrowPressed 0x40
#define kThemeTopOutsideArrowPressed 0x01
#define kThemeTopInsideArrowPressed 0x02
#define kThemeTopTrackPressed 0x04
#define kThemeBottomTrackPressed 0x10
#define kThemeBottomInsideArrowPressed 0x20
#define kThemeBottomOutsideArrowPressed 0x40
/* thumb direction */
#define kThemeThumbPlain 0
#define kThemeThumbUpward 1
#define kThemeThumbDownward 2
#define kThemeTrackHorizontal 0x01
#define kThemeTrackRightToLeft 0x02
#define kThemeTrackShowThumb 0x04
#define kThemeTrackThumbRgnIsNotGhost 0x08
#define kThemeTrackNoScrollBarArrows 0x10
#define kThemeTrackHasFocus 0x20
#define kThemeTrackHideTrack 0x40
#define kThemeWindowHasGrow 0x01
#define kThemeWindowHasHorizontalZoom 0x08
#define kThemeWindowHasVerticalZoom 0x10
#define kThemeWindowHasFullZoom 0x18
#define kThemeWindowHasCloseBox 0x20
#define kThemeWindowHasCollapseBox 0x40
#define kThemeWindowHasTitleText 0x80
#define kThemeWindowIsCollapsed 0x0100
#define kThemeWindowHasDirty 0x0200
#define kThemeWindowHasToolbarButton 0x0800
#define kThemeDocumentWindow 0
#define kThemeDialogWindow 1
#define kThemeMovableDialogWindow 2
#define kThemeAlertWindow 3
#define kThemeMovableAlertWindow 4
#define kThemePlainDialogWindow 5
#define kThemeShadowDialogWindow 6
#define kThemePopupWindow 7
#define kThemeUtilityWindow 8
#define kThemeUtilitySideWindow 9
#define kThemeSheetWindow 10
#define kThemeDrawerWindow 11
#define kThemeWidgetCloseBox 0
#define kThemeWidgetZoomBox 1
#define kThemeWidgetCollapseBox 2
#define kThemeWidgetDirtyCloseBox 6
#define kThemeWidgetToolbarButton 7
#define kThemeArrowLeft 0
#define kThemeArrowDown 1
#define kThemeArrowRight 2
#define kThemeArrowUp 3
#define kThemeArrow3pt 0
#define kThemeArrow5pt 1
#define kThemeArrow7pt 2
#define kThemeArrow9pt 3
#define kThemeGrowLeft 0x01 /* can grow to the left */
#define kThemeGrowRight 0x02 /* can grow to the right */
#define kThemeGrowUp 0x04 /* can grow up */
#define kThemeGrowDown 0x08 /* can grow down */
#define kThemePushButton 0
#define kThemeCheckBox 1
#define kThemeRadioButton 2
#define kThemeBevelButton 3
#define kThemeArrowButton 4
#define kThemePopupButton 5
#define kThemeDisclosureTriangle 6
#define kThemeIncDecButton 7
#define kThemeBevelButtonSmall 8
#define kThemeBevelButtonMedium 3
#define kThemeBevelButtonLarge 9
#define kThemeListHeaderButton 10
#define kThemeRoundButton 11
#define kThemeRoundButtonLarge 12
#define kThemeCheckBoxSmall 13
#define kThemeRadioButtonSmall 14
#define kThemeRoundedBevelButton 15
#define kThemeComboBox 16
#define kThemeComboBoxSmall 17
#define kThemeComboBoxMini 18
#define kThemeCheckBoxMini 19
#define kThemeRadioButtonMini 20
#define kThemeIncDecButtonSmall 21
#define kThemeIncDecButtonMini 22
#define kThemeArrowButtonSmall 23
#define kThemeArrowButtonMini 24
#define kThemePushButtonNormal 25
#define kThemePushButtonSmall 26
#define kThemePushButtonMini 27
#define kThemePopupButtonNormal 28
#define kThemePopupButtonSmall 29
#define kThemePopupButtonMini 30
#define kThemeBevelButtonInset 31
#define kThemePushButtonTextured 32
#define kThemePushButtonTexturedSmall 33
#define kThemeRoundButtonHelp 34
#define kThemePushButtonInset 32
#define kThemePushButtonInsetSmall 33
#define kThemeNormalCheckBox 1
#define kThemeNormalRadioButton 2
#define kThemeLargeBevelButton 9
#define kThemeMediumBevelButton 3
#define kThemeMiniCheckBox 19
#define kThemeMiniRadioButton 20
#define kThemeSmallBevelButton 8
#define kThemeSmallCheckBox 13
#define kThemeSmallRadioButton 14
#define kThemeLargeRoundButton 12
#define kThemeDisclosureButton 6
#define kThemeButtonOff 0
#define kThemeButtonOn 1
#define kThemeButtonMixed 2
#define kThemeDisclosureRight 0
#define kThemeDisclosureDown 1
#define kThemeDisclosureLeft 2
#define kThemeAdornmentNone 0
#define kThemeAdornmentDefault 0x01
#define kThemeAdornmentFocus 0x04
#define kThemeAdornmentRightToLeft 0x10
#define kThemeAdornmentDrawIndicatorOnly 0x20
#define kThemeAdornmentHeaderButtonLeftNeighborSelected 0x40
#define kThemeAdornmentHeaderButtonRightNeighborSelected 0x80
#define kThemeAdornmentHeaderButtonSortUp 0x0100
#define kThemeAdornmentHeaderMenuButton 0x0200
#define kThemeAdornmentHeaderButtonNoShadow 0x0400
#define kThemeAdornmentHeaderButtonShadowOnly 0x0800
#define kThemeAdornmentHeaderButtonNoSortArrow 0x1000
#define kThemeAdornmentArrowLeftArrow 0x40
#define kThemeAdornmentArrowDownArrow 0x80
#define kThemeAdornmentArrowDoubleArrow 0x0100
#define kThemeAdornmentArrowUpArrow 0x0200
#define kThemeAdornmentArrowRightArrow 0x0400
#define kThemeAdornmentNoShadow 0x0400
#define kThemeAdornmentShadowOnly 0x0800
#define kThemeNoSounds 0
#define kThemeWindowSoundsMask 0x01
#define kThemeMenuSoundsMask 0x02
#define kThemeControlSoundsMask 0x04
#define kThemeFinderSoundsMask 0x08
#define kThemeDragSoundNone 0
#define kThemeDragSoundMoveWindow 'wmov'
#define kThemeDragSoundGrowWindow 'wgro'
#define kThemeDragSoundMoveUtilWindow 'umov'
#define kThemeDragSoundGrowUtilWindow 'ugro'
#define kThemeDragSoundMoveDialog 'dmov'
#define kThemeDragSoundMoveAlert 'amov'
#define kThemeDragSoundMoveIcon 'imov'
#define kThemeDragSoundSliderThumb 'slth'
#define kThemeDragSoundSliderGhost 'slgh'
#define kThemeDragSoundScrollBarThumb 'sbth'
#define kThemeDragSoundScrollBarGhost 'sbgh'
#define kThemeDragSoundScrollBarArrowDecreasing 'sbad'
#define kThemeDragSoundScrollBarArrowIncreasing 'sbai'
#define kThemeDragSoundDragging 'drag'
#define kThemeSoundNone 0
#define kThemeSoundMenuOpen 'mnuo' /* menu sounds */
#define kThemeSoundMenuClose 'mnuc'
#define kThemeSoundMenuItemHilite 'mnui'
#define kThemeSoundMenuItemRelease 'mnus'
#define kThemeSoundWindowClosePress 'wclp' /* window sounds */
#define kThemeSoundWindowCloseEnter 'wcle'
#define kThemeSoundWindowCloseExit 'wclx'
#define kThemeSoundWindowCloseRelease 'wclr'
#define kThemeSoundWindowZoomPress 'wzmp'
#define kThemeSoundWindowZoomEnter 'wzme'
#define kThemeSoundWindowZoomExit 'wzmx'
#define kThemeSoundWindowZoomRelease 'wzmr'
#define kThemeSoundWindowCollapsePress 'wcop'
#define kThemeSoundWindowCollapseEnter 'wcoe'
#define kThemeSoundWindowCollapseExit 'wcox'
#define kThemeSoundWindowCollapseRelease 'wcor'
#define kThemeSoundWindowDragBoundary 'wdbd'
#define kThemeSoundUtilWinClosePress 'uclp' /* utility window sounds */
#define kThemeSoundUtilWinCloseEnter 'ucle'
#define kThemeSoundUtilWinCloseExit 'uclx'
#define kThemeSoundUtilWinCloseRelease 'uclr'
#define kThemeSoundUtilWinZoomPress 'uzmp'
#define kThemeSoundUtilWinZoomEnter 'uzme'
#define kThemeSoundUtilWinZoomExit 'uzmx'
#define kThemeSoundUtilWinZoomRelease 'uzmr'
#define kThemeSoundUtilWinCollapsePress 'ucop'
#define kThemeSoundUtilWinCollapseEnter 'ucoe'
#define kThemeSoundUtilWinCollapseExit 'ucox'
#define kThemeSoundUtilWinCollapseRelease 'ucor'
#define kThemeSoundUtilWinDragBoundary 'udbd'
#define kThemeSoundWindowOpen 'wopn' /* window close and zoom action */
#define kThemeSoundWindowClose 'wcls'
#define kThemeSoundWindowZoomIn 'wzmi'
#define kThemeSoundWindowZoomOut 'wzmo'
#define kThemeSoundWindowCollapseUp 'wcol'
#define kThemeSoundWindowCollapseDown 'wexp'
#define kThemeSoundWindowActivate 'wact'
#define kThemeSoundUtilWindowOpen 'uopn'
#define kThemeSoundUtilWindowClose 'ucls'
#define kThemeSoundUtilWindowZoomIn 'uzmi'
#define kThemeSoundUtilWindowZoomOut 'uzmo'
#define kThemeSoundUtilWindowCollapseUp 'ucol'
#define kThemeSoundUtilWindowCollapseDown 'uexp'
#define kThemeSoundUtilWindowActivate 'uact'
#define kThemeSoundDialogOpen 'dopn'
#define kThemeSoundDialogClose 'dlgc'
#define kThemeSoundAlertOpen 'aopn'
#define kThemeSoundAlertClose 'altc'
#define kThemeSoundPopupWindowOpen 'pwop'
#define kThemeSoundPopupWindowClose 'pwcl'
#define kThemeSoundButtonPress 'btnp' /* button */
#define kThemeSoundButtonEnter 'btne'
#define kThemeSoundButtonExit 'btnx'
#define kThemeSoundButtonRelease 'btnr'
#define kThemeSoundDefaultButtonPress 'dbtp' /* default button */
#define kThemeSoundDefaultButtonEnter 'dbte'
#define kThemeSoundDefaultButtonExit 'dbtx'
#define kThemeSoundDefaultButtonRelease 'dbtr'
#define kThemeSoundCancelButtonPress 'cbtp' /* cancel button */
#define kThemeSoundCancelButtonEnter 'cbte'
#define kThemeSoundCancelButtonExit 'cbtx'
#define kThemeSoundCancelButtonRelease 'cbtr'
#define kThemeSoundCheckboxPress 'chkp' /* checkboxes */
#define kThemeSoundCheckboxEnter 'chke'
#define kThemeSoundCheckboxExit 'chkx'
#define kThemeSoundCheckboxRelease 'chkr'
#define kThemeSoundRadioPress 'radp' /* radio buttons */
#define kThemeSoundRadioEnter 'rade'
#define kThemeSoundRadioExit 'radx'
#define kThemeSoundRadioRelease 'radr'
#define kThemeSoundScrollArrowPress 'sbap' /* scroll bars */
#define kThemeSoundScrollArrowEnter 'sbae'
#define kThemeSoundScrollArrowExit 'sbax'
#define kThemeSoundScrollArrowRelease 'sbar'
#define kThemeSoundScrollEndOfTrack 'sbte'
#define kThemeSoundScrollTrackPress 'sbtp'
#define kThemeSoundSliderEndOfTrack 'slte' /* sliders */
#define kThemeSoundSliderTrackPress 'sltp'
#define kThemeSoundBalloonOpen 'blno' /* help balloons */
#define kThemeSoundBalloonClose 'blnc'
#define kThemeSoundBevelPress 'bevp' /* Bevel buttons */
#define kThemeSoundBevelEnter 'beve'
#define kThemeSoundBevelExit 'bevx'
#define kThemeSoundBevelRelease 'bevr'
#define kThemeSoundLittleArrowUpPress 'laup' /* Little Arrows */
#define kThemeSoundLittleArrowDnPress 'ladp'
#define kThemeSoundLittleArrowEnter 'lare'
#define kThemeSoundLittleArrowExit 'larx'
#define kThemeSoundLittleArrowUpRelease 'laur'
#define kThemeSoundLittleArrowDnRelease 'ladr'
#define kThemeSoundPopupPress 'popp' /* Popup Buttons */
#define kThemeSoundPopupEnter 'pope'
#define kThemeSoundPopupExit 'popx'
#define kThemeSoundPopupRelease 'popr'
#define kThemeSoundDisclosurePress 'dscp' /* Disclosure Buttons */
#define kThemeSoundDisclosureEnter 'dsce'
#define kThemeSoundDisclosureExit 'dscx'
#define kThemeSoundDisclosureRelease 'dscr'
#define kThemeSoundTabPressed 'tabp' /* Tabs */
#define kThemeSoundTabEnter 'tabe'
#define kThemeSoundTabExit 'tabx'
#define kThemeSoundTabRelease 'tabr'
#define kThemeSoundDragTargetHilite 'dthi' /* drag manager */
#define kThemeSoundDragTargetUnhilite 'dtuh'
#define kThemeSoundDragTargetDrop 'dtdr'
#define kThemeSoundEmptyTrash 'ftrs' /* finder */
#define kThemeSoundSelectItem 'fsel'
#define kThemeSoundNewItem 'fnew'
#define kThemeSoundReceiveDrop 'fdrp'
#define kThemeSoundCopyDone 'fcpd'
#define kThemeSoundResolveAlias 'fral'
#define kThemeSoundLaunchApp 'flap'
#define kThemeSoundDiskInsert 'dski'
#define kThemeSoundDiskEject 'dske'
#define kThemeSoundFinderDragOnIcon 'fdon'
#define kThemeSoundFinderDragOffIcon 'fdof'
#define kThemePopupTabNormalPosition 0
#define kThemePopupTabCenterOnWindow 1
#define kThemePopupTabCenterOnOffset 2
#define appearanceBadBrushIndexErr (-30560) /* pattern index invalid */
#define appearanceProcessRegisteredErr (-30561)
#define appearanceProcessNotRegisteredErr (-30562)
#define appearanceBadTextColorIndexErr (-30563)
#define appearanceThemeHasNoAccents (-30564)
#define appearanceBadCursorIndexErr (-30565)
#define kThemeActiveDialogBackgroundBrush 1
#define kThemeInactiveDialogBackgroundBrush 2
#define kThemeActiveAlertBackgroundBrush 3
#define kThemeInactiveAlertBackgroundBrush 4
#define kThemeActiveModelessDialogBackgroundBrush 5
#define kThemeInactiveModelessDialogBackgroundBrush 6
#define kThemeActiveUtilityWindowBackgroundBrush 7
#define kThemeInactiveUtilityWindowBackgroundBrush 8
#define kThemeListViewSortColumnBackgroundBrush 9
#define kThemeListViewBackgroundBrush 10
#define kThemeIconLabelBackgroundBrush 11
#define kThemeListViewSeparatorBrush 12
#define kThemeChasingArrowsBrush 13
#define kThemeDragHiliteBrush 14
#define kThemeDocumentWindowBackgroundBrush 15
#define kThemeFinderWindowBackgroundBrush 16
#define kThemeActiveScrollBarDelimiterBrush 17
#define kThemeInactiveScrollBarDelimiterBrush 18
#define kThemeFocusHighlightBrush 19
#define kThemeActivePopupArrowBrush 20
#define kThemePressedPopupArrowBrush 21
#define kThemeInactivePopupArrowBrush 22
#define kThemeAppleGuideCoachmarkBrush 23
#define kThemeActiveDialogTextColor 1
#define kThemeInactiveDialogTextColor 2
#define kThemeActiveAlertTextColor 3
#define kThemeInactiveAlertTextColor 4
#define kThemeActiveModelessDialogTextColor 5
#define kThemeInactiveModelessDialogTextColor 6
#define kThemeActiveWindowHeaderTextColor 7
#define kThemeInactiveWindowHeaderTextColor 8
#define kThemeActivePlacardTextColor 9
#define kThemeInactivePlacardTextColor 10
#define kThemePressedPlacardTextColor 11
#define kThemeActivePushButtonTextColor 12
#define kThemeInactivePushButtonTextColor 13
#define kThemePressedPushButtonTextColor 14
#define kThemeActiveBevelButtonTextColor 15
#define kThemeInactiveBevelButtonTextColor 16
#define kThemePressedBevelButtonTextColor 17
#define kThemeActivePopupButtonTextColor 18
#define kThemeInactivePopupButtonTextColor 19
#define kThemePressedPopupButtonTextColor 20
#define kThemeIconLabelTextColor 21
#define kThemeListViewTextColor 22
#define kThemeActiveDocumentWindowTitleTextColor 23
#define kThemeInactiveDocumentWindowTitleTextColor 24
#define kThemeActiveMovableModalWindowTitleTextColor 25
#define kThemeInactiveMovableModalWindowTitleTextColor 26
#define kThemeActiveUtilityWindowTitleTextColor 27
#define kThemeInactiveUtilityWindowTitleTextColor 28
#define kThemeActivePopupWindowTitleColor 29
#define kThemeInactivePopupWindowTitleColor 30
#define kThemeActiveRootMenuTextColor 31
#define kThemeSelectedRootMenuTextColor 32
#define kThemeDisabledRootMenuTextColor 33
#define kThemeActiveMenuItemTextColor 34
#define kThemeSelectedMenuItemTextColor 35
#define kThemeDisabledMenuItemTextColor 36
#define kThemeActivePopupLabelTextColor 37
#define kThemeInactivePopupLabelTextColor 38
#define kAEThemeSwitch 'thme' /* Event ID's: Theme Switched */
#define kThemeNoAdornment 0
#define kThemeDefaultAdornment 0x01
#define kThemeFocusAdornment 0x04
#define kThemeRightToLeftAdornment 0x10
#define kThemeDrawIndicatorOnly 0x20
#define kThemeBrushPassiveAreaFill 25
#define kThemeScrollBar 0
#define kThemeSlider 2
#define kThemeProgressBar 3
#define kThemeIndeterminateBar 4
#endif /* __APPEARANCE_R__ */

View File

@@ -0,0 +1,76 @@
/*
File: CarbonEvents.r
Contains: Carbon Event Manager
Copyright: <20> 1999-2008 by Apple Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __CARBONEVENTS_R__
#define __CARBONEVENTS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kHICommandOK 'ok '
#define kHICommandCancel 'not!'
#define kHICommandQuit 'quit'
#define kHICommandQuitAndDiscardWindows 'qudw'
#define kHICommandQuitAndKeepWindows 'qukw'
#define kHICommandUndo 'undo'
#define kHICommandRedo 'redo'
#define kHICommandCut 'cut '
#define kHICommandCopy 'copy'
#define kHICommandPaste 'past'
#define kHICommandClear 'clea'
#define kHICommandSelectAll 'sall'
#define kHICommandHide 'hide'
#define kHICommandHideOthers 'hido'
#define kHICommandShowAll 'shal'
#define kHICommandPreferences 'pref'
#define kHICommandZoomWindow 'zoom'
#define kHICommandMinimizeWindow 'mini'
#define kHICommandMinimizeAll 'mina'
#define kHICommandMaximizeWindow 'maxi'
#define kHICommandMaximizeAll 'maxa'
#define kHICommandArrangeInFront 'frnt'
#define kHICommandBringAllToFront 'bfrt'
#define kHICommandWindowListSeparator 'wldv'
#define kHICommandWindowListTerminator 'wlst'
#define kHICommandSelectWindow 'swin'
#define kHICommandRotateWindowsForward 'rotw'
#define kHICommandRotateWindowsBackward 'rotb'
#define kHICommandRotateFloatingWindowsForward 'rtfw'
#define kHICommandRotateFloatingWindowsBackward 'rtfb'
#define kHICommandToggleFullScreen 'fsm '
#define kHICommandAbout 'abou'
#define kHICommandNew 'new '
#define kHICommandOpen 'open'
#define kHICommandClose 'clos'
#define kHICommandCloseAll 'cloa'
#define kHICommandCloseFile 'clof'
#define kHICommandSave 'save'
#define kHICommandSaveAs 'svas'
#define kHICommandRevert 'rvrt'
#define kHICommandPrint 'prnt'
#define kHICommandPageSetup 'page'
#define kHICommandAppHelp 'ahlp'
#define kHICommandShowCharacterPalette 'chrp'
#define kHICommandShowSpellingPanel 'shsp'
#define kHICommandCheckSpelling 'cksp'
#define kHICommandChangeSpelling 'chsp'
#define kHICommandCheckSpellingAsYouType 'aspc'
#define kHICommandIgnoreSpelling 'igsp'
#define kHICommandLearnWord 'lrwd'
#define kHICommandStartDictation 'sdct'
#endif /* __CARBONEVENTS_R__ */

View File

@@ -0,0 +1,470 @@
/*
File: HIToolbox/ControlDefinitions.h
Contains: Definitions of controls provided by the Control Manager
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __CONTROLDEFINITIONS__
#define __CONTROLDEFINITIONS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#ifndef __LISTS__
#include <HIToolbox/Lists.h>
#endif
#ifndef __MACHELP__
#include <HIToolbox/MacHelp.h>
#endif
#ifndef __MENUS__
#include <HIToolbox/Menus.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* ControlDefinitions.h
*
* Discussion:
* System software supplies a variety of controls for your
* applications to use. They are described herein.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> Control Definition ID<49>s */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Standard System 7 procIDs*/
enum {
pushButProc = 0,
checkBoxProc = 1,
radioButProc = 2,
scrollBarProc = 16,
popupMenuProc = 1008
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> Control Part Codes */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
enum {
kControlLabelPart = 1,
kControlMenuPart = 2,
kControlTrianglePart = 4,
kControlEditTextPart = 5, /* Appearance 1.0 and later*/
kControlPicturePart = 6, /* Appearance 1.0 and later*/
kControlIconPart = 7, /* Appearance 1.0 and later*/
kControlClockPart = 8, /* Appearance 1.0 and later*/
kControlListBoxPart = 24, /* Appearance 1.0 and later*/
kControlListBoxDoubleClickPart = 25, /* Appearance 1.0 and later*/
kControlImageWellPart = 26, /* Appearance 1.0 and later*/
kControlRadioGroupPart = 27, /* Appearance 1.0.2 and later*/
kControlButtonPart = 10,
kControlCheckBoxPart = 11,
kControlRadioButtonPart = 11,
kControlUpButtonPart = kAppearancePartUpButton,
kControlDownButtonPart = kAppearancePartDownButton,
kControlPageUpPart = kAppearancePartPageUpArea,
kControlPageDownPart = kAppearancePartPageDownArea,
kControlClockHourDayPart = 9, /* Appearance 1.1 and later*/
kControlClockMinuteMonthPart = 10, /* Appearance 1.1 and later*/
kControlClockSecondYearPart = 11, /* Appearance 1.1 and later*/
kControlClockAMPMPart = 12, /* Appearance 1.1 and later*/
kControlDataBrowserPart = 24, /* CarbonLib 1.0 and later*/
kControlDataBrowserDraggedPart = 25 /* CarbonLib 1.0 and later*/
};
/*--------------------------------------------------------------------------------------*/
/* <20> DEPRECATED */
/* */
/* All functions below this point are either deprecated (they continue to function */
/* but are not the most modern nor most efficient solution to a problem), or they are */
/* completely unavailable on Mac OS X. */
/*--------------------------------------------------------------------------------------*/
/*
<20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
<20> EDIT TEXT (CDEF 17)
<20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
Use the EditUnicodeText control to replace the Edit Text control. It uses the same
data tags as the Edit Text control.
*/
/* Edit Text proc IDs */
enum {
kControlEditTextProc = 272,
kControlEditTextPasswordProc = 274
};
/* proc IDs available with Appearance 1.1 or later */
enum {
kControlEditTextInlineInputProc = 276 /* Can't combine with the other variants*/
};
/* Control Kind Tag */
enum {
kControlKindEditText = 'etxt'
};
#if !__LP64__
/*
* CreateEditTextControl() *** DEPRECATED ***
*
* Deprecated:
* Use CreateEditUnicodeTextControl API instead.
*
* Summary:
* Creates a new edit text control.
*
* Discussion:
* This control is a legacy control. It is deprecated in favor of
* the EditUnicodeText control, which handles Unicode and draws its
* text using antialiasing.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window in which the control should be placed. May be NULL
* in 10.3 and later.
*
* boundsRect:
* The bounds of the control, in local coordinates of the window.
*
* text:
* The text of the control. May be NULL.
*
* isPassword:
* A Boolean indicating whether the field is to be used as a
* password field. Passing false indicates that the field is to
* display entered text normally. True means that the field will
* be used as a password field and any text typed into the field
* will be displayed only as bullets.
*
* useInlineInput:
* A Boolean indicating whether or not the control is to accept
* inline input. Pass true to to accept inline input, otherwise
* pass false.
*
* style:
* The control's font style, size, color, and so on. May be NULL.
*
* outControl:
* On exit, contains the new control (if noErr is returned as the
* result code).
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateEditTextControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef text, /* can be NULL */
Boolean isPassword,
Boolean useInlineInput,
const ControlFontStyleRec * style, /* can be NULL */
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/* ControlData tags supported only by the classic EditText control*/
#endif /* !__LP64__ */
enum {
kControlEditTextTEHandleTag = 'than', /* The TEHandle of the text edit record*/
kControlEditTextInlinePreUpdateProcTag = 'prup', /* TSMTEPreUpdateUPP and TSMTEPostUpdateUpp. For use with inline input variant...*/
kControlEditTextInlinePostUpdateProcTag = 'poup' /* ...The refCon parameter will contain the ControlRef.*/
};
/*
The classic EditText control also supports these tags defined for the EditUnicodeText control:
kControlEditTextLockedTag
kControlEditTextStyleTag
kControlEditTextFixedTextTag
kControlEditTextTextTag
kControlEditTextKeyFilterTag
kControlEditTextValidationProcTag
kControlEditTextSelectionTag
kControlEditTextKeyScriptBehaviorTag
kControlEditTextCFStringTag
kControlEditTextPasswordTag
kControlEditTextPasswordCFStringTag
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> PICTURE CONTROL (CDEF 19) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Value parameter should contain the ID of the picture you wish to display when */
/* creating controls of this type. If you don't want the control tracked at all, use */
/* the 'no track' variant. */
/* Picture control proc IDs */
enum {
kControlPictureProc = 304,
kControlPictureNoTrackProc = 305 /* immediately returns kControlPicturePart*/
};
/* Control Kind Tag */
enum {
kControlKindPicture = 'pict'
};
/* The HIObject class ID for the HIPictureView class. */
#define kHIPictureViewClassID CFSTR("com.apple.HIPictureView")
#if !__LP64__
/*
* CreatePictureControl()
*
* Summary:
* Creates a picture control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounding box of the control.
*
* content:
* The descriptor for the picture you want the control to display.
*
* dontTrack:
* A Boolean value indicating whether the control should hilite
* when it is clicked on. False means hilite and track the mouse.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreatePictureControl(
WindowRef window, /* can be NULL */
const Rect * boundsRect,
const ControlButtonContentInfo * content,
Boolean dontTrack,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by picture controls */
#endif /* !__LP64__ */
enum {
kControlPictureHandleTag = 'pich' /* PicHandle*/
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> LIST BOX (CDEF 22) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Lists use an auxiliary resource to define their format. The resource type used is */
/* 'ldes' and a definition for it can be found in Appearance.r. The resource ID for */
/* the ldes is passed in the 'value' parameter when creating the control. You may pass */
/* zero in value. This tells the List Box control to not use a resource. The list will */
/* be created with default values, and will use the standard LDEF (0). You can change */
/* the list by getting the list handle. You can set the LDEF to use by using the tag */
/* below (kControlListBoxLDEFTag) */
/* List Box proc IDs */
enum {
kControlListBoxProc = 352,
kControlListBoxAutoSizeProc = 353
};
/* Control Kind Tag */
enum {
kControlKindListBox = 'lbox'
};
#if !__LP64__
/*
* CreateListBoxControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateListBoxControl(
WindowRef window,
const Rect * boundsRect,
Boolean autoSize,
SInt16 numRows,
SInt16 numColumns,
Boolean horizScroll,
Boolean vertScroll,
SInt16 cellHeight,
SInt16 cellWidth,
Boolean hasGrowSpace,
const ListDefSpec * listDef,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by list box */
#endif /* !__LP64__ */
enum {
kControlListBoxListHandleTag = 'lhan', /* ListHandle*/
kControlListBoxKeyFilterTag = kControlKeyFilterTag, /* ControlKeyFilterUPP*/
kControlListBoxFontStyleTag = kControlFontStyleTag /* ControlFontStyleRec*/
};
/* New tags in 1.0.1 or later */
enum {
kControlListBoxDoubleClickTag = 'dblc', /* Boolean. Was last click a double-click?*/
kControlListBoxLDEFTag = 'ldef' /* SInt16. ID of LDEF to use.*/
};
/* Resource Types */
enum {
kControlListDescResType = 'ldes' /* used for list box control (Appearance 1.0 and later)*/
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> SCROLL TEXT BOX (CDEF 27) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This control implements a scrolling box of (non-editable) text. This is useful for */
/* credits in about boxes, etc. */
/* The standard version of this control has a scroll bar, but the autoscrolling */
/* variant does not. The autoscrolling variant needs two pieces of information to */
/* work: delay (in ticks) before the scrolling starts, and time (in ticks) between */
/* scrolls. It will scroll one pixel at a time, unless changed via SetControlData. */
/* */
/* Parameter What Goes Here */
/* <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> */
/* Value Resource ID of 'TEXT'/'styl' content. */
/* Min Scroll start delay (in ticks) . */
/* Max Delay (in ticks) between scrolls. */
/* */
/* NOTE: This control is only available with Appearance 1.1. */
/* Scroll Text Box Proc IDs */
enum {
kControlScrollTextBoxProc = 432,
kControlScrollTextBoxAutoScrollProc = 433
};
/* Control Kind Tag */
enum {
kControlKindScrollingTextBox = 'stbx'
};
#if !__LP64__
/*
* CreateScrollingTextBoxControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateScrollingTextBoxControl(
WindowRef window,
const Rect * boundsRect,
SInt16 contentResID,
Boolean autoScroll,
UInt32 delayBeforeAutoScroll,
UInt32 delayBetweenAutoScroll,
UInt16 autoScrollAmount,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by Scroll Text Box */
#endif /* !__LP64__ */
enum {
kControlScrollTextBoxDelayBeforeAutoScrollTag = 'stdl', /* UInt32 (ticks until autoscrolling starts)*/
kControlScrollTextBoxDelayBetweenAutoScrollTag = 'scdl', /* UInt32 (ticks between scrolls)*/
kControlScrollTextBoxAutoScrollAmountTag = 'samt', /* UInt16 (pixels per scroll) -- defaults to 1*/
kControlScrollTextBoxContentsTag = 'tres', /* SInt16 (resource ID of 'TEXT'/'styl') -- write only!*/
kControlScrollTextBoxAnimatingTag = 'anim' /* Boolean (whether the text box should auto-scroll)*/
};
#if OLDROUTINENAMES
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> OLDROUTINENAMES */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
enum {
inLabel = kControlLabelPart,
inMenu = kControlMenuPart,
inTriangle = kControlTrianglePart,
inButton = kControlButtonPart,
inCheckBox = kControlCheckBoxPart,
inUpButton = kControlUpButtonPart,
inDownButton = kControlDownButtonPart,
inPageUp = kControlPageUpPart,
inPageDown = kControlPageDownPart
};
enum {
kInLabelControlPart = kControlLabelPart,
kInMenuControlPart = kControlMenuPart,
kInTriangleControlPart = kControlTrianglePart,
kInButtonControlPart = kControlButtonPart,
kInCheckBoxControlPart = kControlCheckBoxPart,
kInUpButtonControlPart = kControlUpButtonPart,
kInDownButtonControlPart = kControlDownButtonPart,
kInPageUpControlPart = kControlPageUpPart,
kInPageDownControlPart = kControlPageDownPart
};
#endif /* OLDROUTINENAMES */
#ifdef __cplusplus
}
#endif
#endif /* __CONTROLDEFINITIONS__ */

View File

@@ -0,0 +1,116 @@
/*
File: ControlDefinitions.r
Contains: Definitions of controls provided by the Control Manager
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __CONTROLDEFINITIONS_R__
#define __CONTROLDEFINITIONS_R__
#ifndef __CONTROLS_R__
#include <HIToolbox/Controls.r>
#endif
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define pushButProc 0
#define checkBoxProc 1
#define radioButProc 2
#define scrollBarProc 16
#define popupMenuProc 1008
#define kControlLabelPart 1
#define kControlMenuPart 2
#define kControlTrianglePart 4
#define kControlEditTextPart 5 /* Appearance 1.0 and later */
#define kControlPicturePart 6 /* Appearance 1.0 and later */
#define kControlIconPart 7 /* Appearance 1.0 and later */
#define kControlClockPart 8 /* Appearance 1.0 and later */
#define kControlListBoxPart 24 /* Appearance 1.0 and later */
#define kControlListBoxDoubleClickPart 25 /* Appearance 1.0 and later */
#define kControlImageWellPart 26 /* Appearance 1.0 and later */
#define kControlRadioGroupPart 27 /* Appearance 1.0.2 and later */
#define kControlButtonPart 10
#define kControlCheckBoxPart 11
#define kControlRadioButtonPart 11
#define kControlUpButtonPart 20
#define kControlDownButtonPart 21
#define kControlPageUpPart 22
#define kControlPageDownPart 23
#define kControlClockHourDayPart 9 /* Appearance 1.1 and later */
#define kControlClockMinuteMonthPart 10 /* Appearance 1.1 and later */
#define kControlClockSecondYearPart 11 /* Appearance 1.1 and later */
#define kControlClockAMPMPart 12 /* Appearance 1.1 and later */
#define kControlDataBrowserPart 24 /* CarbonLib 1.0 and later */
#define kControlDataBrowserDraggedPart 25 /* CarbonLib 1.0 and later */
#define kControlEditTextProc 272
#define kControlEditTextPasswordProc 274
#define kControlEditTextInlineInputProc 276 /* Can't combine with the other variants */
#define kControlKindEditText 'etxt'
#define kControlPictureProc 304
#define kControlPictureNoTrackProc 305 /* immediately returns kControlPicturePart */
#define kControlKindPicture 'pict'
#define kControlPictureHandleTag 'pich' /* PicHandle */
#define kControlListBoxProc 352
#define kControlListBoxAutoSizeProc 353
#define kControlKindListBox 'lbox'
#define kControlListBoxListHandleTag 'lhan' /* ListHandle */
#define kControlListBoxKeyFilterTag 'fltr' /* ControlKeyFilterUPP */
#define kControlListBoxFontStyleTag 'font' /* ControlFontStyleRec */
#define kControlListBoxDoubleClickTag 'dblc' /* Boolean. Was last click a double-click? */
#define kControlListBoxLDEFTag 'ldef' /* SInt16. ID of LDEF to use. */
#define kControlListDescResType 'ldes' /* used for list box control (Appearance 1.0 and later) */
#define kControlScrollTextBoxProc 432
#define kControlScrollTextBoxAutoScrollProc 433
#define kControlKindScrollingTextBox 'stbx'
#define kControlScrollTextBoxDelayBeforeAutoScrollTag 'stdl' /* UInt32 (ticks until autoscrolling starts) */
#define kControlScrollTextBoxDelayBetweenAutoScrollTag 'scdl' /* UInt32 (ticks between scrolls) */
#define kControlScrollTextBoxAutoScrollAmountTag 'samt' /* UInt16 (pixels per scroll) -- defaults to 1 */
#define kControlScrollTextBoxContentsTag 'tres' /* SInt16 (resource ID of 'TEXT'/'styl') -- write only! */
#define kControlScrollTextBoxAnimatingTag 'anim' /* Boolean (whether the text box should auto-scroll) */
/*--------------------------ldes <20> List Box Description Template------------------------*/
/* Used in conjunction with the list box control. */
type 'ldes'
{
switch
{
case versionZero:
key integer = 0; /* version */
integer; /* Rows */
integer; /* Columns */
integer; /* Cell Height */
integer; /* Cell Width */
byte noVertScroll, hasVertScroll; /* Vert Scroll */
fill byte; /* Filler Byte */
byte noHorizScroll, hasHorizScroll; /* Horiz Scroll */
fill byte; /* Filler Byte */
integer; /* LDEF Res ID */
byte noGrowSpace, hasGrowSpace; /* HasGrow? */
fill byte;
};
};
#endif /* __CONTROLDEFINITIONS_R__ */

View File

@@ -0,0 +1,266 @@
/*
File: Controls.r
Contains: Control Manager interfaces
Copyright: <20> 1985-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __CONTROLS_R__
#define __CONTROLS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlNoVariant 0 /* No variant */
#define kControlUsesOwningWindowsFontVariant 0x08 /* Control uses owning windows font to display text */
#define kControlNoPart 0
#define kControlIndicatorPart 129
#define kControlDisabledPart 254
#define kControlInactivePart 255
#define kControlEntireControl 0
#define kControlStructureMetaPart (-1)
#define kControlContentMetaPart (-2)
#define kControlOpaqueMetaPart (-3)
#define kControlClickableMetaPart (-4)
#define kControlFocusNoPart 0 /* tells control to clear its focus */
#define kControlFocusNextPart (-1) /* tells control to focus on the next part */
#define kControlFocusPrevPart (-2) /* tells control to focus on the previous part */
#define kControlCollectionTagBounds 'boun'
#define kControlCollectionTagValue 'valu'
#define kControlCollectionTagMinimum 'min '
#define kControlCollectionTagMaximum 'max '
#define kControlCollectionTagViewSize 'view'
#define kControlCollectionTagVisibility 'visi'
#define kControlCollectionTagRefCon 'refc'
#define kControlCollectionTagTitle 'titl'
#define kControlCollectionTagUnicodeTitle 'uttl'
#define kControlCollectionTagIDSignature 'idsi'
#define kControlCollectionTagIDID 'idid'
#define kControlCollectionTagCommand 'cmd '
#define kControlCollectionTagVarCode 'varc'
#define kControlContentTextOnly 0
#define kControlNoContent 0
#define kControlContentIconSuiteRes 1
#define kControlContentCIconRes 2
#define kControlContentPictRes 3
#define kControlContentICONRes 4
#define kControlContentAlertIconRes 5
#define kControlContentIconSuiteHandle 129
#define kControlContentCIconHandle 130
#define kControlContentPictHandle 131
#define kControlContentIconRef 132
#define kControlContentICON 133
#define kControlContentCGImageRef 134
#define kControlKeyScriptBehaviorAllowAnyScript 'any ' /* leaves the current keyboard alone and allows user to change the keyboard. */
#define kControlKeyScriptBehaviorPrefersRoman 'prmn' /* switches the keyboard to roman, but allows them to change it as desired. */
#define kControlKeyScriptBehaviorRequiresRoman 'rrmn' /* switches the keyboard to roman and prevents the user from changing it. */
#define kControlFontBigSystemFont (-1) /* force to big system font */
#define kControlFontSmallSystemFont (-2) /* force to small system font */
#define kControlFontSmallBoldSystemFont (-3) /* force to small bold system font */
#define kControlFontViewSystemFont (-4) /* force to views system font (DataBrowser control only) */
#define kControlFontMiniSystemFont (-5) /* force to mini system font */
#define kControlUseFontMask 0x0001
#define kControlUseFaceMask 0x0002
#define kControlUseSizeMask 0x0004
#define kControlUseForeColorMask 0x0008
#define kControlUseBackColorMask 0x0010
#define kControlUseModeMask 0x0020
#define kControlUseJustMask 0x0040
#define kControlUseAllMask 0x00FF
#define kControlAddFontSizeMask 0x0100
#define kControlAddToMetaFontMask 0x0200 /* Available in Appearance 1.1 or later */
#define kControlUseThemeFontIDMask 0x0080 /* Available in Mac OS X or later */
#define kDoNotActivateAndIgnoreClick 0 /* probably never used. here for completeness. */
#define kDoNotActivateAndHandleClick 1 /* let the control handle the click while the window is still in the background. */
#define kActivateAndIgnoreClick 2 /* control doesn't want to respond directly to the click, but window should still be brought forward. */
#define kActivateAndHandleClick 3 /* control wants to respond to the click, but only after the window has been activated. */
#define kControlFontStyleTag 'font'
#define kControlKeyFilterTag 'fltr'
#define kControlKindTag 'kind'
#define kControlSizeTag 'size'
#define kControlContentTag 'cont'
#define kControlThemeTextFontTag 'thft'
#define kControlThemeTextHorizontalFlushTag 'thhf'
#define kControlThemeTextVerticalFlushTag 'thvf'
#define kControlThemeTextTruncationTag 'thtt'
#define kControlThemeTextInfoTag 'thti'
#define kControlSupportsGhosting 0x01
#define kControlSupportsEmbedding 0x02
#define kControlSupportsFocus 0x04
#define kControlWantsIdle 0x08
#define kControlWantsActivate 0x10
#define kControlHandlesTracking 0x20
#define kControlSupportsDataAccess 0x40
#define kControlHasSpecialBackground 0x80
#define kControlGetsFocusOnClick 0x0100
#define kControlSupportsCalcBestRect 0x0200
#define kControlSupportsLiveFeedback 0x0400
#define kControlHasRadioBehavior 0x0800 /* Available in Appearance 1.0.1 or later */
#define kControlSupportsDragAndDrop 0x1000 /* Available in Carbon */
#define kControlAutoToggles 0x4000 /* Available in Appearance 1.1 or later */
#define kControlSupportsGetRegion 0x00020000 /* Available in Appearance 1.1 or later */
#define kControlSupportsFlattening 0x00080000 /* Available in Carbon */
#define kControlSupportsSetCursor 0x00100000 /* Available in Carbon */
#define kControlSupportsContextualMenus 0x00200000 /* Available in Carbon */
#define kControlSupportsClickActivation 0x00400000 /* Available in Carbon */
#define kControlIdlesWithTimer 0x00800000 /* Available in Carbon - this bit indicates that the control animates automatically */
#define kControlInvertsUpDownValueMeaning 0x01000000
#if !__LP64__
#define drawCntl 0
#define testCntl 1
#define calcCRgns 2
#define initCntl 3 /* Param is Collection, result is OSStatus */
#define dispCntl 4
#define posCntl 5
#define thumbCntl 6
#define dragCntl 7
#define autoTrack 8
#define calcCntlRgn 10
#define calcThumbRgn 11
#define drawThumbOutline 12
#define kControlMsgDrawGhost 13
#define kControlMsgCalcBestRect 14 /* Calculate best fitting rectangle for control */
#define kControlMsgHandleTracking 15
#define kControlMsgFocus 16 /* param indicates action. */
#define kControlMsgKeyDown 17
#define kControlMsgIdle 18
#define kControlMsgGetFeatures 19
#define kControlMsgSetData 20
#define kControlMsgGetData 21
#define kControlMsgActivate 22
#define kControlMsgSetUpBackground 23
#define kControlMsgCalcValueFromPos 26
#define kControlMsgTestNewMsgSupport 27 /* See if this control supports new messaging */
#define kControlMsgSubValueChanged 25 /* Available in Appearance 1.0.1 or later */
#define kControlMsgSubControlAdded 28 /* Available in Appearance 1.0.1 or later */
#define kControlMsgSubControlRemoved 29 /* Available in Appearance 1.0.1 or later */
#define kControlMsgApplyTextColor 30 /* Available in Appearance 1.1 or later */
#define kControlMsgGetRegion 31 /* Available in Appearance 1.1 or later */
#define kControlMsgFlatten 32 /* Available in Carbon. Param is Collection. */
#define kControlMsgSetCursor 33 /* Available in Carbon. Param is ControlSetCursorRec */
#define kControlMsgDragEnter 38 /* Available in Carbon. Param is DragRef, result is boolean indicating acceptibility of drag. */
#define kControlMsgDragLeave 39 /* Available in Carbon. As above. */
#define kControlMsgDragWithin 40 /* Available in Carbon. As above. */
#define kControlMsgDragReceive 41 /* Available in Carbon. Param is DragRef, result is OSStatus indicating success/failure. */
#define kControlMsgDisplayDebugInfo 46 /* Available in Carbon on X. */
#define kControlMsgContextualMenuClick 47 /* Available in Carbon. Param is ControlContextualMenuClickRec */
#define kControlMsgGetClickActivation 48 /* Available in Carbon. Param is ControlClickActivationRec */
#endif /* !__LP64__ */
#define kControlSizeNormal 0
#define kControlSizeSmall 1
#define kControlSizeLarge 2
#define kControlSizeMini 3
#define kControlSizeAuto 0xFFFF
#define kDrawControlEntireControl 0
#define kDrawControlIndicatorOnly 129
#if !__LP64__
#define kDragControlEntireControl 0
#define kDragControlIndicator 1
#endif /* !__LP64__ */
#if !__LP64__
#define kControlSupportsNewMessages ' ok '
#endif /* !__LP64__ */
#define kControlKeyFilterBlockKey 0
#define kControlKeyFilterPassKey 1
#define kControlKindSignatureApple 'appl'
#if !__LP64__
/*--------------------------cctb <20> Control Color old Lookup Table----------------------*/
#ifdef oldTemp
type 'cctb' {
unsigned hex longint; /* CCSeed */
integer; /* ccReserved */
integer = $$Countof(ColorSpec) - 1; /* ctSize */
wide array ColorSpec {
integer cFrameColor, /* partcode */
cBodyColor,
cTextColor,
cElevatorColor;
unsigned integer; /* RGB: red */
unsigned integer; /* green */
unsigned integer; /* blue */
};
};
#else
type 'cctb' {
unsigned hex longint = 0; /* CCSeed */
integer = 0; /* ccReserved */
integer = $$Countof(ColorSpec) - 1; /* ctSize */
wide array ColorSpec {
integer cFrameColor, /* partcode */
cBodyColor,
cTextColor,
cElevatorColor,
cFillPatColor,
cArrowsLight,
cArrowsDark,
cThumbLight,
cThumbDark,
cHiliteLight,
cHiliteDark,
cTitleBarLight,
cTitleBarDark,
cTingeLight,
cTingeDark;
unsigned integer; /* RGB: red */
unsigned integer; /* green */
unsigned integer; /* blue */
};
};
#endif
/*----------------------------CNTL <20> Control Template-----------------------------------*/
type 'CNTL' {
rect; /* Bounds */
integer; /* Value */
byte invisible, visible; /* visible */
fill byte;
integer; /* Max */
integer; /* Min */
integer pushButProc, /* ProcID */
checkBoxProc,
radioButProc,
pushButProcUseWFont = 8,
checkBoxProcUseWFont,
radioButProcUseWFont,
scrollBarProc = 16;
longint; /* RefCon */
pstring; /* Title */
};
#define popupMenuCDEFproc 1008 /* ProcID 1008 = 16 * 63 */
#endif /* !__LP64__ */
#endif /* __CONTROLS_R__ */

View File

@@ -0,0 +1,347 @@
/*
File: Dialogs.r
Contains: Dialog Manager interfaces.
Copyright: <20> 1985-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __DIALOGS_R__
#define __DIALOGS_R__
#ifndef __MACWINDOWS_R__
#include <HIToolbox/MacWindows.r>
#endif
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
/* Alert types to pass into StandardAlert */
#define kAlertStopAlert 0
#define kAlertNoteAlert 1
#define kAlertCautionAlert 2
#define kAlertPlainAlert 3
#define kAlertDefaultOKText (-1) /* "OK" */
#define kAlertDefaultCancelText (-1) /* "Cancel" */
#define kAlertDefaultOtherText (-1) /* "Don't Save" */
#define kAlertStdAlertOKButton 1
#define kAlertStdAlertCancelButton 2
#define kAlertStdAlertOtherButton 3
#define kAlertStdAlertHelpButton 4
#define kDialogFlagsUseThemeBackground 0x01
#define kDialogFlagsUseControlHierarchy 0x02
#define kDialogFlagsHandleMovableModal 0x04
#define kDialogFlagsUseThemeControls 0x08
#define kDialogFlagsUseCompositing 0x0100
/* Alert Flags for use in alrx resource */
#define kAlertFlagsUseThemeBackground 0x01
#define kAlertFlagsUseControlHierarchy 0x02
#define kAlertFlagsAlertIsMovable 0x04
#define kAlertFlagsUseThemeControls 0x08
#define kAlertFlagsUseCompositing 0x0100
#define kDialogFontNoFontStyle 0
#define kDialogFontUseFontMask 0x0001
#define kDialogFontUseFaceMask 0x0002
#define kDialogFontUseSizeMask 0x0004
#define kDialogFontUseForeColorMask 0x0008
#define kDialogFontUseBackColorMask 0x0010
#define kDialogFontUseModeMask 0x0020
#define kDialogFontUseJustMask 0x0040
#define kDialogFontUseAllMask 0x00FF
#define kDialogFontAddFontSizeMask 0x0100
#define kDialogFontUseFontNameMask 0x0200
#define kDialogFontAddToMetaFontMask 0x0400
#define kDialogFontUseThemeFontIDMask 0x0080
#define kHICommandOther 'othr' /* sent by standard sheet dialogs when the "other" button is pressed */
#define kStdCFStringAlertVersionOne 1
#define kStdCFStringAlertVersionTwo 2
#define kStdAlertDoNotDisposeSheet 0x01
#define kStdAlertDoNotAnimateOnDefault 0x02
#define kStdAlertDoNotAnimateOnCancel 0x04
#define kStdAlertDoNotAnimateOnOther 0x08
#define kStdAlertDoNotCloseOnHelp 0x10
/*----------------------------wctb <20> Alert Color Lookup Table--------------------------*/
type 'actb' as 'wctb';
/*----------------------------ALRT <20> Alert Template-------------------------------------*/
/*
ALRT_RezTemplateVersion:
0 - original
1 - additional positioning info at end <-- default
*/
#ifndef ALRT_RezTemplateVersion
#define ALRT_RezTemplateVersion 1
#endif
type 'ALRT' {
rect; /* boundsRect */
integer; /* 'DITL' ID */
/* NOTE: the stages are ordered 4, 3, 2, 1 */
wide array [4] {
boolean OK, Cancel; /* Bold Outline */
boolean invisible, visible; /* Draw Alert */
unsigned bitstring[2] silent = 0
sound1, sound2, sound3; /* Beeps */
};
#if ALRT_RezTemplateVersion == 1
/* The following are alert positioning options used by System 7.0 and later */
unsigned integer noAutoCenter = 0x0000,
centerMainScreen = 0x280a,
alertPositionMainScreen = 0x300a,
staggerMainScreen = 0x380a,
centerParentWindow = 0xa80a,
alertPositionParentWindow = 0xb00a,
staggerParentWindow = 0xb80a,
centerParentWindowScreen = 0x680a,
alertPositionParentWindowScreen = 0x700a,
staggerParentWindowScreen = 0x780a;
#endif
};
/* stages for ALRT */
#define silentStage OK, visible, silent
#define silentStages { silentStage; silentStage; silentStage; silentStage; }
#define beepStage OK, visible, sound1
#define beepStages { beepStage; beepStage; beepStage; beepStage; }
/*----------------------------dctb <20> Dialog Color Lookup Table--------------------------*/
type 'dctb' as 'wctb';
/*----------------------------DITL <20> Dialog Item List-----------------------------------*/
type 'DITL' {
integer = $$CountOf(DITLarray) - 1; /* Array size */
wide array DITLarray {
fill long;
rect; /* Item bounds */
switch {
case HelpItem: /* Help Mgr type item */
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 1; /* this is a new type = 1 */
switch {
case HMScanhdlg:
byte = 4; /* sizeola */
key int = 1; /* key value */
integer; /* resource ID */
case HMScanhrct:
byte = 4; /* sizeola */
key int = 2; /* key value */
integer; /* resource ID */
case HMScanAppendhdlg:
byte = 6; /* sizeola */
key int = 8; /* key value */
integer; /* resource ID */
integer; /* offset (zero based) */
};
case Button:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 4;
pstring; /* Title */
case CheckBox:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 5;
pstring; /* Title */
case RadioButton:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 6;
pstring; /* Title */
case Control:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 7;
byte = 2;
integer; /* 'CNTL' ID */
case StaticText:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 8;
pstring; /* Text */
case EditText:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 16;
pstring; /* Text */
case Icon:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 32;
byte = 2;
integer; /* 'ICON' ID */
case Picture:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 64;
byte = 2;
integer; /* 'PICT' ID */
case UserItem:
boolean enabled,disabled; /* Enable flag */
key bitstring[7] = 0;
byte = 0;
};
align word;
};
};
/*----------------------------DLOG <20> Dialog Template------------------------------------*/
/*
DLOG_RezTemplateVersion:
0 - original
1 - additional positioning info at end <-- default
*/
#ifndef DLOG_RezTemplateVersion
#define DLOG_RezTemplateVersion 1
#endif
type 'DLOG' {
rect; /* boundsRect */
integer documentProc, /* procID */
dBoxProc,
plainDBox,
altDBoxProc,
noGrowDocProc,
movableDBoxProc,
zoomDocProc = 8,
zoomNoGrow = 12;
byte invisible, visible; /* visible */
fill byte;
byte noGoAway, goAway; /* goAway */
fill byte;
unsigned hex longint; /* refCon */
integer; /* 'DITL' ID */
pstring; /* title */
#if DLOG_RezTemplateVersion == 1
/* The following are window positioning options used by System 7.0 and later */
align word;
unsigned integer noAutoCenter = 0x0000,
centerMainScreen = 0x280a,
alertPositionMainScreen = 0x300a,
staggerMainScreen = 0x380a,
centerParentWindow = 0xa80a,
alertPositionParentWindow = 0xb00a,
staggerParentWindow = 0xb80a,
centerParentWindowScreen = 0x680a,
alertPositionParentWindowScreen = 0x700a,
staggerParentWindowScreen = 0x780a;
#endif
};
/*----------------------------alrx <20> Extended Alert Template---------------------------*/
type 'alrx'
{
switch
{
case versionZero:
key integer=0;
unsigned longint; /* flags */
longint; /* refCon */
byte kUseClassicWindow,
kUseThemeWindow; /* Window type */
fill byte; /* filler */
fill long; /* filler */
fill long; /* filler */
fill long; /* filler */
fill long; /* filler */
pstring; /* title (movable only) */
case versionOne:
key integer=1;
unsigned longint; /* flags */
longint; /* refCon */
byte kUseClassicWindow,
kUseThemeWindow; /* Window type */
fill byte; /* filler */
pstring; /* title (movable only) */
};
};
/*----------------------------dlgx <20> Extended Dialog Template---------------------------*/
type 'dlgx'
{
switch
{
case versionZero:
key integer=0;
unsigned longint; /* flags */
};
};
/*-----------------------------dftb <20> Dialog Control Font Table--------------------------*/
type 'dftb'
{
switch
{
case versionZero:
key integer = 0; /* version */
integer = $$Countof(FontStyle);
array FontStyle
{
switch
{
case skipItem:
key integer=0;
case dataItem:
key integer=1;integer; /* Flags */
integer; /* Font ID */
integer; /* Font Size */
integer; /* Font Style */
integer; /* Text Mode */
integer; /* Justification */
unsigned integer; /* ForeColor: red */
unsigned integer; /* green */
unsigned integer; /* blue */
unsigned integer; /* BackColor: red */
unsigned integer; /* green */
unsigned integer; /* blue */
pstring; /* Font Name */
};
};
};
};
#endif /* __DIALOGS_R__ */

View File

@@ -0,0 +1,909 @@
/*
File: HIToolbox/Events.h
Contains: Event Manager Interfaces.
Copyright: <20> 1985-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __EVENTS__
#define __EVENTS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
typedef UInt16 EventKind;
typedef UInt16 EventMask;
enum {
nullEvent = 0,
mouseDown = 1,
mouseUp = 2,
keyDown = 3,
keyUp = 4,
autoKey = 5,
updateEvt = 6,
diskEvt = 7, /* Not sent in Carbon. See kEventClassVolume in CarbonEvents.h*/
activateEvt = 8,
osEvt = 15,
kHighLevelEvent = 23
};
enum {
mDownMask = 1 << mouseDown, /* mouse button pressed*/
mUpMask = 1 << mouseUp, /* mouse button released*/
keyDownMask = 1 << keyDown, /* key pressed*/
keyUpMask = 1 << keyUp, /* key released*/
autoKeyMask = 1 << autoKey, /* key repeatedly held down*/
updateMask = 1 << updateEvt, /* window needs updating*/
diskMask = 1 << diskEvt, /* disk inserted*/
activMask = 1 << activateEvt, /* activate/deactivate window*/
highLevelEventMask = 0x0400, /* high-level events (includes AppleEvents)*/
osMask = 1 << osEvt, /* operating system events (suspend, resume)*/
everyEvent = 0xFFFF /* all of the above*/
};
enum {
charCodeMask = 0x000000FF,
keyCodeMask = 0x0000FF00,
adbAddrMask = 0x00FF0000,
osEvtMessageMask = (UInt32)0xFF000000
};
enum {
/* OS event messages. Event (sub)code is in the high byte of the message field.*/
mouseMovedMessage = 0x00FA,
suspendResumeMessage = 0x0001
};
enum {
resumeFlag = 1 /* Bit 0 of message indicates resume vs suspend*/
};
#if CALL_NOT_IN_CARBON
/* convertClipboardFlag is not ever set under Carbon. This is because scrap conversion is */
/* not tied to suspend/resume events any longer. Your application should instead use the */
/* scrap promise mechanism and fulfill scrap requests only when your promise keeper proc */
/* is called. If you need to know if the scrap has changed, you can cache the last */
/* ScrapRef you received and compare it with the current ScrapRef */
enum {
convertClipboardFlag = 2 /* Bit 1 in resume message indicates clipboard change*/
};
#endif /* CALL_NOT_IN_CARBON */
/*
CARBON ALERT! BATTLESTATIONS!
The EventModifiers bits defined here are also used in the newer Carbon Event
key modifiers parameters. There are two main differences:
1) The Carbon key modifiers parameter is a UInt32, not a UInt16. Never try to
extract the key modifiers parameter from a Carbon Event into an EventModifiers
type. You will probably get your stack trashed.
2) The Carbon key modifiers is just that: key modifiers. That parameter will
never contain the button state bit.
*/
typedef UInt16 EventModifiers;
enum {
/* modifiers */
activeFlagBit = 0, /* activate? (activateEvt and mouseDown)*/
btnStateBit = 7, /* state of button?*/
cmdKeyBit = 8, /* command key down?*/
shiftKeyBit = 9, /* shift key down?*/
alphaLockBit = 10, /* alpha lock down?*/
optionKeyBit = 11, /* option key down?*/
controlKeyBit = 12, /* control key down?*/
rightShiftKeyBit = 13, /* right shift key down? Not supported on Mac OS X.*/
rightOptionKeyBit = 14, /* right Option key down? Not supported on Mac OS X.*/
rightControlKeyBit = 15 /* right Control key down? Not supported on Mac OS X.*/
};
enum {
activeFlag = 1 << activeFlagBit,
btnState = 1 << btnStateBit,
cmdKey = 1 << cmdKeyBit,
shiftKey = 1 << shiftKeyBit,
alphaLock = 1 << alphaLockBit,
optionKey = 1 << optionKeyBit,
controlKey = 1 << controlKeyBit,
rightShiftKey = 1 << rightShiftKeyBit, /* Not supported on Mac OS X.*/
rightOptionKey = 1 << rightOptionKeyBit, /* Not supported on Mac OS X.*/
rightControlKey = 1 << rightControlKeyBit /* Not supported on Mac OS X.*/
};
/* MacRoman character codes*/
enum {
kNullCharCode = 0,
kHomeCharCode = 1,
kEnterCharCode = 3,
kEndCharCode = 4,
kHelpCharCode = 5,
kBellCharCode = 7,
kBackspaceCharCode = 8,
kTabCharCode = 9,
kLineFeedCharCode = 10,
kVerticalTabCharCode = 11,
kPageUpCharCode = 11,
kFormFeedCharCode = 12,
kPageDownCharCode = 12,
kReturnCharCode = 13,
kFunctionKeyCharCode = 16,
kCommandCharCode = 17, /* glyph available only in system fonts*/
kCheckCharCode = 18, /* glyph available only in system fonts*/
kDiamondCharCode = 19, /* glyph available only in system fonts*/
kAppleLogoCharCode = 20, /* glyph available only in system fonts*/
kEscapeCharCode = 27,
kClearCharCode = 27,
kLeftArrowCharCode = 28,
kRightArrowCharCode = 29,
kUpArrowCharCode = 30,
kDownArrowCharCode = 31,
kSpaceCharCode = 32,
kDeleteCharCode = 127,
kBulletCharCode = 165,
kNonBreakingSpaceCharCode = 202
};
/* useful Unicode code points*/
enum {
kShiftUnicode = 0x21E7, /* Unicode UPWARDS WHITE ARROW*/
kControlUnicode = 0x2303, /* Unicode UP ARROWHEAD*/
kOptionUnicode = 0x2325, /* Unicode OPTION KEY*/
kCommandUnicode = 0x2318, /* Unicode PLACE OF INTEREST SIGN*/
kPencilUnicode = 0x270E, /* Unicode LOWER RIGHT PENCIL; actually pointed left until Mac OS X 10.3*/
kPencilLeftUnicode = 0xF802, /* Unicode LOWER LEFT PENCIL; available in Mac OS X 10.3 and later*/
kCheckUnicode = 0x2713, /* Unicode CHECK MARK*/
kDiamondUnicode = 0x25C6, /* Unicode BLACK DIAMOND*/
kBulletUnicode = 0x2022, /* Unicode BULLET*/
kAppleLogoUnicode = 0xF8FF /* Unicode APPLE LOGO*/
};
/*
* Summary:
* Virtual keycodes
*
* Discussion:
* These constants are the virtual keycodes defined originally in
* Inside Mac Volume V, pg. V-191. They identify physical keys on a
* keyboard. Those constants with "ANSI" in the name are labeled
* according to the key position on an ANSI-standard US keyboard.
* For example, kVK_ANSI_A indicates the virtual keycode for the key
* with the letter 'A' in the US keyboard layout. Other keyboard
* layouts may have the 'A' key label on a different physical key;
* in this case, pressing 'A' will generate a different virtual
* keycode.
*/
enum {
kVK_ANSI_A = 0x00,
kVK_ANSI_S = 0x01,
kVK_ANSI_D = 0x02,
kVK_ANSI_F = 0x03,
kVK_ANSI_H = 0x04,
kVK_ANSI_G = 0x05,
kVK_ANSI_Z = 0x06,
kVK_ANSI_X = 0x07,
kVK_ANSI_C = 0x08,
kVK_ANSI_V = 0x09,
kVK_ANSI_B = 0x0B,
kVK_ANSI_Q = 0x0C,
kVK_ANSI_W = 0x0D,
kVK_ANSI_E = 0x0E,
kVK_ANSI_R = 0x0F,
kVK_ANSI_Y = 0x10,
kVK_ANSI_T = 0x11,
kVK_ANSI_1 = 0x12,
kVK_ANSI_2 = 0x13,
kVK_ANSI_3 = 0x14,
kVK_ANSI_4 = 0x15,
kVK_ANSI_6 = 0x16,
kVK_ANSI_5 = 0x17,
kVK_ANSI_Equal = 0x18,
kVK_ANSI_9 = 0x19,
kVK_ANSI_7 = 0x1A,
kVK_ANSI_Minus = 0x1B,
kVK_ANSI_8 = 0x1C,
kVK_ANSI_0 = 0x1D,
kVK_ANSI_RightBracket = 0x1E,
kVK_ANSI_O = 0x1F,
kVK_ANSI_U = 0x20,
kVK_ANSI_LeftBracket = 0x21,
kVK_ANSI_I = 0x22,
kVK_ANSI_P = 0x23,
kVK_ANSI_L = 0x25,
kVK_ANSI_J = 0x26,
kVK_ANSI_Quote = 0x27,
kVK_ANSI_K = 0x28,
kVK_ANSI_Semicolon = 0x29,
kVK_ANSI_Backslash = 0x2A,
kVK_ANSI_Comma = 0x2B,
kVK_ANSI_Slash = 0x2C,
kVK_ANSI_N = 0x2D,
kVK_ANSI_M = 0x2E,
kVK_ANSI_Period = 0x2F,
kVK_ANSI_Grave = 0x32,
kVK_ANSI_KeypadDecimal = 0x41,
kVK_ANSI_KeypadMultiply = 0x43,
kVK_ANSI_KeypadPlus = 0x45,
kVK_ANSI_KeypadClear = 0x47,
kVK_ANSI_KeypadDivide = 0x4B,
kVK_ANSI_KeypadEnter = 0x4C,
kVK_ANSI_KeypadMinus = 0x4E,
kVK_ANSI_KeypadEquals = 0x51,
kVK_ANSI_Keypad0 = 0x52,
kVK_ANSI_Keypad1 = 0x53,
kVK_ANSI_Keypad2 = 0x54,
kVK_ANSI_Keypad3 = 0x55,
kVK_ANSI_Keypad4 = 0x56,
kVK_ANSI_Keypad5 = 0x57,
kVK_ANSI_Keypad6 = 0x58,
kVK_ANSI_Keypad7 = 0x59,
kVK_ANSI_Keypad8 = 0x5B,
kVK_ANSI_Keypad9 = 0x5C
};
/* keycodes for keys that are independent of keyboard layout*/
enum {
kVK_Return = 0x24,
kVK_Tab = 0x30,
kVK_Space = 0x31,
kVK_Delete = 0x33,
kVK_Escape = 0x35,
kVK_Command = 0x37,
kVK_Shift = 0x38,
kVK_CapsLock = 0x39,
kVK_Option = 0x3A,
kVK_Control = 0x3B,
kVK_RightCommand = 0x36,
kVK_RightShift = 0x3C,
kVK_RightOption = 0x3D,
kVK_RightControl = 0x3E,
kVK_Function = 0x3F,
kVK_F17 = 0x40,
kVK_VolumeUp = 0x48,
kVK_VolumeDown = 0x49,
kVK_Mute = 0x4A,
kVK_F18 = 0x4F,
kVK_F19 = 0x50,
kVK_F20 = 0x5A,
kVK_F5 = 0x60,
kVK_F6 = 0x61,
kVK_F7 = 0x62,
kVK_F3 = 0x63,
kVK_F8 = 0x64,
kVK_F9 = 0x65,
kVK_F11 = 0x67,
kVK_F13 = 0x69,
kVK_F16 = 0x6A,
kVK_F14 = 0x6B,
kVK_F10 = 0x6D,
kVK_F12 = 0x6F,
kVK_F15 = 0x71,
kVK_Help = 0x72,
kVK_Home = 0x73,
kVK_PageUp = 0x74,
kVK_ForwardDelete = 0x75,
kVK_F4 = 0x76,
kVK_End = 0x77,
kVK_F2 = 0x78,
kVK_PageDown = 0x79,
kVK_F1 = 0x7A,
kVK_LeftArrow = 0x7B,
kVK_RightArrow = 0x7C,
kVK_DownArrow = 0x7D,
kVK_UpArrow = 0x7E
};
/* ISO keyboards only*/
enum {
kVK_ISO_Section = 0x0A
};
/* JIS keyboards only*/
enum {
kVK_JIS_Yen = 0x5D,
kVK_JIS_Underscore = 0x5E,
kVK_JIS_KeypadComma = 0x5F,
kVK_JIS_Eisu = 0x66,
kVK_JIS_Kana = 0x68
};
struct EventRecord {
EventKind what;
unsigned long message;
UInt32 when;
Point where;
EventModifiers modifiers;
};
typedef struct EventRecord EventRecord;
typedef CALLBACK_API( void , FKEYProcPtr )(void);
typedef STACK_UPP_TYPE(FKEYProcPtr) FKEYUPP;
/*
* NewFKEYUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: not available
* Non-Carbon CFM: available as macro/inline
*/
/*
* DisposeFKEYUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: not available
* Non-Carbon CFM: available as macro/inline
*/
/*
* InvokeFKEYUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: not available
* Non-Carbon CFM: available as macro/inline
*/
#if !__LP64__
/*
* GetMouse() *** DEPRECATED ***
*
* Deprecated:
* Use HIGetMousePosition instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
GetMouse(Point * mouseLoc) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
#endif /* !__LP64__ */
/*
* Button() *** DEPRECATED ***
*
* Deprecated:
* Use GetCurrentButtonState or GetCurrentEventButtonState instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
Button(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
#if !__LP64__
/*
* StillDown()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
StillDown(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* WaitMouseUp()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
WaitMouseUp(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* KeyTranslate() *** DEPRECATED ***
*
* Deprecated:
* Use UCKeyTranslate instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern UInt32
KeyTranslate(
const void * transData,
UInt16 keycode,
UInt32 * state) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
/*
* GetCaretTime()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern UInt32
GetCaretTime(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
QuickTime 3.0 supports GetKeys() on unix and win32
But, on little endian machines you will have to be
careful about bit numberings and/or use a KeyMapByteArray
instead.
*/
#if TARGET_API_MAC_OS8
typedef UInt32 KeyMap[4];
#else
typedef BigEndianUInt32 KeyMap[4];
#endif /* TARGET_API_MAC_OS8 */
typedef UInt8 KeyMapByteArray[16];
/*
* GetKeys()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
GetKeys(KeyMap theKeys) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Obsolete event types & masks */
enum {
networkEvt = 10,
driverEvt = 11,
app1Evt = 12,
app2Evt = 13,
app3Evt = 14,
app4Evt = 15,
networkMask = 0x0400,
driverMask = 0x0800,
app1Mask = 0x1000,
app2Mask = 0x2000,
app3Mask = 0x4000,
app4Mask = 0x8000
};
struct EvQEl {
QElemPtr qLink;
SInt16 qType;
EventKind evtQWhat; /* this part is identical to the EventRecord as defined above */
unsigned long evtQMessage;
UInt32 evtQWhen;
Point evtQWhere;
EventModifiers evtQModifiers;
};
typedef struct EvQEl EvQEl;
typedef EvQEl * EvQElPtr;
typedef CALLBACK_API( void , GetNextEventFilterProcPtr )(EventRecord *theEvent, Boolean *result);
typedef STACK_UPP_TYPE(GetNextEventFilterProcPtr) GetNextEventFilterUPP;
/*
* NewGetNextEventFilterUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: not available
* Non-Carbon CFM: available as macro/inline
*/
/*
* DisposeGetNextEventFilterUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: not available
* Non-Carbon CFM: available as macro/inline
*/
/*
* InvokeGetNextEventFilterUPP()
*
* Availability:
* Mac OS X: not available
* CarbonLib: not available
* Non-Carbon CFM: available as macro/inline
*/
typedef GetNextEventFilterUPP GNEFilterUPP;
#if !__LP64__
/*
* GetDblTime()
*
* Summary:
* Returns the maximum time (in units of 1/60th of a second) allowed
* between two consecutive mouse-down events in order for the second
* click to be considered a double-click.
*
* Discussion:
* In 64-bit applications, you may replace calls to this API with
* calls to NXClickTime (declared in
* <IOKit/hidsystem/event_status_driver.h>) or with +[NSEvent
* doubleClickInterval] (available in Mac OS X 10.6 and later).
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* The maximum time between mouse-downs allowed for a double-click.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern UInt32
GetDblTime(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetEventMask()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
SetEventMask(EventMask value) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* GetNextEvent() *** DEPRECATED ***
*
* Deprecated:
* Use ReceiveNextEvent instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
GetNextEvent(
EventMask eventMask,
EventRecord * theEvent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
/*
* WaitNextEvent() *** DEPRECATED ***
*
* Deprecated:
* Use ReceiveNextEvent instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
WaitNextEvent(
EventMask eventMask,
EventRecord * theEvent,
UInt32 sleep,
RgnHandle mouseRgn) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
/*
* EventAvail() *** DEPRECATED ***
*
* Deprecated:
* Use FindSpecificEventInQueue instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
EventAvail(
EventMask eventMask,
EventRecord * theEvent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
/*
* PostEvent() *** DEPRECATED ***
*
* Deprecated:
* Use PostEventToQueue or CGEventPost instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
PostEvent(
EventKind eventNum,
UInt32 eventMsg) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
#endif /* !__LP64__ */
/*
* FlushEvents() *** DEPRECATED ***
*
* Deprecated:
* Use FlushEventsMatchingListFromQueue,
* FlushSpecificEventsFromQueue, or FlushEventQueue instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
FlushEvents(
EventMask whichMask,
EventMask stopMask) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
#if OLDROUTINENAMES
#define KeyTrans(transData, keycode, state) KeyTranslate(transData, keycode, state)
#endif /* OLDROUTINENAMES */
#if !__LP64__
/*
* KeyScript() *** DEPRECATED ***
*
* Deprecated:
* Use TISSelectInputSource API for positive verbs (ScriptCode).
* Use TSMDocument properties to restrict input sources:
* kTSMDocumentEnabledInputSourcesPropertyTag
* kTSMDocumentInputSourceOverridePropertyTag
*
* Summary:
* Switch to the specified script's default (last used) input source.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
KeyScript(short code) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
#endif /* !__LP64__ */
/*
* IsCmdChar() *** DEPRECATED ***
*
* Deprecated:
* Use IsUserCancelEventRef or CheckEventQueueForUserCancel instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework but deprecated in 10.6
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern Boolean
IsCmdChar(
const EventRecord * event,
short test) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6;
/*
LowMem accessor functions previously in LowMem.h
*/
/*
* LMGetKeyThresh()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern SInt16
LMGetKeyThresh(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if !__LP64__
/*
* LMSetKeyThresh()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
LMSetKeyThresh(SInt16 value) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* LMGetKeyRepThresh()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern SInt16
LMGetKeyRepThresh(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if !__LP64__
/*
* LMSetKeyRepThresh()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
LMSetKeyRepThresh(SInt16 value) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* LMGetKbdLast()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern UInt8
LMGetKbdLast(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if !__LP64__
/*
* LMSetKbdLast()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
LMSetKbdLast(UInt8 value) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* LMGetKbdType()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern UInt8
LMGetKbdType(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if !__LP64__
/*
* LMSetKbdType()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern void
LMSetKbdType(UInt8 value) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __EVENTS__ */

View File

@@ -0,0 +1,976 @@
/*
File: HIToolbox/HIAccessibility.h
Contains: Accessibility Carbon events and API for HIToolbox
Copyright: <20> 2005-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIACCESSIBILITY__
#define __HIACCESSIBILITY__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __COREFOUNDATION__
#include <CoreFoundation/CoreFoundation.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __EVENTS__
#include <HIToolbox/Events.h>
#endif
#ifndef __MENUS__
#include <HIToolbox/Menus.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#ifndef __MACWINDOWS__
#include <HIToolbox/MacWindows.h>
#endif
#ifndef __HIOBJECT__
#include <HIToolbox/HIObject.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*--------------------------------------------------------------------------------------*/
/* Accessibility Events */
/*--------------------------------------------------------------------------------------*/
/*
kEventClassAccessibility quick reference:
kEventAccessibleGetChildAtPoint = 1,
kEventAccessibleGetFocusedChild = 2,
kEventAccessibleGetAllAttributeNames = 21,
kEventAccessibleGetAllParameterizedAttributeNames = 25,
kEventAccessibleGetNamedAttribute = 22,
kEventAccessibleSetNamedAttribute = 23,
kEventAccessibleIsNamedAttributeSettable = 24,
kEventAccessibleGetAllActionNames = 41,
kEventAccessiblePerformNamedAction = 42,
kEventAccessibleGetNamedActionDescription = 44
*/
/*
* kEventClassAccessibility / kEventAccessibleGetChildAtPoint
*
* Summary:
* Finds the child of an accessible object at a given point.
*
* Discussion:
* The kEventParamMouseLocation parameter will contain a global
* point. Your handler for this event should find the child of
* yourself which is underneath that point and return it in the
* kEventParamAccessibleChild parameter.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* --> kEventParamMouseLocation (in, typeHIPoint)
* The location in global coordinates.
*
* <-- kEventParamAccessibleChild (out, typeCFTypeRef)
* On exit, contains the child of the accessible object at the
* specified point, in the form of an AXUIElementRef. If there
* is no child at the given point, you should still return
* noErr, but leave the parameter empty (do not call
* SetEventParameter). Only return immediate children; do not
* return grandchildren of yourself.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleGetChildAtPoint = 1
};
/*
* kEventClassAccessibility / kEventAccessibleGetFocusedChild
*
* Summary:
* Finds the focused child of an accessible object.
*
* Discussion:
* Your handler for this event should find the child of itself which
* is part of the focus chain and return it in the
* kEventParamAccessibleChild parameter.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* <-- kEventParamAccessibleChild (out, typeCFTypeRef)
* On exit, contains the focused child of the accessible
* object, in the form of an AXUIElementRef. If there is no
* child in the focus chain, you should still return noErr,
* but leave the parameter empty (do not call
* SetEventParameter). Only return immediate children; do not
* return grandchildren of yourself.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleGetFocusedChild = 2
};
/*
* kEventClassAccessibility / kEventAccessibleGetAllAttributeNames
*
* Summary:
* Returns the attributes supported by an accessible object. You
* must only return the names of your regular (non-parameterized)
* attributes via this event. If you support parameterized
* attributes, you must return them via the new
* kEventAccessibleGetAllParameterizedAttributeNames event.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* <-> kEventParamAccessibleAttributeNames (in/out, typeCFMutableArrayRef)
* Add each of the regular (non-parameterized) attribute names
* supported by the accessible object to this array, as
* CFStringRefs.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleGetAllAttributeNames = 21
};
/*
* kEventClassAccessibility / kEventAccessibleGetAllParameterizedAttributeNames
*
* Summary:
* Returns the parameterized attributes supported by an accessible
* object. You must not return the names of your regular
* (non-parameterized) attributes via this event. If you support
* regular attributes, you must return them via the original
* kEventAccessibleGetAllAttributeNames event. Parameterized
* attributes are introduced in Mac OS X 10.3.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* <-> kEventParamAccessibleAttributeNames (in/out, typeCFMutableArrayRef)
* Add each of the parameterized attribute names supported by
* the accessible object to this array, as CFStringRefs.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleGetAllParameterizedAttributeNames = 25
};
/*
* kEventClassAccessibility / kEventAccessibleGetNamedAttribute
*
* Summary:
* Returns the value of an attribute of an accessible object.
*
* Discussion:
* The kEventParamAccessibleAttributeName parameter will contain an
* attribute name in the form of a CFStringRef. If you support the
* named attribute, return the attribute<74>s value in the
* kEventParamAccessibleAttributeValue parameter.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* --> kEventParamAccessibleAttributeName (in, typeCFStringRef)
* The name of the requested attribute.
*
* --> kEventParamAccessibleAttributeParameter (in, typeCFTypeRef)
* This parameter is optional and will only exist if your
* accessible object is being asked for the value of a
* parameterized attribute. When present, this event parameter
* will contain a CFTypeRef describing the parameters of the
* request. Parameterized attributes are introduced in Mac OS
* X 10.3.
*
* <-- kEventParamAccessibleAttributeValue (out, typeCFTypeRef)
* On exit, contains the attribute's value. The type of this
* parameter varies according to the attribute; it might
* typically be typeCFStringRef (for a textual attribute),
* typeBoolean (for a boolean attribute), or typeSInt32 (for
* an integer-valued attribute).
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleGetNamedAttribute = 22
};
/*
* kEventClassAccessibility / kEventAccessibleSetNamedAttribute
*
* Summary:
* Sets the value of an attribute of an accessible object.
*
* Discussion:
* The kEventParamAccessibleAttributeName parameter will contain an
* attribute name in the form of a CFStringRef. The
* kEventParamAccessibleAttributeValue parameter will contain data
* in an arbitrary format. If you support the named attribute, set
* the named attribute<74>s value to the data provided in the event.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* --> kEventParamAccessibleAttributeName (in, typeCFStringRef)
* The name of the requested attribute.
*
* --> kEventParamAccessibleAttributeValue (in, typeCFTypeRef)
* The new value of the attribute. The type of this parameter
* varies according to the attribute; it might typically be
* typeCFStringRef (for a textual attribute), typeBoolean (for
* a boolean attribute), or typeSInt32 (for an integer-valued
* attribute).
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleSetNamedAttribute = 23
};
/*
* kEventClassAccessibility / kEventAccessibleIsNamedAttributeSettable
*
* Summary:
* Determines whether an attribute of an accessible object can be
* modified.
*
* Discussion:
* The kEventParamAccessibleAttributeName parameter will contain an
* attribute name in the form of a CFStringRef. If you support the
* named attribute, set the kEventParamAccessibleAttributeSettable
* parameter to a Boolean indicating whether the named attribute can
* have its value changed via the kEventAccessibleSetNamedAttribute
* event.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* --> kEventParamAccessibleAttributeName (in, typeCFStringRef)
* The name of the requested attribute.
*
* <-- kEventParamAccessibleAttributeSettable (out, typeBoolean)
* On exit, indicates whether the attribute may be modified.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleIsNamedAttributeSettable = 24
};
/*
* kEventClassAccessibility / kEventAccessibleGetAllActionNames
*
* Summary:
* Returns the actions supported by an accessible object.
*
* Discussion:
* The kEventParamAccessibleActionNames parameter will contain a
* CFMutableArrayRef. Add each of the action names you support to
* this array in the form of a CFStringRef.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* <-> kEventParamAccessibleActionNames (in/out, typeCFMutableArrayRef)
* Add each of the actions supported by the accessible object
* to this array, as CFStringRefs.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleGetAllActionNames = 41
};
/*
* kEventClassAccessibility / kEventAccessiblePerformNamedAction
*
* Summary:
* Requests that a specific action be performed by an accessible
* object.
*
* Discussion:
* The kEventParamAccessibleActionName parameter will contain an
* attribute name in the form of a CFStringRef. If you support the
* named action, perform the action. There are times, however, when
* performing an action causes an accessible object to call a
* routine which may not return immediately, such as StandardAlert
* or PopUpMenuSelect. You should only call such routines when you
* receive an action request that was queued; if you call such a
* routine when processing an event that was directly dispatched,
* you will probably cause the assistive app to receive a timeout
* error. On Mac OS X 10.3 and later, the
* kEventParamAccessibilityEventQueued parameter will indicate
* whether the event was queued. If so, process the request
* normally. If not, you can request that the event be posted to the
* queue and sent to you later by returning
* eventDeferAccessibilityEventErr from your handler. On Mac OS X
* 10.2, the parameter will not exist, the event will always be
* directly dispatched, and there is no way to request that it be
* posted to the queue; in this case, you should perform the action
* even if it will cause the assistive app to receive a timeout
* error.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* --> kEventParamAccessibleActionName (in, typeCFStringRef)
* The name of the requested action.
*
* --> kEventParamAccessibilityEventQueued (in, typeBoolean)
* An indication of whether this event was delivered to you
* via the main event queue. This parameter only exists on Mac
* OS X 10.3 and later. See the discussion for more details.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessiblePerformNamedAction = 42
};
/*
* kEventClassAccessibility / kEventAccessibleGetNamedActionDescription
*
* Summary:
* Returns a human-language description of an action supported by an
* accessible object.
*
* Discussion:
* The kEventParamAccessibleActionName parameter will contain an
* attribute name in the form of a CFStringRef. The
* kEventParamAccessibleActionDescription parameter will contain a
* CFMutableStringRef. If you support the named action, alter the
* mutable string to contain a textual description of the action<6F>s
* significance.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamAccessibleObject (in, typeCFTypeRef)
* The accessible object, in the form of an AXUIElementRef.
*
* --> kEventParamAccessibleActionName (in, typeCFStringRef)
* The name of the requested action.
*
* <-> kEventParamAccessibleActionDescription (in/out, typeCFMutableStringRef)
* If you support the action, extract this parameter from the
* event and set the contents of the mutable string to contain
* a description of the action. Do not set this event
* parameter to a CFStringRef of your own creation; you must
* modify the preexisting mutable string stored in the event
* parameter.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventAccessibleGetNamedActionDescription = 44
};
#if !__LP64__
/*
* AXUIElementCreateWithHIObjectAndIdentifier()
*
* Discussion:
* This routine creates an AXUIElementRef to represent an accessible
* object for a Carbon application. A Carbon accessible object is
* comprised of an HIObjectRef and a 64-bit identifier. The
* resulting AXUIElementRef is a CFTypeRef, and must be managed as
* such. You can create a new AXUIElementRef every time you need
* one. Even though the actual hex values of two AXUIElementRefs
* might be different, they may represent the same accessible
* object; because AXUIElementRefs are Core Foundation objects, you
* can use CFEqual to compare them.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inHIObject:
* The HIObjectRef of the accessible object.
*
* inIdentifier:
* The 64-bit identifier of the accessible object.
*
* Result:
* An AXUIElementRef that represents the Carbon accessible object
* identified by the given HIObjectRef and 64-bit identifier. This
* follows CoreFoundation semantics in that it will return NULL for
* failure, and because it is a "Create" function you will need to
* CFRelease() this AXUIElementRef when it is no longer needed.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern AXUIElementRef
AXUIElementCreateWithHIObjectAndIdentifier(
HIObjectRef inHIObject,
UInt64 inIdentifier) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* AXUIElementGetHIObject()
*
* Discussion:
* If the incoming AXUIElementRef is a Carbon accessible object,
* this routine will return the HIObjectRef of the accessible object.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inUIElement:
* The AXUIElementRef of whom you'd like to get the HIObjectRef.
*
* Result:
* The HIObjectRef of the AXUIElementRef. If the incoming
* AXUIElementRef is not a Carbon accessible object, this routine
* will return NULL.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern HIObjectRef
AXUIElementGetHIObject(AXUIElementRef inUIElement) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* AXUIElementGetIdentifier()
*
* Discussion:
* If the incoming AXUIElementRef is a Carbon accessible object,
* this routine will pass back the 64-bit identifier of the
* accessible object.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inUIElement:
* The AXUIElementRef of whom you'd like to get the 64-bit
* identifier.
*
* outIdentifier:
* The 64-bit identifier of the AXUIElementRef. If the incoming
* AXUIElementRef is not a Carbon accessible object, this routine
* will pass back zero. Note that zero is often a legal value for
* Carbon accessible object, so do not assume that the accessible
* object is not a Carbon accessible object just because you get a
* result of zero.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern void
AXUIElementGetIdentifier(
AXUIElementRef inUIElement,
UInt64 * outIdentifier) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* AXNotificationHIObjectNotify()
*
* Discussion:
* Posts a notification for the given pseudo-AXUIElementRef. Though
* an actual AXUIElementRef is not actually passed in to this
* function, its component parts are. This saves the implementation
* the hassle of dismantling the AXUIElementRef into its component
* parts.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inNotification:
* The notification name string.
*
* inHIObject:
* The HIObjectRef component of the AXUIElementRef to whom the
* notification applies.
*
* inIdentifier:
* The 64-bit identifier component of the AXUIElementRef to whom
* the notification applies.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern void
AXNotificationHIObjectNotify(
CFStringRef inNotification,
HIObjectRef inHIObject,
UInt64 inIdentifier) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HICopyAccessibilityRoleDescription()
*
* Summary:
* Returns the role description string for a standard role or a
* standard role-subrole pair.
*
* Discussion:
* This routine is useful if you are implementing an accessible
* object that has a standard role or role-subrole pair and you want
* to make sure your object provides the same role description
* string that the equivalent system-supplied object provides. In
* other words, if you are implementing an accessible object of role
* kAXButtonRole, you can use this routine to make sure it provides
* the same role description that the standard push button provides.
*
* This routine can provide role description strings for all roles
* and role-subrole pairs that are used in the standard/system
* accessible objects on Mac OS X 10.4 and later. Once this routine
* is able to provide a role description string for a role or
* role-subrole pair, it will continue to do so on subsequent system
* releases, even if the system no longer produces a standard
* accessible object with that role or role-subrole pair.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inRole:
* The role CFStringRef for your accessible object. Callers
* typically pass one of the kAXFooRole constant strings from
* within the HIServices framework.
*
* inSubrole:
* The subrole CFStringRef for your accessible object. Callers
* typically pass one of the kAXFooSubrole constant strings from
* within the HIServices framework. Pass NULL if your accessible
* object does not have a subrole.
*
* Result:
* A CFStringRef with the standard role description for the role or
* role-subrole pair. You must release the role description when you
* are finished with it. If there is no standard role description
* for the role or role-subrole pair, this routine will return NULL.
* If you pass either an unknown role or an unknown subrole, this
* routine will return NULL.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern CFStringRef
HICopyAccessibilityRoleDescription(
CFStringRef inRole,
CFStringRef inSubrole) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HICopyAccessibilityActionDescription()
*
* Summary:
* Returns the action description string for a standard
* accessibility action.
*
* Discussion:
* This routine is useful if you are implementing an accessible
* object that implements a standard action and you want to make
* sure your object provides the same role action string that the a
* system-supplied object provides.
* This routine can provide action description strings for all
* actions that are used in the standard/system accessible objects
* on Mac OS X 10.4 and later. Once this routine is able to provide
* a description string for an action, it will continue to do so on
* subsequent system releases, even if the system no longer produces
* a standard accessible object that supports the action.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inAction:
* The action CFStringRef for which you'd like to generate a
* description. Callers must pass one of the kAXFooAction constant
* strings from within the HIServices framework.
*
* Result:
* A CFStringRef with the standard description for the action. You
* must release the description when you are finished with it. If
* you pass an unsupported action to this routine, the behavior is
* undefined.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern CFStringRef
HICopyAccessibilityActionDescription(CFStringRef inAction) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIObjectIsAccessibilityIgnored()
*
* Discussion:
* Reports whether or not the given HIObject is marked as ignored
* for accessibility.
*
* See the discussion of HIObjectSetAccessibilityIgnored for details
* on what it means to be accessibility ignored.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inObject:
* The object whose accessibility ignored state you wish to query.
*
* Result:
* A Boolean value indicating whether or not the HIObject is ignored
* for accessibility.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HIObjectIsAccessibilityIgnored(HIObjectRef inObject) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIObjectSetAccessibilityIgnored()
*
* Discussion:
* Marks an HIObject as ignored (or not) for the purposes of the
* accessibility APIs.
*
* An HIObject that is ignored for accessibility will never be shown
* to an assistive application that uses the accessibility APIs to
* examine an interface. Your application's accessibility
* implementation can (and should) still report an ignored HIObject
* as usual. Carbon's accessibility engine will automatically prune
* any ignored HIObjects out of the data that is shown to an
* assistive application.
* <BR>By default, an HIObject is *not* accessibility ignored.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inObject:
* The object whose accessibility ignored state you wish to change.
*
* inIgnored:
* A Boolean value indicating whether or not to ignore the object.
*
* Result:
* An OSStatus signifying success or failure.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIObjectSetAccessibilityIgnored(
HIObjectRef inObject,
Boolean inIgnored) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIObjectSetAuxiliaryAccessibilityAttribute()
*
* Summary:
* Associates an additional accessibility attribute with a UIElement
* that is used to represent a given HIObject or a part thereof.
*
* Discussion:
* This routine lets your application provide the name of and data
* for an accessibility attribute that you want to add to the
* UIElement used to represent a given HIObject-identifier pair.
* Normally, accessibility attributes can only be supplied
* dynamically via Carbon Events, but this routine allows you to
* supply them statically.
*
* When an accessibility attribute Carbon Event is handled by the
* HIObject with a given identifier, the toolbox automatically
* supplies the names and/or values of any auxiliary attributes
* associated with that HIObject- identifier pair.
*
* This routine is particularly useful for supplying values for the
* kAXDescriptionAttribute, kAXTitleUIElementAttribute,
* kAXServesAsTitleUIElementAttribute, kAXLinkedUIElementsAttribute
* and other attributes whose value is specific to the layout and
* usage of your application.
*
* This routine only allows you to associate attributes whose values
* never change. If you need to supply attributes whose values are
* determined dynamically or whose values are settable, you must
* install the normal accessibility Carbon Event handlers.
*
* The auxiliary attribute store is consulted during the HIObject's
* default handling of the accessibility attribute Carbon Events.
* This means that any programmatic handling of a given
* accessibility attribute will have a chance to override or block
* the consultation of the store. The general rule is that if the
* toolbox or a Carbon Event handler can provide the attribute value
* some other way, the store will not be consulted.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inHIObject:
* The HIObjectRef part of the object-identifier pair to which the
* attribute data is associated.
*
* inIdentifier:
* The 64-bit identifier part of the object-identifier pair to
* which the attribute data is associated. When you want to
* associate the attribute data to the HIObject as a whole -- such
* as when you want to give a description attribute to a push
* button -- you should pass zero in this parameter.
*
* inAttributeName:
* A CFStringRef of the name of the attribute you wish to
* associate with the object-identifier pair. This string will be
* retained before adding it to the auxiliary attribute store.
*
* inAttributeData:
* A CFTypeRef with the data to be supplied as the attribute's
* value. This data will be retained before adding it to the
* auxiliary attribute store; you may release inAttributeData
* after you have called this routine. The inAttributeData
* parameter may also be NULL, which indicates that the named
* auxiliary attribute should no longer be associated with the
* object-identifier pair; any named attribute data previously
* associated with the object-identifier pair will be released.
*
* Result:
* An OSStatus result code. The function will return noErr if it was
* able to associate the attribute data with the HIObjectRef. If the
* HIObjectRef is invalid, paramErr will be returned. Other results
* may be returned in other situations.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIObjectSetAuxiliaryAccessibilityAttribute(
HIObjectRef inHIObject,
UInt64 inIdentifier,
CFStringRef inAttributeName,
CFTypeRef inAttributeData) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIObjectOverrideAccessibilityContainment()
*
* Summary:
* Allows you to override the AXUIElementRefs that an HIObject would
* normally supply as the values of its AXParent, AXWindow, and
* AXTopLevelUIElement attributes.
*
* Discussion:
* This routine allows you to change the parent that an HIObject
* would normally supply in the accessibility hierarchy. For
* instance, a popup control could call this routine on its menu so
* that the menu returned the popup control as the menu's parent;
* normally the menu would return the application as its parent.
* Optionally, this routine also allows you to change the window and
* top-level element that an HIObject would normally supply.
*
* If the input HIObject is a standard toolbox construct like an
* HIView or a Menu, the input HIObject will not be added as an
* accessibility child of its normal parent. In all other cases, it
* is the client's responsibility to ensure that the input HIObject
* is not added as an accessibility child of its normal parent.
*
* If the desired AXUIElementRef parent represents an HIView, a
* Menu, or a Window, the input HIObject will be automatically added
* as an accessibility child of the specified parent. In all other
* cases, it is the client's responsibility to manually add the
* input HIObject as a child of the specified parent. To represent
* an HIView, a Menu, or a Window, an AXUIElementRef must contain
* the appropriate HIObjectRef as well as an identifier value of
* zero.
*
* Similar rules don't have to apply for the handling of the window
* and top-level element attributes because those attributes don't
* represent two-way relationships.
*
* A containment override is not necessarily supported by every type
* of HIObject. Currently, it is supported by HIViews, Menus, and
* Windows.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inHIObject:
* The HIObjectRef whose parent attribute you want to override.
*
* inDesiredParent:
* The AXUIElementRef that you wish the HIObject to return as the
* value of its AXParent attribute. This routine makes a copy of
* the AXUIElementRef; you must release inDesiredParent after you
* have called this routine. Passing NULL indicates that you want
* the HIObject to revert to its normal, un-overridden behavior.
*
* inDesiredWindow:
* The AXUIElementRef that you wish the HIObject to return as the
* value of its AXWindow attribute. This routine makes a copy of
* the AXUIElementRef; you must release inDesiredWindow after you
* have called this routine. Passing NULL indicates that you want
* the HIObject to report its normal window, if any.
*
* inDesiredTopLevelUIElement:
* The AXUIElementRef that you wish the HIObject to return as the
* value of its AXTopLevelUIElement attribute. This routine makes
* a copy of the AXUIElementRef; you must release
* inDesiredTopLevelUIElement after you have called this routine.
* Passing NULL indicates that you want the HIObject to report its
* normal top-level element, if any.
*
* Result:
* An OSStatus result code. If the HIObjectRef is invalid, this
* routine will return paramErr.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIObjectOverrideAccessibilityContainment(
HIObjectRef inHIObject,
AXUIElementRef inDesiredParent,
AXUIElementRef inDesiredWindow,
AXUIElementRef inDesiredTopLevelUIElement) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HIACCESSIBILITY__ */

View File

@@ -0,0 +1,576 @@
/*
File: HIToolbox/HIArchive.h
Contains: HIArchive Interfaces.
Copyright: <20> 2004-2008 by Apple Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIARCHIVE__
#define __HIARCHIVE__
#ifndef __HIOBJECT__
#include <HIToolbox/HIObject.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIArchive
*
* Discussion:
* HIArchive provides a standard, extensible mechanism to flatten
* objects for storage in memory or on disk for later retrieval or
* transfer to another application. The archive is encoded using the
* binary property list format. The binary plist can be converted to
* text XML with /usr/bin/plutil for development purposes. Details
* on how to create an object that supports the HIArchive protocol
* are provided in HIToolbox/HIObject.h.
*
* When writing data out to an archive, the client must first use
* HIArchiveCreateForEncoding to generate the archive into which the
* data will be encoded. From there, data may be added to the
* archive by calling HIArchiveEncodeBoolean, HIArchiveEncodeNumber,
* and HIArchiveEncodeCFType. If HIArchiveEncodeCFType is being
* called on one of your custom HIObjects, HIToolbox will send it
* the kEventHIObjectEncode event (see HIObject.h). In order to
* receive this event your HIObject must first have set its
* archiving-ignored value to false via HIObjectSetArchivingIgnored.
* This lets HIToolbox know your object supports archiving. The
* kEventParamHIArchive parameter contains the HIArchiveRef into
* which it should encode all of its relevant state information. All
* information added to the archive is written with a key. This key
* is used later during the unarchiving process to pull the encoded
* data from the archive. System supplied HIObjects namespace their
* keys with an HI prefix. Subclasses of system supplied HIObjects
* should only use this namespace if explicitly overriding a value
* written to the archive by the superclass. Take care to mantain
* the same data format when overriding the default to avoid
* incompatibilities. When your archiving process is complete,
* HIArchiveCopyEncodedData will compress the data into the archive
* and return it in a CFDataRef. This CFDataRef can be sent to
* another application or written out to disk for later retrieval.
* Once the encoded data is compressed, no more data may be added to
* the archive. At this point, the HIArchiveRef must be released via
* CFRelease.
*
* When retrieving data from an archive, the client must first use
* HIArchiveCreateForDecoding to create an archive reference capable
* of decoding the data from the provided CFDataRef. Given the
* HIArchiveRef, data may be pulled from the archive via
* HIArchiveDecodeBoolean, HIArchiveDecodeNumber, and
* HIArchiveCopyDecodedCFType. If HIArchiveCopyDecodedCFType is
* called on one of your custom HIObjects, HIToolbox will send it
* the kEventHIObjectInitialize event (see HIOject.h). The
* kEventParamHIArchive parameter contains the HIArchiveRef from
* which it should decode all of its relevant state information.
* Because these data values were written by key, they can be read
* in any order regardless of how they were written. This also means
* new keyed values can be added without breaking existing decoding
* routines. Once all data has been read from the archive, it may
* simply be released via CFRelease.
*
* For those clients who wish to provide HIArchive editing features
* there are a few tricks necessary to achieve the desired behavior.
* A generic HIArchive editor will likely be used by clients to edit
* objects for which it has no direct knowledge (or which have not
* yet been designed). For instance, it may provide users with the
* ability to edit custom HIViews, including generic functionality
* to set the view's class identifier, title, frame, etc. In this
* case, it is necessary to instantiate the superclass
* ("com.apple.hiview") of the custom view object because the custom
* view class itself hasn't been registered within the editor.
*
*
* After the user has completed editing the object and desires to
* write out the archive, the editor must set the custom archive
* data to the object with HIObjectSetCustomArchiveData as a
* CFDictionary. Standard keys for initialization parameter types,
* names and values, class and superclass identifiers and CDEF
* procID are provided in HIToolbox/HIObject.h. Of particular
* importance are the object's class and superclass identifier.
* HIArchive uses these values to instantiate the proper object when
* loading the archive within the client's application. The
* parameter types, names and values are then automatically passed
* to the client object through its initialization event.
*
* At this point, the object can simply be written into the archive
* with HIArchiveCreateForEncoding and HIArchiveEncodeCFType.
* HIArchive will handle writing the appropriate classID based on
* the custom data that was assigned earlier.
*
* Generic HIArchive editing applications will also need to handle
* loading client archives. In this case, the archive is decoded in
* editing mode by passing the
* kHIArchiveDecodeSuperclassForUnregisteredObjects proxy bit in
* HIArchiveCreateForDecoding. When objects not registered in the
* current application are decoded, HIArchive will notice this and
* look into the custom data for the object's superclass identifier,
* instantiate an object of that type instead and attach the custom
* data to the newly created object. The editor can then look at the
* attached custom data with HIObjectCopyCustomArchiveData and
* provide it in the UI for the user to edit.
*/
typedef struct OpaqueHIArchiveRef* HIArchiveRef;
/*
* Discussion:
* HIArchive errors
*/
enum {
/*
* The archive was created specifically for encoding or decoding but
* passed into a non-corresponding routine.
*/
hiArchiveTypeMismatchErr = -6780,
/*
* The keyed value requested does not exist in the archive.
*/
hiArchiveKeyNotAvailableErr = -6781,
/*
* HIArchiveCopyEncodedData has been called and no more data may be
* encoded.
*/
hiArchiveEncodingCompleteErr = -6782,
/*
* The HIObject does not support the archiving protocol.
*/
hiArchiveHIObjectIgnoresArchivingErr = -6783
};
/*
* Discussion:
* HIArchiveCreateForDecoding options
*/
enum {
/*
* kDecodeSuperclassForUnregisteredObjects is passed to
* HIArchiveCreateForDecoding indicating that if an HIObject's class
* has not been registered before it is pulled from the archive,
* HIArchiveCopyDecodedCFType will automatically instantiate the
* unarchived object as its superclass if it exists. For instance, a
* custom HIView of class "com.myco.customview" being unarchived will
* be instantiated as class "com.apple.hiview" if your app has not
* yet registered "com.myco.customview". This is useful for archive
* editors that do not implement all objects contained in a client
* archive. Note that only data written to the archive by the
* superclass will be decoded. All data unique to the unregistered
* subclass will be ignored. This option also signals the HIObject to
* load its custom archive data so it can be accessed via
* HIObjectCopyCustomArchiveData. HIArchive is unable to instantiate
* unregistered objects whose superclasses are also unregistered.
*/
kHIArchiveDecodeSuperclassForUnregisteredObjects = (1 << 0),
/*
* Indicates that an archive is being decoded by an archive editor.
* This information is passed to the object being decoded via the
* kEventParamDecodingForEditor parameter in the
* kEventHIObjectInitialize and kEventHIObjectCreatedFromArchive
* event. This option may be used in Mac OS X 10.5 and later.
*/
kHIArchiveDecodingForEditor = (1 << 1)
};
#if !__LP64__
/*
* HIArchiveGetTypeID()
*
* Summary:
* Returns the CFType identifier for an HIArchive object.
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* A CFTypeID unique to HIArchive instances.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern CFTypeID
HIArchiveGetTypeID(void) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveCreateForEncoding()
*
* Summary:
* Creates an HIArchive for use in encoding object information.
*
* Discussion:
* The created HIArchiveRef is a CFType and must be released via
* CFRelease.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* outEncoder:
* An HIArchive reference which receives the created HIArchive on
* return.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveCreateForEncoding(HIArchiveRef * outEncoder) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveEncodeBoolean()
*
* Summary:
* Adds a keyed boolean value to the provided archive.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inEncoder:
* An HIArchiveRef to which the boolean value is added.
*
* inKey:
* The key associated with the boolean value used for later
* decoding.
*
* inBoolean:
* The boolean value to be encoded.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveEncodeBoolean(
HIArchiveRef inEncoder,
CFStringRef inKey,
Boolean inBoolean) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveEncodeNumber()
*
* Summary:
* Adds a keyed number value to the provided archive.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inEncoder:
* An HIArchiveRef to which the number value is added.
*
* inKey:
* The key associated with the number value used for later
* decoding.
*
* inNumberType:
* A CFNumberType describing the type of number value being
* encoded.
*
* inNumberValue:
* The number value to be encoded.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveEncodeNumber(
HIArchiveRef inEncoder,
CFStringRef inKey,
CFNumberType inNumberType,
const void * inNumberValue) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveEncodeCFType()
*
* Summary:
* Adds a keyed CFType to the provided archive.
*
* Discussion:
* Encodes basic and property list based CFTypes including HIObjects
* supporting the archiving protocol. If the HIObject supports the
* archiving protocol, it will receive the kEventHIObjectEncode
* event during which it should encode all relevant state
* information. The kEventParamHIArchive parameter contains the
* archive into which data should be added.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inEncoder:
* An HIArchiveRef to which the CFType is added.
*
* inKey:
* The key associated with the CFType used for later decoding.
*
* inCFType:
* The CFType to be encoded.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveEncodeCFType(
HIArchiveRef inEncoder,
CFStringRef inKey,
CFTypeRef inCFType) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveCopyEncodedData()
*
* Summary:
* Returns the encoded archive as a CFDataRef.
*
* Discussion:
* Compresses the archived data for storage and returns it as a
* CFDataRef. After the archived data is compressed, no further
* information may be encoded. Do not call this routine until the
* encoding process is complete.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inEncoder:
* An HIArchiveRef into which the archived data was compiled.
*
* outData:
* A CFData reference which receives the compressed archive data
* on return.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveCopyEncodedData(
HIArchiveRef inEncoder,
CFDataRef * outData) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveCreateForDecoding()
*
* Summary:
* Creates an HIArchive for use in decoding the object information
* contained in the provided CFData reference.
*
* Discussion:
* The created HIArchiveRef is a CFType and must be released via
* CFRelease.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inData:
* A CFDataRef containing a previously encoded archive.
*
* inOptions:
* The only option supported by this routine at present is
* kHIArchiveDecodeSuperclassForUnregisteredObjects. You may also
* pass zero for this parameter to get the default behavior.
*
* outDecoder:
* An HIArchive reference which receives the created HIArchive on
* return.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveCreateForDecoding(
CFDataRef inData,
OptionBits inOptions,
HIArchiveRef * outDecoder) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveDecodeBoolean()
*
* Summary:
* Pulls a keyed boolean value from the provided archive.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inDecoder:
* An HIArchiveRef from which the boolean value is pulled.
*
* inKey:
* The key associated with the boolean value used while encoding.
*
* outBoolean:
* The boolean value to be decoded.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveDecodeBoolean(
HIArchiveRef inDecoder,
CFStringRef inKey,
Boolean * outBoolean) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveDecodeNumber()
*
* Summary:
* Pulls a keyed number value from the provided archive.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inDecoder:
* An HIArchiveRef from which the number value is pulled.
*
* inKey:
* The key associated with the number value used while encoding.
*
* inNumberType:
* A CFNumberType describing the type of number value being
* encoded.
*
* outNumberValue:
* The number value to be decoded.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveDecodeNumber(
HIArchiveRef inDecoder,
CFStringRef inKey,
CFNumberType inNumberType,
void * outNumberValue) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIArchiveCopyDecodedCFType()
*
* Summary:
* Pulls a keyed CFType from the provided archive.
*
* Discussion:
* Decodes basic and property list based CFTypes and HIObjects. If
* the CFType is an HIObject, it will be constructed and receive the
* kEventHIObjectInitialize event. The kEventParamHIArchive
* parameter contains the archive from which data should be
* retrieved.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inDecoder:
* An HIArchiveRef from which the CFType value is pulled.
*
* inKey:
* The key associated with the CFType used while encoding.
*
* outCFType:
* The CFType to be decoded.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIArchiveCopyDecodedCFType(
HIArchiveRef inDecoder,
CFStringRef inKey,
CFTypeRef * outCFType) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HIARCHIVE__ */

View File

@@ -0,0 +1,996 @@
/*
File: HIToolbox/HIButtonViews.h
Contains: Definitions of the button views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIBUTTONVIEWS__
#define __HIBUTTONVIEWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIButtonViews.h
*
* Discussion:
* API definitions for the simple button views provided by
* HIToolbox: pushbutton, checkbox, radio button and radio group,
* bevel button, and round button.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* PUSH BUTTON (CDEF 23) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Two new variants of the standard pushbutton have been added to the standard control */
/* suite that draw a color icon next to the control title. One variant draws the icon */
/* on the left side, the other draws it on the right side (when the system justifica- */
/* tion is right to left, these are reversed). */
/* */
/* When either of the icon pushbuttons are created, the contrlMax field of the control */
/* record is used to determine the ID of the 'cicn' resource drawn in the pushbutton. */
/* */
/* In addition, a push button can now be told to draw with a default outline using the */
/* SetControlData routine with the kControlPushButtonDefaultTag below. */
/* */
/* A push button may also be marked using the kControlPushButtonCancelTag. This has */
/* no visible representation, but does cause the button to play the CancelButton theme */
/* sound instead of the regular pushbutton theme sound when pressed. */
/* */
/* Push Button proc IDs */
enum {
kControlPushButtonProc = 368,
kControlPushButLeftIconProc = 374, /* Standard pushbutton with left-side icon*/
kControlPushButRightIconProc = 375 /* Standard pushbutton with right-side icon*/
};
/* Push Button Icon Alignments */
typedef UInt16 ControlPushButtonIconAlignment;
enum {
kControlPushButtonIconOnLeft = 6,
kControlPushButtonIconOnRight = 7
};
/* Control Kind Tag */
enum {
kControlKindPushButton = 'push',
kControlKindPushIconButton = 'picn'
};
/* The HIObject class ID for the HIPushButton class. */
#define kHIPushButtonClassID CFSTR("com.apple.HIPushButton")
/* Creation APIs: Carbon Only */
#if !__LP64__
/*
* CreatePushButtonControl()
*
* Summary:
* Creates a push button control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounds of the control, in local coordinates of the window.
*
* title:
* The control title. May be NULL.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreatePushButtonControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title, /* can be NULL */
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* CreatePushButtonWithIconControl()
*
* Summary:
* Creates a push button control containing an icon or other
* graphical content.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounds of the control, in local coordinates of the window.
*
* title:
* The control title. May be NULL.
*
* icon:
* The control graphic content.
*
* iconAlignment:
* The alignment of the control graphic content.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreatePushButtonWithIconControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title, /* can be NULL */
ControlButtonContentInfo * icon,
ControlPushButtonIconAlignment iconAlignment,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* Summary:
* Tagged data supported by standard buttons
*/
enum {
/*
* Data is a Boolean indicating if a push button is a default button.
* If so, the button will draw with the appropriate appearance.
* Available in Mac OS 8.5 and later.
*/
kControlPushButtonDefaultTag = 'dflt',
/*
* Data is a Boolean indicating if a push button is a cancel button.
* If so, the button will draw with an appropriate appearance.
* Available in Mac OS 8.5 and later.
*/
kControlPushButtonCancelTag = 'cncl',
/*
* Data is a ControlButtonContentInfo or HIViewContentInfo structure.
* May be used to set or retrieve a button's image content. Available
* in Mac OS X 10.4 and later. In Mac OS X 10.4, the push button
* supports the kControlContentCIconRes and kControlContentCGImageRef
* content types. In Mac OS X 10.5 and later, the push button also
* supports IconRef content.
*/
kControlPushButtonContentTag = kControlContentTag,
/*
* Data is a ControlPushButtonIconAlignment indicating the desired
* alignment for the button's image content. Applies to all types of
* image content that may be associated with the push button, not
* just icons. Available in Mac OS X 10.4 and later.
*/
kControlPushButtonIconAlignmentTag = 'cpia',
/*
* Data is a Boolean. On 10.10 and later, getting this value always
* returns false, and setting this value is ignored. Available in Mac
* OS X 10.5 and later.
*/
kControlPushButtonAnimatingTag = 'anim'
};
/*
* Summary:
* Tagged data supported by push buttons
*
* Discussion:
* This new tag is available on Mac OS X 10.4 and later. The
* constant is not in the Mac OS X 10.4 and Mac OS X 10.5 headers,
* but the constant value is functional on both releases.
*/
enum {
/*
* Data is a Boolean indicating if a push button is a textured push
* button, to be drawn on a textured window. Textured was previously
* referred to as "metal". This attribute is only to be set on push
* buttons being used in composited windows.
*/
kControlPushButtonIsTexturedTag = 'metl'
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* CHECKBOX (CDEF 23) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* The standard checkbox view supports a "mixed" value that indicates that the */
/* current setting contains a mixed set of on and off values. The control value used */
/* to display this indication is defined below: */
/* */
/* kControlCheckBoxMixedValue = 2 */
/* */
/* Check Box proc ID */
enum {
kControlCheckBoxProc = 369
};
/* Variants with Appearance 1.1 or later */
enum {
kControlCheckBoxAutoToggleProc = 371
};
/* Control Kind Tag */
enum {
kControlKindCheckBox = 'cbox'
};
/* The HIObject class ID for the HICheckBox class. */
#define kHICheckBoxClassID CFSTR("com.apple.HICheckBox")
#if !__LP64__
/*
* CreateCheckBoxControl()
*
* Summary:
* Creates a checkbox control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounds of the control, in local coordinates of the window.
*
* title:
* The control title. May be NULL.
*
* initialValue:
* The initial value of the control. Should be zero (off), one
* (on), or two (mixed). The control is automatically given a
* minimum value of zero and a maximum value of two.
*
* autoToggle:
* Whether this control should have auto-toggle behavior. If true,
* the control will automatically toggle between on and off states
* when clicked.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateCheckBoxControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title, /* can be NULL */
SInt32 initialValue,
Boolean autoToggle,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Check Box Values */
#endif /* !__LP64__ */
enum {
kControlCheckBoxUncheckedValue = 0,
kControlCheckBoxCheckedValue = 1,
kControlCheckBoxMixedValue = 2
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* RADIO BUTTON (CDEF 23) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* The standard radio button control supports a "mixed" value that indicates that the */
/* current setting contains a mixed set of on and off values. The control value used */
/* to display this indication is defined below: */
/* */
/* kControlRadioButtonMixedValue = 2 */
/* */
/* Radio Button proc IDs */
enum {
kControlRadioButtonProc = 370
};
/* Variants with Appearance 1.1 or later */
enum {
kControlRadioButtonAutoToggleProc = 372
};
/* Radio Button Values */
enum {
kControlRadioButtonUncheckedValue = 0,
kControlRadioButtonCheckedValue = 1,
kControlRadioButtonMixedValue = 2
};
/* Control Kind Tag */
enum {
kControlKindRadioButton = 'rdio'
};
/* The HIObject class ID for the HIRadioButton class. */
#define kHIRadioButtonClassID CFSTR("com.apple.HIRadioButton")
#if !__LP64__
/*
* CreateRadioButtonControl()
*
* Summary:
* Creates a radio button control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounds of the control, in local coordinates of the window.
*
* title:
* The control title. May be NULL.
*
* initialValue:
* The initial value of the control. Should be zero (off), one
* (on), or two (mixed). The control is automatically given a
* minimum value of zero and a maximum value of two.
*
* autoToggle:
* Whether this control should have auto-toggle behavior. If true,
* the control will automatically toggle between on and off states
* when clicked. This parameter should be false if the control
* will be embedded into a radio group control; in that case, the
* radio group will handle setting the correct control value in
* response to a click.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateRadioButtonControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title, /* can be NULL */
SInt32 initialValue,
Boolean autoToggle,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* RADIO GROUP (CDEF 26) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This control implements a radio group. It is an embedding control and can therefore */
/* only be used when a control hierarchy is established for its owning window. You */
/* should only embed controls that have radio button behavior - currently radio buttons*/
/* and bevel buttons. Specifically, you can embed controls that return the feature bit */
/* kControlHasRadioBehavior. As controls are embedded into it, the group sets up its */
/* value, min, and max to represent the number of embedded items. */
/* The current value of the control is the index of the sub-control that is the current*/
/* 'on' radio button. To get the current radio button control handle, you can use the */
/* control manager call GetIndexedSubControl, passing in the value of the radio group. */
/* */
/* Note that when creating radio buttons for use in a radio group control, you should */
/* not use the autoToggle version of the radio button. The radio group control will */
/* handling toggling the radio button values itself; auto-toggle radio buttons do not */
/* work properly in a radio group control on Mac OS 9. */
/* */
/* NOTE: This control is only available with Appearance 1.0.1. */
/* Radio Group Proc ID */
#endif /* !__LP64__ */
enum {
kControlRadioGroupProc = 416
};
/* Control Kind Tag */
enum {
kControlKindRadioGroup = 'rgrp'
};
/* The HIObject class ID for the HIRadioGroup class. */
#define kHIRadioGroupClassID CFSTR("com.apple.HIRadioGroup")
/* Creation API: Carbon Only */
#if !__LP64__
/*
* CreateRadioGroupControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateRadioGroupControl(
WindowRef window,
const Rect * boundsRect,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
BEVEL BUTTON INTERFACE (CDEF 2)
Bevel buttons allow you to control the content type (pict/icon/etc.), the behavior
(pushbutton/toggle/sticky), and the bevel size. You also have the option of
attaching a menu to it. When a menu is present, you can specify which way the
popup arrow is facing (down or right).
This is all made possible by overloading the Min, Max, and Value parameters for the
control, as well as adjusting the variant. Here's the breakdown of what goes where:
Parameter What Goes Here
Min Hi Byte = Behavior, Lo Byte = content type.
Max ResID for resource-based content types.
Value MenuID to attach, 0 = no menu, please.
The variant is broken down into two halves. The low 2 bits control the bevel type.
Bit 2 controls the popup arrow direction (if a menu is present) and bit 3 controls
whether or not to use the control's owning window's font.
Constants for all you need to put this together are below. The values for behaviors
are set up so that you can simply add them to the content type for use in the Min
parameter of NewControl.
An example call:
control = NewControl( window, &bounds, "\p", true, 0, kControlContentIconSuiteRes +
kBehaviorToggles, myIconSuiteID, bevelButtonSmallBevelProc,
0L );
Attaching a menu:
control = NewControl( window, &bounds, "\p", true, kMyMenuID,
kControlContentIconSuiteRes, myIconSuiteID, bevelButtonSmallBevelProc +
kBevelButtonMenuOnRight, 0L );
This will attach menu ID kMyMenuID to the button, with the popup arrow facing right.
This also puts the menu up to the right of the button. You can also specify that a
menu can have multiple items checked at once by adding kBehaviorMultiValueMenus
into the Min parameter. If you do use multivalue menus, the GetBevelButtonMenuValue
helper function will return the last item chosen from the menu, whether or not it
was checked.
NOTE: Bevel buttons with menus actually have *two* values. The value of the
button (on/off), and the value of the menu. The menu value can be gotten
with the GetBevelButtonMenuValue helper function.
Handle-based Content
You can create your control and then set the content to an existing handle to an
icon suite, etc. using the macros below. Please keep in mind that resource-based
content is owned by the control, handle-based content is owned by you. The CDEF will
not try to dispose of handle-based content. If you are changing the content type of
the button on the fly, you must make sure that if you are replacing a handle-
based content with a resource-based content to properly dispose of the handle,
else a memory leak will ensue.
Textual Content
Please note that if a bevel button gets its textual content from the title
of the control. To alter the textual content of a bevel button, use the
SetControlTitle[WithCFString] API.
Implicit Menu Arrow Sizing
Bevel buttons can now have implicit popup menu arrow sizes on Mac OS X 10.5 and later. Use
SetControlData(..., kControlSizeTag, ...), where the default control size is
kControlSizeAuto. kControlSizeAuto has the bevel button render its popup menu arrow
at a size that is dependent on the size of the bevel button -- this is the behavior
on Tiger and earlier. kControlSizeNormal has it render the normal size arrow and
kControlSizeSmall has it render the arrow small. All other sizes are invalid.
*/
/* Bevel Button Proc IDs */
#endif /* !__LP64__ */
enum {
kControlBevelButtonSmallBevelProc = 32,
kControlBevelButtonNormalBevelProc = 33,
kControlBevelButtonLargeBevelProc = 34
};
/* Add these variant codes to kBevelButtonSmallBevelProc to change the type of button */
enum {
kControlBevelButtonSmallBevelVariant = 0,
kControlBevelButtonNormalBevelVariant = (1 << 0),
kControlBevelButtonLargeBevelVariant = (1 << 1),
kControlBevelButtonMenuOnRightVariant = (1 << 2)
};
/* Bevel Thicknesses */
typedef UInt16 ControlBevelThickness;
enum {
kControlBevelButtonSmallBevel = 0,
kControlBevelButtonNormalBevel = 1,
kControlBevelButtonLargeBevel = 2
};
/* Behaviors of bevel buttons. These are set up so you can add */
/* them together with the content types for use in the Min */
/* parameter of NewControl. Note that the behavior of a bevel */
/* button cannot be changed after the button is created. */
enum {
kControlBehaviorPushbutton = 0,
kControlBehaviorToggles = 0x0100,
kControlBehaviorSticky = 0x0200,
kControlBehaviorOffsetContents = 0x8000,
kControlBehaviorSingleValueMenu = 0,
kControlBehaviorMultiValueMenu = 0x4000 /* only makes sense when a menu is attached.*/
};
/* Behaviors for 1.0.1 or later */
enum {
kControlBehaviorCommandMenu = 0x2000 /* menu holds commands, not choices. Overrides multi-value bit.*/
};
typedef UInt16 ControlBevelButtonBehavior;
typedef UInt16 ControlBevelButtonMenuBehavior;
/* Bevel Button Menu Placements */
typedef UInt16 ControlBevelButtonMenuPlacement;
enum {
kControlBevelButtonMenuOnBottom = 0,
kControlBevelButtonMenuOnRight = (1 << 2)
};
/* Control Kind Tag */
enum {
kControlKindBevelButton = 'bevl'
};
/* The HIObject class ID for the HIBevelButton class. */
#define kHIBevelButtonClassID CFSTR("com.apple.HIBevelButton")
/* Creation API: Carbon Only */
#if !__LP64__
/*
* CreateBevelButtonControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateBevelButtonControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title,
ControlBevelThickness thickness,
ControlBevelButtonBehavior behavior,
ControlButtonContentInfoPtr info,
MenuID menuID,
ControlBevelButtonMenuBehavior menuBehavior,
ControlBevelButtonMenuPlacement menuPlacement,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Graphic Alignments */
#endif /* !__LP64__ */
typedef SInt16 ControlButtonGraphicAlignment;
enum {
kControlBevelButtonAlignSysDirection = -1, /* only left or right*/
kControlBevelButtonAlignCenter = 0,
kControlBevelButtonAlignLeft = 1,
kControlBevelButtonAlignRight = 2,
kControlBevelButtonAlignTop = 3,
kControlBevelButtonAlignBottom = 4,
kControlBevelButtonAlignTopLeft = 5,
kControlBevelButtonAlignBottomLeft = 6,
kControlBevelButtonAlignTopRight = 7,
kControlBevelButtonAlignBottomRight = 8
};
/* Text Alignments */
typedef SInt16 ControlButtonTextAlignment;
enum {
kControlBevelButtonAlignTextSysDirection = teFlushDefault,
kControlBevelButtonAlignTextCenter = teCenter,
kControlBevelButtonAlignTextFlushRight = teFlushRight,
kControlBevelButtonAlignTextFlushLeft = teFlushLeft
};
/* Text Placements */
typedef SInt16 ControlButtonTextPlacement;
enum {
kControlBevelButtonPlaceSysDirection = -1, /* if graphic on right, then on left*/
kControlBevelButtonPlaceNormally = 0,
kControlBevelButtonPlaceToRightOfGraphic = 1,
kControlBevelButtonPlaceToLeftOfGraphic = 2,
kControlBevelButtonPlaceBelowGraphic = 3,
kControlBevelButtonPlaceAboveGraphic = 4
};
/* Data tags supported by the bevel button controls */
enum {
kControlBevelButtonContentTag = kControlContentTag, /* ControlImageContentInfo*/
kControlBevelButtonTransformTag = 'tran', /* IconTransformType*/
kControlBevelButtonTextAlignTag = 'tali', /* ButtonTextAlignment*/
kControlBevelButtonTextOffsetTag = 'toff', /* SInt16*/
kControlBevelButtonGraphicAlignTag = 'gali', /* ButtonGraphicAlignment*/
kControlBevelButtonGraphicOffsetTag = 'goff', /* Point*/
kControlBevelButtonTextPlaceTag = 'tplc', /* ButtonTextPlacement*/
kControlBevelButtonMenuValueTag = 'mval', /* SInt16*/
kControlBevelButtonMenuHandleTag = 'mhnd', /* MenuRef*/
kControlBevelButtonMenuRefTag = 'mhnd', /* MenuRef*/
kControlBevelButtonCenterPopupGlyphTag = 'pglc' /* Boolean: true = center, false = bottom right*/
};
/* These are tags in 1.0.1 or later */
enum {
kControlBevelButtonLastMenuTag = 'lmnu', /* SInt16: menuID of last menu item selected from*/
kControlBevelButtonMenuDelayTag = 'mdly' /* SInt32: ticks to delay before menu appears*/
};
/* tags available with Appearance 1.1 or later */
enum {
/* Boolean: True = if an icon of the ideal size for*/
/* the button isn't available, scale a larger or*/
/* smaller icon to the ideal size. False = don't*/
/* scale; draw a smaller icon or clip a larger icon.*/
/* Default is false. Only applies to IconSuites and*/
kControlBevelButtonScaleIconTag = 'scal' /* IconRefs.*/
};
/* tags available in Mac OS X and later */
enum {
kControlBevelButtonOwnedMenuRefTag = 'omrf', /* MenuRef (control will dispose)*/
kControlBevelButtonKindTag = 'bebk' /* ThemeButtonKind ( kTheme[Small,Medium,Large,Rounded]BevelButton )*/
};
/*
* Summary:
* Tags available with Mac OS X 10.3 or later
*/
enum {
/*
* Passed data is an Boolean. Gets or sets whether or not the
* associated menu is a multi-value menu or not. True means that the
* menu can have multiple selections.
*/
kControlBevelButtonIsMultiValueMenuTag = 'mult'
};
/* Helper routines are available only thru the shared library/glue. */
#if !__LP64__
/*
* GetBevelButtonMenuValue()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
GetBevelButtonMenuValue(
ControlRef inButton,
MenuItemIndex * outValue) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetBevelButtonMenuValue()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetBevelButtonMenuValue(
ControlRef inButton,
MenuItemIndex inValue) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* GetBevelButtonMenuHandle()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
GetBevelButtonMenuHandle(
ControlRef inButton,
MenuHandle * outHandle) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#define GetBevelButtonMenuRef GetBevelButtonMenuHandle
/*
* GetBevelButtonContentInfo()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
GetBevelButtonContentInfo(
ControlRef inButton,
ControlButtonContentInfoPtr outContent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetBevelButtonContentInfo()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetBevelButtonContentInfo(
ControlRef inButton,
ControlButtonContentInfoPtr inContent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetBevelButtonTransform()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetBevelButtonTransform(
ControlRef inButton,
IconTransformType transform) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetBevelButtonGraphicAlignment()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetBevelButtonGraphicAlignment(
ControlRef inButton,
ControlButtonGraphicAlignment inAlign,
SInt16 inHOffset,
SInt16 inVOffset) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetBevelButtonTextAlignment()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetBevelButtonTextAlignment(
ControlRef inButton,
ControlButtonTextAlignment inAlign,
SInt16 inHOffset) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetBevelButtonTextPlacement()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetBevelButtonTextPlacement(
ControlRef inButton,
ControlButtonTextPlacement inWhere) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* ROUND BUTTON */
/* (CDEF 31) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
#endif /* !__LP64__ */
/*
* ControlRoundButtonSize
*
* Discussion:
* Button Sizes
*/
typedef SInt16 ControlRoundButtonSize;
enum {
/*
* A 20 pixel diameter button.
*/
kControlRoundButtonNormalSize = kControlSizeNormal,
/*
* A 25 pixel diameter button.
*/
kControlRoundButtonLargeSize = kControlSizeLarge
};
/* Data tags supported by the round button controls */
enum {
kControlRoundButtonContentTag = kControlContentTag, /* ControlImageContentInfo*/
kControlRoundButtonSizeTag = kControlSizeTag /* ControlRoundButtonSize*/
};
/* Control Kind Tag */
enum {
kControlKindRoundButton = 'rndb'
};
/* The HIObject class ID for the HIRoundButton class. */
#define kHIRoundButtonClassID CFSTR("com.apple.HIRoundButton")
#if !__LP64__
/*
* CreateRoundButtonControl()
*
* Summary:
* Creates a new instance of the Round Button Control.
*
* Discussion:
* CreateRoundButtonControl is preferred over NewControl because it
* allows you to specify the exact set of parameters required to
* create the control without overloading parameter semantics.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inWindow:
* The WindowRef in which to create the control. May be NULL in
* 10.3 and later.
*
* inBoundsRect:
* The bounding rectangle for the control. The height and width of
* the control is fixed (specified by the ControlRoundButtonSize
* parameter) and the control will be centered within the
* rectangle you specify.
*
* inSize:
* The button size; either kControlRoundButtonNormalSize or
* kControlRoundButtonLargeSize.
*
* inContent:
* Any optional content displayed in the button. Currently only
* kControlContentIconRef is supported. May be NULL.
*
* outControl:
* On successful exit, this will contain the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateRoundButtonControl(
WindowRef inWindow, /* can be NULL */
const Rect * inBoundsRect,
ControlRoundButtonSize inSize,
ControlButtonContentInfo * inContent, /* can be NULL */
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#if OLDROUTINENAMES
enum {
kControlCheckboxUncheckedValue = kControlCheckBoxUncheckedValue,
kControlCheckboxCheckedValue = kControlCheckBoxCheckedValue,
kControlCheckboxMixedValue = kControlCheckBoxMixedValue
};
#endif /* OLDROUTINENAMES */
#ifdef __cplusplus
}
#endif
#endif /* __HIBUTTONVIEWS__ */

View File

@@ -0,0 +1,136 @@
/*
File: HIButtonViews.r
Contains: Definitions of the button views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIBUTTONVIEWS_R__
#define __HIBUTTONVIEWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlPushButtonProc 368
#define kControlPushButLeftIconProc 374 /* Standard pushbutton with left-side icon */
#define kControlPushButRightIconProc 375 /* Standard pushbutton with right-side icon */
#define kControlPushButtonIconOnLeft 6
#define kControlPushButtonIconOnRight 7
#define kControlKindPushButton 'push'
#define kControlKindPushIconButton 'picn'
#define kControlPushButtonDefaultTag 'dflt'
#define kControlPushButtonCancelTag 'cncl'
#define kControlPushButtonContentTag 'cont'
#define kControlPushButtonIconAlignmentTag 'cpia'
#define kControlPushButtonAnimatingTag 'anim'
#define kControlPushButtonIsTexturedTag 'metl'
#define kControlCheckBoxProc 369
#define kControlCheckBoxAutoToggleProc 371
#define kControlKindCheckBox 'cbox'
#define kControlCheckBoxUncheckedValue 0
#define kControlCheckBoxCheckedValue 1
#define kControlCheckBoxMixedValue 2
#define kControlRadioButtonProc 370
#define kControlRadioButtonAutoToggleProc 372
#define kControlRadioButtonUncheckedValue 0
#define kControlRadioButtonCheckedValue 1
#define kControlRadioButtonMixedValue 2
#define kControlRadioGroupProc 416
#define kControlKindRadioGroup 'rgrp'
#define kControlBevelButtonSmallBevelProc 32
#define kControlBevelButtonNormalBevelProc 33
#define kControlBevelButtonLargeBevelProc 34
#define kControlBevelButtonSmallBevelVariant 0
#define kControlBevelButtonNormalBevelVariant 0x01
#define kControlBevelButtonLargeBevelVariant 0x02
#define kControlBevelButtonMenuOnRightVariant 0x04
#define kControlBevelButtonSmallBevel 0
#define kControlBevelButtonNormalBevel 1
#define kControlBevelButtonLargeBevel 2
#define kControlBehaviorPushbutton 0
#define kControlBehaviorToggles 0x0100
#define kControlBehaviorSticky 0x0200
#define kControlBehaviorOffsetContents 0x8000
#define kControlBehaviorSingleValueMenu 0
#define kControlBehaviorMultiValueMenu 0x4000 /* only makes sense when a menu is attached. */
#define kControlBehaviorCommandMenu 0x2000 /* menu holds commands, not choices. Overrides multi-value bit. */
#define kControlBevelButtonMenuOnBottom 0
#define kControlBevelButtonMenuOnRight 0x04
#define kControlKindBevelButton 'bevl'
#define kControlBevelButtonAlignSysDirection (-1) /* only left or right */
#define kControlBevelButtonAlignCenter 0
#define kControlBevelButtonAlignLeft 1
#define kControlBevelButtonAlignRight 2
#define kControlBevelButtonAlignTop 3
#define kControlBevelButtonAlignBottom 4
#define kControlBevelButtonAlignTopLeft 5
#define kControlBevelButtonAlignBottomLeft 6
#define kControlBevelButtonAlignTopRight 7
#define kControlBevelButtonAlignBottomRight 8
#define kControlBevelButtonAlignTextSysDirection 0
#define kControlBevelButtonAlignTextCenter 1
#define kControlBevelButtonAlignTextFlushRight (-1)
#define kControlBevelButtonAlignTextFlushLeft (-2)
#define kControlBevelButtonPlaceSysDirection (-1) /* if graphic on right, then on left */
#define kControlBevelButtonPlaceNormally 0
#define kControlBevelButtonPlaceToRightOfGraphic 1
#define kControlBevelButtonPlaceToLeftOfGraphic 2
#define kControlBevelButtonPlaceBelowGraphic 3
#define kControlBevelButtonPlaceAboveGraphic 4
#define kControlBevelButtonContentTag 'cont' /* ControlImageContentInfo */
#define kControlBevelButtonTransformTag 'tran' /* IconTransformType */
#define kControlBevelButtonTextAlignTag 'tali' /* ButtonTextAlignment */
#define kControlBevelButtonTextOffsetTag 'toff' /* SInt16 */
#define kControlBevelButtonGraphicAlignTag 'gali' /* ButtonGraphicAlignment */
#define kControlBevelButtonGraphicOffsetTag 'goff' /* Point */
#define kControlBevelButtonTextPlaceTag 'tplc' /* ButtonTextPlacement */
#define kControlBevelButtonMenuValueTag 'mval' /* SInt16 */
#define kControlBevelButtonMenuHandleTag 'mhnd' /* MenuRef */
#define kControlBevelButtonMenuRefTag 'mhnd' /* MenuRef */
#define kControlBevelButtonCenterPopupGlyphTag 'pglc' /* Boolean: true = center, false = bottom right */
#define kControlBevelButtonLastMenuTag 'lmnu' /* SInt16: menuID of last menu item selected from */
#define kControlBevelButtonMenuDelayTag 'mdly' /* SInt32: ticks to delay before menu appears */
/* Boolean: True = if an icon of the ideal size for */
/* the button isn't available, scale a larger or */
/* smaller icon to the ideal size. False = don't */
/* scale; draw a smaller icon or clip a larger icon. */
/* Default is false. Only applies to IconSuites and */
#define kControlBevelButtonScaleIconTag 'scal' /* IconRefs. */
#define kControlBevelButtonOwnedMenuRefTag 'omrf' /* MenuRef (control will dispose) */
#define kControlBevelButtonKindTag 'bebk' /* ThemeButtonKind ( kTheme[Small,Medium,Large,Rounded]BevelButton ) */
#define kControlBevelButtonIsMultiValueMenuTag 'mult'
#define kControlRoundButtonNormalSize 0
#define kControlRoundButtonLargeSize 2
#define kControlRoundButtonContentTag 'cont' /* ControlImageContentInfo */
#define kControlRoundButtonSizeTag 'size' /* ControlRoundButtonSize */
#define kControlKindRoundButton 'rndb'
#endif /* __HIBUTTONVIEWS_R__ */

View File

@@ -0,0 +1,181 @@
/*
File: HIToolbox/HIClockView.h
Contains: Definition of the clock view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HICLOCKVIEW__
#define __HICLOCKVIEW__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIClockView.h
*
* Discussion:
* API definitions for the clock view.
*/
/*==============================================================================*/
/* Clock view events */
/*==============================================================================*/
enum {
kEventClassClockView = 'cloc'
};
/*
* kEventClassClockView / kEventClockDateOrTimeChanged
*
* Summary:
* Allows clients to determine when the user has changed the date or
* time in the clock view.
*
* Discussion:
* This event is sent by the clock view when the user has changed
* the date or time. Clients could register for this notification in
* order to update some state based on the date or time in the
* clock, for instance. This event is sent to the view only, it will
* not propagate. It is sent to all handlers installed on the view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamDirectObject (in, typeControlRef)
* The view whose date has changed.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventClockDateOrTimeChanged = 1
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> CLOCK (CDEF 15) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* NOTE: You can specify more options in the Value paramter when creating the clock. */
/* See below. */
/* */
/* NOTE: Under Appearance 1.1, the clock control knows and returns more part codes. */
/* The new clock-specific part codes are defined with the other control parts. */
/* Besides these clock-specific parts, we also return kControlUpButtonPart */
/* and kControlDownButtonPart when they hit the up and down arrows. */
/* The new part codes give you more flexibility for focusing and hit testing. */
/* */
/* The original kControlClockPart is still valid. When hit testing, it means */
/* that some non-editable area of the clock's whitespace has been clicked. */
/* When focusing a currently unfocused clock, it changes the focus to the */
/* first part; it is the same as passing kControlFocusNextPart. When */
/* re-focusing a focused clock, it will not change the focus at all. */
/* Clock proc IDs */
enum {
kControlClockTimeProc = 240,
kControlClockTimeSecondsProc = 241,
kControlClockDateProc = 242,
kControlClockMonthYearProc = 243
};
/* Clock Types */
typedef UInt16 ControlClockType;
enum {
kControlClockTypeHourMinute = 0,
kControlClockTypeHourMinuteSecond = 1,
kControlClockTypeMonthDayYear = 2,
kControlClockTypeMonthYear = 3
};
/* Clock Flags */
/* These flags can be passed into 'value' field on creation of the control. */
/* Value is set to 0 after control is created. */
typedef UInt32 ControlClockFlags;
enum {
kControlClockFlagStandard = 0, /* editable, non-live*/
kControlClockNoFlags = 0,
kControlClockFlagDisplayOnly = 1, /* add this to become non-editable*/
kControlClockIsDisplayOnly = 1,
kControlClockFlagLive = 2, /* automatically shows current time on idle. only valid with display only.*/
kControlClockIsLive = 2
};
/* Control Kind Tag */
enum {
kControlKindClock = 'clck'
};
/* The HIObject class ID for the HIClock class. */
#define kHIClockViewClassID CFSTR("com.apple.HIClock")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateClockControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateClockControl(
WindowRef window,
const Rect * boundsRect,
ControlClockType clockType,
ControlClockFlags clockFlags,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by clocks */
#endif /* !__LP64__ */
enum {
kControlClockLongDateTag = 'date', /* LongDateRec, 32-bit only*/
kControlClockAbsoluteTimeTag = 'abst', /* CFAbsoluteTime; available in Leopard and later*/
kControlClockFontStyleTag = kControlFontStyleTag, /* ControlFontStyleRec*/
kControlClockAnimatingTag = 'anim' /* Boolean*/
};
#ifdef __cplusplus
}
#endif
#endif /* __HICLOCKVIEW__ */

View File

@@ -0,0 +1,47 @@
/*
File: HIClockView.r
Contains: Definition of the clock view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HICLOCKVIEW_R__
#define __HICLOCKVIEW_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlClockTimeProc 240
#define kControlClockTimeSecondsProc 241
#define kControlClockDateProc 242
#define kControlClockMonthYearProc 243
#define kControlClockTypeHourMinute 0
#define kControlClockTypeHourMinuteSecond 1
#define kControlClockTypeMonthDayYear 2
#define kControlClockTypeMonthYear 3
#define kControlClockFlagStandard 0 /* editable, non-live */
#define kControlClockNoFlags 0
#define kControlClockFlagDisplayOnly 1 /* add this to become non-editable */
#define kControlClockIsDisplayOnly 1
#define kControlClockFlagLive 2 /* automatically shows current time on idle. only valid with display only. */
#define kControlClockIsLive 2
#define kControlKindClock 'clck'
#define kControlClockLongDateTag 'date' /* LongDateRec, 32-bit only */
#define kControlClockAbsoluteTimeTag 'abst' /* CFAbsoluteTime; available in Leopard and later */
#define kControlClockFontStyleTag 'font' /* ControlFontStyleRec */
#define kControlClockAnimatingTag 'anim' /* Boolean */
#endif /* __HICLOCKVIEW_R__ */

View File

@@ -0,0 +1,27 @@
/*
File: HIToolbox/HICocoaView.h
Contains: HICocoaView routines
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HICOCOAVIEW__
#define __HICOCOAVIEW__
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#endif /* __HICOCOAVIEW__ */

View File

@@ -0,0 +1,564 @@
/*
File: HIToolbox/HIComboBox.h
Contains: Definition of the combo box view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HICOMBOBOX__
#define __HICOMBOBOX__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIComboBox.h
*
* Discussion:
* API definitions for the combo box view.
*/
/*==============================================================================*/
/* HIComboBox */
/* */
/* The combo box is a new view starting in Mac OS 10.2. It can be used in */
/* both the new compositing mode, as well as the traditional Control Manager */
/* mode. Like all new HIFoo views, this view is created invisible. You must */
/* show the view after creation if you want to, like, see it and stuff. */
/*==============================================================================*/
/* The HIObject class ID for the HIComboBox class. */
#define kHIComboBoxClassID CFSTR("com.apple.HIComboBox")
/*
kEventClassHIComboBox quick reference:
kEventComboBoxListItemSelected = 1
*/
enum {
kEventClassHIComboBox = 'hicb'
};
enum {
kEventParamComboBoxListSelectedItemIndex = 'cbli'
};
/*
* kEventClassHIComboBox / kEventComboBoxListItemSelected
*
* Summary:
* Notification that an item in the ComboBox disclosure list has
* been selected.
*
* Discussion:
* This event is sent as a notification when an item in the ComboBox
* disclosure list has been selected. This event is sent to all
* handlers installed on the view. This does not imply that the
* selection has been accepted; for that you will need to register
* for the kEventClassTextField/kEventTextAccepted event; you can
* register for that event in order to make live selections however.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamDirectObject (in, typeControlRef)
* The ComboBox view that has sent the notification.
*
* --> kEventParamComboBoxListSelectedItemIndex (in, typeCFIndex)
* The index of the combo box list item that has been selected.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventComboBoxListItemSelected = 1
};
/*
* Summary:
* ComboBox attributes
*/
enum {
/*
* A constant with value zero; the lack of any attributes.
*/
kHIComboBoxNoAttributes = 0,
/*
* The view will attempt to auto complete the text the user is typing
* with an item in the ComboBox list that is the closest appropriate
* match.
*/
kHIComboBoxAutoCompletionAttribute = (1 << 0),
/*
* The view will disclose the ComboBox list after the user enters
* text.
*/
kHIComboBoxAutoDisclosureAttribute = (1 << 1),
/*
* The items in the ComboBox list will be automatically sorted in
* alphabetical order.
*/
kHIComboBoxAutoSortAttribute = (1 << 2),
/*
* The ComboBox list will be automatically sized to fit the Human
* Interface Guidelines.
*/
kHIComboBoxAutoSizeListAttribute = (1 << 3),
/*
* The minimum set of ComboBox attributes commonly used.
*/
kHIComboBoxStandardAttributes = (kHIComboBoxAutoCompletionAttribute | kHIComboBoxAutoDisclosureAttribute | kHIComboBoxAutoSizeListAttribute)
};
/* ControlKind*/
enum {
kControlKindHIComboBox = 'cbbx'
};
/* ComboBox Part codes*/
enum {
kHIComboBoxEditTextPart = 5,
kHIComboBoxDisclosurePart = 28
};
/*
The ComboBox view supports these tags previously defined for the EditUnicodeText view.
These tags are available through Get/SetControlData with a ControlPartCode of kHIComboBoxEditTextPart:
kControlFontStyleTag
kControlEditTextFixedTextTag
kControlEditTextTextTag
kControlEditTextKeyFilterTag
kControlEditTextValidationProcTag
kControlEditUnicodeTextPostUpdateProcTag
kControlEditTextSelectionTag
kControlEditTextKeyScriptBehaviorTag
kControlEditTextCharCount
kControlEditTextCFStringTag
*/
/*
* Discussion:
* ComboBox ControlData tags available with Mac OS X 10.2 and later.
*/
enum {
/*
* Extract the contents of the ComboBox list as a CFArray. The
* CFArray will be retained: if you get the array, you own it and
* will be required to release it; if you set it the toolbox makes a
* copy of it and you are free to release your reference.
*/
kHIComboBoxListTag = 'cbls', /* CFArrayRef; bumps the refCount on get/retains on set*/
/*
* The width of the ComboBox list. This can be customized. This
* disables the autosize attribute.
*/
kHIComboBoxListPixelWidthTag = 'cblw', /* UInt32 */
/*
* The height of the ComboBox list. This can be customized. This
* disables the autosize attribute.
*/
kHIComboBoxListPixelHeightTag = 'cblh', /* UInt32*/
/*
* The number of visible items in the list. This can be customized.
* This disables the autosize attribute.
*/
kHIComboBoxNumVisibleItemsTag = 'cbni' /* UInt32*/
};
#if !__LP64__
/*
* HIComboBoxCreate()
*
* Summary:
* Creates a combo box view. The new view is initially invisible.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* boundsRect:
* The bounding box of the view.
*
* text:
* The default text in the editable portion of the view. Can be
* NULL.
*
* style:
* The font style of the both editable text and the text in the
* disclosure list. Can be NULL.
*
* list:
* The default values available in the disclosure list. Can be
* NULL.
*
* inAttributes:
* The default attributes of the combo box.
*
* outComboBox:
* On exit, contains the new view.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxCreate(
const HIRect * boundsRect,
CFStringRef text, /* can be NULL */
const ControlFontStyleRec * style, /* can be NULL */
CFArrayRef list, /* can be NULL */
OptionBits inAttributes,
HIViewRef * outComboBox) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxGetItemCount()
*
* Summary:
* Get the number of items in the combo box disclosure list.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box.
*
* Result:
* The number of items in the combo box disclosure list.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern ItemCount
HIComboBoxGetItemCount(HIViewRef inComboBox) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxInsertTextItemAtIndex()
*
* Summary:
* Inserts a CFString in the disclosure list
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box whose disclosure list the text will be inserted
* in.
*
* inIndex:
* The index that the text should be inserted in. If the index
* does not fall within the number of items in the combo box list,
* it will be appended to the end of the list.
*
* inText:
* The text item to be inserted in the combo box disclosure list.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxInsertTextItemAtIndex(
HIViewRef inComboBox,
CFIndex inIndex,
CFStringRef inText) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxAppendTextItem()
*
* Summary:
* Appends a text item to the combo box disclosure list.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box whose disclosure list the text will be appended
* to.
*
* inText:
* The text item to be appended to the combo box disclosure list.
*
* outIndex:
* On exit, the index of the new item. Can be NULL if the caller
* does not require this information.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxAppendTextItem(
HIViewRef inComboBox,
CFStringRef inText,
CFIndex * outIndex) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxCopyTextItemAtIndex()
*
* Summary:
* Copy the text from the combo box disclosure list
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box that contains the text item you would like to
* copy.
*
* inIndex:
* The index of the text item. Will return paramErr if the index
* is out of bounds of the combo box list.
*
* outString:
* A copy of the string at the given index. Remember this is now
* your copy that you will need to release.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxCopyTextItemAtIndex(
HIViewRef inComboBox,
CFIndex inIndex,
CFStringRef * outString) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxRemoveItemAtIndex()
*
* Summary:
* Remove an item from a combo box disclosure list.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box that contains the disclosure list that you would
* like to remove an item from.
*
* inIndex:
* The index of the item to remove.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxRemoveItemAtIndex(
HIViewRef inComboBox,
CFIndex inIndex) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxChangeAttributes()
*
* Summary:
* Change the attributes of a combo box
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box whose attributes you would like to change.
*
* inAttributesToSet:
* The attributes to set.
*
* inAttributesToClear:
* The attributes to clear.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxChangeAttributes(
HIViewRef inComboBox,
OptionBits inAttributesToSet,
OptionBits inAttributesToClear) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxGetAttributes()
*
* Summary:
* Get the attributes of a combo box.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box whose attributes you would like to obtain.
*
* outAttributes:
* The attributes of the combo box.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxGetAttributes(
HIViewRef inComboBox,
OptionBits * outAttributes) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIComboBoxIsListVisible()
*
* Summary:
* Returns whether the combo box list is currently disclosed.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box whose list visibility you would like to obtain.
*
* Result:
* A boolean value indicating whether the combo box list is
* disclosed (true) or hidden (false).
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HIComboBoxIsListVisible(HIViewRef inComboBox) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIComboBoxSetListVisible()
*
* Summary:
* Hides or shows the combo box list.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inComboBox:
* The combo box whose list will be hidden or shown.
*
* inVisible:
* A boolean value indicating whether you wish to hide the list
* (false) or show the list (true).
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIComboBoxSetListVisible(
HIViewRef inComboBox,
Boolean inVisible) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HICOMBOBOX__ */

View File

@@ -0,0 +1,29 @@
/*
File: HIComboBox.r
Contains: Definition of the combo box view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HICOMBOBOX_R__
#define __HICOMBOBOX_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kHIComboBoxListTag 'cbls' /* CFArrayRef; bumps the refCount on get/retains on set */
#define kHIComboBoxListPixelWidthTag 'cblw' /* UInt32 */
#define kHIComboBoxListPixelHeightTag 'cblh' /* UInt32 */
#define kHIComboBoxNumVisibleItemsTag 'cbni' /* UInt32 */
#endif /* __HICOMBOBOX_R__ */

View File

@@ -0,0 +1,819 @@
/*
File: HIToolbox/HIContainerViews.h
Contains: Definition of the container views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HICONTAINERVIEWS__
#define __HICONTAINERVIEWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIContainerViews.h
*
* Discussion:
* API definitions for the views that can contain other views: group
* box, placard, window header, and user pane.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> GROUP BOX (CDEF 10) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* The group box CDEF can be use in several ways. It can have no title, a text title, */
/* a check box as the title, or a popup button as a title. There are two versions of */
/* group boxes, primary and secondary, which look slightly different. */
/* Group Box proc IDs */
enum {
kControlGroupBoxTextTitleProc = 160,
kControlGroupBoxCheckBoxProc = 161,
kControlGroupBoxPopupButtonProc = 162,
kControlGroupBoxSecondaryTextTitleProc = 164,
kControlGroupBoxSecondaryCheckBoxProc = 165,
kControlGroupBoxSecondaryPopupButtonProc = 166
};
/* Control Kind Tag */
enum {
kControlKindGroupBox = 'grpb',
kControlKindCheckGroupBox = 'cgrp',
kControlKindPopupGroupBox = 'pgrp'
};
/* The HIObject class ID for the HIGroupBox class. */
#define kHIGroupBoxClassID CFSTR("com.apple.HIGroupBox")
/* The HIObject class ID for the HICheckBoxGroup class. */
#define kHICheckBoxGroupClassID CFSTR("com.apple.HICheckBoxGroup")
/* Creation APIs: Carbon only */
#if !__LP64__
/*
* CreateGroupBoxControl()
*
* Summary:
* Creates a group box control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control.
*
* boundsRect:
* The bounding box of the control.
*
* title:
* The title of the control.
*
* primary:
* Whether to create a primary or secondary group box.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateGroupBoxControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title,
Boolean primary,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* CreateCheckGroupBoxControl()
*
* Summary:
* Creates a group box control that has a check box as its title.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control.
*
* boundsRect:
* The bounding box of the control.
*
* title:
* The title of the control (used as the title of the check box).
*
* initialValue:
* The initial value of the check box.
*
* primary:
* Whether to create a primary or secondary group box.
*
* autoToggle:
* Whether to create an auto-toggling check box. Auto-toggling
* check box titles are only supported on Mac OS X; this parameter
* must be false when used with CarbonLib.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateCheckGroupBoxControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title,
SInt32 initialValue,
Boolean primary,
Boolean autoToggle,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* CreatePopupGroupBoxControl()
*
* Summary:
* Creates a group box control that has a popup button as its title.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control.
*
* boundsRect:
* The bounding box of the control.
*
* title:
* The title of the control (used as the title of the popup
* button).
*
* primary:
* Whether to create a primary or secondary group box.
*
* menuID:
* The menu ID of the menu to be displayed by the popup button.
*
* variableWidth:
* Whether the popup button should have a variable-width title.
* Fixed-width titles are only supported by Mac OS X; this
* parameter must be true when used with CarbonLib.
*
* titleWidth:
* The width in pixels of the popup button title.
*
* titleJustification:
* The justification of the popup button title. Use one of the
* TextEdit justification constants here (teFlushDefault,
* teCenter, teFlushRight, or teFlushLeft).
*
* titleStyle:
* The QuickDraw text style of the popup button title.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreatePopupGroupBoxControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef title,
Boolean primary,
MenuID menuID,
Boolean variableWidth,
SInt16 titleWidth,
SInt16 titleJustification,
Style titleStyle,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by group box */
#endif /* !__LP64__ */
enum {
kControlGroupBoxMenuHandleTag = 'mhan', /* MenuRef (popup title only)*/
kControlGroupBoxMenuRefTag = 'mhan', /* MenuRef (popup title only)*/
kControlGroupBoxFontStyleTag = kControlFontStyleTag /* ControlFontStyleRec*/
};
/* tags available with Appearance 1.1 or later */
enum {
kControlGroupBoxTitleRectTag = 'trec' /* Rect. Rectangle that the title text/control is drawn in. (get only)*/
};
/*
* Summary:
* Tags available with Mac OS X 10.3 or later
*/
enum {
/*
* Passed data is a Rect. Returns the full rectangle that content is
* drawn in (get only). This is slightly different than the content
* region, as it also includes the frame drawn around the content.
*/
kControlGroupBoxFrameRectTag = 'frec'
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> PLACARD (CDEF 14) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Placard proc IDs */
enum {
kControlPlacardProc = 224
};
/* Control Kind Tag */
enum {
kControlKindPlacard = 'plac'
};
/* The HIObject class ID for the HIPlacardView class. */
#define kHIPlacardViewClassID CFSTR("com.apple.HIPlacardView")
#if !__LP64__
/*
* CreatePlacardControl()
*
* Summary:
* Creates a placard control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounding box of the control.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreatePlacardControl(
WindowRef window, /* can be NULL */
const Rect * boundsRect,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> WINDOW HEADER (CDEF 21) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Window Header proc IDs */
#endif /* !__LP64__ */
enum {
kControlWindowHeaderProc = 336, /* normal header*/
kControlWindowListViewHeaderProc = 337 /* variant for list views - no bottom line*/
};
/* Control Kind Tag */
enum {
kControlKindWindowHeader = 'whed'
};
/*
* Summary:
* Tags available with Mac OS X 10.3 or later
*/
enum {
/*
* Passed data is a Boolean. Set to true if the control is to draw
* as a list header.
*/
kControlWindowHeaderIsListHeaderTag = 'islh'
};
/* The HIObject class ID for the HIWindowHeaderView class. */
#define kHIWindowHeaderViewClassID CFSTR("com.apple.HIWindowHeaderView")
/* Creation API: Carbon Only */
#if !__LP64__
/*
* CreateWindowHeaderControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateWindowHeaderControl(
WindowRef window,
const Rect * boundsRect,
Boolean isListHeader,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> USER PANE (CDEF 16) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* User panes have two primary purposes: to allow easy implementation of a custom */
/* control by the developer, and to provide a generic container for embedding other */
/* controls. */
/* */
/* In Carbon, with the advent of Carbon-event-based controls, you may find it easier */
/* to simply write a new control from scratch than to customize a user pane control. */
/* The set of callbacks provided by the user pane will not be extended to support */
/* new Control Manager features; instead, you should just write a real control. */
/* */
/* User panes do not, by default, support embedding. If you try to embed a control */
/* into a user pane, you will get back errControlIsNotEmbedder. You can make a user */
/* pane support embedding by passing the kControlSupportsEmbedding flag in the 'value' */
/* parameter when you create the control. */
/* */
/* User panes support the following overloaded control initialization options: */
/* */
/* Parameter What Goes Here */
/* <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> */
/* Value Control feature flags */
/* User Pane proc IDs */
#endif /* !__LP64__ */
enum {
kControlUserPaneProc = 256
};
/* Control Kind Tag */
enum {
kControlKindUserPane = 'upan'
};
/* The HIObject class ID for the HIUserPane class. Valid in Mac OS X 10.4 and later. */
#define kHIUserPaneClassID CFSTR("com.apple.HIUserPane")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateUserPaneControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateUserPaneControl(
WindowRef window,
const Rect * boundsRect,
UInt32 features,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by user panes */
/* Currently, they are all proc ptrs for doing things like drawing and hit testing, etc. */
#endif /* !__LP64__ */
enum {
kControlUserItemDrawProcTag = 'uidp', /* UserItemUPP*/
kControlUserPaneDrawProcTag = 'draw', /* ControlUserPaneDrawUPP*/
kControlUserPaneHitTestProcTag = 'hitt', /* ControlUserPaneHitTestUPP*/
kControlUserPaneTrackingProcTag = 'trak', /* ControlUserPaneTrackingUPP*/
kControlUserPaneIdleProcTag = 'idle', /* ControlUserPaneIdleUPP*/
kControlUserPaneKeyDownProcTag = 'keyd', /* ControlUserPaneKeyDownUPP*/
kControlUserPaneActivateProcTag = 'acti', /* ControlUserPaneActivateUPP*/
kControlUserPaneFocusProcTag = 'foci', /* ControlUserPaneFocusUPP*/
kControlUserPaneBackgroundProcTag = 'back' /* ControlUserPaneBackgroundUPP (32-bit only)*/
};
typedef CALLBACK_API( void , ControlUserPaneDrawProcPtr )(ControlRef control, ControlPartCode part);
typedef CALLBACK_API( ControlPartCode , ControlUserPaneHitTestProcPtr )(ControlRef control, Point where);
typedef CALLBACK_API( ControlPartCode , ControlUserPaneTrackingProcPtr )(ControlRef control, Point startPt, ControlActionUPP actionProc);
typedef CALLBACK_API( void , ControlUserPaneIdleProcPtr )(ControlRef control);
typedef CALLBACK_API( ControlPartCode , ControlUserPaneKeyDownProcPtr )(ControlRef control, SInt16 keyCode, SInt16 charCode, SInt16 modifiers);
typedef CALLBACK_API( void , ControlUserPaneActivateProcPtr )(ControlRef control, Boolean activating);
typedef CALLBACK_API( ControlPartCode , ControlUserPaneFocusProcPtr )(ControlRef control, ControlFocusPart action);
typedef STACK_UPP_TYPE(ControlUserPaneDrawProcPtr) ControlUserPaneDrawUPP;
typedef STACK_UPP_TYPE(ControlUserPaneHitTestProcPtr) ControlUserPaneHitTestUPP;
typedef STACK_UPP_TYPE(ControlUserPaneTrackingProcPtr) ControlUserPaneTrackingUPP;
typedef STACK_UPP_TYPE(ControlUserPaneIdleProcPtr) ControlUserPaneIdleUPP;
typedef STACK_UPP_TYPE(ControlUserPaneKeyDownProcPtr) ControlUserPaneKeyDownUPP;
typedef STACK_UPP_TYPE(ControlUserPaneActivateProcPtr) ControlUserPaneActivateUPP;
typedef STACK_UPP_TYPE(ControlUserPaneFocusProcPtr) ControlUserPaneFocusUPP;
/*
* NewControlUserPaneDrawUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneDrawUPP
NewControlUserPaneDrawUPP(ControlUserPaneDrawProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewControlUserPaneHitTestUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneHitTestUPP
NewControlUserPaneHitTestUPP(ControlUserPaneHitTestProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewControlUserPaneTrackingUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneTrackingUPP
NewControlUserPaneTrackingUPP(ControlUserPaneTrackingProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewControlUserPaneIdleUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneIdleUPP
NewControlUserPaneIdleUPP(ControlUserPaneIdleProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewControlUserPaneKeyDownUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneKeyDownUPP
NewControlUserPaneKeyDownUPP(ControlUserPaneKeyDownProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewControlUserPaneActivateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneActivateUPP
NewControlUserPaneActivateUPP(ControlUserPaneActivateProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewControlUserPaneFocusUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneFocusUPP
NewControlUserPaneFocusUPP(ControlUserPaneFocusProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneDrawUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneDrawUPP(ControlUserPaneDrawUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneHitTestUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneHitTestUPP(ControlUserPaneHitTestUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneTrackingUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneTrackingUPP(ControlUserPaneTrackingUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneIdleUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneIdleUPP(ControlUserPaneIdleUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneKeyDownUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneKeyDownUPP(ControlUserPaneKeyDownUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneActivateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneActivateUPP(ControlUserPaneActivateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneFocusUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneFocusUPP(ControlUserPaneFocusUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneDrawUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeControlUserPaneDrawUPP(
ControlRef control,
ControlPartCode part,
ControlUserPaneDrawUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneHitTestUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlPartCode
InvokeControlUserPaneHitTestUPP(
ControlRef control,
Point where,
ControlUserPaneHitTestUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneTrackingUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlPartCode
InvokeControlUserPaneTrackingUPP(
ControlRef control,
Point startPt,
ControlActionUPP actionProc,
ControlUserPaneTrackingUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneIdleUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeControlUserPaneIdleUPP(
ControlRef control,
ControlUserPaneIdleUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneKeyDownUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlPartCode
InvokeControlUserPaneKeyDownUPP(
ControlRef control,
SInt16 keyCode,
SInt16 charCode,
SInt16 modifiers,
ControlUserPaneKeyDownUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneActivateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeControlUserPaneActivateUPP(
ControlRef control,
Boolean activating,
ControlUserPaneActivateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneFocusUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlPartCode
InvokeControlUserPaneFocusUPP(
ControlRef control,
ControlFocusPart action,
ControlUserPaneFocusUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if __MACH__
#ifdef __cplusplus
inline ControlUserPaneDrawUPP NewControlUserPaneDrawUPP(ControlUserPaneDrawProcPtr userRoutine) { return userRoutine; }
inline ControlUserPaneHitTestUPP NewControlUserPaneHitTestUPP(ControlUserPaneHitTestProcPtr userRoutine) { return userRoutine; }
inline ControlUserPaneTrackingUPP NewControlUserPaneTrackingUPP(ControlUserPaneTrackingProcPtr userRoutine) { return userRoutine; }
inline ControlUserPaneIdleUPP NewControlUserPaneIdleUPP(ControlUserPaneIdleProcPtr userRoutine) { return userRoutine; }
inline ControlUserPaneKeyDownUPP NewControlUserPaneKeyDownUPP(ControlUserPaneKeyDownProcPtr userRoutine) { return userRoutine; }
inline ControlUserPaneActivateUPP NewControlUserPaneActivateUPP(ControlUserPaneActivateProcPtr userRoutine) { return userRoutine; }
inline ControlUserPaneFocusUPP NewControlUserPaneFocusUPP(ControlUserPaneFocusProcPtr userRoutine) { return userRoutine; }
inline void DisposeControlUserPaneDrawUPP(ControlUserPaneDrawUPP) { }
inline void DisposeControlUserPaneHitTestUPP(ControlUserPaneHitTestUPP) { }
inline void DisposeControlUserPaneTrackingUPP(ControlUserPaneTrackingUPP) { }
inline void DisposeControlUserPaneIdleUPP(ControlUserPaneIdleUPP) { }
inline void DisposeControlUserPaneKeyDownUPP(ControlUserPaneKeyDownUPP) { }
inline void DisposeControlUserPaneActivateUPP(ControlUserPaneActivateUPP) { }
inline void DisposeControlUserPaneFocusUPP(ControlUserPaneFocusUPP) { }
inline void InvokeControlUserPaneDrawUPP(ControlRef control, ControlPartCode part, ControlUserPaneDrawUPP userUPP) { (*userUPP)(control, part); }
inline ControlPartCode InvokeControlUserPaneHitTestUPP(ControlRef control, Point where, ControlUserPaneHitTestUPP userUPP) { return (*userUPP)(control, where); }
inline ControlPartCode InvokeControlUserPaneTrackingUPP(ControlRef control, Point startPt, ControlActionUPP actionProc, ControlUserPaneTrackingUPP userUPP) { return (*userUPP)(control, startPt, actionProc); }
inline void InvokeControlUserPaneIdleUPP(ControlRef control, ControlUserPaneIdleUPP userUPP) { (*userUPP)(control); }
inline ControlPartCode InvokeControlUserPaneKeyDownUPP(ControlRef control, SInt16 keyCode, SInt16 charCode, SInt16 modifiers, ControlUserPaneKeyDownUPP userUPP) { return (*userUPP)(control, keyCode, charCode, modifiers); }
inline void InvokeControlUserPaneActivateUPP(ControlRef control, Boolean activating, ControlUserPaneActivateUPP userUPP) { (*userUPP)(control, activating); }
inline ControlPartCode InvokeControlUserPaneFocusUPP(ControlRef control, ControlFocusPart action, ControlUserPaneFocusUPP userUPP) { return (*userUPP)(control, action); }
#else
#define NewControlUserPaneDrawUPP(userRoutine) ((ControlUserPaneDrawUPP)userRoutine)
#define NewControlUserPaneHitTestUPP(userRoutine) ((ControlUserPaneHitTestUPP)userRoutine)
#define NewControlUserPaneTrackingUPP(userRoutine) ((ControlUserPaneTrackingUPP)userRoutine)
#define NewControlUserPaneIdleUPP(userRoutine) ((ControlUserPaneIdleUPP)userRoutine)
#define NewControlUserPaneKeyDownUPP(userRoutine) ((ControlUserPaneKeyDownUPP)userRoutine)
#define NewControlUserPaneActivateUPP(userRoutine) ((ControlUserPaneActivateUPP)userRoutine)
#define NewControlUserPaneFocusUPP(userRoutine) ((ControlUserPaneFocusUPP)userRoutine)
#define DisposeControlUserPaneDrawUPP(userUPP)
#define DisposeControlUserPaneHitTestUPP(userUPP)
#define DisposeControlUserPaneTrackingUPP(userUPP)
#define DisposeControlUserPaneIdleUPP(userUPP)
#define DisposeControlUserPaneKeyDownUPP(userUPP)
#define DisposeControlUserPaneActivateUPP(userUPP)
#define DisposeControlUserPaneFocusUPP(userUPP)
#define InvokeControlUserPaneDrawUPP(control, part, userUPP) (*userUPP)(control, part)
#define InvokeControlUserPaneHitTestUPP(control, where, userUPP) (*userUPP)(control, where)
#define InvokeControlUserPaneTrackingUPP(control, startPt, actionProc, userUPP) (*userUPP)(control, startPt, actionProc)
#define InvokeControlUserPaneIdleUPP(control, userUPP) (*userUPP)(control)
#define InvokeControlUserPaneKeyDownUPP(control, keyCode, charCode, modifiers, userUPP) (*userUPP)(control, keyCode, charCode, modifiers)
#define InvokeControlUserPaneActivateUPP(control, activating, userUPP) (*userUPP)(control, activating)
#define InvokeControlUserPaneFocusUPP(control, action, userUPP) (*userUPP)(control, action)
#endif
#endif
#if !__LP64__
typedef CALLBACK_API( void , ControlUserPaneBackgroundProcPtr )(ControlRef control, ControlBackgroundPtr info);
typedef STACK_UPP_TYPE(ControlUserPaneBackgroundProcPtr) ControlUserPaneBackgroundUPP;
/*
* NewControlUserPaneBackgroundUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlUserPaneBackgroundUPP
NewControlUserPaneBackgroundUPP(ControlUserPaneBackgroundProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlUserPaneBackgroundUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlUserPaneBackgroundUPP(ControlUserPaneBackgroundUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlUserPaneBackgroundUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeControlUserPaneBackgroundUPP(
ControlRef control,
ControlBackgroundPtr info,
ControlUserPaneBackgroundUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if __MACH__
#ifdef __cplusplus
inline ControlUserPaneBackgroundUPP NewControlUserPaneBackgroundUPP(ControlUserPaneBackgroundProcPtr userRoutine) { return userRoutine; }
inline void DisposeControlUserPaneBackgroundUPP(ControlUserPaneBackgroundUPP) { }
inline void InvokeControlUserPaneBackgroundUPP(ControlRef control, ControlBackgroundPtr info, ControlUserPaneBackgroundUPP userUPP) { (*userUPP)(control, info); }
#else
#define NewControlUserPaneBackgroundUPP(userRoutine) ((ControlUserPaneBackgroundUPP)userRoutine)
#define DisposeControlUserPaneBackgroundUPP(userUPP)
#define InvokeControlUserPaneBackgroundUPP(control, info, userUPP) (*userUPP)(control, info)
#endif
#endif
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HICONTAINERVIEWS__ */

View File

@@ -0,0 +1,60 @@
/*
File: HIContainerViews.r
Contains: Definition of the container views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HICONTAINERVIEWS_R__
#define __HICONTAINERVIEWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlGroupBoxTextTitleProc 160
#define kControlGroupBoxCheckBoxProc 161
#define kControlGroupBoxPopupButtonProc 162
#define kControlGroupBoxSecondaryTextTitleProc 164
#define kControlGroupBoxSecondaryCheckBoxProc 165
#define kControlGroupBoxSecondaryPopupButtonProc 166
#define kControlKindGroupBox 'grpb'
#define kControlKindCheckGroupBox 'cgrp'
#define kControlKindPopupGroupBox 'pgrp'
#define kControlGroupBoxMenuHandleTag 'mhan' /* MenuRef (popup title only) */
#define kControlGroupBoxMenuRefTag 'mhan' /* MenuRef (popup title only) */
#define kControlGroupBoxFontStyleTag 'font' /* ControlFontStyleRec */
#define kControlGroupBoxTitleRectTag 'trec' /* Rect. Rectangle that the title text/control is drawn in. (get only) */
#define kControlGroupBoxFrameRectTag 'frec'
#define kControlPlacardProc 224
#define kControlKindPlacard 'plac'
#define kControlWindowHeaderProc 336 /* normal header */
#define kControlWindowListViewHeaderProc 337 /* variant for list views - no bottom line */
#define kControlKindWindowHeader 'whed'
#define kControlWindowHeaderIsListHeaderTag 'islh'
#define kControlUserPaneProc 256
#define kControlKindUserPane 'upan'
#define kControlUserItemDrawProcTag 'uidp' /* UserItemUPP */
#define kControlUserPaneDrawProcTag 'draw' /* ControlUserPaneDrawUPP */
#define kControlUserPaneHitTestProcTag 'hitt' /* ControlUserPaneHitTestUPP */
#define kControlUserPaneTrackingProcTag 'trak' /* ControlUserPaneTrackingUPP */
#define kControlUserPaneIdleProcTag 'idle' /* ControlUserPaneIdleUPP */
#define kControlUserPaneKeyDownProcTag 'keyd' /* ControlUserPaneKeyDownUPP */
#define kControlUserPaneActivateProcTag 'acti' /* ControlUserPaneActivateUPP */
#define kControlUserPaneFocusProcTag 'foci' /* ControlUserPaneFocusUPP */
#define kControlUserPaneBackgroundProcTag 'back' /* ControlUserPaneBackgroundUPP (32-bit only) */
#endif /* __HICONTAINERVIEWS_R__ */

View File

@@ -0,0 +1,103 @@
/*
File: HIDataBrowser.r
Contains: API and type definitions related to Data Browser.
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIDATABROWSER_R__
#define __HIDATABROWSER_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlKindDataBrowser 'datb'
#define kDataBrowserNoView '????' /* Error State */
#define kDataBrowserListView 'lstv'
#define kDataBrowserColumnView 'clmv'
#define kDataBrowserDragSelect 0x01 /* <20> ListMgr lNoRect */
#define kDataBrowserSelectOnlyOne 0x02 /* <20> ListMgr lOnlyOne */
#define kDataBrowserResetSelection 0x04 /* <20> ListMgr lNoExtend */
#define kDataBrowserCmdTogglesSelection 0x08 /* <20> ListMgr lUseSense */
#define kDataBrowserNoDisjointSelection 0x10 /* <20> ListMgr lNoDisjoint */
#define kDataBrowserAlwaysExtendSelection 0x20 /* <20> ListMgr lExtendDrag */
#define kDataBrowserNeverEmptySelectionSet 0x40 /* <20> ListMgr lNoNilHilite */
#define kDataBrowserOrderUndefined 0 /* Not currently supported */
#define kDataBrowserOrderIncreasing 1
#define kDataBrowserOrderDecreasing 2
/* == Corresponding data type or structure == */
#define kDataBrowserCustomType '????' /* No associated data, custom callbacks used */
#define kDataBrowserIconType 'icnr' /* IconRef, IconTransformType, RGBColor */
#define kDataBrowserTextType 'text' /* CFStringRef */
#define kDataBrowserDateTimeType 'date' /* DateTime or LongDateTime */
#define kDataBrowserSliderType 'sldr' /* Min, Max, Value */
#define kDataBrowserCheckboxType 'chbx' /* ThemeButtonValue */
#define kDataBrowserProgressBarType 'prog' /* Min, Max, Value */
#define kDataBrowserRelevanceRankType 'rank' /* Min, Max, Value */
#define kDataBrowserPopupMenuType 'menu' /* MenuRef, Value */
#define kDataBrowserIconAndTextType 'ticn' /* IconRef, CFStringRef, etc */
#define kDataBrowserPropertyEnclosingPart 0
#define kDataBrowserPropertyContentPart '----'
#define kDataBrowserPropertyDisclosurePart 'disc'
#define kDataBrowserPropertyTextPart 'text'
#define kDataBrowserPropertyIconPart 'icnr'
#define kDataBrowserPropertySliderPart 'sldr'
#define kDataBrowserPropertyCheckboxPart 'chbx'
#define kDataBrowserPropertyProgressBarPart 'prog'
#define kDataBrowserPropertyRelevanceRankPart 'rank'
#define kDataBrowserUniversalPropertyFlagsMask 0xFF
#define kDataBrowserPropertyIsMutable 0x01
#define kDataBrowserDefaultPropertyFlags 0x00
#define kDataBrowserUniversalPropertyFlags 0xFF /* support for an old name */
#define kDataBrowserPropertyIsEditable 0x01 /* support for an old name */
#define kDataBrowserPropertyFlagsOffset 8
#define kDataBrowserPropertyFlagsMask 0xFF00
#define kDataBrowserCheckboxTriState 0x0100 /* kDataBrowserCheckboxType */
#define kDataBrowserDateTimeRelative 0x0100 /* kDataBrowserDateTimeType */
#define kDataBrowserDateTimeDateOnly 0x0200 /* kDataBrowserDateTimeType */
#define kDataBrowserDateTimeTimeOnly 0x0400 /* kDataBrowserDateTimeType */
#define kDataBrowserDateTimeSecondsToo 0x0800 /* kDataBrowserDateTimeType */
#define kDataBrowserSliderPlainThumb 0x00 /* kDataBrowserSliderType */
#define kDataBrowserSliderUpwardThumb 0x0100 /* kDataBrowserSliderType */
#define kDataBrowserSliderDownwardThumb 0x0200 /* kDataBrowserSliderType */
#define kDataBrowserDoNotTruncateText 0x0300 /* kDataBrowserTextType && kDataBrowserIconAndTextType */
#define kDataBrowserTruncateTextAtEnd 0x0200 /* kDataBrowserTextType && kDataBrowserIconAndTextType */
#define kDataBrowserTruncateTextMiddle 0x00 /* kDataBrowserTextType && kDataBrowserIconAndTextType */
#define kDataBrowserTruncateTextAtStart 0x0100 /* kDataBrowserTextType && kDataBrowserIconAndTextType */
#define kDataBrowserPopupMenuButtonless 0x0100 /* kDataBrowserPopupMenuType */
#define kDataBrowserPropertyModificationFlags 0xFF00 /* support for an old name */
#define kDataBrowserRelativeDateTime 0x0100 /* support for an old name */
#define kDataBrowserViewSpecificFlagsOffset 16
#define kDataBrowserViewSpecificFlagsMask 0x00FF0000
#define kDataBrowserViewSpecificPropertyFlags 0x00FF0000 /* support for an old name */
#define kDataBrowserClientPropertyFlagsOffset 24
#define kDataBrowserClientPropertyFlagsMask 0xFF000000
/* kDataBrowserTableView DataBrowserPropertyFlags */
#define kDataBrowserTableViewSelectionColumn 0x00010000
#define kDataBrowserListViewSelectionColumn 0x00010000
#define kDataBrowserListViewMovableColumn 0x00020000
#define kDataBrowserListViewSortableColumn 0x00040000
#define kDataBrowserListViewTypeSelectColumn 0x00080000
#define kDataBrowserListViewNoGapForIconInHeaderButton 0x00100000
#define kDataBrowserListViewDefaultColumnFlags 0x00060000
#endif /* __HIDATABROWSER_R__ */

View File

@@ -0,0 +1,382 @@
/*
File: HIToolbox/HIDisclosureViews.h
Contains: API and type definitions related to disclosure views.
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIDISCLOSUREVIEWS__
#define __HIDISCLOSUREVIEWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
#ifndef __MACWINDOWS__
#include <HIToolbox/MacWindows.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> DISCLOSURE BUTTON */
/* (CDEF 30) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* The HIObject class ID for the HIDisclosureButton class. */
#define kHIDisclosureButtonClassID CFSTR("com.apple.HIDisclosureButton")
#if !__LP64__
/*
* CreateDisclosureButtonControl()
*
* Summary:
* Creates a new instance of the Disclosure Button Control.
*
* Discussion:
* CreateDisclosureButtonControl is preferred over NewControl
* because it allows you to specify the exact set of parameters
* required to create the control without overloading parameter
* semantics. The initial minimum of the Disclosure Button will be
* kControlDisclosureButtonClosed, and the maximum will be
* kControlDisclosureButtonDisclosed.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inWindow:
* The WindowRef in which to create the control.
*
* inBoundsRect:
* The bounding rectangle for the control. The height of the
* control is fixed and the control will be centered vertically
* within the rectangle you specify.
*
* inValue:
* The initial value; either kControlDisclosureButtonClosed or
* kControlDisclosureButtonDisclosed.
*
* inAutoToggles:
* A boolean value indicating whether its value should change
* automatically after tracking the mouse.
*
* outControl:
* On successful exit, this will contain the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateDisclosureButtonControl(
WindowRef inWindow,
const Rect * inBoundsRect,
SInt32 inValue,
Boolean inAutoToggles,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Control Kind Tag */
#endif /* !__LP64__ */
enum {
kControlKindDisclosureButton = 'disb'
};
/*
* Discussion:
* Disclosure Button Values
*/
enum {
/*
* The control be drawn suggesting a closed state.
*/
kControlDisclosureButtonClosed = 0,
/*
* The control will be drawn suggesting an open state.
*/
kControlDisclosureButtonDisclosed = 1
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> DISCLOSURE TRIANGLE (CDEF 4) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This control can be used as either left or right facing. It can also handle its own */
/* tracking if you wish. This means that when the 'autotoggle' variant is used, if the */
/* user clicks the control, its state will change automatically from open to closed */
/* and vice-versa depending on its initial state. After a successful call to Track- */
/* Control, you can just check the current value to see what state it was switched to. */
/*
* Summary:
* Triangle proc IDs
*
* Discussion:
* This control can be used as either left or right facing. It can
* also handle its own tracking if you wish. This means that when
* the 'autotoggle' variant is used, if the user clicks the control,
* its state will change automatically from open to closed and
* vice-versa depending on its initial state. After a successful
* call to TrackControl, you can just check the current value to see
* what state it was switched to.
*/
enum {
kControlTriangleProc = 64,
kControlTriangleLeftFacingProc = 65,
kControlTriangleAutoToggleProc = 66,
kControlTriangleLeftFacingAutoToggleProc = 67
};
/*
* ControlDisclosureTriangleOrientation
*
* Summary:
* The orientations available to a disclosure triangle control.
*/
typedef UInt16 ControlDisclosureTriangleOrientation;
enum {
/*
* Points right on a left-to-right script system (Mac OS X and later
* or CarbonLib 1.5 and later only)
*/
kControlDisclosureTrianglePointDefault = 0,
kControlDisclosureTrianglePointRight = 1,
kControlDisclosureTrianglePointLeft = 2
};
/* Control Kind Tag */
enum {
kControlKindDisclosureTriangle = 'dist'
};
/* The HIObject class ID for the HIDisclosureTriangle class. */
#define kHIDisclosureTriangleClassID CFSTR("com.apple.HIDisclosureTriangle")
#if !__LP64__
/*
* CreateDisclosureTriangleControl()
*
* Summary:
* Creates a Disclosure Triangle control at a specific position in
* the specified window.
*
* Discussion:
* Disclosure Triangles are small controls that give the user a way
* to toggle the visibility of information or other user interface.
* When information is in a hidden state, a Disclosure Triangle is
* considered "closed" and should point to the right (or sometimes
* to the left). When the user clicks on it, the Disclosure Triangle
* rotates downwards into the "open" state. The application should
* repond by revealing the appropriate information or interface. On
* Mac OS X, a root control will be created for the window if one
* does not already exist. If a root control exists for the window,
* the Disclosure Triangle control will be embedded into it.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inWindow:
* The WindowRef into which the Disclosure Triangle will be
* created.
*
* inBoundsRect:
* The desired position (in coordinates local to the window's
* port) for the Disclosure Triangle.
*
* inOrientation:
* The direction the Disclosure Triangle should point when it is
* "closed". Passing kControlDisclosureTrianglePointDefault is
* only legal as of Mac OS X and CarbonLib 1.5.
*
* inTitle:
* The title for the Disclosure Triangle. The title will only be
* displayed if the inDrawTitle parameter is true. Title display
* only works on Mac OS X.
*
* inInitialValue:
* The starting value determines whether the Disclosure Triangle
* is initially in its "open" or "closed" state. The value 0
* represents the "closed" state and 1 represents the "open" state.
*
* inDrawTitle:
* A Boolean indicating whether the Disclosure Triangle should
* draw its title next to the widget. Title display only works on
* Mac OS X.
*
* inAutoToggles:
* A Boolean indicating whether the Disclosure Triangle should
* change its own value (from "open" to "closed" and vice-versa)
* automatically when it is clicked on.
*
* outControl:
* On successful output, outControl will contain a reference to
* the Disclosure Triangle control.
*
* Result:
* An OSStatus code indicating success or failure.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateDisclosureTriangleControl(
WindowRef inWindow,
const Rect * inBoundsRect,
ControlDisclosureTriangleOrientation inOrientation,
CFStringRef inTitle,
SInt32 inInitialValue,
Boolean inDrawTitle,
Boolean inAutoToggles,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* Summary:
* Tagged data supported by disclosure triangles
*/
enum {
/*
* An SInt16 for the last value that the control had.
*/
kControlTriangleLastValueTag = 'last'
};
#if !__LP64__
/*
* SetDisclosureTriangleLastValue()
*
* Summary:
* Set the last value that the control had.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inDisclosureTriangle:
* The disclosure triangle to affect.
*
* inValue:
* The last value.
*
* Result:
* An OSErr code indicating success or failure.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetDisclosureTriangleLastValue(
HIViewRef inDisclosureTriangle,
SInt16 inValue) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* HIDisclosureTriangleSetDisplaysTitle()
*
* Summary:
* Sets whether a disclosure triangle displays its title.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inDisclosureTriangle:
* The disclosure triangle to affect.
*
* inDisplaysTitle:
* A Boolean where true means "display the title" and false means
* "don't display the title".
*
* Result:
* An OSStatus code indicating success or failure.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
HIDisclosureTriangleSetDisplaysTitle(
HIViewRef inDisclosureTriangle,
Boolean inDisplaysTitle) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* HIDisclosureTriangleGetDisplaysTitle()
*
* Summary:
* Determines whether a disclosure triangle displays its title.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inDisclosureTriangle:
* The disclosure triangle to test.
*
* Result:
* A Boolean indicating if the view will display the title. The
* incoming disclosure triangle reference must be valid or the
* return value is undefined.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern Boolean
HIDisclosureTriangleGetDisplaysTitle(HIViewRef inDisclosureTriangle) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HIDISCLOSUREVIEWS__ */

View File

@@ -0,0 +1,35 @@
/*
File: HIDisclosureViews.r
Contains: API and type definitions related to disclosure views.
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIDISCLOSUREVIEWS_R__
#define __HIDISCLOSUREVIEWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlKindDisclosureButton 'disb'
#define kControlDisclosureButtonClosed 0
#define kControlDisclosureButtonDisclosed 1
#define kControlTriangleProc 64
#define kControlTriangleLeftFacingProc 65
#define kControlTriangleAutoToggleProc 66
#define kControlTriangleLeftFacingAutoToggleProc 67
#define kControlKindDisclosureTriangle 'dist'
#define kControlTriangleLastValueTag 'last'
#endif /* __HIDISCLOSUREVIEWS_R__ */

View File

@@ -0,0 +1,321 @@
/*
File: HIToolbox/HIGeometry.h
Contains: HIToolbox interfaces for geometry
Copyright: <20> 1984-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIGEOMETRY__
#define __HIGEOMETRY__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*
* HIPoint
*
* Discussion:
* HIPoint is a new, floating point-based type to help express
* coordinates in a much richer fashion than the classic QuickDraw
* points. It will, in time, be more heavily used throughout the
* Toolbox. For now, it is replacing our use of typeQDPoint in mouse
* events. This is to better support sub-pixel tablet coordinates.
* If you ask for a mouse location with typeQDPoint, and the point
* is actually stored as typeHIPoint, it will automatically be
* coerced to typeQDPoint for you, so this change should be largely
* transparent to applications. HIPoints are in screen space, i.e.
* the top left of the screen is 0, 0.
*/
typedef CGPoint HIPoint;
/*
* HISize
*
* Discussion:
* HISize is a floating point-based type to help express dimensions
* in a much richer fashion than the classic QuickDraw coordinates.
*/
typedef CGSize HISize;
/*
* HIRect
*
* Discussion:
* HIRect is a new, floating point-based type to help express
* rectangles in a much richer fashion than the classic QuickDraw
* rects. It will, in time, be more heavily used throughout the
* Toolbox. HIRects are in screen space, i.e. the top left of the
* screen is 0, 0.
*/
typedef CGRect HIRect;
#if !__LP64__
/*
* HIGetScaleFactor() *** DEPRECATED ***
*
* Discussion:
* This function is deprecated and should not be used by
* applications targeting Mac OS X 10.7 or later. Please use an
* appropriate AppKit API instead.
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* This function always returns 1.0.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only] but deprecated in 10.7
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern CGFloat
HIGetScaleFactor(void) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7;
#endif /* !__LP64__ */
/*
* HICoordinateSpace
*
* Summary:
* Coordinate spaces for use with HIPointConvert, HIRectConvert, and
* HISizeConvert.
*/
typedef UInt32 HICoordinateSpace;
enum {
/*
* The coordinate space defined by the position and sizes of the
* screen GDevices. More correctly, this is a 72 DPI coordinate space
* covering the screens. When the scale factor is not 1.0, this is
* the compatibility notion of global coordinates. When the scale
* factor is 1.0, this and kHICoordSpaceScreenPixel are the same.
*/
kHICoordSpace72DPIGlobal = 1,
/*
* The coordinate space defined by physical screen pixels. When the
* scale factor is 1.0, this and kHICoordSpace72DPIGlobal are the
* same.
*/
kHICoordSpaceScreenPixel = 2,
/*
* The coordinate space of a specified WindowRef, with { 0, 0 } at
* the top left of the window's structure. When this is passed to a
* conversion routine as a source or destination coordinate space,
* you must also pass a WindowRef as a source or destination object.
*/
kHICoordSpaceWindow = 3,
/*
* The coordinate space of a given HIViewRef, with { 0, 0 } at the
* top left of the view unless changed by HIViewSetBoundsOrigin. When
* this is passed to a conversion routine as a source or destination
* coordinate space, you must also pass an HIViewRef as a source or
* destination object.
*/
kHICoordSpaceView = 4
};
/*
* HIPointConvert()
*
* Discussion:
* This routine converts an HIPoint from one coordinate space to
* another. It takes into account the resolution-independent display
* scale factor as appropriate.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* ioPoint:
* The HIPoint to convert.
*
* inSourceSpace:
* The HICoordinateSpace constant specifying the source coordinate
* space that the point is to be converted from. Some coordinate
* spaces require the caller to pass extra information in the
* inSourceObject parameter.
*
* inSourceObject:
* An specific object defining the source coordinate space that
* the point is to be converted from. You might pass a WindowRef
* or an HIViewRef. If no object is necessary, you must pass NULL.
* See the HICoordinateSpace documentation for details on which
* HICoordinateSpaces require objects.
*
* inDestinationSpace:
* The HICoordinateSpace constant specifying the destination
* coordinate space that the point is to be converted to. Some
* coordinate spaces require the caller to pass extra information
* in the inDestinationObject parameter.
*
* inDestinationObject:
* An specific object defining the destination coordinate space
* that the point is to be converted to. You might pass a
* WindowRef or an HIViewRef. If no object is necessary, you must
* pass NULL. See the HICoordinateSpace documentation for details
* on which HICoordinateSpaces require objects.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern void
HIPointConvert(
HIPoint * ioPoint,
HICoordinateSpace inSourceSpace,
void * inSourceObject, /* can be NULL */
HICoordinateSpace inDestinationSpace,
void * inDestinationObject) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIRectConvert()
*
* Discussion:
* This routine converts an HIRect from one coordinate space to
* another. It takes into account the resolution-independent display
* scale factor as appropriate.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* ioRect:
* The HIRect to convert.
*
* inSourceSpace:
* The HICoordinateSpace constant specifying the source coordinate
* space that the rect is to be converted from. Some coordinate
* spaces require the caller to pass extra information in the
* inSourceObject parameter.
*
* inSourceObject:
* An specific object defining the source coordinate space that
* the rect is to be converted from. You might pass a WindowRef or
* an HIViewRef. If no object is necessary, you must pass NULL.
* See the HICoordinateSpace documentation for details on which
* HICoordinateSpaces require objects.
*
* inDestinationSpace:
* The HICoordinateSpace constant specifying the destination
* coordinate space that the rect is to be converted to. Some
* coordinate spaces require the caller to pass extra information
* in the inDestinationObject parameter.
*
* inDestinationObject:
* An specific object defining the destination coordinate space
* that the rect is to be converted to. You might pass a WindowRef
* or an HIViewRef. If no object is necessary, you must pass NULL.
* See the HICoordinateSpace documentation for details on which
* HICoordinateSpaces require objects.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern void
HIRectConvert(
HIRect * ioRect,
HICoordinateSpace inSourceSpace,
void * inSourceObject, /* can be NULL */
HICoordinateSpace inDestinationSpace,
void * inDestinationObject) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HISizeConvert()
*
* Discussion:
* This routine converts an HISize from one coordinate space to
* another. It takes into account the resolution-independent display
* scale factor as appropriate.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* ioSize:
* The HISize to convert.
*
* inSourceSpace:
* The HICoordinateSpace constant specifying the source coordinate
* space that the size is to be converted from. Some coordinate
* spaces require the caller to pass extra information in the
* inSourceObject parameter.
*
* inSourceObject:
* An specific object defining the source coordinate space that
* the size is to be converted from. You might pass a WindowRef or
* an HIViewRef. If no object is necessary, you must pass NULL.
* See the HICoordinateSpace documentation for details on which
* HICoordinateSpaces require objects.
*
* inDestinationSpace:
* The HICoordinateSpace constant specifying the destination
* coordinate space that the size is to be converted to. Some
* coordinate spaces require the caller to pass extra information
* in the inDestinationObject parameter.
*
* inDestinationObject:
* An specific object defining the destination coordinate space
* that the size is to be converted to. You might pass a WindowRef
* or an HIViewRef. If no object is necessary, you must pass NULL.
* See the HICoordinateSpace documentation for details on which
* HICoordinateSpaces require objects.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern void
HISizeConvert(
HISize * ioSize,
HICoordinateSpace inSourceSpace,
void * inSourceObject, /* can be NULL */
HICoordinateSpace inDestinationSpace,
void * inDestinationObject) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __HIGEOMETRY__ */

View File

@@ -0,0 +1,687 @@
/*
File: HIToolbox/HIImageViews.h
Contains: API and type definitions related to views that display image content.
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIIMAGEVIEWS__
#define __HIIMAGEVIEWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*==============================================================================*/
/* HIImageView */
/* */
/* The image view is a new view starting in Mac OS 10.2. It can only be used */
/* in a compositing window. Like all new HIFoo views, this view is initially */
/* invisible. You must show the view after creation. */
/*==============================================================================*/
/* The HIObject class ID for the HIImageView class. */
#define kHIImageViewClassID CFSTR("com.apple.HIImageView")
/*
*/
enum {
/*
* The control kind of the image view
*/
kControlKindHIImageView = 'imag'
};
#if !__LP64__
/*
* HIImageViewCreate()
*
* Discussion:
* Creates an image view. The view responds to the scrollable
* interface and can be used in a scrolling view. You can pass an
* image initially, or set one later.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inImage:
* An initial image, or NULL. You can set the image later via
* SetControlData.
*
* outView:
* The new image view.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIImageViewCreate(
CGImageRef inImage, /* can be NULL */
HIViewRef * outView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewSetOpaque()
*
* Discussion:
* Allows you to set whether an image view should be treated as
* opaque. If this is set to true, the image view can make certain
* optimizations for compositing and scrolling. The alpha-related
* image view APIs are rendered useless if opacity it set to true.
* An image view, when created, is transparent by default.
*
* NOTE: In Mac OS X 10.2, this view was documented as being opaque
* by default, but the implementation did not enforce that. So in
* Mac OS X 10.3 and beyond, the view is transparent by default, and
* you can make it opaque by calling HIImageViewSetOpaque.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to affect.
*
* inOpaque:
* The new opacity setting. Pass true to indicate you want the
* image to be treated as opaque.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIImageViewSetOpaque(
HIViewRef inView,
Boolean inOpaque) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewIsOpaque()
*
* Discussion:
* Allows you to determine whether an image view is opaque or not.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to query.
*
* Result:
* A boolean result, where true indicates the image view is opaque.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HIImageViewIsOpaque(HIViewRef inView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewSetAlpha()
*
* Discussion:
* Allows you to set the alpha for an image, making it more or less
* transparent. An alpha of 1.0 is fully opaque, and 0.0 is fully
* transparent. The default alpha for an image is 1.0.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to affect.
*
* inAlpha:
* The new alpha value.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIImageViewSetAlpha(
HIViewRef inView,
CGFloat inAlpha) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewGetAlpha()
*
* Discussion:
* Allows you to get the alpha for an image. An alpha of 1.0 is
* fully opaque, and 0.0 is fully transparent.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to query.
*
* Result:
* A floating point number representing the alpha from 0.0 through
* 1.0.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern CGFloat
HIImageViewGetAlpha(HIViewRef inView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewSetScaleToFit()
*
* Discussion:
* Normally an image view will clip to the view's bounds. Using this
* API, you can instead tell the image view to size the image to fit
* into the view bounds specified.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to affect.
*
* inScaleToFit:
* A boolean indicating whether the image should be scaled to fit
* the view bounds (true) or merely clip to the view bounds
* (false).
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIImageViewSetScaleToFit(
HIViewRef inView,
Boolean inScaleToFit) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewGetScaleToFit()
*
* Discussion:
* Returns whether or not an image view will scale the image it
* displays to the view bounds or merely clip to the view bounds. A
* true result means it scales.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to query.
*
* Result:
* A boolean result.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HIImageViewGetScaleToFit(HIViewRef inView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewSetImage()
*
* Discussion:
* Sets the image to display in an image view. The image passed in
* is retained by the view, so you may release the image after
* calling this API if you no longer need to reference it.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to affect.
*
* inImage:
* The image to set.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIImageViewSetImage(
HIViewRef inView,
CGImageRef inImage) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIImageViewCopyImage()
*
* Discussion:
* Gets the image for an image view. If there is no image set on the
* view, or the view ref is invalid, NULL is returned. The image is
* retained, so you should take care to release it when you are
* finished with it.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to query.
*
* Result:
* A CoreGraphics (Quartz) image ref.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern CGImageRef
HIImageViewCopyImage(HIViewRef inView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
#endif /* !__LP64__ */
/*
* HIImageViewAutoTransformOptions
*
* Summary:
* These are the available options for applying automatic transforms
* on image views and can be accessed with the
* HIImageViewSetAutoTransform and HIImageViewGetAutoTransform APIs.
*
* Discussion:
* Currently, the auto transforms for disabled or inactive image
* views is similar to the transform applied to the image of an
* image well or the image in a bevel button when those controls are
* disabled or inactive.
*/
typedef UInt32 HIImageViewAutoTransformOptions;
enum {
/*
* No transform is applied to the image.
*/
kHIImageViewAutoTransformNone = 0,
/*
* Transforms are applied to the image view's image when the view is
* disabled.
*/
kHIImageViewAutoTransformOnDisable = 1 << 0,
/*
* Transforms are applied to the image view's image when the view is
* deactivated.
*/
kHIImageViewAutoTransformOnDeactivate = 1 << 1
};
#if !__LP64__
/*
* HIImageViewSetAutoTransform()
*
* Discussion:
* Sets how an image view will automatically transform its image.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view for which to set the auto transform options.
*
* inOptions:
* A set of HIImageViewAutoTransformOptions bits.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
HIImageViewSetAutoTransform(
HIViewRef inView,
HIImageViewAutoTransformOptions inOptions) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* HIImageViewGetAutoTransform()
*
* Discussion:
* Gets how an image view is set to automatically transform its
* image.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The image view to query.
*
* Result:
* A value of HIImageViewAutoTransformOptions bits. The return value
* is undefined if the HIViewRef is invalid.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern HIImageViewAutoTransformOptions
HIImageViewGetAutoTransform(HIViewRef inView) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
#endif /* !__LP64__ */
/*
*/
enum {
/*
* This tag is used with GetControlData and SetControlData to get or
* set the CGImageRef associated with an HIImageView. This constant
* is deprecated; use the HIImageViewCopyImage and
* HIImageViewSetImage APIs to get or set the image for an image view.
*/
kHIImageViewImageTag = 'imag'
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> ICON CONTROL (CDEF 20) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Value parameter should contain the ID of the ICON or cicn you wish to display when */
/* creating controls of this type. If you don't want the control tracked at all, use */
/* the 'no track' variant. */
/* Icon control proc IDs */
enum {
kControlIconProc = 320,
kControlIconNoTrackProc = 321, /* immediately returns kControlIconPart*/
kControlIconSuiteProc = 322,
kControlIconSuiteNoTrackProc = 323 /* immediately returns kControlIconPart*/
};
enum {
/* icon ref controls may have either an icon, color icon, icon suite, or icon ref.*/
/* for data other than icon, you must set the data by passing a*/
/* ControlButtonContentInfo to SetControlData*/
kControlIconRefProc = 324,
kControlIconRefNoTrackProc = 325 /* immediately returns kControlIconPart*/
};
/* Control Kind Tag */
enum {
kControlKindIcon = 'icon'
};
/* The HIObject class ID for the HIIconView class. */
#define kHIIconViewClassID CFSTR("com.apple.HIIconView")
#if !__LP64__
/*
* CreateIconControl()
*
* Summary:
* Creates an Icon control at a specific position in the specified
* window.
*
* Discussion:
* Icon controls display an icon that (optionally) hilites when
* clicked on. On Mac OS X, a root control will be created for the
* window if one does not already exist. If a root control exists
* for the window, the Icon control will be embedded into it.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inWindow:
* The WindowRef into which the Icon control will be created. May
* be NULL on 10.3 and later.
*
* inBoundsRect:
* The desired position (in coordinates local to the window's
* port) for the Icon control.
*
* inIconContent:
* The descriptor for the icon you want the control to display.
* Mac OS X and CarbonLib 1.5 (and beyond) support all of the icon
* content types. Prior to CarbonLib 1.5, the only content types
* that are properly respected are kControlContentIconSuiteRes,
* kControlContentCIconRes, and kControlContentICONRes.
*
* inDontTrack:
* A Boolean value indicating whether the control should hilite
* when it is clicked on. False means hilite and track the mouse.
*
* outControl:
* On successful output, outControl will contain a reference to
* the Icon control.
*
* Result:
* An OSStatus code indicating success or failure.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateIconControl(
WindowRef inWindow, /* can be NULL */
const Rect * inBoundsRect,
const ControlButtonContentInfo * inIconContent,
Boolean inDontTrack,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by icon controls */
#endif /* !__LP64__ */
enum {
kControlIconTransformTag = 'trfm', /* IconTransformType*/
kControlIconAlignmentTag = 'algn' /* IconAlignmentType*/
};
/* Tags available with appearance 1.1 or later */
enum {
kControlIconResourceIDTag = 'ires', /* SInt16 resource ID of icon to use*/
kControlIconContentTag = kControlContentTag /* ControlImageContentInfo*/
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> IMAGE WELL (CDEF 11) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Image Wells allow you to control the content type (pict/icon/etc.) shown in the */
/* well. */
/* */
/* This is made possible by overloading the Min and Value parameters for the control. */
/* */
/* Parameter What Goes Here */
/* <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> */
/* Min content type (see constants for bevel buttons) */
/* Value Resource ID of content type, if resource-based. */
/* */
/* Handle-based Content */
/* <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> */
/* You can create your control and then set the content to an existing handle to an */
/* icon suite, etc. using the macros below. Please keep in mind that resource-based */
/* content is owned by the control, handle-based content is owned by you. The CDEF will*/
/* not try to dispose of handle-based content. If you are changing the content type of */
/* the button on the fly, you must make sure that if you are replacing a handle- */
/* based content with a resource-based content to properly dispose of the handle, */
/* else a memory leak will ensue. */
/* */
/* Image Well proc IDs */
enum {
kControlImageWellProc = 176
};
/* Control Kind Tag */
enum {
kControlKindImageWell = 'well'
};
/* The HIObject class ID for the HIImageWell class. */
#define kHIImageWellClassID CFSTR("com.apple.HIImageWell")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateImageWellControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateImageWellControl(
WindowRef window,
const Rect * boundsRect,
const ControlButtonContentInfo * info,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by image wells */
#endif /* !__LP64__ */
enum {
kControlImageWellContentTag = kControlContentTag, /* ControlImageContentInfo*/
kControlImageWellTransformTag = 'tran', /* IconTransformType*/
kControlImageWellIsDragDestinationTag = 'drag' /* Boolean*/
};
/* Helper routines are available only thru the shared library/glue. */
#if !__LP64__
/*
* GetImageWellContentInfo()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
GetImageWellContentInfo(
ControlRef inButton,
ControlButtonContentInfoPtr outContent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetImageWellContentInfo()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetImageWellContentInfo(
ControlRef inButton,
ControlButtonContentInfoPtr inContent) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetImageWellTransform()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetImageWellTransform(
ControlRef inButton,
IconTransformType inTransform) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HIIMAGEVIEWS__ */

View File

@@ -0,0 +1,48 @@
/*
File: HIImageViews.r
Contains: API and type definitions related to views that display image content.
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIIMAGEVIEWS_R__
#define __HIIMAGEVIEWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlIconProc 320
#define kControlIconNoTrackProc 321 /* immediately returns kControlIconPart */
#define kControlIconSuiteProc 322
#define kControlIconSuiteNoTrackProc 323 /* immediately returns kControlIconPart */
/* icon ref controls may have either an icon, color icon, icon suite, or icon ref. */
/* for data other than icon, you must set the data by passing a */
/* ControlButtonContentInfo to SetControlData */
#define kControlIconRefProc 324
#define kControlIconRefNoTrackProc 325 /* immediately returns kControlIconPart */
#define kControlKindIcon 'icon'
#define kControlIconTransformTag 'trfm' /* IconTransformType */
#define kControlIconAlignmentTag 'algn' /* IconAlignmentType */
#define kControlIconResourceIDTag 'ires' /* SInt16 resource ID of icon to use */
#define kControlIconContentTag 'cont' /* ControlImageContentInfo */
#define kControlImageWellProc 176
#define kControlKindImageWell 'well'
#define kControlImageWellContentTag 'cont' /* ControlImageContentInfo */
#define kControlImageWellTransformTag 'tran' /* IconTransformType */
#define kControlImageWellIsDragDestinationTag 'drag' /* Boolean */
#endif /* __HIIMAGEVIEWS_R__ */

View File

@@ -0,0 +1,121 @@
/*
File: HIToolbox/HILittleArrows.h
Contains: Definition of the little arrows view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HILITTLEARROWS__
#define __HILITTLEARROWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HILittleArrows.h
*
* Discussion:
* API definitions for the little arrows view.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> LITTLE ARROWS (CDEF 6) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This control implements the little up and down arrows that are used in clock views. */
/* Little Arrows proc IDs */
enum {
kControlLittleArrowsProc = 96
};
/* Control Kind Tag */
enum {
kControlKindLittleArrows = 'larr'
};
/*
* Summary:
* Tags available with Mac OS X 10.3 or later
*/
enum {
/*
* Passed data is an SInt32. Gets or sets the increment value of the
* control. Note that the little arrows control does not actually
* ever change its own value in response to clicks, and so it does
* not ever use the increment value; you must use an action proc to
* handle clicks on the control's arrows and change the control value
* yourself. However, you can store the increment value in the
* control's data and read it later with GetControlData.
*/
kControlLittleArrowsIncrementValueTag = 'incr'
};
/* The HIObject class ID for the HILittleArrows class. */
#define kHILittleArrowsClassID CFSTR("com.apple.HILittleArrows")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateLittleArrowsControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateLittleArrowsControl(
WindowRef window,
const Rect * boundsRect,
SInt32 value,
SInt32 minimum,
SInt32 maximum,
SInt32 increment,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HILITTLEARROWS__ */

View File

@@ -0,0 +1,27 @@
/*
File: HILittleArrows.r
Contains: Definition of the little arrows view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HILITTLEARROWS_R__
#define __HILITTLEARROWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlLittleArrowsProc 96
#define kControlKindLittleArrows 'larr'
#define kControlLittleArrowsIncrementValueTag 'incr'
#endif /* __HILITTLEARROWS_R__ */

View File

@@ -0,0 +1,142 @@
/*
File: HIToolbox/HIMenuView.h
Contains: Definition of the base and standard menu views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIMENUVIEW__
#define __HIMENUVIEW__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
#ifndef __MENUS__
#include <HIToolbox/Menus.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIMenuView.h
*
* Discussion:
* API definitions for the base and standard menu views.
*/
/*==============================================================================*/
/* HIMenuView */
/* */
/* HIMenuView and HIStandardMenuView are new views available in Mac OS X 10.3. */
/* HIMenuView is intended for use as a base class for custom menu item views; */
/* it does not draw or handle events itself, but provides useful functionality */
/* that all menu views need to implement. HIStandardMenuView is the standard */
/* HIView used by the Menu Manager to draw menu item content, beginning with */
/* Mac OS X 10.3. It can also be subclassed by custom menu item views. */
/* Both of these views are meant to be used only in compositing windows. */
/* */
/* Because HIMenuView and HIStandardMenuView are not typically created */
/* directly by applications, no API is provided to create instances of these */
/* views. If you need to create an instance of either view, you can use */
/* HIObjectCreate. */
/*==============================================================================*/
/* the HIObject class ID for the HIMenuView class*/
#define kHIMenuViewClassID CFSTR("com.apple.HIMenuView")
/* the HIObject class ID for the standard menu HIView class*/
#define kHIStandardMenuViewClassID CFSTR("com.apple.HIStandardMenuView")
/* Control Kinds (only used in Mac OS X 10.4 and later)*/
enum {
kControlKindHIMenuView = 'menu',
kControlKindHIStandardMenuView = 'smnu'
};
/*
The kEventHIObjectInitialize event for HIMenuView and HIStandardMenuView is expected to contain
the following parameters. Be sure to include these parameters in the init event if you create an
instance of these views with HIObjectCreate.
--> kEventParamMenuRef (in, typeMenuRef)
The menu that the view should draw.
*/
/*
* kHIViewMenuContentID
*
* Summary:
* The HIViewID for the menu content view. The Menu Manager assigns
* this view ID to all menu content views.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewMenuContentID AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
#if !__LP64__
/*
* HIMenuViewGetMenu()
*
* Summary:
* Returns the MenuRef that is associated with an HIView that is a
* subclass of HIMenuView.
*
* Discussion:
* An HIMenuView subclass might use this API to determine the menu
* that it should draw. Prior to Mac OS X 10.5, this API returns
* NULL if passed an instance of the standard menu view. In Mac OS X
* 10.5 and later, this API correctly returns the owning menu of an
* instance of the standard menu view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The view whose menu to return.
*
* Result:
* The MenuRef associated with the HIView, or NULL if an HIView is
* passed that is not a subclass of HIMenuView.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern MenuRef
HIMenuViewGetMenu(HIViewRef inView) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HIMENUVIEW__ */

View File

@@ -0,0 +1,300 @@
/*
File: HIToolbox/HIPopupButton.h
Contains: Definitions of the popup button and popup arrow views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIPOPUPBUTTON__
#define __HIPOPUPBUTTON__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIPopupButton.h
*
* Discussion:
* API definitions for the popup button and popup arrow views.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> POPUP BUTTON (CDEF 25) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This is the new Appearance Popup Button. It takes the same variants and does the */
/* same overloading as the previous popup menu control. There are some differences: */
/* */
/* Passing in a menu ID of -12345 causes the popup not to try and get the menu from a */
/* resource. Instead, you can build the menu and later stuff the MenuRef field in */
/* the popup data information. */
/* */
/* You can pass -1 in the Max parameter to have the control calculate the width of the */
/* title on its own instead of guessing and then tweaking to get it right. It adds the */
/* appropriate amount of space between the title and the popup. */
/* */
/* Theme Popup Button proc IDs */
enum {
kControlPopupButtonProc = 400,
kControlPopupFixedWidthVariant = 1 << 0,
kControlPopupVariableWidthVariant = 1 << 1,
kControlPopupUseAddResMenuVariant = 1 << 2,
kControlPopupUseWFontVariant = kControlUsesOwningWindowsFontVariant
};
/* Control Kind Tag */
enum {
kControlKindPopupButton = 'popb'
};
/* The HIObject class ID for the HIPopupButton class. */
#define kHIPopupButtonClassID CFSTR("com.apple.HIPopupButton")
#if !__LP64__
/*
* CreatePopupButtonControl()
*
* Summary:
* Creates a popup button control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounding box of the control.
*
* title:
* The title of the control.
*
* menuID:
* The ID of a menu that should be used by the control. A menu
* with this ID should be inserted into the menubar with
* InsertMenu(menu, kInsertHierarchicalMenu). You can also pass
* -12345 to have the control delay its acquisition of a menu; in
* this case, you can build the menu and later provide it to the
* control with SetControlData and kControlPopupButtonMenuRefTag
* or kControlPopupButtonOwnedMenuRefTag.
*
* variableWidth:
* Whether the width of the control is allowed to vary according
* to the width of the selected menu item text, or should remain
* fixed to the original control bounds width.
*
* titleWidth:
* The width of the title.
*
* titleJustification:
* The justification of the title.
*
* titleStyle:
* A QuickDraw style bitfield indicating the font style of the
* title.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreatePopupButtonControl(
WindowRef window, /* can be NULL */
const Rect * boundsRect,
CFStringRef title,
MenuID menuID,
Boolean variableWidth,
SInt16 titleWidth,
SInt16 titleJustification,
Style titleStyle,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* These tags are available in 1.0.1 or later of Appearance */
#endif /* !__LP64__ */
enum {
kControlPopupButtonMenuHandleTag = 'mhan', /* MenuRef*/
kControlPopupButtonMenuRefTag = 'mhan', /* MenuRef*/
kControlPopupButtonMenuIDTag = 'mnid' /* SInt16*/
};
/* These tags are available in 1.1 or later of Appearance */
enum {
kControlPopupButtonExtraHeightTag = 'exht', /* SInt16 - extra vertical whitespace within the button*/
kControlPopupButtonOwnedMenuRefTag = 'omrf' /* MenuRef*/
};
/* These tags are available in Mac OS X */
enum {
kControlPopupButtonCheckCurrentTag = 'chck' /* Boolean - whether the popup puts a checkmark next to the current item (defaults to true)*/
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> POPUP ARROW (CDEF 12) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* The popup arrow CDEF is used to draw the small arrow normally associated with a */
/* popup control. The arrow can point in four directions, and a small or large version */
/* can be used. This control is provided to allow clients to draw the arrow in a */
/* normalized fashion which will take advantage of themes automatically. */
/* */
/* Popup Arrow proc IDs */
enum {
kControlPopupArrowEastProc = 192,
kControlPopupArrowWestProc = 193,
kControlPopupArrowNorthProc = 194,
kControlPopupArrowSouthProc = 195,
kControlPopupArrowSmallEastProc = 196,
kControlPopupArrowSmallWestProc = 197,
kControlPopupArrowSmallNorthProc = 198,
kControlPopupArrowSmallSouthProc = 199
};
/* Popup Arrow Orientations */
enum {
kControlPopupArrowOrientationEast = 0,
kControlPopupArrowOrientationWest = 1,
kControlPopupArrowOrientationNorth = 2,
kControlPopupArrowOrientationSouth = 3
};
typedef UInt16 ControlPopupArrowOrientation;
/* Popup Arrow Size */
enum {
kControlPopupArrowSizeNormal = 0,
kControlPopupArrowSizeSmall = 1
};
typedef UInt16 ControlPopupArrowSize;
/* Control Kind Tag */
enum {
kControlKindPopupArrow = 'parr'
};
/* The HIObject class ID for the HIPopupArrow class. */
#define kHIPopupArrowClassID CFSTR("com.apple.hipopuparrow")
#if !__LP64__
/*
* CreatePopupArrowControl()
*
* Summary:
* Creates a popup arrow control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounding box of the control.
*
* orientation:
* The orientation of the control.
*
* size:
* The size of the control.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreatePopupArrowControl(
WindowRef window, /* can be NULL */
const Rect * boundsRect,
ControlPopupArrowOrientation orientation,
ControlPopupArrowSize size,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*--------------------------------------------------------------------------------------*/
/* <20> DEPRECATED */
/* */
/* All declarations below this point are either deprecated (they continue to function */
/* but are not the most modern nor most efficient solution to a problem), or they are */
/* completely unavailable on Mac OS X. */
/*--------------------------------------------------------------------------------------*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> Pop-Up Menu Control Constants */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Variant codes for the System 7 pop-up menu*/
#endif /* !__LP64__ */
enum {
popupFixedWidth = 1 << 0,
popupVariableWidth = 1 << 1,
popupUseAddResMenu = 1 << 2,
popupUseWFont = 1 << 3
};
/* Menu label styles for the System 7 pop-up menu*/
enum {
popupTitleBold = 1 << 8,
popupTitleItalic = 1 << 9,
popupTitleUnderline = 1 << 10,
popupTitleOutline = 1 << 11,
popupTitleShadow = 1 << 12,
popupTitleCondense = 1 << 13,
popupTitleExtend = 1 << 14,
popupTitleNoStyle = 1 << 15
};
/* Menu label justifications for the System 7 pop-up menu*/
enum {
popupTitleLeftJust = 0x00000000,
popupTitleCenterJust = 0x00000001,
popupTitleRightJust = 0x000000FF
};
#ifdef __cplusplus
}
#endif
#endif /* __HIPOPUPBUTTON__ */

View File

@@ -0,0 +1,75 @@
/*
File: HIPopupButton.r
Contains: Definitions of the popup button and popup arrow views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIPOPUPBUTTON_R__
#define __HIPOPUPBUTTON_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlPopupButtonProc 400
#define kControlPopupFixedWidthVariant 0x01
#define kControlPopupVariableWidthVariant 0x02
#define kControlPopupUseAddResMenuVariant 0x04
#define kControlPopupUseWFontVariant 0x08
#define kControlKindPopupButton 'popb'
#define kControlPopupButtonMenuHandleTag 'mhan' /* MenuRef */
#define kControlPopupButtonMenuRefTag 'mhan' /* MenuRef */
#define kControlPopupButtonMenuIDTag 'mnid' /* SInt16 */
#define kControlPopupButtonExtraHeightTag 'exht' /* SInt16 - extra vertical whitespace within the button */
#define kControlPopupButtonOwnedMenuRefTag 'omrf' /* MenuRef */
#define kControlPopupButtonCheckCurrentTag 'chck' /* Boolean - whether the popup puts a checkmark next to the current item (defaults to true) */
#define kControlPopupArrowEastProc 192
#define kControlPopupArrowWestProc 193
#define kControlPopupArrowNorthProc 194
#define kControlPopupArrowSouthProc 195
#define kControlPopupArrowSmallEastProc 196
#define kControlPopupArrowSmallWestProc 197
#define kControlPopupArrowSmallNorthProc 198
#define kControlPopupArrowSmallSouthProc 199
#define kControlPopupArrowOrientationEast 0
#define kControlPopupArrowOrientationWest 1
#define kControlPopupArrowOrientationNorth 2
#define kControlPopupArrowOrientationSouth 3
#define kControlPopupArrowSizeNormal 0
#define kControlPopupArrowSizeSmall 1
#define kControlKindPopupArrow 'parr'
#define popupFixedWidth 0x01
#define popupVariableWidth 0x02
#define popupUseAddResMenu 0x04
#define popupUseWFont 0x08
#define popupTitleBold 0x0100
#define popupTitleItalic 0x0200
#define popupTitleUnderline 0x0400
#define popupTitleOutline 0x0800
#define popupTitleShadow 0x1000
#define popupTitleCondense 0x2000
#define popupTitleExtend 0x4000
#define popupTitleNoStyle 0x8000
#define popupTitleLeftJust 0x00000000
#define popupTitleCenterJust 0x00000001
#define popupTitleRightJust 0x000000FF
#endif /* __HIPOPUPBUTTON_R__ */

View File

@@ -0,0 +1,156 @@
/*
File: HIToolbox/HIProgressViews.h
Contains: Definition of the progress-display views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIPROGRESSVIEWS__
#define __HIPROGRESSVIEWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIProgressViews.h
*
* Discussion:
* API definitions for the views that display progress: the progress
* bar and the chasing arrows.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> PROGRESS INDICATOR (CDEF 5) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This CDEF implements both determinate and indeterminate progress bars. To switch, */
/* just use SetControlData to set the indeterminate flag to make it indeterminate. Any */
/* animation will automatically be handled by the toolbox on an event timer. */
/* Progress Bar proc IDs */
enum {
kControlProgressBarProc = 80,
kControlRelevanceBarProc = 81
};
/* Control Kind Tag */
enum {
kControlKindProgressBar = 'prgb',
kControlKindRelevanceBar = 'relb'
};
/* The HIObject class ID for the HIProgressBar class. */
#define kHIProgressBarClassID CFSTR("com.apple.HIProgressBar")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateProgressBarControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateProgressBarControl(
WindowRef window,
const Rect * boundsRect,
SInt32 value,
SInt32 minimum,
SInt32 maximum,
Boolean indeterminate,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by progress bars */
#endif /* !__LP64__ */
enum {
kControlProgressBarIndeterminateTag = 'inde', /* Boolean*/
kControlProgressBarAnimatingTag = 'anim' /* Boolean*/
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> CHASING ARROWS (CDEF 7) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This control will automatically animate via an event loop timer. */
/* */
/* Chasing Arrows proc IDs */
enum {
kControlChasingArrowsProc = 112
};
/* Control Kind Tag */
enum {
kControlKindChasingArrows = 'carr'
};
/* The HIObject class ID for the HIChasingArrows class. */
#define kHIChasingArrowsClassID CFSTR("com.apple.HIChasingArrows")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateChasingArrowsControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateChasingArrowsControl(
WindowRef window,
const Rect * boundsRect,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by the Chasing Arrows control */
#endif /* !__LP64__ */
enum {
kControlChasingArrowsAnimatingTag = 'anim' /* Boolean*/
};
#ifdef __cplusplus
}
#endif
#endif /* __HIPROGRESSVIEWS__ */

View File

@@ -0,0 +1,36 @@
/*
File: HIProgressViews.r
Contains: Definition of the progress-display views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIPROGRESSVIEWS_R__
#define __HIPROGRESSVIEWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlProgressBarProc 80
#define kControlRelevanceBarProc 81
#define kControlKindProgressBar 'prgb'
#define kControlKindRelevanceBar 'relb'
#define kControlProgressBarIndeterminateTag 'inde' /* Boolean */
#define kControlProgressBarAnimatingTag 'anim' /* Boolean */
#define kControlChasingArrowsProc 112
#define kControlKindChasingArrows 'carr'
#define kControlChasingArrowsAnimatingTag 'anim' /* Boolean */
#endif /* __HIPROGRESSVIEWS_R__ */

View File

@@ -0,0 +1,88 @@
/*
File: HIToolbox/HIRelevanceBar.h
Contains: Definition of the relevance bar view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIRELEVANCEBAR__
#define __HIRELEVANCEBAR__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIRelevanceBar.h
*
* Discussion:
* API definitions for the relevance bar view.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> RELEVANCE BAR */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* The HIObject class ID for the HIRelevanceBar class. */
#define kHIRelevanceBarClassID CFSTR("com.apple.HIRelevanceBar")
#if !__LP64__
/*
* CreateRelevanceBarControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateRelevanceBarControl(
WindowRef window,
const Rect * boundsRect,
SInt32 value,
SInt32 minimum,
SInt32 maximum,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HIRELEVANCEBAR__ */

View File

@@ -0,0 +1,656 @@
/*
File: HIToolbox/HIScrollView.h
Contains: Definition of the scrollbar and scroll views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISCROLLVIEW__
#define __HISCROLLVIEW__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIScrollView.h
*
* Discussion:
* API definitions for the scrollbar and scroll views.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> SCROLL BAR (CDEF 24) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* This is the new Appearance scroll bar. */
/* */
/* Mac OS X has a "Scroll to here" option in the General pane of System Preferences */
/* which allows users to click in the page up/down regions of a scroll bar and have */
/* the thumb/indicator jump directly to the clicked position, which alters the value */
/* of the scroll bar and moves the scrolled content appropriately. As long as the */
/* mouse button is held down, the click is treated as though the user had clicked in */
/* the thumb/indicator in the first place. */
/* */
/* If you want the scroll bars in your application to work with the "Scroll to here" */
/* option, you must do the following: */
/* */
/* 1. Create live-tracking scroll bars, not scroll bars that show a "ghost" thumb */
/* when you click on it. You can request live-tracking scroll bars by passing true */
/* in the liveTracking parameter to CreateScrollBarControl. If you create scroll bars */
/* with NewControl, use the kControlScrollBarLiveProc. */
/* */
/* 2. Write an appropriate ControlActionProc and associate it with your scroll bar */
/* via the SetControlAction API. This allows your application to update its content */
/* appropriately when the live-tracking scroll bar is clicked. */
/* */
/* 3. When calling HandleControlClick or TrackControl, pass -1 in the action proc */
/* parameter. This is a request for the Control Manager to use the action proc you */
/* associated with your control in step 2. If you rely on the standard window event */
/* handler to do your control tracking, this step is handled for you automatically. */
/* */
/* Theme Scroll Bar proc IDs */
enum {
kControlScrollBarProc = 384, /* normal scroll bar*/
kControlScrollBarLiveProc = 386 /* live scrolling variant*/
};
/* Control Kind Tag */
enum {
kControlKindScrollBar = 'sbar'
};
/* The HIObject class ID for the HIScrollBar class. */
#define kHIScrollBarClassID CFSTR("com.apple.HIScrollBar")
#if !__LP64__
/*
* CreateScrollBarControl()
*
* Summary:
* Creates a scroll bar control.
*
* Discussion:
* This creation API is available in Carbon only.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window that should contain the control. May be NULL on 10.3
* and later.
*
* boundsRect:
* The bounding box of the control.
*
* value:
* The initial value of the control.
*
* minimum:
* The minimum value of the control.
*
* maximum:
* The maximum value of the control.
*
* viewSize:
* The size of the visible area of the scroll bar content.
*
* liveTracking:
* A Boolean indicating whether or not live tracking is enabled
* for this scroll bar. If set to true and a valid
* liveTrackingProc is also passed in, the callback will be called
* repeatedly as the thumb is moved during tracking. If set to
* false, a semi-transparent thumb called a "ghost thumb" will
* draw and no live tracking will occur.
*
* liveTrackingProc:
* If liveTracking is on, a ControlActionUPP callback to be called
* as the control live tracks. This callback is called repeatedly
* as the scroll thumb is moved during tracking.
*
* outControl:
* On exit, contains the new control.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateScrollBarControl(
WindowRef window,
const Rect * boundsRect,
SInt32 value,
SInt32 minimum,
SInt32 maximum,
SInt32 viewSize,
Boolean liveTracking,
ControlActionUPP liveTrackingProc,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* These tags are available in Mac OS X or later */
#endif /* !__LP64__ */
enum {
kControlScrollBarShowsArrowsTag = 'arro' /* Boolean whether or not to draw the scroll arrows*/
};
/*==============================================================================*/
/* HIScrollView */
/* */
/* The scroll view is a new view starting in Mac OS 10.2. It can be used in */
/* the new compositing mode ONLY due to the nature of how it works. Like all */
/* new HIFoo views, this view is created invisibly. You must show the view */
/* after creation if you want to, like, see it and stuff. */
/* The HIScrollView will set the frame of the contained view when its bounds */
/* change, so it is not necessary to set up the layout of the embedded view. */
/* */
/* Using an HIScrollView requires a few steps: */
/* */
/* 1. Install your scrollable content view into the HIScrollView instance using */
/* HIViewAddSubview. */
/* */
/* 2. If the scrollable content view doesn't already handle the */
/* kEventScrollableGetInfo and kEventScrollableScrollTo events, you must */
/* install handlers on your scrollable content view and handle those events */
/* manually. More details on those events can be found below. */
/* */
/* 3. If the scrollable content view doesn't already send out the */
/* kEventScrollableInfoChanged event to its parent view, you must send this */
/* event to the HIScrollView instance whenever your scrollable content */
/* view's size or origin changes. More details on this event can be found */
/* below. */
/*==============================================================================*/
/* The HIObject class ID for the HIScrollView class. */
#define kHIScrollViewClassID CFSTR("com.apple.HIScrollView")
/* Control Kind*/
enum {
kControlKindHIScrollView = 'scrl'
};
/*
kEventClassScrollable quick reference:
kEventScrollableGetInfo = 1,
kEventScrollableInfoChanged = 2,
kEventScrollableScrollTo = 10
*/
enum {
kEventClassScrollable = 'scrl'
};
/*
*/
enum {
/*
* The image size is the total size of the scrollable view, including
* any parts of the view that are not currently visible. For example,
* a scrollable view that displays a 100-page document would return a
* horizontal size equal to the width of a page and a vertical image
* size equal to 100 times the height of a page.
*/
kEventParamImageSize = 'imsz', /* typeHISize*/
/*
* The view size is the current size of the scrollable view.
* Typically, this is the same as the view's bounds, and can be
* acquired by calling HIViewGetBounds.
*/
kEventParamViewSize = 'vwsz', /* typeHISize*/
/*
* The line size is the distance that the HIScrollView should scroll
* its subview when the user clicks the scroll bar arrows. For
* example, this might be 10 pixels vertically and 20 pixels
* horizontally.
*/
kEventParamLineSize = 'lnsz', /* typeHISize*/
/*
* The origin is the current view-relative origin with the total
* scrollable image that is displayed at the top left corner of the
* view. These coordinates should always be greater than or equal to
* zero. They should be less than or equal to the view<65>s image size
* minus its view size. Typically, a view that implements the
* kEventScrollableScrollTo event by calling HIViewSetBoundsOrigin
* will return the current bounds origin for this parameter, and a
* view that implements the ScrollTo event by storing the origin in
* its instance data will return its stored origin for this
* parameter. For example, a scrollable view that is currently
* displaying page 10 of a 100-page document would return a
* horizontal origin of zero and a vertical origin equal to 10 times
* the height of a page.
*/
kEventParamOrigin = 'orgn' /* typeHIPoint*/
};
/*
* kEventClassScrollable / kEventScrollableGetInfo
*
* Summary:
* Requests information from an HIScrollView<65>s scrollable view about
* its size and origin.
*
* Discussion:
* This event is sent by an HIScrollView to its scrollable view to
* determine the current size and origin of the scrollable view. A
* scrollable view must implement this event in order to scroll
* properly inside an HIScrollView. This event is sent only to the
* view, and is not propagated past it.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* <-- kEventParamImageSize (out, typeHISize)
* On exit, contains the size of the entire scrollable view.
*
* <-- kEventParamViewSize (out, typeHISize)
* On exit, contains the amount of the scrollable view that is
* visible.
*
* <-- kEventParamLineSize (out, typeHISize)
* On exit, contains the amount that should be scrolled in
* response to a single click on a scrollbar arrow.
*
* <-- kEventParamOrigin (out, typeHIPoint)
* On exit, contains the scrollable view<65>s current origin.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventScrollableGetInfo = 1
};
/*
* kEventClassScrollable / kEventScrollableInfoChanged
*
* Summary:
* Notification that the size or origin of an HIScrollView<65>s
* scrollable view has changed.
*
* Discussion:
* This event is not sent by HIScrollView itself; rather, it may be
* sent to an instance of HIScrollView to notify the scroll view
* that the size or origin of its scrollable view have changed. The
* HIScrollView responds to this event by sending a
* kEventScrollableGetInfo to its scrollable view. It then updates
* the scroll bars appropriately to reflect the new reality of the
* scrollable view. It does NOT move the origin of the scrollable
* view at all. It is just a notification to allow the scroll view
* to sync up with its scrollable view.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventScrollableInfoChanged = 2
};
/*
* kEventClassScrollable / kEventScrollableScrollTo
*
* Summary:
* Requests that an HIScrollView<65>s scrollable view should scroll to
* a particular origin.
*
* Discussion:
* This event is sent by an HIScrollView to its scrollable view to
* request that the scrollable view update its current origin and
* redraw. Typically, a scrollable view scrolls its content either
* by setting its bounds origin with HIViewSetBoundsOrigin or by
* offsetting its drawing by the scroll origin. If the view embeds
* other views, it must use HIViewSetBoundsOrigin to allow the
* embedded views to scroll along with their containing view. A view
* that uses HIViewSetBoundsOrigin should call that API in response
* to this event; a view that offsets its drawing by the scroll
* origin should update its current origin in its own instance data
* in response to this event. A scrollable view should also use
* either HIViewScrollRect to scroll its content, or
* HIViewSetNeedsDisplay to cause itself to redraw using the new
* origin point. A scrollable view must implement this event in
* order to scroll properly inside an HIScrollView.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamOrigin (in, typeHIPoint)
* The new origin for the scrollable view. The origin
* coordinates will vary from (0,0) to the scrollable view<65>s
* image size minus its view size.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventScrollableScrollTo = 10
};
/*
* Summary:
* HIScrollView options
*/
enum {
/*
* This indicates that a vertical scroll bar is desired.
*/
kHIScrollViewOptionsVertScroll = (1 << 0),
/*
* This indicates that a horizontal scroll bar is desired.
*/
kHIScrollViewOptionsHorizScroll = (1 << 1),
/*
* This indicates that space for a grow box should be taken into
* account when laying out scroll bars. On Mac OS X 10.3 and earlier,
* if both the horizontal and vertical scroll bars are requested,
* this attribute is assumed. On Mac OS X 10.4 and later, this
* attribute is *NOT* assumed; this allows the scroll view to support
* auto-hiding of the two scroll bars independently on Mac OS X 10.4
* and later. If you want to preserve space for the grow box on all
* systems, specify this option bit.
*/
kHIScrollViewOptionsAllowGrow = (1 << 2),
/*
* This indicates that if the grow area is visible, then the scroll
* view should fill it with white. Available in Mac OS X 10.5 and
* later.
*/
kHIScrollViewOptionsFillGrowArea = (1 << 3),
/*
* Indicates that the scroll view should never use smooth scrolling,
* overriding the user's preference. Applications should rarely use
* this option, but it may be appropriate for certain cases.
*/
kHIScrollViewOptionsDisableSmoothScrolling = 1 << 4,
kHIScrollViewValidOptions = (kHIScrollViewOptionsVertScroll | kHIScrollViewOptionsHorizScroll | kHIScrollViewOptionsAllowGrow | kHIScrollViewOptionsFillGrowArea | kHIScrollViewOptionsDisableSmoothScrolling)
};
/*
* HIScrollViewAction
*
* Summary:
* HIScrollView navigation actions. See HIScrollViewNavigate for
* more information.
*/
typedef UInt32 HIScrollViewAction;
enum {
/*
* The scroll view should move to the top of the content.
*/
kHIScrollViewScrollToTop = (1 << 0),
/*
* The scroll view should move to the bottom of the content.
*/
kHIScrollViewScrollToBottom = (1 << 1),
/*
* The scroll view should move to the left of the content.
*/
kHIScrollViewScrollToLeft = (1 << 2),
/*
* The scroll view should move to the right of the content.
*/
kHIScrollViewScrollToRight = (1 << 3),
/*
* The scroll view should page up.
*/
kHIScrollViewPageUp = (1 << 4),
/*
* The scroll view should page down.
*/
kHIScrollViewPageDown = (1 << 5),
/*
* The scroll view should page left.
*/
kHIScrollViewPageLeft = (1 << 6),
/*
* The scroll view should page right.
*/
kHIScrollViewPageRight = (1 << 7)
};
#if !__LP64__
/*
* HIScrollViewCreate()
*
* Discussion:
* Creates a scroll view. This view has 3 parts, essentially. It can
* have one or two scroll bars (horizontal/vertical), and a view to
* be scrolled. The view to be scrolled is merely added via
* HIViewAddSubview. The scroll view will automatically connect it
* up appropriately. By default, the HIScrollView will not
* automatically hide the scroll bars if the content fits within the
* scrollable view. Use the HIScrollViewSetScrollBarAutoHide API to
* enable that feature.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inOptions:
* Options for our scroll view. You must specify either a
* horizontal or a vertical scroll bar. If neither is passed, an
* error is returned.
*
* outView:
* The new scroll view.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIScrollViewCreate(
OptionBits inOptions,
HIViewRef * outView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIScrollViewSetScrollBarAutoHide()
*
* Discussion:
* Sets a scroll view's scroll bars to auto-hide when the entire
* scrollable view it is managing can be fully displayed in its
* bounds. This is similar to the behavior you see in the Preview
* application.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The view to affect.
*
* inAutoHide:
* The new auto-hide setting (true == auto-hide).
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIScrollViewSetScrollBarAutoHide(
HIViewRef inView,
Boolean inAutoHide) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIScrollViewGetScrollBarAutoHide()
*
* Discussion:
* Gets a scroll view's current scroll bar auto-hide setting.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The view to examine.
*
* Result:
* A boolean result.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HIScrollViewGetScrollBarAutoHide(HIViewRef inView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIScrollViewNavigate()
*
* Discussion:
* Allows you to programmatically change what portion of a scroll
* view's target you are seeing. For example, you can move to the
* beginning or end of a document. You can also page up, down, left
* and right. In general, you should not call this from embedded
* content (i.e. the scrollable view inside the scroll view). For
* those cases, you should instead position yourself appropriately
* and tell the scroll view you changed via the
* kEventScrollableInfoChanged carbon event. This routine merely is
* a programmatic way to scroll as one would by hand using the
* scroll bars.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The scroll view to affect.
*
* inAction:
* The action to take.
*
* Result:
* A operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIScrollViewNavigate(
HIViewRef inView,
HIScrollViewAction inAction) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HIScrollViewCanNavigate()
*
* Discussion:
* Allows you to tell whether it is currently possible to navigate
* somehow in a scroll view. For example, if a scroll view is
* already at the top of the scrollable content, it is not possible
* to navigate upward, so home and page up actions would not be
* possible. You might use this function to help you update the
* state of menu items or the like.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inView:
* The view to examine.
*
* inAction:
* The action to test.
*
* Result:
* A boolean result.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HIScrollViewCanNavigate(
HIViewRef inView,
HIScrollViewAction inAction) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HISCROLLVIEW__ */

View File

@@ -0,0 +1,28 @@
/*
File: HIScrollView.r
Contains: Definition of the scrollbar and scroll views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISCROLLVIEW_R__
#define __HISCROLLVIEW_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlScrollBarProc 384 /* normal scroll bar */
#define kControlScrollBarLiveProc 386 /* live scrolling variant */
#define kControlKindScrollBar 'sbar'
#endif /* __HISCROLLVIEW_R__ */

View File

@@ -0,0 +1,468 @@
/*
File: HIToolbox/HISearchField.h
Contains: Definition of the search field view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISEARCHFIELD__
#define __HISEARCHFIELD__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HISearchField.h
*
* Discussion:
* API definitions for the search field view.
*/
/*==============================================================================*/
/* HISearchField */
/* */
/* HISearchField is a new view available in Mac OS X 10.3. */
/* This view is designed to be used for applications that provide searching */
/* functionality. Visually, it is a standard text field optionally adorned */
/* with a search icon on the left and/or a cancel image on the right. */
/* When the user has accepted the text by pressing the return or enter key */
/* a Carbon Event of kEventClassTextField / kEventTextAccepted will be sent */
/* to the view. This will be the indication that the search should begin. */
/* This view will also respond to all the standard control data tags that are */
/* used by the EditUnicodeText view. */
/*==============================================================================*/
/* The HIObject class ID for the HISearchField class. */
#define kHISearchFieldClassID CFSTR("com.apple.HISearchField")
/* ControlKind*/
enum {
kControlKindHISearchField = 'srfd'
};
/* HISearchField part codes*/
enum {
kControlSearchFieldCancelPart = 30,
kControlSearchFieldMenuPart = 31
};
/*
The SearchField view supports those tags previously defined for the EditUnicodeText view.
These tags are available through Get/SetControlData with ControlPartCode of kControlEditTextPart:
kControlFontStyleTag
kControlEditTextFixedTextTag
kControlEditTextTextTag
kControlEditTextKeyFilterTag
kControlEditTextValidationProcTag
kControlEditUnicodeTextPostUpdateProcTag
kControlEditTextSelectionTag
kControlEditTextKeyScriptBehaviorTag
kControlEditTextCharCount
kControlEditTextCFStringTag
*/
/*
* Summary:
* HISearchField attributes
*/
enum {
/*
* A constant with value zero; the lack of any attributes.
*/
kHISearchFieldNoAttributes = 0,
/*
* This view contains the cancel icon in the text field.
*/
kHISearchFieldAttributesCancel = (1 << 0),
/*
* This view contains the search icon in the text field. If a menu is
* associated with the search field, this attribute is implicitly set
* and the search icon will display with a menu disclosure badge.
* Available in Mac OS X 10.4 and later.
*/
kHISearchFieldAttributesSearchIcon = (1 << 1)
};
/* Event Classes*/
enum {
kEventClassSearchField = 'srfd'
};
/*
* kEventClassSearchField / kEventSearchFieldCancelClicked
*
* Summary:
* Notification that the cancel icon has been depressed.
*
* Discussion:
* This event is sent by the HISearchField view if the cancel icon
* is enabled (attribute of kHISearchFieldAtttributesCancel), and
* the cancel has been clicked.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamDirectObject (in, typeControlRef)
* The HISearchField that has sent the notification.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventSearchFieldCancelClicked = 1
};
/*
* kEventClassSearchField / kEventSearchFieldSearchClicked
*
* Summary:
* Notification that the search icon has been depressed.
*
* Discussion:
* This event is sent by the HISearchField view if the search icon
* is enabled (attribute of kHISearchFieldAttributesSearchIcon or a
* menu is associated with the search field), and the search icon
* has been clicked. If a menu is associated with the search field,
* the search field will handle the display and tracking of the menu
* by default. This event is sent to the search field only, it will
* not propagate.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamDirectObject (in, typeControlRef)
* The HISearchField that has sent the notification.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventSearchFieldSearchClicked = 2
};
#if !__LP64__
/*
* HISearchFieldCreate()
*
* Summary:
* Creates a search field view. The new view is initially invisible.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inBounds:
* The initial bounds of the view. If this parameter is NULL, the
* view defaults to have empty bounds ( 0, 0, 0, 0 ).
*
* inAttributes:
* The initial attributes of the search field. Indicates whether
* the field should contain the cancel icon.
*
* inSearchMenu:
* The menu to be associated with this search field. If
* inSearchMenu is non-NULL, it will be retained by the search
* field and the search icon will be enabled in the left side of
* the text field. If this parameter is NULL, the view will not
* display the search icon in the left portion of the text field.
* You are expected to install handlers on this menu to handle the
* visual appearance of the menu (for example, to draw check marks
* or enable items when the menu receives the
* kEventMenuEnableItems Carbon Event), and to keep track of what
* action should be performed by associating HICommands with each
* menu item and installing a handler for the {
* kEventClassCommand, kEventCommandProcess } Carbon Event.
*
* inDescriptiveText:
* The text to be displayed in the text field when the field does
* not have focus and contains no user entered text. This is meant
* to be an indication of what the search criteria is. For
* example, you may wish to identify to the user that the search
* will cover the "Subject" or "Contents" of a selected range of
* items. If inDescriptiveText is non-NULL it will be retained by
* the search field.
*
* outRef:
* On exit, contains the new view.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchFieldCreate(
const HIRect * inBounds, /* can be NULL */
OptionBits inAttributes,
MenuRef inSearchMenu, /* can be NULL */
CFStringRef inDescriptiveText, /* can be NULL */
HIViewRef * outRef) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISearchFieldSetSearchMenu()
*
* Summary:
* Set the search menu associated with the view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSearchField:
* The search field to associate the search menu with.
*
* inSearchMenu:
* The menu to associate with the search field. If there is
* already a menu associated with the search field, that menu will
* be released. If inSearchMenu is non-NULL, it will be retained
* by the search field and the search icon will be enabled in the
* left side of the text field. You are expected to install
* handlers on this menu to handle the visual appearance of the
* menu (for example, to draw check marks or enable items when the
* menu receives the kEventMenuEnableItems Carbon Event), and to
* keep track of what action should be performed by associating
* HICommands with each menu item and installing a handler for the
* { kEventClassCommand, kEventCommandProcess } Carbon Event. If
* inSearchMenu is NULL, the search icon will be removed from the
* left side of the text field and no menu will be associated with
* this field.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchFieldSetSearchMenu(
HIViewRef inSearchField,
MenuRef inSearchMenu) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISearchFieldGetSearchMenu()
*
* Summary:
* Get the menu that is associated with the search field
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSearchField:
* The search field you wish to retrieve the search menu from.
*
* outSearchMenu:
* On exit, will contain the menu that is associated with search
* field. The menu will _not_ be retained on output and this
* parameter cannot be NULL.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchFieldGetSearchMenu(
HIViewRef inSearchField,
MenuRef * outSearchMenu) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISearchFieldChangeAttributes()
*
* Summary:
* Set the attributes for the given search field.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSearchField:
* The search field to change the attributes of.
*
* inAttributesToSet:
* The attributes to set.
*
* inAttributesToClear:
* The attributes to clear.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchFieldChangeAttributes(
HIViewRef inSearchField,
OptionBits inAttributesToSet,
OptionBits inAttributesToClear) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISearchFieldGetAttributes()
*
* Summary:
* Returns the attributes of the search field.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSearchField:
* The search field to get the attributes of.
*
* outAttributes:
* On exit, will contain the attributes of the search field. This
* parameter cannot be NULL.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchFieldGetAttributes(
HIViewRef inSearchField,
OptionBits * outAttributes) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISearchFieldSetDescriptiveText()
*
* Summary:
* Set the description of the search action of the search field.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSearchField:
* The search field to change the description of.
*
* inDescription:
* The new description for the search field. If the search field
* contains a description, it will be released. If inDescription
* is non-NULL, it will be retained by the search field. If it is
* NULL, no description will be associated with the search field.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchFieldSetDescriptiveText(
HIViewRef inSearchField,
CFStringRef inDescription) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISearchFieldCopyDescriptiveText()
*
* Summary:
* Get the description that is associated with the search field.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSearchField:
* The search field you wish to retrieve the description from.
*
* outDescription:
* On exit, will contain the description that is associated with
* the search field. This parameter cannot be NULL. If there is no
* description associated with the search field, outDescription
* will be set to NULL. If there is a description, a CFStringRef
* will be created that contains the contents of the description.
* You posess ownership of this string and will need to release it
* when you no longer need it.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchFieldCopyDescriptiveText(
HIViewRef inSearchField,
CFStringRef * outDescription) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HISEARCHFIELD__ */

View File

@@ -0,0 +1,915 @@
/*
File: HIToolbox/HISegmentedView.h
Contains: API and type definitions related to HISegmentedView.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISEGMENTEDVIEW__
#define __HISEGMENTEDVIEW__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
/*==============================================================================*/
/* HISegmentedView */
/* */
/* HISegmentedView is a new view available in Mac OS X 10.3 and later. */
/* Examples of the segmented view are the Finder's icon/column/list view */
/* switcher, and the back/forward buttons in Open panels. */
/* The segmented view operates as a group of buttons, each of which can be */
/* configured with different behaviors and content. */
/* */
/* Accessibility Notes: Those of you who wish to customize the accessibility */
/* information provided for individual segments of the segmented view -- by */
/* handling various kEventClassAccessibility Carbon Events, by calling */
/* HIObjectSetAuxiliaryAccessibilityAttribute, etc. -- need to know how to */
/* interpret and/or build AXUIElementRefs that represent individual segments. */
/* The AXUIElement representing an individual segment will/must be constructed */
/* using the segmented view's HIViewRef and the UInt64 identifier of the */
/* one-based index of the segment the element refers to. As usual, a UInt64 */
/* identifier of zero represents the segmented view as a whole. You must */
/* neither interpret nor create segmented view elements whose identifiers are */
/* greater than the count of segments in the segmented view. */
/*==============================================================================*/
/* The HIObject class ID for the HISegmentedView class. */
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#define kHISegmentedViewClassID CFSTR("com.apple.HISegmentedView")
/* The HIViewKind for the HISegmentedView class. */
enum {
kHISegmentedViewKind = 'sgmt'
};
#if !__LP64__
/*
* HISegmentedViewCreate()
*
* Summary:
* Creates a segmented view. This is the type of view you would use
* to implement the icon/column/list view switcher as seen in the
* Finder.
*
* After creating a segmented view, you need to set the number of
* segments via HISegmentedViewSetSegmentCount. Each segment can be
* configured independently using the other HISegmentedView APIs.
*
*
* Changing the number of segments and configuring each segment will
* change the appearance of the segmented view. After you configure
* the view, you may want to call HIViewGetOptimalBounds on the view
* and resize it so the content will fit optimally.
*
* The value of the whole segmented view corresponds to the index of
* the currently selected segment with the radio behavior. If you
* set the value of the whole segmented view to n via
* HIViewSetValue, every radio-behavior segment will have its value
* set to zero except for the segment at index n; if segment n also
* has the radio behavior, it will have its value set to one. When a
* radio-behavior segment is clicked, the value of the whole
* segmented view will be set to the segment's index.
*
* The segmented view works in both compositing and non-compositing
* modes.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inBounds:
* The bounds of the view to be created. Can be NULL, in which
* case the view is created with CGRectZero bounds.
*
* outRef:
* A valid pointer to an HIViewRef. On successful completion of
* this routine, the destination HIViewRef will be filled with the
* HIViewRef of the newly created view. The view is initially
* invisible.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewCreate(
const HIRect * inBounds, /* can be NULL */
HIViewRef * outRef) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewSetSegmentCount()
*
* Summary:
* Sets the number of segments for the segmented view. Any previous
* segments beyond the new count will have their content released.
* All new segments beyond the previous count be initialized with
* the most basic settings possible: momentary, no attributes, zero
* value, enabled, no command, no label, no content, and
* auto-calculated content width. You should configure any new
* segments to match your needs.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view for which the number of segments is to be
* set.
*
* inSegmentCount:
* A positive integer indicating how many segments the view is to
* have.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentCount(
HIViewRef inSegmentedView,
UInt32 inSegmentCount) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewGetSegmentCount()
*
* Summary:
* Gets the number of segments in the segmented view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view for which the number of segments is to be
* retrieved.
*
* Result:
* A UInt32 indicating the number of segments in the segmented view.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern UInt32
HISegmentedViewGetSegmentCount(HIViewRef inSegmentedView) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#endif /* !__LP64__ */
/*
* Summary:
* HISegmentBehavior constants
*/
enum {
/*
* Pops back up after being pressed, just like a push button.
*/
kHISegmentBehaviorMomentary = 1,
/*
* Stays pressed until another segment with the radio behavior is
* pressed. This makes the segment behave like a radio button. After
* this segment is clicked, the segmented view's value will be
* changed to this segment's one-based index.
*/
kHISegmentBehaviorRadio = 2,
/*
* Like a check box. When clicked, it toggles back and forth between
* checked and unchecked states. This behavior is not implemented in
* any version of Mac OS X, and this constant is deprecated.
*/
kHISegmentBehaviorToggles = 3,
/*
* After being pressed, this type of segment stays pressed until you
* programatically unpress it. This behavior is not implemented in
* any version of Mac OS X, and this constant is deprecated.
*/
kHISegmentBehaviorSticky = 4
};
typedef UInt32 HISegmentBehavior;
#if !__LP64__
/*
* HISegmentedViewSetSegmentBehavior()
*
* Summary:
* Changes the behavior of an individual segment of a segmented
* view. By default, a segment has the kHISegmentBehaviorMomentary
* behavior.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment whose behavior you
* want to change.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose behavior you want to
* change. This must be a non-zero value that is no higher than
* the segmented view's current segment count.
*
* inBehavior:
* A HISegmentBehavior describing the behavior you wish the
* segment to have.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentBehavior(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
HISegmentBehavior inBehavior) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewGetSegmentBehavior()
*
* Summary:
* Returns the behavior of an individual segment of a segmented view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose behavior you desire.
* This must be a non-zero value that is no higher than the
* segmented view's current segment count.
*
* Result:
* A HISegmentBehavior describing the behavior of the given segment.
* If you pass an illegal segment index, the result is undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern HISegmentBehavior
HISegmentedViewGetSegmentBehavior(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#endif /* !__LP64__ */
/*
* Summary:
* HISegmentedView segment attributes
*
* Discussion:
* These attribute bits are for use with
* HISegmentedViewChangeSegmentAttributes and
* HISegmentedViewGetSegmentAttributes.
*/
enum {
/*
* Pass this to indicate no attributes at all.
*/
kHISegmentNoAttributes = 0,
/*
* If this attribute bit is set, the command that gets sent out when
* the segment is clicked will be directed at the user focus instead
* of up the segmented view's containment hierarchy.
*/
kHISegmentSendCmdToUserFocus = (1 << 0)
};
#if !__LP64__
/*
* HISegmentedViewChangeSegmentAttributes()
*
* Summary:
* Changes the attributes of an individual segment of a segmented
* view. By default, a segment has no attribute bits set.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment whose attributes you
* want to change.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose attributes you want to
* change. This must be a non-zero value that is no higher than
* the segmented view's current segment count.
*
* inAttributesToSet:
* The attribute bits you wish to set for the segment.
*
* inAttributesToClear:
* The attribute bits you wish to clear for the segment.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewChangeSegmentAttributes(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
OptionBits inAttributesToSet,
OptionBits inAttributesToClear) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewGetSegmentAttributes()
*
* Summary:
* Returns the attributes of an individual segment of a segmented
* view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose attributes you desire.
* This must be a non-zero value that is no higher than the
* segmented view's current segment count.
*
* Result:
* The attribute bits that are set/enabled for the given segment. If
* you pass an illegal segment index, the result is undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OptionBits
HISegmentedViewGetSegmentAttributes(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewSetSegmentValue()
*
* Summary:
* Changes the value of an individual segment of a segmented view.
* This is only meaningful for segments with the sticky, toggles, or
* radio behaviors. If you set the value of momentary segments to
* something other than zero, the behavior is undefined.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment whose value you want
* to change.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose value you want to
* change. This must be a non-zero value that is no higher than
* the segmented view's current segment count.
*
* inValue:
* The value you wish the segment to have. Zero means
* unpressed/unselected and one means pressed/selected. Other
* values will result in undefined behavior.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentValue(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
SInt32 inValue) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewGetSegmentValue()
*
* Summary:
* Determines the value of an individual segment of a segmented
* view. This is only meaningful for segments with the sticky,
* toggles, or radio behaviors. The value of a momentary segment is
* undefined.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose value you desire. This
* must be a non-zero value that is no higher than the segmented
* view's current segment count.
*
* Result:
* A SInt32 indicating the value of the given segment. If you pass
* an illegal segment index, the result is undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern SInt32
HISegmentedViewGetSegmentValue(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewSetSegmentEnabled()
*
* Summary:
* Enables or disables an individual segment of a segmented view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment to enable or disable.
*
* inSegmentIndexOneBased:
* The one-based index of the segment to disable or enable. This
* must be a non-zero value that is no higher than the segmented
* view's current segment count.
*
* inEnabled:
* A Boolean indicating whether the segment is to become enabled
* or disabled.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentEnabled(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
Boolean inEnabled) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewIsSegmentEnabled()
*
* Summary:
* Tests an individual segment of a segmented view to see if it is
* enabled or disabled.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment to test. This must be a
* non-zero value that is no higher than the segmented view's
* current segment count.
*
* Result:
* True if the segment is enabled or false if the segment is
* disabled. If you pass an illegal segment index, the result is
* undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HISegmentedViewIsSegmentEnabled(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewSetSegmentCommand()
*
* Summary:
* Sets the command ID for the given segment. By default, the
* command is zero. If you set any non-zero command ID, the
* segmented view will send an HICommand whenever the segment is
* clicked. By default, the command is sent to the segmented view
* and up the containment hierarchy. You can request that the
* command start at the user focus instead by turning on the
* kHISegmentSendCmdToUserFocus attribute for the segment.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment whose command you wish
* to set.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose command you wish to
* set. This must be a non-zero value that is no higher than the
* segmented view's current segment count.
*
* inCommand:
* The command ID you wish to associate with the segment. A value
* of zero signifies "no command".
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentCommand(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
UInt32 inCommand) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewGetSegmentCommand()
*
* Summary:
* Gets the command ID associated with the given segment.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment to query. This must be a
* non-zero value that is no higher than the segmented view's
* current segment count.
*
* Result:
* Returns the command ID associated with the segment. If you pass
* an illegal segment index, the result is undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern UInt32
HISegmentedViewGetSegmentCommand(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewSetSegmentLabel()
*
* Summary:
* Sets the label string for the given segment. By default, a
* segment has no label string.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment whose label you wish
* to set.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose label you wish to set.
* This must be a non-zero value that is no higher than the
* segmented view's current segment count.
*
* inLabel:
* A CFStringRef with the text of the label. The segmented view
* will copy the string passed in. You may pass NULL or an empty
* CFStringRef if you wish to eliminate the label from the segment.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentLabel(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
CFStringRef inLabel) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewCopySegmentLabel()
*
* Summary:
* Gets the label associated with the given segment.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment to query. This must be a
* non-zero value that is no higher than the segmented view's
* current segment count.
*
* outLabel:
* On exit, outLabel will be a copy of the label associated with
* the segment; you must release this string. If there is no label
* associated with the segment, outLabel will be set to NULL.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewCopySegmentLabel(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
CFStringRef * outLabel) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewSetSegmentContentWidth()
*
* Summary:
* Sets whether you want the segment to automatically calculate its
* own width or whether you want to determine the segment's width
* manually. The content width is the horizontal area taken up by a
* segment's label and/or image.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment whose content width
* you wish to set.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose content width you wish
* to set. This must be a non-zero value that is no higher than
* the segmented view's current segment count.
*
* inAutoCalculateWidth:
* A Boolean indicating whether you want the segment to calculate
* its own width. If you pass true, the inWidth parameter is
* ignored.
*
* inWidth:
* If you passed false in inAutoCalculateWidth, this parameter
* specifies the width you want to manually associate with the
* segment. If you pass a negative width, the behavior is
* undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentContentWidth(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
Boolean inAutoCalculateWidth,
CGFloat inWidth) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewGetSegmentContentWidth()
*
* Summary:
* Gets the content width of the given segment. This also optionally
* passes back a Boolean indicating whether the width was
* automatically calculated. The content width is the horizontal
* area taken up by a segment's label and/or image.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment to query. This must be a
* non-zero value that is no higher than the segmented view's
* current segment count.
*
* outAutoCalculated:
* On exit, this is a Boolean indicating whether the width was
* automatically calculated. You may pass NULL if you don't need
* this information.
*
* Result:
* Returns the width of the content for the given segment. If you
* pass an illegal segment index, the result is undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern CGFloat
HISegmentedViewGetSegmentContentWidth(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
Boolean * outAutoCalculated) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewSetSegmentImage()
*
* Summary:
* Sets or clears the image associated with a given segment.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment whose image you wish
* to set.
*
* inSegmentIndexOneBased:
* The one-based index of the segment whose image you wish to set.
* This must be a non-zero value that is no higher than the
* segmented view's current segment count.
*
* inImage:
* An HIViewImageContentInfo structure with the image information
* for the given segment. Prior to Mac OS X 10.5, segments only
* support three types of image content: kHIViewContentNone (no
* image), kHIViewContentIconRef, and kHIViewContentCGImageRef.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewSetSegmentImage(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
const HIViewImageContentInfo * inImage) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewGetSegmentImageContentType()
*
* Summary:
* Gets the type of image content drawn by the given segment. You
* will need to call this before calling
* HISegmentedViewCopySegmentImage so you know what type of image
* content to request from the latter API.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment to query. This must be a
* non-zero value that is no higher than the segmented view's
* current segment count.
*
* Result:
* Returns the image content type of the image drawn by the given
* segment. If you pass an illegal segment index, the result is
* undefined.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern HIViewImageContentType
HISegmentedViewGetSegmentImageContentType(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HISegmentedViewCopySegmentImage()
*
* Summary:
* Gives you a copy of the image (if any) drawn by the given
* segment. You are responsible for releasing any image passed back
* by this function. You request the image by asking for a
* particular type of image. If the segment isn't using the
* requested type of image, an error will be returned. If you wish
* to know the actual type of image displayed by the segment, you
* can call HISegmentedViewGetSegmentImageContentType.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSegmentedView:
* The segmented view that owns the segment being queried.
*
* inSegmentIndexOneBased:
* The one-based index of the segment to query. This must be a
* non-zero value that is no higher than the segmented view's
* current segment count.
*
* ioImage:
* On entry, you must fill out the contentType field of this
* structure with the type of image you desire. On exit, if that
* type of image is used by the segment, the appropriate field of
* the union will be filled in with a copy of the image. You are
* responsible for releasing the image.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISegmentedViewCopySegmentImage(
HIViewRef inSegmentedView,
UInt32 inSegmentIndexOneBased,
HIViewImageContentInfo * ioImage) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HISEGMENTEDVIEW__ */

View File

@@ -0,0 +1,25 @@
/*
File: HISegmentedView.r
Contains: API and type definitions related to HISegmentedView.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISEGMENTEDVIEW_R__
#define __HISEGMENTEDVIEW_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kHISegmentedViewKind 'sgmt'
#endif /* __HISEGMENTEDVIEW_R__ */

View File

@@ -0,0 +1,98 @@
/*
File: HIToolbox/HISeparator.h
Contains: Definition of the separator view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISEPARATOR__
#define __HISEPARATOR__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HISeparator.h
*
* Discussion:
* API definitions for the separator view.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> VISUAL SEPARATOR (CDEF 9) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Separator lines determine their orientation (horizontal or vertical) automatically */
/* based on the relative height and width of their contrlRect. */
/* Visual separator proc IDs */
enum {
kControlSeparatorLineProc = 144
};
/* Control Kind Tag */
enum {
kControlKindSeparator = 'sepa'
};
/* The HIObject class ID for the HIVisualSeparator class. */
#define kHIVisualSeparatorClassID CFSTR("com.apple.HIVisualSeparator")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateSeparatorControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateSeparatorControl(
WindowRef window,
const Rect * boundsRect,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HISEPARATOR__ */

View File

@@ -0,0 +1,26 @@
/*
File: HISeparator.r
Contains: Definition of the separator view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISEPARATOR_R__
#define __HISEPARATOR_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlSeparatorLineProc 144
#define kControlKindSeparator 'sepa'
#endif /* __HISEPARATOR_R__ */

View File

@@ -0,0 +1,337 @@
/*
File: HIToolbox/HISlider.h
Contains: API and type definitions related to HISlider.
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISLIDER__
#define __HISLIDER__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
#ifndef __MACWINDOWS__
#include <HIToolbox/MacWindows.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* Discussion:
* There are several variants that control the behavior of the
* slider control. Any combination of the following three constants
* can be added to the basic CDEF ID (kSliderProc).
*
* Mac OS X has a "Scroll to here" option in the General pane of
* System Preferences which allows users to click in the page
* up/down regions of a slider and have the thumb/indicator jump
* directly to the clicked position, which alters the value of the
* slider and moves any associated content appropriately. As long as
* the mouse button is held down, the click is treated as though the
* user had clicked in the thumb/indicator in the first place.
*
*
* If you want the sliders in your application to work with the
* "Scroll to here" option, you must do the following:
*
* 1. Create live-tracking sliders, not sliders that show a "ghost"
* thumb when you click on it. You can request live-tracking sliders
* by passing true in the liveTracking parameter to
* CreateSliderControl. If you create sliders with NewControl, use
* the kControlSliderLiveFeedback variant.
*
* 2. Write an appropriate ControlActionProc and associate it with
* your slider via the SetControlAction API. This allows your
* application to update its content appropriately when the
* live-tracking slider is clicked.
*
* 3. When calling HandleControlClick or TrackControl, pass -1 in
* the action proc parameter. This is a request for the Control
* Manager to use the action proc you associated with your control
* in step 2. If you rely on the standard window event handler to do
* your control tracking, this step is handled for you automatically.
*/
enum {
kControlSliderProc = 48,
kControlSliderLiveFeedback = (1 << 0),
kControlSliderHasTickMarks = (1 << 1),
kControlSliderReverseDirection = (1 << 2),
kControlSliderNonDirectional = (1 << 3)
};
/*
* ControlSliderOrientation
*
* Discussion:
* Slider Orientation
*/
typedef UInt16 ControlSliderOrientation;
enum {
/*
* If horizontal, the thumb of the slider points downwards. If
* vertical, the thumb of the slider points to the right. This
* orientation of slider can show tick marks.
*/
kControlSliderPointsDownOrRight = 0,
/*
* If horizontal, the thumb of the slider points upwards. If
* vertical, the thumb of the slider points to the left. This
* orientation of slider can show tick marks.
*/
kControlSliderPointsUpOrLeft = 1,
/*
* The slider thumb is non-directional. This orientation of slider is
* not capable of showing tick marks.
*/
kControlSliderDoesNotPoint = 2
};
/* Control Kind Tag */
enum {
kControlKindSlider = 'sldr'
};
/* The HIObject class ID for the HISlider class. */
#define kHISliderClassID CFSTR("com.apple.HISlider")
#if !__LP64__
/*
* CreateSliderControl()
*
* Summary:
* Creates a slider control with the specified settings.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window in which to create the slider.
*
* boundsRect:
* The bounds with which to create the slider.
*
* value:
* The initial value of the slider. Should be in the range of the
* minimum and maximum values.
*
* minimum:
* The minimum value of the slider. Should be less than the
* maximum.
*
* maximum:
* The maximum value of the slider. Should be greater than the
* minimum.
*
* orientation:
* The orientation of the slider.
*
* numTickMarks:
* The number of tick marks of the slider. The orientation must
* not support tick marks if this value is non-zero.
*
* liveTracking:
*
* liveTrackingProc:
*
* outControl:
* A pointer to a ControlRef in which to store a reference to the
* created slider.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateSliderControl(
WindowRef window,
const Rect * boundsRect,
SInt32 value,
SInt32 minimum,
SInt32 maximum,
ControlSliderOrientation orientation,
UInt16 numTickMarks,
Boolean liveTracking,
ControlActionUPP liveTrackingProc,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* HISliderGetThumbOrientation()
*
* Summary:
* Get the orientation of the thumb of a slider.
*
* Discussion:
* Available only on Mac OS X 10.5 and later.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSlider:
* A reference to the slider from which to retrieve the thumb
* orientation.
*
* Result:
* The current thumb orientation of the specified slider. The
* incoming slider reference must be valid or the return value is
* undefined.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern ControlSliderOrientation
HISliderGetThumbOrientation(HIViewRef inSlider) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* HISliderSetThumbOrientation()
*
* Summary:
* Set the orientation of the thumb of a slider.
*
* Discussion:
* Available only on Mac OS X 10.5 and later. This call may change
* the bounds needed to draw the slider fully. If changing the
* orientation so that tick marks will appear/disappear, be sure to
* resize the control to its optimal size if necessary.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSlider:
* A reference to the slider from which to retrieve the thumb
* orientation.
*
* inOrientation:
* A ControlSliderOrientation for the desired thumb orientation.
*
* Result:
* An OSStatus code indicating success or failure.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
HISliderSetThumbOrientation(
HIViewRef inSlider,
ControlSliderOrientation inOrientation) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* HISliderGetTickMarkCount()
*
* Summary:
* Get the tick mark count of a slider.
*
* Discussion:
* Available only on Mac OS X 10.5 and later.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSlider:
* A reference to the slider for which to get the tick mark count.
*
* Result:
* The current tick mark count of the specified slider. The incoming
* slider reference must be valid or the return value is undefined.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern ItemCount
HISliderGetTickMarkCount(HIViewRef inSlider) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* HISliderSetTickMarkCount()
*
* Summary:
* Set the tick mark count of a slider. Tick marks will not appear
* on a slider unless its orientation is pointy (i.e.
* kControlSliderPointsDownOrRight/UpOrLeft) This call may change
* the bounds needed to draw the slider fully. If changing the tick
* mark count so that tick marks will appear/disappear, be sure to
* resize the control to its optimal size if necessary.
*
* Discussion:
* Available only on Mac OS X 10.5 and later.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSlider:
* A reference to the slider for which to set the tick mark count.
*
* inNumTicks:
* The desired number of tick marks.
*
* Result:
* An OSStatus code indicating success or failure.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern OSStatus
HISliderSetTickMarkCount(
HIViewRef inSlider,
ItemCount inNumTicks) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HISLIDER__ */

View File

@@ -0,0 +1,35 @@
/*
File: HISlider.r
Contains: API and type definitions related to HISlider.
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HISLIDER_R__
#define __HISLIDER_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlSliderProc 48
#define kControlSliderLiveFeedback 0x01
#define kControlSliderHasTickMarks 0x02
#define kControlSliderReverseDirection 0x04
#define kControlSliderNonDirectional 0x08
#define kControlSliderPointsDownOrRight 0
#define kControlSliderPointsUpOrLeft 1
#define kControlSliderDoesNotPoint 2
#define kControlKindSlider 'sldr'
#endif /* __HISLIDER_R__ */

View File

@@ -0,0 +1,275 @@
/*
File: HIToolbox/HITabbedView.h
Contains: Definition of the tab view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HITABBEDVIEW__
#define __HITABBEDVIEW__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*
* HITabbedView.h
*
* Discussion:
* API definitions for the tab view.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> TABS (CDEF 8) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Tabs use an auxiliary resource (tab#) to hold tab information such as the tab name */
/* and an icon suite ID for each tab. */
/* */
/* The ID of the tab# resource that you wish to associate with a tab control should */
/* be passed in as the Value parameter of the control. If you are using GetNewControl, */
/* then the Value slot in the CNTL resource should have the ID of the 'tab#' resource */
/* on creation. */
/* */
/* Passing zero in for the tab# resource tells the control not to read in a tab# res. */
/* You can then use SetControlMaximum to add tabs, followed by a call to SetControlData*/
/* with the kControlTabInfoTag, passing in a pointer to a ControlTabInfoRec. This sets */
/* the name and optionally an icon for a tab. Pass the 1-based tab index as the part */
/* code parameter to SetControlData to indicate the tab that you want to modify. */
/* */
/* Accessibility Notes: Those of you who wish to customize the accessibility */
/* information provided for individual tabs of a tabs control -- by handling various */
/* kEventClassAccessibility Carbon Events, by calling */
/* HIObjectSetAuxiliaryAccessibilityAttribute, etc. -- need to know how to interpret */
/* and/or build AXUIElementRefs that represent individual tabs. The AXUIElement */
/* representing an individual tab will/must be constructed using the tab control's */
/* ControlRef and the UInt64 identifier of the one-based index of the tab the element */
/* refers to. As usual, a UInt64 identifier of zero represents the tabs control as a */
/* whole. You must neither interpret nor create tab control elements whose identifiers */
/* are greater than the count of tabs in the tabs control. */
/* Tabs proc IDs */
enum {
kControlTabLargeProc = 128, /* Large tab size, north facing */
kControlTabSmallProc = 129, /* Small tab size, north facing */
kControlTabLargeNorthProc = 128, /* Large tab size, north facing */
kControlTabSmallNorthProc = 129, /* Small tab size, north facing */
kControlTabLargeSouthProc = 130, /* Large tab size, south facing */
kControlTabSmallSouthProc = 131, /* Small tab size, south facing */
kControlTabLargeEastProc = 132, /* Large tab size, east facing */
kControlTabSmallEastProc = 133, /* Small tab size, east facing */
kControlTabLargeWestProc = 134, /* Large tab size, west facing */
kControlTabSmallWestProc = 135 /* Small tab size, west facing */
};
/* Tab Directions */
typedef UInt16 ControlTabDirection;
enum {
kControlTabDirectionNorth = 0,
kControlTabDirectionSouth = 1,
kControlTabDirectionEast = 2,
kControlTabDirectionWest = 3
};
/* Tab Sizes */
typedef UInt16 ControlTabSize;
enum {
kControlTabSizeLarge = kControlSizeNormal,
kControlTabSizeSmall = kControlSizeSmall,
kControlTabSizeMini = kControlSizeMini
};
/* Control Tab Entry - used during creation */
/* Note that the client is responsible for allocating/providing */
/* the ControlButtonContentInfo and string storage for this */
/* structure. */
struct ControlTabEntry {
ControlButtonContentInfo * icon;
CFStringRef name;
Boolean enabled;
};
typedef struct ControlTabEntry ControlTabEntry;
/* Control Kind Tag */
enum {
kControlKindTabs = 'tabs'
};
/* The HIObject class ID for the HITabbedView class. */
#define kHITabbedViewClassID CFSTR("com.apple.HITabbedView")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateTabsControl()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateTabsControl(
WindowRef window,
const Rect * boundsRect,
ControlTabSize size,
ControlTabDirection direction,
UInt16 numTabs,
const ControlTabEntry * tabArray,
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* Summary:
* Tagged data supported by the Tabs control.
*/
enum {
/*
* Used to get the bounds of the control area benath the tabs. Cannot
* be used with SetControlData. Data is of type Rect.
*/
kControlTabContentRectTag = 'rect',
/*
* Used to get or set the enable state of a specific tab. The part
* code parameter to Get/SetControlData must be a 1-based tab index.
* Data is of type Boolean.
*/
kControlTabEnabledFlagTag = 'enab',
/*
* Used to get or set the font and style attributes of a specific
* tab. The part code parameter to Get/SetControlData must be a
* 1-based tab index. Data is of type ControlFontStyleRec.
*/
kControlTabFontStyleTag = kControlFontStyleTag,
/*
* Used to get or set the name and image of a specified tab. The part
* code parameter to Get/SetControlData must be a 1-based tab index.
* Data is of type ControlTabInfoRec. Available in Appearance Manager
* 1.0.1 and later.
*/
kControlTabInfoTag = 'tabi',
/*
* Used to get or set the image of a specified tab. The part code
* parameter to Get/SetControlData must be a 1-based tab index. When
* used with GetControlData, if the tab image is an IconRef or
* CGImageRef, the Tabs control will automatically retain the icon or
* image, and the caller of GetControlData must release it. Data is
* of type ControlImageContentInfo, or HIViewContentInfo. Available
* in Mac OS X 10.1 and later.
*/
kControlTabImageContentTag = kControlContentTag
};
enum {
kControlTabInfoVersionZero = 0, /* ControlTabInfoRec*/
kControlTabInfoVersionOne = 1 /* ControlTabInfoRecV1*/
};
struct ControlTabInfoRec {
SInt16 version; /* version of this structure.*/
SInt16 iconSuiteID; /* icon suite to use. Zero indicates no icon*/
Str255 name; /* name to be displayed on the tab*/
};
typedef struct ControlTabInfoRec ControlTabInfoRec;
struct ControlTabInfoRecV1 {
SInt16 version; /* version of this structure. == kControlTabInfoVersionOne*/
SInt16 iconSuiteID; /* icon suite to use. Zero indicates no icon*/
CFStringRef name; /* name to be displayed on the tab. Will be retained so caller*/
/* should always release it.*/
};
typedef struct ControlTabInfoRecV1 ControlTabInfoRecV1;
/* Helper routines are available only thru the shared library/glue. */
#if !__LP64__
/*
* GetTabContentRect()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
GetTabContentRect(
ControlRef inTabControl,
Rect * outContentRect) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetTabEnabled()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
SetTabEnabled(
ControlRef inTabControl,
SInt16 inTabToHilite,
Boolean inEnabled) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> Resource Types */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
#endif /* !__LP64__ */
enum {
kControlTabListResType = 'tab#' /* used for tab control (Appearance 1.0 and later)*/
};
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __HITABBEDVIEW__ */

View File

@@ -0,0 +1,71 @@
/*
File: HITabbedView.r
Contains: Definition of the tab view provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HITABBEDVIEW_R__
#define __HITABBEDVIEW_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlTabLargeProc 128 /* Large tab size, north facing */
#define kControlTabSmallProc 129 /* Small tab size, north facing */
#define kControlTabLargeNorthProc 128 /* Large tab size, north facing */
#define kControlTabSmallNorthProc 129 /* Small tab size, north facing */
#define kControlTabLargeSouthProc 130 /* Large tab size, south facing */
#define kControlTabSmallSouthProc 131 /* Small tab size, south facing */
#define kControlTabLargeEastProc 132 /* Large tab size, east facing */
#define kControlTabSmallEastProc 133 /* Small tab size, east facing */
#define kControlTabLargeWestProc 134 /* Large tab size, west facing */
#define kControlTabSmallWestProc 135 /* Small tab size, west facing */
#define kControlTabDirectionNorth 0
#define kControlTabDirectionSouth 1
#define kControlTabDirectionEast 2
#define kControlTabDirectionWest 3
#define kControlKindTabs 'tabs'
#define kControlTabContentRectTag 'rect'
#define kControlTabEnabledFlagTag 'enab'
#define kControlTabFontStyleTag 'font'
#define kControlTabInfoTag 'tabi'
#define kControlTabImageContentTag 'cont'
#define kControlTabInfoVersionZero 0 /* ControlTabInfoRec */
#define kControlTabInfoVersionOne 1 /* ControlTabInfoRecV1 */
#define kControlTabListResType 'tab#' /* used for tab control (Appearance 1.0 and later) */
/*-------------------------------tab# <20> Tab Control Template-----------------------------*/
type 'tab#'
{
switch
{
case versionZero:
key integer = 0; /* version */
integer = $$Countof(TabInfo);
array TabInfo
{
integer; /* Icon Suite ID */
pstring; /* Tab Name */
fill long; /* Reserved */
fill word; /* Reserved */
};
};
};
#endif /* __HITABBEDVIEW_R__ */

View File

@@ -0,0 +1,70 @@
/*
File: HIToolbox/HITextLengthFilter.h
Contains: Header file for HITextLengthFilter object.
Copyright: <20> 1984-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
/*
HITextLengthFilter
This object enforces a maximum character length on a text field. It is typically attached as a
delegate to an editable text view, such as an EditUnicodeText, HIComboBox, HISearchField, or
HITextView object.
This object handles the following Carbon events:
kEventClassTextField
kEventTextShouldChangeInRange
This object does not send or post any Carbon events.
This object has no dependencies on other AppObjects.
This object is customizable to specify the maximum length for the text field.
Your application customizes the maximum length for the text field by specifying
a value for the kEventParamTextLength param of the kEventHIObjectInitialize event
used when creating an instance of this object.
*/
#ifndef __HITEXTLENGTHFILTER__
#define __HITEXTLENGTHFILTER__
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
/*
* kHITextLengthFilterClassID
*
* Discussion:
* HIObject class ID for the HITextLengthFilter object.
*/
#define kHITextLengthFilterClassID CFSTR("com.apple.appobjects.HITextLengthFilter")
/*
* Summary:
* Initialization event parameters for HITextLengthFilter objects.
*/
enum {
/*
* [typeUInt32] The maximum text length in characters that is
* allowed by this object.
*/
kEventParamTextLength = 'TLEN'
};
#endif /* __HITEXTLENGTHFILTER__ */

View File

@@ -0,0 +1,115 @@
/*
File: HIToolbox/HITextUtils.h
Contains: Text utilities provided by HIToolbox.
Copyright: <20> 2002-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HITEXTUTILS__
#define __HITEXTUTILS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#if !__LP64__
/*
* GetTextAndEncodingFromCFString()
*
* Summary:
* Converts the contents of a CFString to the one- or two-byte
* encoding that most accurately represents the original Unicode
* characters in the string.
*
* Discussion:
* Because the Macintosh toolbox has had, until Carbon, little
* support for Unicode, you may often find that your applications
* need to translate a CFString (containing Unicode characters) back
* to a one- or two-byte encoding of the string in order to draw,
* measure, or otherwise use the text in the string.
* GetTextAndEncodingFromCFString is a utility that may be helpful
* to do this, in some circumstances. The Carbon toolbox uses this
* API itself when translating CFStrings to Pascal strings.
* GetTextAndEncodingFromCFString attempts to convert the Unicode
* characters in the string to the closest non-Unicode
* representation of the string. For example, a string containing
* only Unicode characters that are present in the MacRoman one-byte
* encoding will be translated to MacRoman, and
* kTextEncodingMacRoman will be returned as the encoding of the
* text. A string containing Unicode characters that are present in
* the MacJapanese two-byte encoding will be translated to
* MacJapanese (Shift-JIS), and kTextEncodingMacJapanese will be
* returned as the encoding of the text.
* GetTextAndEncodingFromCFString is designed to be used for simple
* strings which contain only text from a single language. It is not
* designed to translate strings with multiple runs of text from
* different languages, and will only return the first run of such a
* string; for example, if you pass it a string containing a run of
* Roman characters followed by a run of Japanese characters, it
* will only return the Roman characters in the output buffer. For
* more complex text translation, you should call the Unicode
* converter directly (see ConvertFromUnicodeToTextRun, which
* GetTextAndEncodingFromCFString uses internally).
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inString:
* The string to convert.
*
* outText:
* The output buffer in which to place the converted text.
*
* inTextMaxLength:
* The length in bytes of the input buffer.
*
* outTextLength:
* On exit, contains the length in bytes of the text that was
* placed into the output buffer.
*
* outEncoding:
* On exit, contains the encoding of the text that was placed into
* the output buffer.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.2.5 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetTextAndEncodingFromCFString(
CFStringRef inString,
BytePtr outText,
ByteCount inTextMaxLength,
ByteCount * outTextLength,
TextEncoding * outEncoding) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HITEXTUTILS__ */

View File

@@ -0,0 +1,851 @@
/*
File: HIToolbox/HITextViews.h
Contains: Definitions of text-display and text-editing views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HITEXTVIEWS__
#define __HITEXTVIEWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#ifndef __MACTEXTEDITOR__
#include <HIToolbox/MacTextEditor.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*
* HITextViews.h
*
* Discussion:
* API definitions for the standard text-display and text-editing
* views: Static text view, HITextView, EditUnicodeText view, and
* (deprecated) classic EditText view.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> Static Text (CDEF 18) */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Static Text proc IDs */
enum {
kControlStaticTextProc = 288
};
/* Control Kind Tag */
enum {
kControlKindStaticText = 'stxt'
};
/* The HIObject class ID for the HIStaticTextView class. */
#define kHIStaticTextViewClassID CFSTR("com.apple.HIStaticTextView")
/* Creation API: Carbon only */
#if !__LP64__
/*
* CreateStaticTextControl()
*
* Summary:
* Creates a new static text control.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window in which the control should be placed. May be NULL
* in 10.3 and later.
*
* boundsRect:
* The bounds of the control, in local coordinates of the window.
*
* text:
* The text of the control. May be NULL.
*
* style:
* The control's font style, size, color, and so on. May be NULL.
*
* outControl:
* On exit, contains the new control.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateStaticTextControl(
WindowRef window, /* can be NULL */
const Rect * boundsRect,
CFStringRef text, /* can be NULL */
const ControlFontStyleRec * style, /* can be NULL */
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* Summary:
* Tagged data supported by the static text control
*/
enum {
/*
* Used to get or set the control's current text style. Data is of
* type ControlFontStyleRec. Available with Appearance Manager 1.0
* (Mac OS 8.0) and later.
*/
kControlStaticTextStyleTag = kControlFontStyleTag,
/*
* Used to get or set the control's current text. Data is an array of
* chars. Generally you should used GetControlDataSize to determine
* the length of the text, and allocate a buffer of that length,
* before calling GetControlData with this selector. Deprecated in
* Carbon in favor of kControlStaticTextCFStringTag. Available with
* Appearance Manager 1.0 (Mac OS 8.0) and later.
*/
kControlStaticTextTextTag = 'text',
/*
* Used to get the height of the control's text. May not be used with
* SetControlData. Data is of type SInt16. Available with Appearance
* Manager 1.0 (Mac OS 8.0) and later.
*/
kControlStaticTextTextHeightTag = 'thei',
/*
* Used to get or set the control's text truncation style. Data is of
* type TruncCode; pass a truncation code of -1 to indication no
* truncation. Available with Appearance Manager 1.1 (Mac OS 8.5) and
* later. Truncation will not occur unless
* kControlStaticTextIsMultilineTag is set to false.
*/
kControlStaticTextTruncTag = 'trun',
/*
* Used to get or set the control's current text. Data is of type
* CFStringRef. When setting the text, the control will retain the
* string, so you may release the string after calling
* SetControlData; if the string is mutable, the control will make a
* copy of the string, so any changes to the string after calling
* SetControlData will not affect the control. When getting the text,
* the control retains the string before returning it to you, so you
* must release the string after you are done with it. Available in
* CarbonLib 1.5 and Mac OS X 10.0 and later.
*/
kControlStaticTextCFStringTag = 'cfst',
/*
* Used to get or set whether the control draws its text in multiple
* lines if the text is too wide for the control bounds. If false,
* then the control always draws the text in a single line. Data is
* of type Boolean. Default is true. Available in Mac OS X 10.1 and
* later.
*/
kControlStaticTextIsMultilineTag = 'stim'
};
/*==============================================================================*/
/* Text field events */
/* */
/* A text field is the part of some views that you can enter text into. */
/* A text field is common to the EditText, EditUnicodeText, ComboBox, */
/* HISearchField, and HITextView views. The kEventClassTextField event allows */
/* you to receive notifications when the text has been accepted by the user. */
/* For example, you can install a handler for a kEventClassTextField / */
/* kEventTextAccepted event on a HISearchField view to receive a notification */
/* that the user has initiated a search by hitting the return or enter key. */
/* You can also filter the text that will replace a selection before the */
/* change has been made to either accept or reject the replacement. */
/*==============================================================================*/
/*
kEventClassTextField quick reference:
kEventTextAccepted = 1,
kEventTextShouldChangeInRange = 2,
kEventTextDidChange = 3
*/
enum {
kEventClassTextField = 'txfd'
};
enum {
kEventParamTextSelection = 'txsl', /* typeCFRange*/
kEventParamCandidateText = 'tstx', /* typeCFStringRef*/
kEventParamReplacementText = 'trtx', /* typeCFStringRef*/
kEventParamUnconfirmedRange = 'tunr', /* typeCFRange*/
kEventParamUnconfirmedText = 'txun' /* typeCFStringRef*/
};
/*
* kEventClassTextField / kEventTextAccepted
*
* Summary:
* Notification that the text in a view's editable text field has
* been accepted.
*
* Discussion:
* This event is sent as a notification when the text contained in a
* view's editable text field has been accepted by the user. Text is
* accepted when the user presses return or enter on the keyboard
* for the EditUnicodeText, HIComboBox, and HISearchField views, or
* when the text has changed in the field and the field loses focus
* for the EditUnicodeText, HIComboBox, HISearchField and HITextView
* views.
*
* This event is sent to the view containing the text field only, it
* will not propagate. It is sent to all handlers installed on the
* view containing the text field.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamDirectObject (in, typeControlRef)
* The editable text field that has sent the notification.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventTextAccepted = 1
};
/*
* kEventClassTextField / kEventTextShouldChangeInRange
*
* Summary:
* Returns whether the text should be changed in editable text
* fields.
*
* Discussion:
* There are several editable text field views, such as the
* HIComboBox, HISearchField, HITextView, and EditUnicodeText views.
* There are times when you may require fine-grained control over
* what text is inserted into the text field and either accept the
* changes, reject them or modify what is to be entered. This event
* is sent whenever the text is about to be modified in a text
* field, either by user input or in other scenarios such as a paste
* from the clipboard, spell-checking word correction, or Mac OS X
* Service operation. You can change what text is inserted by
* providing a replacement string as a parameter to this event. This
* event is only sent for Unicode text views; it is not sent for the
* classic non-Unicode EditText control.
*
* This event is not sent prior to programmatic modification of the
* text field contents using SetControlData.
*
* This event is not sent while an active inline editing session is
* in progress. Once the inline text has been confirmed, this event
* will be sent prior to the confirmed text being inserted into the
* text field. If you need control over keystrokes during an inline
* editing session, you can use the kEventTextInputFilterText event.
*
*
* This event is sent to the view containing the text field only; it
* will not propagate.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamDirectObject (in, typeControlRef)
* The editable text field that has sent the notification.
* Available in Mac OS X 10.5 and later.
*
* --> kEventParamTextSelection (in, typeCFRange)
* The range of the selection that is about to be changed. The
* units of the selection are in the same units that are
* returned in a EditTextSelectionRec, when called with
* GetControlData using kControlEditTextSelectionTag.
*
* --> kEventParamCandidateText (in, typeCFStringRef)
* The text that is going to replace the selection. Note that
* this string was originally created with
* CFStringCreateWithCharactersNoCopy, and the original text
* has a limited lifespan. If for some reason you need to
* retain the text past the end of your event handler, you
* should extract the characters from the string with
* CFStringGetCharacters, and then store those characters or
* create a new CFString from them.
*
* <-- kEventParamReplacementText (out, typeCFStringRef)
* On output, can contain optional replacement text.
*
* Result:
* If noErr is returned from your handler and the
* kEventParamReplacementText parameter is added to the event, then
* the contents of that parameter, rather than the candidate text,
* will be added to the text field.
*
* If noErr is returned from your handler and the
* kEventParamReplacementText parameter is _not_ added to the event,
* then the candidate text will be filtered out and no text will be
* entered in the text field. The current selection will be deleted,
* however.
*
* If userCanceledErr is returned from your handler, then no text
* will be entered in the text field and the current selection will
* remain unchanged. Effectively, the editing operation will be
* ignored. Note that when an inline text editing session is active,
* you will only receive this event when the user attempts to
* confirm the inline input. You should not return userCanceledErr
* at this point; doing so will not really prevent the text from
* being committed.
*
* If eventNotHandledErr is returned from your handler, the contents
* of the kEventParamReplacementText parameter are ignored, and the
* candidate text will replace the selection.
*
* Any other return value will result in the default behavior, as if
* eventNotHandledErr had been returned.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventTextShouldChangeInRange = 2
};
/*
* kEventClassTextField / kEventTextDidChange
*
* Summary:
* Indicates that the contents of an editable text field have
* changed.
*
* Discussion:
* This event is sent by all of the Unicode-based editable text
* views: HIComboBox, HISearchField, HITextView and EditUnicodeText.
* This event is not sent for the classic non-Unicode EditText view.
*
*
* Note that this event is sent after inline editing operations,
* such as pressing a dead key, or using a input method that creates
* an inline editing hole. Most clients of this event should ignore
* the event during inline editing, and only respond to changes to
* the text after inline editing completes. A client can check for
* the presence of the kEventParamUnconfirmedRange parameter to
* determine whether inline editing is currently active; if this
* parameter is present, the client may wish to ignore the event.
*
*
* This event is not sent after programmatic modification of the
* text field contents using SetControlData.
*
* This event is sent only to the view containing the text field; it
* will not propagate. It is sent to all handlers registered for it.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* --> kEventParamDirectObject (in, typeControlRef)
* The editable text field that has sent the notification.
* Available in Mac OS X 10.5 and later.
*
* --> kEventParamUnconfirmedRange (in, typeCFRange)
* If the text field currently has an open inline hole, this
* parameter contains the range of text inside the hole. This
* parameter is optional and is only present during inline
* editing.
*
* --> kEventParamUnconfirmedText (in, typeCFStringRef)
* If the text field currently has an open inline hole, this
* parameter contains the non-confirmed text currently being
* edited inside the hole. This parameter is optional and is
* only present during inline editing. Note that this string
* was originally created with
* CFStringCreateWithCharactersNoCopy, and the original text
* has a limited lifespan. If for some reason you need to
* retain the text past the end of your event handler, you
* should extract the characters from the string with
* CFStringGetCharacters, and then store those characters or
* create a new CFString from them.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available
*/
enum {
kEventTextDidChange = 3
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> HITextView */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/*==============================================================================*/
/* HITextView is a MLTE view that can be embedded in the HIView hierarchy. The */
/* view can be embedded in an HIScrollView if scroll bars are desired and can */
/* be used in a composited window. On creation, a TXNObject is created to back */
/* the view. You can extract the TXNObject at any time and use a subset of the */
/* MLTE API with that object as an argument. */
/*==============================================================================*/
/*
In Mac OS X 10.4 and later, HITextView supports these tags previously defined for the EditUnicodeText control:
kControlEditTextCharCount
kControlEditTextSelectionTag
kControlEditTextCFStringTag
kControlEditTextInsertCFStringRefTag
*/
/* The HIObject class ID for the HITextView class. */
/*
* kHITextViewClassID
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern const CFStringRef kHITextViewClassID AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/* ControlKind*/
enum {
kControlKindHITextView = 'hitx'
};
#if !__LP64__
/*
* HITextViewCreate()
*
* Summary:
* Creates a text view. The new view is initially invisible.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inBoundsRect:
* The bounding box of the view. If NULL, the bounds of the view
* will be initialized to 0.
*
* inOptions:
* There are currently no options. This must be 0.
*
* inTXNFrameOptions:
* Any frame options desired for the TXN object creation.
*
* outTextView:
* On exit, contains the new view.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HITextViewCreate(
const HIRect * inBoundsRect, /* can be NULL */
OptionBits inOptions,
TXNFrameOptions inTXNFrameOptions,
HIViewRef * outTextView) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HITextViewGetTXNObject()
*
* Summary:
* Obtains the TXNObject that backs the text view.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inTextView:
* The text view that contains the TXNObject you wish to retrieve.
*
* Result:
* The TXNObject backing the given view.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern TXNObject
HITextViewGetTXNObject(HIViewRef inTextView) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HITextViewSetBackgroundColor()
*
* Summary:
* Sets the background color of the view. This allows you to provide
* alpha as well. If inColor is NULL, the background of the text
* view will not draw.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inTextView:
* The text view that you are modifying the background color of.
*
* inColor:
* A CGColorRef representing the color or pattern that will fill
* the background of the text view. The CGColorRef will be
* retained by this API. If the text view already contains a
* background color, it will be released prior to the new color
* being retained. If inColor is NULL, the background of the text
* view will not draw.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HITextViewSetBackgroundColor(
HIViewRef inTextView,
CGColorRef inColor) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*
* HITextViewCopyBackgroundColor()
*
* Summary:
* Gets the background color of the view. If the background color
* returned is NULL, the background does not draw.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inTextView:
* The text view from which you want to obtain the background
* color.
*
* outColor:
* A CGColorRef representing the color or pattern that is used for
* drawing the background of the text view. If the returned value
* is NULL, the background does not draw. If the returned
* CGColorRef is not NULL, it will be retained on return. You are
* responsible for releasing this CGColorRef when you are no
* longer referencing it.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HITextViewCopyBackgroundColor(
HIViewRef inTextView,
CGColorRef * outColor) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
/*---------------------------------------------------------------------------------------*/
/* EditUnicodeText */
/*---------------------------------------------------------------------------------------*/
/* This view is only available in Mac OS X. It is super similar to Edit Text control */
/* Use all the same Get/Set tags. But don't ask for the TEHandle. */
/*---------------------------------------------------------------------------------------*/
#endif /* !__LP64__ */
enum {
kControlEditUnicodeTextProc = 912,
kControlEditUnicodeTextPasswordProc = 914
};
/* Control Kind Tag */
enum {
kControlKindEditUnicodeText = 'eutx'
};
/* The HIObject class ID for the HITextField class. */
#define kHITextFieldClassID CFSTR("com.apple.HITextField")
#if !__LP64__
/*
* CreateEditUnicodeTextControl()
*
* Summary:
* Creates a new edit text control.
*
* Discussion:
* This is the preferred edit text control. Use it instead of the
* EditText control. This control handles Unicode and draws its text
* using antialiasing, which the other control does not.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* window:
* The window in which the control should be placed. May be NULL
* in 10.3 and later.
*
* boundsRect:
* The bounds of the control, in local coordinates of the window.
*
* text:
* The text of the control. May be NULL.
*
* isPassword:
* A Boolean indicating whether the field is to be used as a
* password field. Passing false indicates that the field is to
* display entered text normally. True means that the field will
* be used as a password field and any text typed into the field
* will be displayed only as bullets.
*
* style:
* The control's font style, size, color, and so on. May be NULL.
*
* outControl:
* On exit, contains the new control (if noErr is returned as the
* result code).
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateEditUnicodeTextControl(
WindowRef window,
const Rect * boundsRect,
CFStringRef text, /* can be NULL */
Boolean isPassword,
const ControlFontStyleRec * style, /* can be NULL */
ControlRef * outControl) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Tagged data supported by edit text */
#endif /* !__LP64__ */
enum {
kControlEditTextStyleTag = kControlFontStyleTag, /* ControlFontStyleRec*/
kControlEditTextTextTag = 'text', /* Buffer of chars - you supply the buffer*/
kControlEditTextKeyFilterTag = kControlKeyFilterTag,
kControlEditTextSelectionTag = 'sele', /* ControlEditTextSelectionRec*/
kControlEditTextPasswordTag = 'pass', /* The clear text password text*/
kControlEditTextCharCount = 'chrc' /* [UInt32] Count of characters in the control's text*/
};
/* tags available with Appearance 1.1 or later */
enum {
kControlEditTextKeyScriptBehaviorTag = 'kscr', /* ControlKeyScriptBehavior. Defaults to "PrefersRoman" for password fields,*/
/* or "AllowAnyScript" for non-password fields.*/
kControlEditTextLockedTag = 'lock', /* Boolean. Locking disables editability.*/
kControlEditTextFixedTextTag = 'ftxt', /* Like the normal text tag, but fixes inline input first*/
kControlEditTextValidationProcTag = 'vali' /* ControlEditTextValidationUPP. Called when a key filter can't be: after cut, paste, etc.*/
};
/*
* Discussion:
* EditText ControlData tags available with Mac OS X and later.
*/
enum {
/*
* Extract the content of the edit text field as a CFString. Don't
* forget that you own the returned CFStringRef and are responsible
* for CFReleasing it.
*/
kControlEditTextCFStringTag = 'cfst', /* CFStringRef (Also available on CarbonLib 1.5)*/
/*
* Extract the content of the edit text field as a CFString, if it is
* a password field. Don't forget that you own the returned
* CFStringRef and are responsible for CFReleasing it.
*/
kControlEditTextPasswordCFStringTag = 'pwcf' /* CFStringRef*/
};
enum {
kControlEditTextSingleLineTag = 'sglc', /* data is a Boolean; indicates whether the control should always be single-line*/
kControlEditTextInsertTextBufferTag = 'intx', /* data is an array of char; get or set the control's text as WorldScript-encoded text*/
kControlEditTextInsertCFStringRefTag = 'incf', /* data is a CFStringRef; get or set the control's text as a CFStringRef. Caller should release CFString if getting.*/
kControlEditUnicodeTextPostUpdateProcTag = 'upup', /* data is a UnicodePostUpdateUPP; get or set the post-update proc*/
kControlEditTextSpellCheckingTag = 'spck', /* data is a Boolean; indicates whether the control wants to have spell checking support. Available in Leopard and later.*/
kControlEditTextSpellCheckAsYouTypeTag = 'scat' /* data is a Boolean; indicates whether you want to support spell-checking-as-you-type. Available in Leopard and later.*/
};
/* Structure for getting the edit text selection. Used with kControlEditTextSelectionTag. */
struct ControlEditTextSelectionRec {
SInt16 selStart;
SInt16 selEnd;
};
typedef struct ControlEditTextSelectionRec ControlEditTextSelectionRec;
typedef ControlEditTextSelectionRec * ControlEditTextSelectionPtr;
typedef CALLBACK_API( void , ControlEditTextValidationProcPtr )(ControlRef control);
/* This callback supplies the functionality of the TSMTEPostUpdateProcPtr that is used */
/* in the EditText control. A client should supply this call if they want to look at */
/* inline text that has been fixed before it is included in the actual body text */
/* if the new text (i.e. the text in the handle) should be included in the body text */
/* the client should return true. If the client wants to block the inclusion of the */
/* text they should return false. */
typedef CALLBACK_API( Boolean , EditUnicodePostUpdateProcPtr )(UniCharArrayHandle uniText, UniCharCount uniTextLength, UniCharArrayOffset iStartOffset, UniCharArrayOffset iEndOffset, void *refcon);
typedef STACK_UPP_TYPE(ControlEditTextValidationProcPtr) ControlEditTextValidationUPP;
typedef STACK_UPP_TYPE(EditUnicodePostUpdateProcPtr) EditUnicodePostUpdateUPP;
/*
* NewControlEditTextValidationUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ControlEditTextValidationUPP
NewControlEditTextValidationUPP(ControlEditTextValidationProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NewEditUnicodePostUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern EditUnicodePostUpdateUPP
NewEditUnicodePostUpdateUPP(EditUnicodePostUpdateProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeControlEditTextValidationUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeControlEditTextValidationUPP(ControlEditTextValidationUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeEditUnicodePostUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern void
DisposeEditUnicodePostUpdateUPP(EditUnicodePostUpdateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeControlEditTextValidationUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeControlEditTextValidationUPP(
ControlRef control,
ControlEditTextValidationUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeEditUnicodePostUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern Boolean
InvokeEditUnicodePostUpdateUPP(
UniCharArrayHandle uniText,
UniCharCount uniTextLength,
UniCharArrayOffset iStartOffset,
UniCharArrayOffset iEndOffset,
void * refcon,
EditUnicodePostUpdateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if __MACH__
#ifdef __cplusplus
inline ControlEditTextValidationUPP NewControlEditTextValidationUPP(ControlEditTextValidationProcPtr userRoutine) { return userRoutine; }
inline EditUnicodePostUpdateUPP NewEditUnicodePostUpdateUPP(EditUnicodePostUpdateProcPtr userRoutine) { return userRoutine; }
inline void DisposeControlEditTextValidationUPP(ControlEditTextValidationUPP) { }
inline void DisposeEditUnicodePostUpdateUPP(EditUnicodePostUpdateUPP) { }
inline void InvokeControlEditTextValidationUPP(ControlRef control, ControlEditTextValidationUPP userUPP) { (*userUPP)(control); }
inline Boolean InvokeEditUnicodePostUpdateUPP(UniCharArrayHandle uniText, UniCharCount uniTextLength, UniCharArrayOffset iStartOffset, UniCharArrayOffset iEndOffset, void * refcon, EditUnicodePostUpdateUPP userUPP) { return (*userUPP)(uniText, uniTextLength, iStartOffset, iEndOffset, refcon); }
#else
#define NewControlEditTextValidationUPP(userRoutine) ((ControlEditTextValidationUPP)userRoutine)
#define NewEditUnicodePostUpdateUPP(userRoutine) ((EditUnicodePostUpdateUPP)userRoutine)
#define DisposeControlEditTextValidationUPP(userUPP)
#define DisposeEditUnicodePostUpdateUPP(userUPP)
#define InvokeControlEditTextValidationUPP(control, userUPP) (*userUPP)(control)
#define InvokeEditUnicodePostUpdateUPP(uniText, uniTextLength, iStartOffset, iEndOffset, refcon, userUPP) (*userUPP)(uniText, uniTextLength, iStartOffset, iEndOffset, refcon)
#endif
#endif
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __HITEXTVIEWS__ */

View File

@@ -0,0 +1,60 @@
/*
File: HITextViews.r
Contains: Definitions of text-display and text-editing views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HITEXTVIEWS_R__
#define __HITEXTVIEWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kControlStaticTextProc 288
#define kControlKindStaticText 'stxt'
#define kControlStaticTextStyleTag 'font'
#define kControlStaticTextTextTag 'text'
#define kControlStaticTextTextHeightTag 'thei'
#define kControlStaticTextTruncTag 'trun'
#define kControlStaticTextCFStringTag 'cfst'
#define kControlStaticTextIsMultilineTag 'stim'
#define kControlEditUnicodeTextProc 912
#define kControlEditUnicodeTextPasswordProc 914
#define kControlKindEditUnicodeText 'eutx'
#define kControlEditTextStyleTag 'font' /* ControlFontStyleRec */
#define kControlEditTextTextTag 'text' /* Buffer of chars - you supply the buffer */
#define kControlEditTextKeyFilterTag 'fltr'
#define kControlEditTextSelectionTag 'sele' /* ControlEditTextSelectionRec */
#define kControlEditTextPasswordTag 'pass' /* The clear text password text */
#define kControlEditTextCharCount 'chrc' /* [UInt32] Count of characters in the control's text */
#define kControlEditTextKeyScriptBehaviorTag 'kscr' /* ControlKeyScriptBehavior. Defaults to "PrefersRoman" for password fields, */
/* or "AllowAnyScript" for non-password fields. */
#define kControlEditTextLockedTag 'lock' /* Boolean. Locking disables editability. */
#define kControlEditTextFixedTextTag 'ftxt' /* Like the normal text tag, but fixes inline input first */
#define kControlEditTextValidationProcTag 'vali' /* ControlEditTextValidationUPP. Called when a key filter can't be: after cut, paste, etc. */
#define kControlEditTextCFStringTag 'cfst' /* CFStringRef (Also available on CarbonLib 1.5) */
#define kControlEditTextPasswordCFStringTag 'pwcf' /* CFStringRef */
#define kControlEditTextSingleLineTag 'sglc' /* data is a Boolean; indicates whether the control should always be single-line */
#define kControlEditTextInsertTextBufferTag 'intx' /* data is an array of char; get or set the control's text as WorldScript-encoded text */
#define kControlEditTextInsertCFStringRefTag 'incf' /* data is a CFStringRef; get or set the control's text as a CFStringRef. Caller should release CFString if getting. */
#define kControlEditUnicodeTextPostUpdateProcTag 'upup' /* data is a UnicodePostUpdateUPP; get or set the post-update proc */
#define kControlEditTextSpellCheckingTag 'spck' /* data is a Boolean; indicates whether the control wants to have spell checking support. Available in Leopard and later. */
#define kControlEditTextSpellCheckAsYouTypeTag 'scat' /* data is a Boolean; indicates whether you want to support spell-checking-as-you-type. Available in Leopard and later. */
#endif /* __HITEXTVIEWS_R__ */

View File

@@ -0,0 +1,260 @@
/*
File: HIToolbox/HIToolbox.h
Contains: Master include for HIToolbox private framework
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HITOOLBOX__
#define __HITOOLBOX__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __HIOBJECT__
#include <HIToolbox/HIObject.h>
#endif
#ifndef __HIARCHIVE__
#include <HIToolbox/HIArchive.h>
#endif
#ifndef __HIGEOMETRY__
#include <HIToolbox/HIGeometry.h>
#endif
#ifndef __HITOOLBAR__
#include <HIToolbox/HIToolbar.h>
#endif
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
#ifndef __HITEXTUTILS__
#include <HIToolbox/HITextUtils.h>
#endif
#ifndef __HIACCESSIBILITY__
#include <HIToolbox/HIAccessibility.h>
#endif
#ifndef __EVENTS__
#include <HIToolbox/Events.h>
#endif
#ifndef __NOTIFICATION__
#include <HIToolbox/Notification.h>
#endif
#ifndef __DRAG__
#include <HIToolbox/Drag.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __HITHEME__
#include <HIToolbox/HITheme.h>
#endif
#ifndef __MACWINDOWS__
#include <HIToolbox/MacWindows.h>
#endif
#ifndef __MENUS__
#include <HIToolbox/Menus.h>
#endif
#ifndef __DIALOGS__
#include <HIToolbox/Dialogs.h>
#endif
#ifndef __CARBONEVENTSCORE__
#include <HIToolbox/CarbonEventsCore.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __TEXTSERVICES__
#include <HIToolbox/TextServices.h>
#endif
#ifndef __SCRAP__
#include <HIToolbox/Scrap.h>
#endif
#ifndef __MACTEXTEDITOR__
#include <HIToolbox/MacTextEditor.h>
#endif
#ifndef __MACHELP__
#include <HIToolbox/MacHelp.h>
#endif
#ifndef __HIBUTTONVIEWS__
#include <HIToolbox/HIButtonViews.h>
#endif
#ifndef __HICLOCKVIEW__
#include <HIToolbox/HIClockView.h>
#endif
#ifndef __HICOCOAVIEW__
#include <HIToolbox/HICocoaView.h>
#endif
#ifndef __HICOMBOBOX__
#include <HIToolbox/HIComboBox.h>
#endif
#ifndef __HICONTAINERVIEWS__
#include <HIToolbox/HIContainerViews.h>
#endif
#ifndef __HIDATABROWSER__
#include <HIToolbox/HIDataBrowser.h>
#endif
#ifndef __HIDISCLOSUREVIEWS__
#include <HIToolbox/HIDisclosureViews.h>
#endif
#ifndef __HIIMAGEVIEWS__
#include <HIToolbox/HIImageViews.h>
#endif
#ifndef __HILITTLEARROWS__
#include <HIToolbox/HILittleArrows.h>
#endif
#ifndef __HIMENUVIEW__
#include <HIToolbox/HIMenuView.h>
#endif
#ifndef __HIPOPUPBUTTON__
#include <HIToolbox/HIPopupButton.h>
#endif
#ifndef __HIPROGRESSVIEWS__
#include <HIToolbox/HIProgressViews.h>
#endif
#ifndef __HIRELEVANCEBAR__
#include <HIToolbox/HIRelevanceBar.h>
#endif
#ifndef __HISCROLLVIEW__
#include <HIToolbox/HIScrollView.h>
#endif
#ifndef __HISEARCHFIELD__
#include <HIToolbox/HISearchField.h>
#endif
#ifndef __HISEGMENTEDVIEW__
#include <HIToolbox/HISegmentedView.h>
#endif
#ifndef __HISEPARATOR__
#include <HIToolbox/HISeparator.h>
#endif
#ifndef __HISLIDER__
#include <HIToolbox/HISlider.h>
#endif
#ifndef __HITABBEDVIEW__
#include <HIToolbox/HITabbedView.h>
#endif
#ifndef __HITEXTVIEWS__
#include <HIToolbox/HITextViews.h>
#endif
#ifndef __HIWINDOWVIEWS__
#include <HIToolbox/HIWindowViews.h>
#endif
#ifndef __HITEXTLENGTHFILTER__
#include <HIToolbox/HITextLengthFilter.h>
#endif
#ifndef __CONTROLDEFINITIONS__
#include <HIToolbox/ControlDefinitions.h>
#endif
#ifndef __TRANSLATIONEXTENSIONS__
#include <HIToolbox/TranslationExtensions.h>
#endif
#ifndef __TRANSLATION__
#include <HIToolbox/Translation.h>
#endif
#ifndef __AEINTERACTION__
#include <HIToolbox/AEInteraction.h>
#endif
#ifndef __TYPESELECT__
#include <HIToolbox/TypeSelect.h>
#endif
#ifndef __MACAPPLICATION__
#include <HIToolbox/MacApplication.h>
#endif
#ifndef __KEYBOARDS__
#include <HIToolbox/Keyboards.h>
#endif
#ifndef __IBCARBONRUNTIME__
#include <HIToolbox/IBCarbonRuntime.h>
#endif
#ifndef __TEXTINPUTSOURCES__
#include <HIToolbox/TextInputSources.h>
#endif
#ifndef __HITOOLBOXDEBUGGING__
#include <HIToolbox/HIToolboxDebugging.h>
#endif
#ifndef __IMKINPUTSESSION__
#include <HIToolbox/IMKInputSession.h>
#endif
#if !__LP64__
#ifndef __LISTS__
#include <HIToolbox/Lists.h>
#endif
#ifndef __TEXTEDIT__
#include <HIToolbox/TextEdit.h>
#endif
#ifndef __TSMTE__
#include <HIToolbox/TSMTE.h>
#endif
#endif /* !__LP64__ */
#endif /* __HITOOLBOX__ */

View File

@@ -0,0 +1,124 @@
/*
File: HIToolbox.r
Contains: Master include for HIToolbox private framework
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HITOOLBOX_R__
#define __HITOOLBOX_R__
#ifndef __APPLICATIONSERVICES_R__
#include <ApplicationServices/ApplicationServices.r>
#endif
#ifndef __CONTROLS_R__
#include <HIToolbox/Controls.r>
#endif
#ifndef __APPEARANCE_R__
#include <HIToolbox/Appearance.r>
#endif
#ifndef __MACWINDOWS_R__
#include <HIToolbox/MacWindows.r>
#endif
#ifndef __MENUS_R__
#include <HIToolbox/Menus.r>
#endif
#ifndef __DIALOGS_R__
#include <HIToolbox/Dialogs.r>
#endif
#ifndef __CARBONEVENTS_R__
#include <HIToolbox/CarbonEvents.r>
#endif
#ifndef __MACHELP_R__
#include <HIToolbox/MacHelp.r>
#endif
#ifndef __HIBUTTONVIEWS_R__
#include <HIToolbox/HIButtonViews.r>
#endif
#ifndef __HICLOCKVIEW_R__
#include <HIToolbox/HIClockView.r>
#endif
#ifndef __HICOMBOBOX_R__
#include <HIToolbox/HIComboBox.r>
#endif
#ifndef __HICONTAINERVIEWS_R__
#include <HIToolbox/HIContainerViews.r>
#endif
#ifndef __HIDATABROWSER_R__
#include <HIToolbox/HIDataBrowser.r>
#endif
#ifndef __HIDISCLOSUREVIEWS_R__
#include <HIToolbox/HIDisclosureViews.r>
#endif
#ifndef __HIIMAGEVIEWS_R__
#include <HIToolbox/HIImageViews.r>
#endif
#ifndef __HILITTLEARROWS_R__
#include <HIToolbox/HILittleArrows.r>
#endif
#ifndef __HIPOPUPBUTTON_R__
#include <HIToolbox/HIPopupButton.r>
#endif
#ifndef __HIPROGRESSVIEWS_R__
#include <HIToolbox/HIProgressViews.r>
#endif
#ifndef __HISCROLLVIEW_R__
#include <HIToolbox/HIScrollView.r>
#endif
#ifndef __HISEGMENTEDVIEW_R__
#include <HIToolbox/HISegmentedView.r>
#endif
#ifndef __HISEPARATOR_R__
#include <HIToolbox/HISeparator.r>
#endif
#ifndef __HISLIDER_R__
#include <HIToolbox/HISlider.r>
#endif
#ifndef __HITABBEDVIEW_R__
#include <HIToolbox/HITabbedView.r>
#endif
#ifndef __HITEXTVIEWS_R__
#include <HIToolbox/HITextViews.r>
#endif
#ifndef __CONTROLDEFINITIONS_R__
#include <HIToolbox/ControlDefinitions.r>
#endif
#ifndef __TRANSLATIONEXTENSIONS_R__
#include <HIToolbox/TranslationExtensions.r>
#endif
#endif /* __HITOOLBOX_R__ */

View File

@@ -0,0 +1,345 @@
#ifndef __HITOOLBOXDEBUGGING__
#define __HITOOLBOXDEBUGGING__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __EVENTS__
#include <HIToolbox/Events.h>
#endif
#ifndef __MACWINDOWS__
#include <HIToolbox/MacWindows.h>
#endif
#ifndef __DIALOGS__
#include <HIToolbox/Dialogs.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/* CarbonEvents */
#if !__LP64__
/*
* DebugSetEventTraceEnabled()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugSetEventTraceEnabled(Boolean inEnabled) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugTraceEvent()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugTraceEvent(
OSType inEventClass,
UInt32 inEventKind,
Boolean inTrace) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugTraceEventByName()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugTraceEventByName(
const char * eventName,
Boolean inTrace) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugPrintTracedEvents()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintTracedEvents(void) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugPrintEventQueue()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintEventQueue(EventQueueRef inQueue) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
#endif /* !__LP64__ */
/*
* DebugPrintMainEventQueue()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintMainEventQueue(void) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugPrintEvent()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintEvent(EventRef inEvent) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/* Control specific debugging routines */
#if !__LP64__
/*
* DebugPrintControl()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintControl(ControlRef inControl) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugPrintControlHierarchy()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintControlHierarchy(WindowRef inWindow) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DumpControlHierarchy()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in AppearanceLib 1.0 and later
*/
extern OSErr
DumpControlHierarchy(
WindowRef inWindow,
const FSSpec * inDumpFile) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* Dialogs */
/*
* DebugPrintDialogInfo()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintDialogInfo(DialogRef inDialog) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/* HIView */
/*
* HIViewFlashDirtyArea()
*
* Discussion:
* Debugging aid. Flashes the region which would be redrawn at the
* next draw time for an entire window.
*
* Parameters:
*
* inWindow:
* The window to flash the dirty region for.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIViewFlashDirtyArea(WindowRef inWindow) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/* Menus */
/*
* DebugPrintMenuList()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintMenuList(void) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugPrintMenu()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintMenu(MenuRef inMenu) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugPrintMenuItem()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintMenuItem(
MenuRef inMenu,
MenuItemIndex inItem) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/* Windows */
/*
* DebugPrintWindow()
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintWindow(WindowRef windowRef) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugPrintWindowGroup()
*
* Summary:
* Prints the contents of a window group to stdout.
*
* Parameters:
*
* inGroup:
* The group whose contents to print.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern void
DebugPrintWindowGroup(WindowGroupRef inGroup) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DebugPrintAllWindowGroups()
*
* Summary:
* Prints the full window group hierarchy, starting at the root
* group.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern void
DebugPrintAllWindowGroups(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DebugPrintWindowList()
*
* Summary:
* Prints the window list to stdout.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugPrintWindowList(void) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* DebugFlashWindowVisRgn() *** DEPRECATED ***
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugFlashWindowVisRgn(WindowRef windowRef) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED;
/*
* DebugFlashWindowUpdateRgn() *** DEPRECATED ***
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
DebugFlashWindowUpdateRgn(WindowRef inWindow) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HITOOLBOXDEBUGGING__ */

View File

@@ -0,0 +1,352 @@
/*
File: HIToolbox/HIWindowViews.h
Contains: Definition of the window-related views provided by HIToolbox.
Copyright: <20> 2006-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HIWINDOWVIEWS__
#define __HIWINDOWVIEWS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __APPEARANCE__
#include <HIToolbox/Appearance.h>
#endif
#ifndef __CARBONEVENTS__
#include <HIToolbox/CarbonEvents.h>
#endif
#ifndef __CONTROLS__
#include <HIToolbox/Controls.h>
#endif
#ifndef __HIVIEW__
#include <HIToolbox/HIView.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* HIWindowViews.h
*
* Discussion:
* API definitions for the window-related views.
*/
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> HIViewIDs for subviews of a window frame view */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/*
* kHIViewWindowContentID
*
* Discussion:
* The standard view ID for the content view of a window. Note that
* a window's content view should not be moved from its original
* container window into any other window; this will cause the
* content view to behave incorrectly. If you need to move all of
* the views from one window into another, embed a user pane into
* the content view and them embed all other views into the user
* pane, and move the user pane from one window to another.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowContentID AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* kHIViewWindowCloseBoxID
*
* Discussion:
* The standard view ID for the close box view of a window. Not all
* windows have close boxes, so be aware that you might not find
* this view if you look for it. This variable is only exported on
* Mac OS X 10.5 and later, but the close box view uses this view ID
* on Mac OS X 10.2 and later. If you need to access the view on an
* earlier version of Mac OS X, you can safely initialize your own
* view ID with the same contents as this constant.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowCloseBoxID AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* kHIViewWindowCollapseBoxID
*
* Discussion:
* The standard view ID for the collapse box view of a window. Not
* all windows have collapse boxes, so be aware that you might not
* find this view if you look for it. This variable is only exported
* on Mac OS X 10.5 and later, but the collapse box view uses this
* view ID on Mac OS X 10.2 and later. If you need to access the
* view on an earlier version of Mac OS X, you can safely initialize
* your own view ID with the same contents as this constant.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowCollapseBoxID AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* kHIViewWindowZoomBoxID
*
* Discussion:
* The standard view ID for the zoom box view of a window. Not all
* windows have zoom boxes, so be aware that you might not find this
* view if you look for it. This variable is only exported on Mac OS
* X 10.5 and later, but the zoom box view uses this view ID on Mac
* OS X 10.2 and later. If you need to access the view on an earlier
* version of Mac OS X, you can safely initialize your own view ID
* with the same contents as this constant.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowZoomBoxID AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* kHIViewWindowToolbarButtonID
*
* Discussion:
* The standard view ID for the toolbar button view of a window. Not
* all windows have toolbar buttons, so be aware that you might not
* find this view if you look for it. This variable is only exported
* on Mac OS X 10.5 and later, but the toolbar button view uses this
* view ID on Mac OS X 10.2 and later. If you need to access the
* view on an earlier version of Mac OS X, you can safely initialize
* your own view ID with the same contents as this constant.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowToolbarButtonID AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* kHIViewWindowTitleID
*
* Discussion:
* The standard view ID for the title view of a window. Not all
* windows have titles, so be aware that you might not find this
* view if you look for it. This variable is only exported on Mac OS
* X 10.5 and later, but the title view uses this view ID on Mac OS
* X 10.2 and later. If you need to access the view on an earlier
* version of Mac OS X, you can safely initialize your own view ID
* with the same contents as this constant.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowTitleID AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* kHIViewWindowToolbarID
*
* Discussion:
* The standard view ID for the toolbar view of a window. Not all
* windows have toolbars, so be aware that you might not find this
* view if you look for it. This variable is only exported on Mac OS
* X 10.5 and later, but the toolbar view uses this view ID on Mac
* OS X 10.2 and later. If you need to access the view on an earlier
* version of Mac OS X, you can safely initialize your own view ID
* with the same contents as this constant.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowToolbarID AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* kHIViewWindowGrowBoxID
*
* Discussion:
* The standard view ID for the grow box view of a window. Not all
* windows have grow boxes, so be aware that you might not find this
* view if you look for it.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern const HIViewID kHIViewWindowGrowBoxID AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* <20> HIView part codes for window frame views */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/*
* Summary:
* HIView part codes used by window frame views.
*
* Discussion:
* These part codes are used by an HIView that implements the frame
* of a window. They may be used with the standard document windows
* provided by the Window Manager. A custom window frame view may
* optionally (but is not required to) implement these part codes in
* its event handlers for kEventControlGetPartRegion/Bounds.
*/
enum {
/*
* Identifies the titlebar part of a window frame view. This partcode
* is used by GetWindowBounds and GetWindowRegion when called with
* kWindowTitleBarRgn.
*/
kHIWindowTitleBarPart = 2,
/*
* Identifies the draggable part of a window frame view. This
* partcode is used by GetWindowBounds and GetWindowRegion when
* called with kWindowDragRgn.
*/
kHIWindowDragPart = 3,
/*
* Identifies the proxy icon part of a window frame title view. The
* title view is a subview of the window frame view and is identified
* by an HIViewID of kHIViewWindowTitleID. This partcode is _not_
* used by the window frame view itself, but only by the title view.
* This partcode is used by GetWindowBounds and GetWindowRegion when
* called with kWindowTitleProxyIconRgn.
*/
kHIWindowTitleProxyIconPart = 2
};
/*==============================================================================*/
/* HIGrowBoxView */
/* */
/* The grow box view is a new view starting in Mac OS 10.2. It can be used in */
/* both the new compositing mode, as well as the traditional Control Manager */
/* mode. Like all new HIFoo views, this view is created invisibly. You must */
/* show the view after creation if you want to, like, see it and stuff. */
/*==============================================================================*/
/* The HIObject class ID for the HIGrowBoxView class. */
#define kHIGrowBoxViewClassID CFSTR("com.apple.higrowboxview")
/* Control Kind*/
enum {
kControlKindHIGrowBoxView = 'grow'
};
/* Currently there is no direct creation API for the grow box, so you must use */
/* HIObjectCreate if you wish to create one directly. Normally, a window will */
/* create one for you, so you should generally never need to do this. */
#if !__LP64__
/*
* HIGrowBoxViewSetTransparent()
*
* Discussion:
* Sets a grow box view as transparent, meaning it will draw the
* grow box lines over any content below it. When not transparent,
* it's an opaque white square with the grow lines.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inGrowBoxView:
* The grow box view reference.
*
* inTransparent:
* Pass true to make the grow view use its transparent look, false
* to give it the opaque look.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIGrowBoxViewSetTransparent(
HIViewRef inGrowBoxView,
Boolean inTransparent) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIGrowBoxViewIsTransparent()
*
* Discussion:
* Returns true if a grow box view is set to be transparent.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inGrowBoxView:
* The grow box view reference.
*
* Result:
* A boolean result.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern Boolean
HIGrowBoxViewIsTransparent(HIViewRef inGrowBoxView) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __HIWINDOWVIEWS__ */

View File

@@ -0,0 +1,206 @@
/*
File: HIToolbox/IBCarbonRuntime.h
Contains: Nib support for Carbon
Copyright: <20> 2000-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __IBCARBONRUNTIME__
#define __IBCARBONRUNTIME__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#ifndef __MACWINDOWS__
#include <HIToolbox/MacWindows.h>
#endif
#ifndef __MENUS__
#include <HIToolbox/Menus.h>
#endif
#ifndef __CONTROLDEFINITIONS__
#include <HIToolbox/ControlDefinitions.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
enum {
kIBCarbonRuntimeCantFindNibFile = -10960,
kIBCarbonRuntimeObjectNotOfRequestedType = -10961,
kIBCarbonRuntimeCantFindObject = -10962
};
/* ----- typedef ------ */
typedef struct OpaqueIBNibRef* IBNibRef;
/* ----- Create & Dispose NIB References ------ */
#if !__LP64__
/*
* CreateNibReference()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateNibReference(
CFStringRef inNibName,
IBNibRef * outNibRef) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* CreateNibReferenceWithCFBundle()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateNibReferenceWithCFBundle(
CFBundleRef inBundle,
CFStringRef inNibName,
IBNibRef * outNibRef) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeNibReference()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern void
DisposeNibReference(IBNibRef inNibRef) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* ----- Window ------ */
/*
* CreateWindowFromNib()
*
* Summary:
* Creates a window from a description stored in a nib file.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inNibRef:
* The identifier for the nib file containing the window
* description.
*
* inName:
* The name of the window description.
*
* outWindow:
* On exit, contains the window, if creation of the window was
* successful.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateWindowFromNib(
IBNibRef inNibRef,
CFStringRef inName,
WindowRef * outWindow) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* ----- Menu -----*/
/*
* CreateMenuFromNib()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateMenuFromNib(
IBNibRef inNibRef,
CFStringRef inName,
MenuRef * outMenuRef) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* ----- MenuBar ------*/
/*
* CreateMenuBarFromNib()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateMenuBarFromNib(
IBNibRef inNibRef,
CFStringRef inName,
Handle * outMenuBar) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* SetMenuBarFromNib()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
SetMenuBarFromNib(
IBNibRef inNibRef,
CFStringRef inName) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#ifdef __cplusplus
}
#endif
#endif /* __IBCARBONRUNTIME__ */

View File

@@ -0,0 +1,280 @@
/*
File: IMKInputSession.h
Contains: IMKInputSession Interfaces.
Copyright: (c) 2006 by Apple Computer, Inc., all rights reserved.
*/
/*!
@header
@abstract This header contains the protocol that is used to communicate with client input sessions. An input method uses this protocol to send text or obtain information about a client's text.
*/
#ifndef __IMKINPUTSESSION__
#define __IMKINPUTSESSION__
//to use this header you must use Objective-C. This will be part of HIToolbox/HIToolbox.h and many people who include that header
//do not use Objective-C.
#ifdef __OBJC__
#import <Foundation/Foundation.h>
#import <HIToolbox/TextServices.h>
/*!
@enum IMKLocationToOffsetMappingMode
@abstract List modes for mapping a screen location to a text offset.
@discussion Often how a screen location should be mapped to a text offset is ambiguous. When tracking a coordinate will not change the offset until the coordinate is completely past a given character. When trying to place an insertion point a coordinate will be mapped to the nearest character boundary.
*/
enum {
kIMKMouseTrackingMode = (1<<0),
kIMKNearestBoundaryMode = (1<<1)
};
typedef NSInteger IMKLocationToOffsetMappingMode;
/*!
@const IMKTextOrientationName
@abstract The key used to find client's text orientation value which is part of the dictionary returned by attributesForCharacterIndex.
@discussion The orientation is the orientation of the client's text. Use this key to access the orientation value in the attributes dictionary returned by attributesForCharacterIndex. The value is an NSNumber which represents a BOOL value. A value of 1 means the client's text is laid out horizontally. A value of 0 means that the client's text is laid out vertically.
*/
extern const NSString* IMKTextOrientationName;
@class IMKClient;
/*!
@protocol IMKTextInput
@abstract Used to send and obtain data from the client side session.
@discussion Input methods call one of the methods in this protocol to communicate with the client.
*/
@protocol IMKTextInput
/*!
@method
@abstract Sends text that has been fully converted to an input session.
@discussion When an input method finishes a conversion it calls this method and passes the finished text as an NSString or NSAttributedString. The replacementRange parameter is there to allow input methods to insert text at a location other than the current selection.
If used the replacementRange should be relative to the beginning of the client document.
If the string should be inserted at the current selection specify a replacementRange with a location and length of NSNotFound.
If the client does not support the TSMDocumentAccess protocol the replacementRange string will be ignored.
*/
- (void)insertText:(id)string replacementRange:(NSRange)replacementRange;
/*!
@method
@abstract Insert the text and mark it to indicate that it is part of an active input session.
@discussion The string parameter must be an NSString or an NSAttributedString. Passing an NSString will produce default marking ( On a 72 dpi screen that is a 2 pixel black underline for the entire string). SelectionRange indicates the area of the string that should be selected and therefore if possible the area that should be displayed. SelectionRange is relative to the string parameter.
For example, if the string contains the these characters: "INPUT" and the range is (5,0) the selection will be set right after the "T."
ReplacementRange specifies the location in the client document where the marked text should be placed. If the marked text should be placed at the current cursor location replacementRange.location will equal NSNotFound. If used (i.e. location is not NSNotFound) the replacementRange is relative to the client document (i.e. 0 is the beginning of the document) and NOT the string parameter.
Currently, the replacement range is sent to the client via the kEventParamTextInputSendReplaceRange Carbon Event parameter. As noted in the comment for this parameter for this parameter to be used the client must support the TSMDocumentAccess protocol. If a client does not support the TSMDocumentAccess protocol the replacementRange will be ignored.
*/
- (void)setMarkedText:(id)string selectionRange:(NSRange)selectionRange replacementRange:(NSRange)replacementRange;
/*
A Note on selectedRange:, attributedSubStringFromRange, and length.
These methods all depend on the client application supporting TSMDocumentAccess Carbon events. Many applications do not support these so input methods should be prepared for these methods to return nil or NSNotFound. The return that can be expected is included in the discussion of each of these methods.
*/
/*!
@method
@abstract Returns the current selection range.
@discussion If the client does not support the TSMDocumentAccess protocol the returned range will have a location value of NSNotFound and a length of NSNotFound.
If a valid range is returned it is relative to the client's document.
*/
- (NSRange)selectedRange;
/*!
@method
@abstract Returns the range in the document that is occupied by marked text, which in other terms is the current inline session.
@discussion While an input method is converting text input and sending it to the client the client will maintain a range of text that is marked. That is to say that there will be a range of text that is underlined in certain ways to indicate to the user that their keystrokes are in the process of being converted by an input method and the conversion has not yet been finalized. The input method uses this method to request that range. The returned range is relative to the clients document.
If this range is not available the range location and length will be NSNotFound.
*/
- (NSRange)markedRange;
/*!
@method
@abstract Called to request a string along with its attributes such as font and glyph info.
@discussion Input methods call this method to obtain a range of text from the client document along with that text's font and glyphInfo. The kind of attributes that can be included in the string are defined in CTStringAttributes.h. The range should be document relative.
If the client does not support TSMDocumentAccess the returned string will be created from data obtained by sending the client application a kEventTextInputGetSelectedText Carbon event.
The returned NSAttributedString is an autoreleased object. Do not release this object unless you retain it first.
Note it is possible that the returned string will be longer or shorter than the specified range. This can be caused when there surrogate unicodes in a document, and the range's location or length splits a surrogate pair.
You can test for this by comparing the string's length against the range you included as the range parameter.
*/
- (NSAttributedString*)attributedSubstringFromRange:(NSRange)range;
/*!
@method
@abstract Returns the length of the text document.
@discussion If the client does not support the TSMDocumentAccess protocol the returned value will be NSNotFound.
Please note that depending on how clients store text determing how long a text document is can be a very expensive operation. Input methods should be aware of this problem and avoid frequently calling this method.
*/
- (NSInteger)length;
/*!
@method
@abstract Map a global point to a location in the text document.
@discussion Given a global point (typically from a mousedown) map that to a location in a text document.
MappingMode is set to kIMKMouseTrackingMode if the input method is tracking the mouse. If the input method is tracking the mouse the application should pin highlighting to the active inline area. If the input method simply wants to map a screen postion to an offset than mappingMode should be set to kIMKNearestBoundaryMode.
If the point is not inside the text body the returned value will be NSNotFound. If the point is inside the text body and inside the marked range inMarkedRange will be set to YES. If it is outside the markedRange it will be set to NO.
*/
- (NSInteger)characterIndexForPoint:(NSPoint)point tracking:(IMKLocationToOffsetMappingMode)mappingMode inMarkedRange:(BOOL*)inMarkedRange;
/*!
@method - (NSDictionary*)attributesForCharacterIndex:(NSUInteger)index lineHeightRectangle:(NSRect*)lineRect;
@abstract Returns a dictionary of text attributes for the text at a given character index. The attributes include the CTFontRef for the text at that index and the text orientation. The text orientation is indicated by an NSNumber whose value is 0 if the text is vertically oriented and 1 if the text is horizontally oriented. The key for this value is IMKTextOrientationKey. Additionally, a rectangle that would frame a one-pixel wide rectangle with the height of the line is returned in the frame parameter. Note that rectangle will be oriented the same way the line is oriented.
@discussion Input methods will call this method to place a candidate window on the screen. The index is relative to the inline session. Note that if there is no inline session the value of index should be 0, which indicates that the information should be taken from the current selection.
The returned NSDictionary is an autoreleased object. Don't release it unless you have retained it.
*/
- (NSDictionary*)attributesForCharacterIndex:(NSUInteger)index lineHeightRectangle:(NSRect*)lineRect;
/*!
@method
@abstract Returns an array of NSString names for the attributes supported by the receiver.
@discussion Input methods should restrict the attributes used to create attributed strings to the attributes in this array.
This is not a copy function. The returned NSArray should not be released unless it is first retained.
*/
- (NSArray*)validAttributesForMarkedText;
/*!
@method
@abstract Override the current keyboard.
@discussion Pass a keyboard unique name. The client will try to locate a keyboard layout with that name in the input method's bundle. If a layout is found it is passed to the client who then tells the text service manager to use that layout for keyboard events. Input methods should call the method each time they are activated.
If an input method wishes to use a system keyboard to override the current keyboard they are responsible for determining the keyboard's unique name. Typically this name a DNS type name such as: com.apple.<some name>.
*/
-(void)overrideKeyboardWithKeyboardNamed:(NSString*)keyboardUniqueName;
/*!
@method
@abstract Select a new input mode.
@discussion The mode identifier is an NSString with a DNS format.
Typically the mode identifier is a DNS type name such as: com.<company name>.inputmethod.<some name>. The identifier should match one of the keys in the ComponentInputModeDict. This method allows an input method to change its mode directly.
*/
-(void)selectInputMode:(NSString*)modeIdentifier;
/*!
@method
@abstract Test to see if the current input session supports Unicode text.
@discussion Input methods that restrict the character codes sent to a client if that client does not support Unicode text should call this method to learn if a given input session supports Unicode text.
*/
-(BOOL)supportsUnicode;
/*!
@method
@abstract Returns the bundle identifier for the process that the input session is attached to.
@discussion Many input methods need to be able to identify the process that input sessions belong to. This method provides that service.
The returned NSString is an autoreleased object. Call retain to own it.
*/
-(NSString*)bundleIdentifier;
/*!
@method
@abstract Returns the window level for client window.
@discussion Call this to determine the client's window level.
Internally, IMKCandidates uses this method to determine the correct level for candidate display. Therefore, input methods that use IMKCandidates have no reason to call this method.
However, many input method developers have built there own candidate display system, and this method is here for their use. In order to display a candidate window at the correct level use this method to obtain the client window level, increment the returned level, and then apply that level to any candidate windows.
*/
-(CGWindowLevel)windowLevel;
/*!
@method
@abstract Check if the current client input session supports a given TSM property.
@discussion This method is available to provide compatibilty for input methods that need to check TSMDocument properties.
*/
-(BOOL)supportsProperty:(TSMDocumentPropertyTag)property;
/*!
@method
@abstract Return a unique ID for the client.
@discussion This method is a wrapper around the NSProcessInfo method globallyUniqueString.
*/
-(NSString*)uniqueClientIdentifierString AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER;
/*!
@method
@abstract Called to request a string along.
@discussion Input methods call this method to obtain a range of text from the client document The range should be document relative.
If the client does not support TSMDocumentAccess the returned string will be created from data obtained by sending the client application a kEventTextInputGetSelectedText Carbon event.
Note that clients that do not support TSMDocumentAccess are extremely rare. Certainly the text system for Cocoa does support this functionality.
The returned NSString is an autoreleased object. Do not release this object unless you retain it first.
Note it is possible that the returned string will be longer or shorter than the specified range. This can be caused when there surrogate unicodes in a document, and the range's location or length splits a surrogate pair.
The parameter actualRange will contain the real range of the string in this case.
*/
- (NSString*)stringFromRange:(NSRange)range actualRange:(NSRangePointer)actualRange AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER;
/*
@method
@abstract Returns a rectangle for a range of text.
@discussion Returns the first logical rectangular area for aRange. The return value is in the global coordinate. The size value can be negative if the text flows to the left. If non-NULL, actuallRange contains the character range corresponding to the returned area.
*/
- (NSRect)firstRectForCharacterRange:(NSRange)aRange actualRange:(NSRangePointer)actualRange AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER;
@end
@protocol IMKUnicodeTextInput
/*!
@method
@abstract Sends unicode text to the client application.
@discussion Use this method to send text that was not generated by user keyboard input. This method should be used by palette input methods that send text to a client. Typically the text is generated in response to user activity in the palette window. The string parameter can be either an NSString or an NSAttributedString. Use an NSAttributed string if you need to include NSGlyphInfo objects with the text in the string.
*/
-(void)insertText:(id)string;
@end
#endif
#endif

View File

@@ -0,0 +1,522 @@
/*
File: HIToolbox/Keyboards.h
Contains: Keyboard API.
Copyright: <20> 1997-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __KEYBOARDS__
#define __KEYBOARDS__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Keyboard API constants */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/*
* PhysicalKeyboardLayoutType
*
* Summary:
* Physical keyboard layout types indicate the physical keyboard
* layout. They are returned by the KBGetLayoutType API.
*/
typedef OSType PhysicalKeyboardLayoutType;
enum {
/*
* A JIS keyboard layout type.
*/
kKeyboardJIS = 'JIS ',
/*
* An ANSI keyboard layout type.
*/
kKeyboardANSI = 'ANSI',
/*
* An ISO keyboard layout type.
*/
kKeyboardISO = 'ISO ',
/*
* An unknown physical keyboard layout type.
*/
kKeyboardUnknown = kUnknownType /* '????'*/
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Keyboard API types */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/*
* KeyboardLayoutRef
*
* Summary:
* The opaque keyboard layout contains information about a keyboard
* layout. It is used with the keyboard layout APIs.
*
* Discussion:
* KeyboardLayoutRef APIs follow CoreFoundation function naming
* convention. You mustn't release any references you get from APIs
* named "Get."
*/
typedef struct OpaqueKeyboardLayoutRef* KeyboardLayoutRef;
/*
* KeyboardLayoutPropertyTag
*
* Summary:
* Keyboard layout property tags specify the value you want to
* retrieve. They are used with the KLGetKeyboardLayoutProperty API.
*/
typedef UInt32 KeyboardLayoutPropertyTag;
enum {
/*
* The keyboard layout data (const void *). It is used with the
* KeyTranslate API.
*/
kKLKCHRData = 0,
/*
* The keyboard layout data (const void *). It is used with the
* UCKeyTranslate API.
*/
kKLuchrData = 1,
/*
* The keyboard layout identifier (KeyboardLayoutIdentifier).
*/
kKLIdentifier = 2,
/*
* The keyboard layout icon (IconRef).
*/
kKLIcon = 3,
/*
* The localized keyboard layout name (CFStringRef).
*/
kKLLocalizedName = 4,
/*
* The keyboard layout name (CFStringRef).
*/
kKLName = 5,
/*
* The keyboard layout group identifier (SInt32).
*/
kKLGroupIdentifier = 6,
/*
* The keyboard layout kind (KeyboardLayoutKind).
*/
kKLKind = 7,
/*
* The language/locale string associated with the keyboard, if any
* (CFStringRef). This string uses ISO 639 and ISO 3166 codes
* (examples: "fr", "en_US". Note: The CFStringRef may be NULL for
* some keyboards.
*/
kKLLanguageCode = 9
};
/*
* KeyboardLayoutKind
*
* Summary:
* Keyboard layout kinds indicate available keyboard layout formats.
*/
typedef SInt32 KeyboardLayoutKind;
enum {
/*
* Both KCHR and uchr formats are available.
*/
kKLKCHRuchrKind = 0,
/*
* Only KCHR format is avaiable.
*/
kKLKCHRKind = 1,
/*
* Only uchr format is available.
*/
kKLuchrKind = 2
};
/*
* KeyboardLayoutIdentifier
*
* Summary:
* Keyboard layout identifiers specify particular keyboard layouts.
*/
typedef SInt32 KeyboardLayoutIdentifier;
enum {
kKLUSKeyboard = 0
};
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* Keyboard API routines */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/*
* KBGetLayoutType()
*
* Summary:
* Returns the physical keyboard layout type.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* iKeyboardType:
* The keyboard type ID. LMGetKbdType().
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: in KeyboardsLib 1.0 and later
*/
extern PhysicalKeyboardLayoutType
KBGetLayoutType(SInt16 iKeyboardType) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/* iterate keyboard layouts*/
#if !__LP64__
/*
* KLGetKeyboardLayoutCount() *** DEPRECATED ***
*
* Deprecated:
* Use TISCreateInputSourceList API to create a list of input
* sources that match specified properties.
*
* Summary:
* Returns the number of keyboard layouts.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* oCount:
* On exit, the number of keyboard layouts
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
KLGetKeyboardLayoutCount(CFIndex * oCount) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* KLGetKeyboardLayoutAtIndex() *** DEPRECATED ***
*
* Deprecated:
* Use TISCreateInputSourceList API to create a list of input
* sources that match specified properties.
*
* Summary:
* Retrieves the keyboard layout at the given index.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* iIndex:
* The index of the keyboard layout to retrieve. If the index is
* outside the index space of the keyboard layouts (0 to N-1
* inclusive, where N is the count of the keyboard layouts), the
* behavior is undefined.
*
* oKeyboardLayout:
* On exit, the keyboard layout with the given index.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
KLGetKeyboardLayoutAtIndex(
CFIndex iIndex,
KeyboardLayoutRef * oKeyboardLayout) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
*** deprecated. ***
NOTE: "Indexed" is a wrong name, please use "AtIndex"...
OSStatus KLGetIndexedKeyboardLayout(
CFIndex iIndex,
KeyboardLayoutRef *oKeyboardLayout );
*/
/* get keyboard layout info*/
/*
* KLGetKeyboardLayoutProperty() *** DEPRECATED ***
*
* Deprecated:
* Use TISGetInputSourceProperty API to query properties of a
* TISInputSourceRef.
*
* Summary:
* Retrives property value for the given keyboard layout and tag.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* iKeyboardLayout:
* The keyboard layout to be queried. If this parameter is not a
* valid KeyboardLayoutRef, the behavior is undefined.
*
* iPropertyTag:
* The property tag.
*
* oValue:
* On exit, the property value for the given keyboard layout and
* tag.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
KLGetKeyboardLayoutProperty(
KeyboardLayoutRef iKeyboardLayout,
KeyboardLayoutPropertyTag iPropertyTag,
const void ** oValue) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/* get keyboard layout with identifier or name*/
/*
* KLGetKeyboardLayoutWithIdentifier() *** DEPRECATED ***
*
* Deprecated:
* Use TISCreateInputSourceList API to create a list of input
* sources that match specified properties, such as the
* kTISPropertyInputSourceID property.
*
* Summary:
* Retrieves the keyboard layout with the given identifier.
*
* Discussion:
* For now, the identifier is in the range of SInt16 which is
* compatible with the Resource Manager resource ID. However, it
* will become an arbitrary SInt32 value at some point, so do not
* assume it is in SInt16 range or falls into the "script range" of
* the resource IDs.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* iIdentifier:
* The keyboard layout identifier.
*
* oKeyboardLayout:
* On exit, the keyboard layout with the given identifier.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
KLGetKeyboardLayoutWithIdentifier(
KeyboardLayoutIdentifier iIdentifier,
KeyboardLayoutRef * oKeyboardLayout) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* KLGetKeyboardLayoutWithName() *** DEPRECATED ***
*
* Deprecated:
* Use TISCreateInputSourceList API to create a list of input
* sources that match specified properties, such as the
* kTISPropertyInputSourceID property.
*
* Summary:
* Retrieves the keyboard layout with the given name.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* iName:
* The keyboard layout name.
*
* oKeyboardLayout:
* On exit, the keyboard layout with the given name.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
KLGetKeyboardLayoutWithName(
CFStringRef iName,
KeyboardLayoutRef * oKeyboardLayout) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/* get/set current keyboard layout of the current group identifier*/
/*
* KLGetCurrentKeyboardLayout() *** DEPRECATED ***
*
* Deprecated:
* Use TISCopyCurrentKeyboardLayoutInputSource.
* TISCopyCurrentKeyboardLayoutInputSource will return the current
* input source if it is a keyboard layout. If the current input
* source is an input method or one of its input modes, the TIS API
* will also return any keyboard override specified via
* TISSetInputMethodKeyboardLayoutOverride.
*
* Summary:
* Retrieves the current keyboard layout.
*
* Discussion:
* Retrieves the current keyboard layout for the current keyboard
* script. To retrive the current keyboard script for Roman
* keyboard script, you need to call KeyScript( smRoman |
* smKeyForceKeyScriptMask ) then call KLGetCurrentKeyboardLayout().
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* oKeyboardLayout:
* On exit, the current keyboard layout.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
KLGetCurrentKeyboardLayout(KeyboardLayoutRef * oKeyboardLayout) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* KLSetCurrentKeyboardLayout() *** DEPRECATED ***
*
* Deprecated:
* To make a keyboard layout become the current input source, use
* TISSelectInputSource API.
*
* Input methods have used this API to override the keyboard layout
* used when the input method or one of its input modes is selected.
* TISSetInputMethodKeyboardLayoutOverride should be used for this
* purpose and TISCopyCurrentKeyboardLayoutInputSource will return
* the keyboard layout specified.
* An benefit of using the TIS API to specify an override is that
* when the input method is selected, the keyboard layout specified
* will be visible to users of the Keyboard Viewer and allow them to
* see the underlying keyboard used for event delivery to your input
* method.
*
* Summary:
* Sets the current keyboard layout.
*
* Discussion:
* Sets the current keyboard layout for the current keyboard script.
* Returns "paramErr" when the current keyboard layout is not
* Unicode and the specified keyboard layout belongs to Unicode
* group. To set Roman keyboard script's current keyboard layout to
* "U.S." for example, you need to call KeyScript( smRoman |
* smKeyForceKeyScriptMask ) then call KLSetCurrentKeyboardLayout(
* theUSKeyboardLayoutRef ).
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* iKeyboardLayout:
* The keyboard layout.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
KLSetCurrentKeyboardLayout(KeyboardLayoutRef iKeyboardLayout) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* OBSOLETE */
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
/* These are obsolete. Carbon does not support these. */
/* Keyboard API Trap Number. Should be moved to Traps.i */
#endif /* !__LP64__ */
enum {
_KeyboardDispatch = 0xAA7A
};
/* Gestalt selector and values for the Keyboard API */
enum {
gestaltKeyboardsAttr = 'kbds',
gestaltKBPS2Keyboards = 1,
gestaltKBPS2SetIDToAny = 2,
gestaltKBPS2SetTranslationTable = 4
};
/* Keyboard API Error Codes */
/*
I stole the range blow from the empty space in the Allocation project but should
be updated to the officially registered range.
*/
enum {
errKBPS2KeyboardNotAvailable = -30850,
errKBIlligalParameters = -30851,
errKBFailSettingID = -30852,
errKBFailSettingTranslationTable = -30853,
errKBFailWritePreference = -30854
};
#ifdef __cplusplus
}
#endif
#endif /* __KEYBOARDS__ */

View File

@@ -0,0 +1,978 @@
/*
File: HIToolbox/MacApplication.h
Contains: Application-level APIs
Copyright: <20> 2000-2008 by Apple Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __MACAPPLICATION__
#define __MACAPPLICATION__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#ifndef __MENUS__
#include <HIToolbox/Menus.h>
#endif
#ifndef __HIOBJECT__
#include <HIToolbox/HIObject.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/*
* kHIToolboxVersionNumber
*
* Discussion:
* The current build number of HIToolbox.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern const float kHIToolboxVersionNumber AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
// the HIToolbox version number for various Mac OS X releases
#define kHIToolboxVersionNumber10_3 (145.0)
#define kHIToolboxVersionNumber10_3_2 (145.35)
#define kHIToolboxVersionNumber10_3_3 (145.38)
#define kHIToolboxVersionNumber10_3_4 (145.41)
#define kHIToolboxVersionNumber10_3_5 (145.43)
#define kHIToolboxVersionNumber10_3_9 (145.48)
#define kHIToolboxVersionNumber10_4 (219)
#define kHIToolboxVersionNumber10_4_1 (219.1)
#define kHIToolboxVersionNumber10_4_2 (220)
#define kHIToolboxVersionNumber10_4_2_SecUpdate (221)
#define kHIToolboxVersionNumber10_4_4 (222)
#define kHIToolboxVersionNumber10_4_4_Intel (223)
#define kHIToolboxVersionNumber10_4_6 (225)
#define kHIToolboxVersionNumber10_4_7 (226)
#define kHIToolboxVersionNumber10_4_9 (227)
#define kHIToolboxVersionNumber10_5 (343)
#define kHIToolboxVersionNumber10_5_1 (343)
#define kHIToolboxVersionNumber10_5_2 (352)
#define kHIToolboxVersionNumber10_5_3 (352)
#define kHIToolboxVersionNumber10_5_4 (352)
#define kHIToolboxVersionNumber10_5_5 (352)
#define kHIToolboxVersionNumber10_5_6 (353)
#define kHIToolboxVersionNumber10_5_7 (353)
/*
* kHIApplicationClassID
*
* Discussion:
* HIObject class ID for the HIApplication object. Available in Mac
* OS X 10.3 and later.
*/
#define kHIApplicationClassID CFSTR("com.apple.HIApplication")
/*
* Summary:
* Controls the presentation of system-provided user interface
* elements.
*
* Discussion:
* Note that the system UI mode is a per-process state. Switching
* from a process that is suppressing system UI to another process
* that is not will cause system UI elements to become visible
* automatically. Switching back to the first process will suppress
* system UI elements again.
*/
enum {
/*
* In this mode, all standard system UI elements are visible.
*/
kUIModeNormal = 0,
/*
* In this mode, system UI elements which cover the "content area" of
* the screen (the area other than the menubar) are hidden. However,
* these elements may automatically show themselves in response to
* mouse movements or other user activity; specifically, the Dock
* will still show itself automatically when the mouse moves into the
* Dock's auto-show region.
*/
kUIModeContentSuppressed = 1,
/*
* In this mode, system UI elements which cover the "content area" of
* the screen (the area other than the menubar) are hidden. Unlike
* kUIModeContentSuppressed, most UI elements will not automatically
* show themselves in this mode.
*/
kUIModeContentHidden = 2,
/*
* In this mode, all system UI elements, including the menubar, are
* hidden. However, these elements may automatically show themselves
* in response to mouse movements or other user activity;
* specifically, the Dock and menubar will still show themselves
* automatically when the mouse moves into the Dock's auto-show
* region. Available in Mac OS X 10.3 and later.
*/
kUIModeAllSuppressed = 4,
/*
* In this mode, all system UI elements, including the menubar, are
* hidden. Most system UI elements will not automatically show
* themselves in this mode. The application may request that the
* menubar automatically show itself while in this mode by passing
* the kUIOptionAutoShowMenuBar flag to SetSystemUIMode.
*/
kUIModeAllHidden = 3
};
typedef UInt32 SystemUIMode;
/*
* Summary:
* Controls optional behavior of system-provided user interface
* elements.
*/
enum {
/*
* Requests that the menubar automatically show itself when the user
* moves the mouse into the screen area that would ordinarily be
* occupied by the menubar. Only valid with kUIModeAllHidden.
*/
kUIOptionAutoShowMenuBar = 1 << 0,
/*
* Requests that the menubar animate on or offscreen, if the UIMode
* is also being changed such that the menubar will change
* visibility. Unlike other UI options, this option is not stored and
* only affects the behavior of this call to SetSystemUIMode. Valid
* for all modes. Available in Mac OS X 10.7 and later.
*/
kUIOptionAnimateMenuBar = 1 << 1,
/*
* Disables all items in the Apple menu. Valid for all modes.
*/
kUIOptionDisableAppleMenu = 1 << 2,
/*
* The active application may not be changed while this process is
* active. Currently disables the Command-Tab and Command-Shift-Tab
* key sequences to switch the active process, and the global window
* rotation key sequence selected by the user in the Keyboard
* preference pane. SetFrontProcess may still be used to explicitly
* switch the active process. Only valid with modes other than
* kUIModeNormal.
*/
kUIOptionDisableProcessSwitch = 1 << 3,
/*
* The Force Quit window may not be displayed while this process is
* active. Currently disables the Command-Option-Escape key sequence
* to open the Force Quit window and the Force Quit menu item in the
* Apple menu. Only valid with modes other than kUIModeNormal.
*/
kUIOptionDisableForceQuit = 1 << 4,
/*
* The current login session may not be terminated while this process
* is active. Currently disables the Power key and the Restart, Shut
* Down, and Log Out menu items in the Apple menu. Only valid with
* modes other than kUIModeNormal.
*/
kUIOptionDisableSessionTerminate = 1 << 5,
/*
* The Hide menu item in the Application menu is disabled. Note that
* this option does not prevent this application from being hidden if
* Hide Others is selected in some other application. Available in
* Mac OS X 10.3 and later.
*/
kUIOptionDisableHide = 1 << 6,
/*
* Provides the ability to specify whether the menu bar will disable
* its adaptive transparency. Note this should be used in conjunction
* with a full-screen window using kUIModeContentSuppressed or
* kUIModeContentHidden. Available in Mac OS X 10.6 and later. This
* constant was published in the Mac OS X 10.5 version of
* MacApplication.h, but had the wrong value (7) and should not be
* used in Mac OS X 10.5.
*/
kUIOptionDisableMenuBarTransparency = 1 << 9
};
typedef OptionBits SystemUIOptions;
/*
* SetSystemUIMode()
*
* Summary:
* Sets the presentation mode for system-provided user interface
* elements.
*
* Discussion:
* The presentation mode of an application determines which
* system-provided user interface elements are visible on thes
* screen. When the frontmost application changes its presentation
* mode, a kEventAppSystemUIModeChanged Carbon event is sent to all
* applications that have registered for the event. This event is
* also sent when an application is activated; it contains the newly
* active application's presentation mode.
*
* Note that SetSystemUIMode should _not_ be used from UIElement or
* BackgroundOnly applications. The presentation mode of the current
* login session is determined by the presentation mode of the
* frontmost faceful application. Therefore, the presentation mode
* of a UIElement or BackgroundOnly application will be ignored,
* since these types of applications can't be the frontmost faceful
* application.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inMode:
* The new mode.
*
* inOptions:
* Options controlling how the new mode behaves. Not all options
* are valid for all modes. Options that are invalid for the
* specified mode are silently ignored.
*
* Result:
* An operating system result code.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
SetSystemUIMode(
SystemUIMode inMode,
SystemUIOptions inOptions) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* GetSystemUIMode()
*
* Summary:
* Returns the presentation mode of the current application.
*
* Discussion:
* Note that GetSystemUIMode returns the presentation mode of the
* calling application, _not_ the mode of the current login session.
* The login session mode may be different, since the login session
* mode is determined by the presentation mode of the frontmost
* faceful application. If the calling application is not currently
* the frontmost faceful application, then its presentation mode
* will not be in use. You may use the kEventAppSystemUIModeChanged
* Carbon event to track changes in the login session's presentation
* mode.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* outMode:
* On exit, contains the current mode. You may pass NULL if you
* don't need this information.
*
* outOptions:
* On exit, contains the current options for the mode. You may
* pass NULL if you don't need this information.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern void
GetSystemUIMode(
SystemUIMode * outMode, /* can be NULL */
SystemUIOptions * outOptions) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
#if !__LP64__
/*
* HIApplicationGetCurrent()
*
* Summary:
* Returns the HIObjectRef of the currently running application
* object.
*
* Discussion:
* This HIObject's EventTargetRef is what will be returned from
* GetApplicationEventTarget. In Mac OS X 10.5, you can use this API
* to install your own HIObject delegates on the application object.
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* The HIObjectRef of the currently running application object.
*
* Availability:
* Mac OS X: in version 10.2 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
* Non-Carbon CFM: not available
*/
extern HIObjectRef
HIApplicationGetCurrent(void) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
/*
* HIApplicationGetFocus()
*
* Summary:
* Returns either the modeless or effective focus.
*
* Discussion:
* With the introduction of the modal focus stack, an application
* may have two different focused windows: the modeless focused
* window (the window most recently passed to the SetUserFocusWindow
* API), and the effective focus (either the modeless focus window
* or, if there is a non-empty modal focus stack, the topmost window
* in the focus stack). This API returns either window.
*
* Note that in Mac OS X 10.5, the GetUserFocusWindow API returns
* the same as HIApplicationGetFocus( false).
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inConsideringModalFocus:
* Indicates whether to return the effective focus (if true) or
* the modeless focus (if false).
*
* Result:
* The focused window, or NULL if there is no focused window.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern WindowRef
HIApplicationGetFocus(Boolean inConsideringModalFocus) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* SetApplicationDockTileImage()
*
* Discussion:
* Sets the image for the tile in the Dock that represents your
* application while it is running. If you set the image, it will
* NOT revert back to its original image when your application
* terminates. You need to manually restore it before quitting.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inImage:
* The image you wish to have as your tile image.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
SetApplicationDockTileImage(CGImageRef inImage) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* OverlayApplicationDockTileImage()
*
* Discussion:
* Takes the image passed in and composites it on top of the current
* image of your application's Dock tile. You might do this to put a
* standard badge over your application's icon to indicate something
* to the user.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inImage:
* The image you wish to overlay onto your tile image.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
OverlayApplicationDockTileImage(CGImageRef inImage) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* RestoreApplicationDockTileImage()
*
* Discussion:
* Restores the tile for your appliation in the Dock to its normal
* image (your application icon). You would use this if some overlay
* or change of the application icon needed to be removed.
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
RestoreApplicationDockTileImage(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* HIApplicationCreateDockTileContext()
*
* Summary:
* Creates a CGContextRef that can be used to draw into an
* application's Dock tile.
*
* Discussion:
* Unlike the BeginCGContextForApplicationDockTile API, this API
* returns a CGContextRef that has no transform applied to it; user
* space and device space are 1:1. Therefore, your application must
* use the output context size to determine the area in which you
* should draw in the context.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* outContextSize:
* On exit, returns the size of the context in which the
* application should draw.
*
* Result:
* A CGContextRef for drawing into the application's Dock tile. You
* must use EndCGContextForApplicationDockTile to release this
* context. To ensure that drawing to the context appears onscreen,
* make sure to call CGContextFlush before releasing the context.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework [32-bit only]
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern CGContextRef
HIApplicationCreateDockTileContext(HISize * outContextSize) AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
/*
* BeginCGContextForApplicationDockTile()
*
* Discussion:
* Creates and returns a CGContextRef. You can use this context to
* draw into your application's Dock tile with Quartz. You MUST call
* EndCGContextForApplicationDockTile and NOT CGContextRelease when
* using this API, as it locks your application's tile in the Dock.
* If you call CGContextRelease, the Dock will never know you are
* done with the tile.
*
* When drawing into the context returned by this API, you should
* draw into a rectangle with origin of (0,0) and size of (128,128).
* If the actual Dock tile window is larger than this size, the API
* will automatically set a transform on the context that will scale
* your content from 128x128 up to the actual tile window size. You
* can get an unscaled CGContextRef using the
* HIApplicationCreateDockTileContext API.
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* A CGContextRef for drawing into the application's Dock tile. You
* must use EndCGContextForApplicationDockTile to release this
* context. To ensure that drawing to the context appears onscreen,
* make sure to call CGContextFlush before releasing the context.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern CGContextRef
BeginCGContextForApplicationDockTile(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* EndCGContextForApplicationDockTile()
*
* Discussion:
* Ends the CG context for your application tile and frees the lock
* on the application Dock tile. You MUST call this routine and NOT
* CGContextRelease when using BeginCGContextForApplicationDockTile
* or HIApplicationCreateDockTileContext, as those APIs lock your
* application's tile in the Dock. If you call CGContextRelease, the
* Dock will never know you are done with the tile.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inContext:
* The context to release. The context is invalid after this call
* and should no longer be used. To ensure that drawing to the
* context appears onscreen, make sure to call CGContextFlush
* before releasing the context.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern void
EndCGContextForApplicationDockTile(CGContextRef inContext) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* BeginQDContextForApplicationDockTile() *** DEPRECATED ***
*
* Deprecated:
* Use HIApplicationCreateDockTileContext or
* BeginCGContextForApplicationDockTile instead, and draw with
* Quartz instead of QuickDraw.
*
* Discussion:
* Creates and returns a CGrafPtr for your application's tile in the
* Dock. You can use this port to draw into your application's Dock
* tile with QuickDraw. You MUST call
* EndQDContextForApplicationDockTile and NOT DisposePort when using
* this API, as it locks your application's tile in the Dock. If you
* call DisposePort, the Dock will never know you are done with the
* tile.
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* A QuickDraw port reference.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern CGrafPtr
BeginQDContextForApplicationDockTile(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* EndQDContextForApplicationDockTile() *** DEPRECATED ***
*
* Deprecated:
* Use EndCGContextForApplicationDockTile instead.
*
* Discussion:
* Disposes the QuickDraw port for your application tile and frees
* the lock on the application Dock tile. You MUST call this routine
* and NOT DisposePort when using
* BeginQDContextForApplicationDockTile, else the Dock will never
* know you are done with the tile.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inContext:
* The context to end. The context is invalid after this call and
* should no longer be used.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern void
EndQDContextForApplicationDockTile(CGrafPtr inContext) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* SetApplicationDockTileMenu()
*
* Summary:
* Sets the menu that is displayed by the application's Dock tile.
*
* Discussion:
* The Carbon Window Manager and the Dock will always automatically
* display a menu containing a list of the application's document
* windows. If the application wants to add other additional menu
* items, it can use the SetApplicationDockTileMenu API to provide
* those items. The items in the specified menu will be combined
* with the window title items. This API increments the refcount of
* the specified menu.
*
* Before the menu is actually displayed, it will receive
* kEventMenuPopulate, kEventMenuOpening, and kEventMenuEnableItems
* Carbon events, so any event handlers for these events may update
* the menu appropriately for the current state of the application.
*
*
* The application should set a command ID for each menu item in the
* Dock tile menu, and when that item is chosen, a
* kEventCommandProcess Carbon event containing the item's command
* ID will be sent to the user focus target.
*
* It is also possible to use the kEventAppGetDockTileMenu Carbon
* event to provide custom Dock tile menu contents; see
* CarbonEvents.h for details.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inMenu:
* The menu to display, or NULL to remove the current Dock tile
* menu.
*
* Availability:
* Mac OS X: in version 10.1 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
SetApplicationDockTileMenu(MenuRef inMenu) AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER;
/*
* GetApplicationDockTileMenu()
*
* Summary:
* Returns the menu that is displayed by the application's Dock tile.
*
* Discussion:
* The menu that is returned by this API is the menu that was passed
* to SetApplicationDockTileMenu. If SetApplicationDockTileMenu has
* not been called (or has been called with NULL), then this API
* will return NULL.
*
* Mac OS X threading:
* Not thread safe
*
* Result:
* The application's Dock tile menu, or NULL if none.
*
* Availability:
* Mac OS X: in version 10.1 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.1 and later
* Non-Carbon CFM: not available
*/
extern MenuRef
GetApplicationDockTileMenu(void) AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER;
/*
* CreateCGImageFromPixMaps()
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CreateCGImageFromPixMaps(
PixMapHandle inImage,
PixMapHandle inMask,
CGImageRef * outImage) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
/*
* GetApplicationTextEncoding()
*
* Summary:
* Returns the application's primary text encoding.
*
* Discussion:
* The application text encoding is used when you create a
* CFStringRef from text stored in Resource Manager resources, which
* typically uses one of the Mac encodings such as MacRoman or
* MacJapanese. The encoding is determined by: (a) if your app is
* bundled, the encoding of the .lproj directory chosen by CFBundle,
* (b) else if your plist has a CFBundleDevelopmentRegionKey, the
* encoding specified by that key, (c) else if your app has a 'vers'
* resource, the encoding for the region field in the 'vers', (d)
* else the current localization of the operating system.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.2 and later
* Non-Carbon CFM: not available
*/
extern TextEncoding
GetApplicationTextEncoding(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if !__LP64__
/*
* GetApplicationScript()
*
* Summary:
* Returns the application script.
*
* Discussion:
* The application script is used when you need a ScriptCode to pass
* to some other API, such as UseThemeFont.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.3 and later
* Non-Carbon CFM: not available
*/
extern ScriptCode
GetApplicationScript(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*------------------------------------------------------------------------------*/
/* HIAboutBox */
/* */
/* The strings below are for use as keys in the inOptions parameter of the */
/* HIAboutBox function, described below. */
/*------------------------------------------------------------------------------*/
#endif /* !__LP64__ */
#define kHIAboutBoxNameKey CFSTR("HIAboutBoxName")
#define kHIAboutBoxVersionKey CFSTR("HIAboutBoxVersion")
#define kHIAboutBoxCopyrightKey CFSTR("HIAboutBoxCopyright")
#define kHIAboutBoxDescriptionKey CFSTR("HIAboutBoxDescription")
#define kHIAboutBoxStringFileKey CFSTR("HIAboutBoxStringFile")
#if !__LP64__
/*
* HIAboutBox()
*
* Summary:
* Displays an HI-conformant about box.
*
* Discussion:
* This about box is a generic about box that automatically can
* display your application name, version string, and copyright
* string. It peeks into either the Info.plist (for the
* CFBundleName, CFBundleVersion, and CFBundleGetInfoString keys) or
* your bundle resource (not recommended) to get the information by
* default. You can customize what it displays by passing in various
* options in the input dictionary. Note that currently the
* description string can only be specified in the options
* dictionary; this function does not check your Info.plist for a
* descriptions string. <br>
* There are three basic ways to call this function. First, you can
* pass NULL for inOptions. As mentioned, default information will
* be displayed. Second, you can pass the actual values for the
* strings displayed by passing the strings in the inOptions
* dictionary using the keys provided, such as kHIAboutBoxNameKey.
* If a replacement string is not passed, the default behavior kicks
* in. For example, you could pass some variant of your application
* name in the dictionary, but not pass a replacement version or
* copyright strings. The Toolbox would display your replacement
* string, and fall back to looking in the Info.plist for the other
* strings. The third way to call this is to pass the name of a
* string file in the dictionary with the key
* kHIAboutBoxStringFileKey. We will automatically use that file to
* find the strings for the about box. The keys in the string file
* should be the same value as the keys you would use to pass into
* the inOptions dictionary. Again, if a string is not found in that
* file, we would fall back to looking for a string in the
* dictionary, and then finally the Info.plist.
*
* Certainly this is not the be-all-end-all of about boxes, but it
* does provide a simple no-work about box for your application. The
* standard Toolbox application handler now responds to the
* kHICommandAbout command ID by calling HIAboutBox for you. This
* means that any Carbon Event-based application will get this
* behavior for free right out of the box. If you wish for the
* window to respond to cmd-W in the menu bar, you should make sure
* that menu item has the kHICommandClose commandID.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inOptions:
* A dictionary of replacement strings, or the name of a string
* file to retrieve the strings from, or NULL. See the discussion
* for how this is used.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.3 and later in Carbon.framework [32-bit only]
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HIAboutBox(CFDictionaryRef inOptions) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
#endif /* !__LP64__ */
/*
* HISearchWindowShow()
*
* Summary:
* Requests that the Spotlight search window be displayed.
*
* Discussion:
* Brings up "search for string" Spotlight UI. The window is shown
* in the default configuration.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* inSearchString:
* A CFString for which to search. You may pass NULL to open the
* search window with no initial query string.
*
* inFlags:
* Optional flags. Use kNilOptions for now.
*
* Result:
* An operating system status code.
*
* Availability:
* Mac OS X: in version 10.4 and later in Carbon.framework
* CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.4 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
HISearchWindowShow(
CFStringRef inSearchString, /* can be NULL */
OptionBits inFlags) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
/*
* HIDictionaryWindowShow()
*
* Summary:
* Implements "Look up in Dictionary" context menu action.
*
* Discussion:
* Opens Dictionary.app or panel to show the definition of a word or
* phrase.
*
* Mac OS X threading:
* Not thread safe
*
* Parameters:
*
* dictionary:
* This parameter is not supported now. You should always pass
* NULL.
*
* textString:
* Text that contains the word or phrase to look up. The data type
* must be either CFStringRef, CFAttributedStringRef, or CFDataRef
* containing Rich Text Format data. Text attributes are used to
* draw the title of the Dictionary Panel.
*
* selectionRange:
* Specifies the selection range in textString. If there is no
* selection, use the range returned by DCSGetTermRangeInString()
* in CoreServices/DictionaryServices.
*
* textFont:
* Required only when the textString is CFStringRef and otherwise
* ignored. Specifies CTFontRef that corresponds to
* selectionRange.location. The font is used to draw the title of
* the Dictionary Panel.
*
* textOrigin:
* Typographic baseline origin point of the character at
* selectionRange.location in screen pixels (the top left of the
* screen is 0, 0)
*
* verticalText:
* Set true if the text is drawn in vertical orientation
*
* viewTransform:
* Affine transformation matrix being applied to the view contains
* textString. Set NULL to use identity matrix. This is used to
* align Dictionary Panel title with the original text. Currently,
* only scaling factor is supported.
*
* Availability:
* Mac OS X: in version 10.5 and later in Carbon.framework
* CarbonLib: not available
* Non-Carbon CFM: not available
*/
extern void
HIDictionaryWindowShow(
DCSDictionaryRef dictionary, /* can be NULL */
CFTypeRef textString,
CFRange selectionRange,
CTFontRef textFont, /* can be NULL */
CGPoint textOrigin,
Boolean verticalText,
const CGAffineTransform * viewTransform) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER;
#ifdef __cplusplus
}
#endif
#endif /* __MACAPPLICATION__ */

View File

@@ -0,0 +1,25 @@
/*
File: MacHelp.r
Contains: Carbon Help Manager Interfaces.
Copyright: <20> 1998-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __MACHELP_R__
#define __MACHELP_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kHMHelpMenuID (-16490) /* Resource ID and menu ID of help menu */
#endif /* __MACHELP_R__ */

View File

@@ -0,0 +1,279 @@
/*
File: MacWindows.r
Contains: Window Manager Interfaces
Copyright: <20> 1997-2008 by Apple Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __MACWINDOWS_R__
#define __MACWINDOWS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kAlertWindowClass 1
#define kMovableAlertWindowClass 2
#define kModalWindowClass 3
#define kMovableModalWindowClass 4
#define kFloatingWindowClass 5
#define kDocumentWindowClass 6
#define kUtilityWindowClass 8
#define kHelpWindowClass 10
#define kSheetWindowClass 11
#define kToolbarWindowClass 12
#define kPlainWindowClass 13
#define kOverlayWindowClass 14
#define kSheetAlertWindowClass 15
#define kAltPlainWindowClass 16
#define kSimpleWindowClass 18
#define kDrawerWindowClass 20
#define kAllWindowClasses 0xFFFFFFFF
#define kWindowNoAttributes 0
#define kWindowCloseBoxAttribute 0x01
#define kWindowHorizontalZoomAttribute 0x02
#define kWindowVerticalZoomAttribute 0x04
#define kWindowFullZoomAttribute 0x06
#define kWindowCollapseBoxAttribute 0x08
#define kWindowResizableAttribute 0x10
#define kWindowSideTitlebarAttribute 0x20
#define kWindowToolbarButtonAttribute 0x40
#define kWindowUnifiedTitleAndToolbarAttribute 0x80
#define kWindowMetalAttribute 0x0100
#define kWindowNoTitleBarAttribute 0x0200
#define kWindowTexturedSquareCornersAttribute 0x0400
#define kWindowMetalNoContentSeparatorAttribute 0x0800
#define kWindowHasRoundBottomBarCornersAttribute 0x1000
#define kWindowDoesNotCycleAttribute 0x8000
#define kWindowNoUpdatesAttribute 0x00010000
#define kWindowNoActivatesAttribute 0x00020000
#define kWindowOpaqueForEventsAttribute 0x00040000
#define kWindowCompositingAttribute 0x00080000
#define kWindowNoShadowAttribute 0x00200000
#define kWindowCanBeVisibleWithoutLoginAttribute 0x00400000
#define kWindowHideOnSuspendAttribute 0x01000000
#define kWindowAsyncDragAttribute 0x00800000
#define kWindowStandardHandlerAttribute 0x02000000
#define kWindowHideOnFullScreenAttribute 0x04000000
#define kWindowInWindowMenuAttribute 0x08000000
#define kWindowLiveResizeAttribute 0x10000000
#define kWindowIgnoreClicksAttribute 0x20000000
#define kWindowHighResolutionCapableAttribute 0x00100000
#define kWindowStandardDocumentAttributes 0x1F
#define kWindowStandardFloatingAttributes 0x09
#define kWindowFrameworkScaledAttribute 0x00100000
#define kWindowDefProcType 'WDEF'
#define kStandardWindowDefinition 0 /* for document windows and dialogs */
#define kRoundWindowDefinition 1 /* old Desk Accessory-style window */
#define kFloatingWindowDefinition 124 /* for floating windows */
/* for use with kStandardWindowDefinition */
#define kDocumentWindowVariantCode 0
#define kModalDialogVariantCode 1
#define kPlainDialogVariantCode 2
#define kShadowDialogVariantCode 3
#define kMovableModalDialogVariantCode 5
#define kAlertVariantCode 7
#define kMovableAlertVariantCode 9 /* for use with kFloatingWindowDefinition */
#define kSideFloaterVariantCode 8
/* Resource IDs for theme-savvy window defprocs */
#define kWindowDocumentDefProcResID 64
#define kWindowDialogDefProcResID 65
#define kWindowUtilityDefProcResID 66
#define kWindowUtilitySideTitleDefProcResID 67
#define kWindowSheetDefProcResID 68
#define kWindowSimpleDefProcResID 69
#define kWindowSheetAlertDefProcResID 70
/* Proc IDs for theme-savvy windows */
#define kWindowDocumentProc 1024
#define kWindowGrowDocumentProc 1025
#define kWindowVertZoomDocumentProc 1026
#define kWindowVertZoomGrowDocumentProc 1027
#define kWindowHorizZoomDocumentProc 1028
#define kWindowHorizZoomGrowDocumentProc 1029
#define kWindowFullZoomDocumentProc 1030
#define kWindowFullZoomGrowDocumentProc 1031
/* Proc IDs for theme-savvy dialogs */
#define kWindowPlainDialogProc 1040
#define kWindowShadowDialogProc 1041
#define kWindowModalDialogProc 1042
#define kWindowMovableModalDialogProc 1043
#define kWindowAlertProc 1044
#define kWindowMovableAlertProc 1045
/* procIDs available from Mac OS 8.1 (Appearance 1.0.1) forward */
#define kWindowMovableModalGrowProc 1046
/* Proc IDs for top title bar theme-savvy floating windows */
#define kWindowFloatProc 1057
#define kWindowFloatGrowProc 1059
#define kWindowFloatVertZoomProc 1061
#define kWindowFloatVertZoomGrowProc 1063
#define kWindowFloatHorizZoomProc 1065
#define kWindowFloatHorizZoomGrowProc 1067
#define kWindowFloatFullZoomProc 1069
#define kWindowFloatFullZoomGrowProc 1071
/* Proc IDs for side title bar theme-savvy floating windows */
#define kWindowFloatSideProc 1073
#define kWindowFloatSideGrowProc 1075
#define kWindowFloatSideVertZoomProc 1077
#define kWindowFloatSideVertZoomGrowProc 1079
#define kWindowFloatSideHorizZoomProc 1081
#define kWindowFloatSideHorizZoomGrowProc 1083
#define kWindowFloatSideFullZoomProc 1085
#define kWindowFloatSideFullZoomGrowProc 1087
/* Proc IDs for sheet windows */
#define kWindowSheetProc 1088 /* available in Mac OS X and CarbonLib 1.3 */
#define kWindowSheetAlertProc 1120 /* available in Mac OS X 10.1 and CarbonLib 1.3 */
/* Proc IDs for simple windows */
#define kWindowSimpleProc 1104
#define kWindowSimpleFrameProc 1105
#define kWindowOverlayProc 1136
#define kWindowNoPosition 0x0000
#define kWindowDefaultPosition 0x0000 /* used by StandardAlert */
#define kWindowCenterMainScreen 0x280A
#define kWindowAlertPositionMainScreen 0x300A
#define kWindowStaggerMainScreen 0x380A
#define kWindowCenterParentWindow 0xA80A
#define kWindowAlertPositionParentWindow 0xB00A
#define kWindowStaggerParentWindow 0xB80A
#define kWindowCenterParentWindowScreen 0x680A
#define kWindowAlertPositionParentWindowScreen 0x700A
#define kWindowStaggerParentWindowScreen 0x780A
#define kWindowCenterOnMainScreen 1
#define kWindowCenterOnParentWindow 2
#define kWindowCenterOnParentWindowScreen 3
#define kWindowCascadeOnMainScreen 4
#define kWindowCascadeOnParentWindow 5
#define kWindowCascadeOnParentWindowScreen 6
#define kWindowCascadeStartAtParentWindowScreen 10
#define kWindowAlertPositionOnMainScreen 7
#define kWindowAlertPositionOnParentWindow 8
#define kWindowAlertPositionOnParentWindowScreen 9
#define kWindowDefinitionVersionOne 1
#define kWindowDefinitionVersionTwo 2
#define kWindowIsCollapsedState 0x01
#define kStoredWindowSystemTag 'appl' /* Only Apple collection items will be of this tag */
#define kStoredBasicWindowDescriptionID 'sbas' /* BasicWindowDescription */
#define kStoredWindowPascalTitleID 's255' /* pascal title string */
#define kStoredWindowTitleCFStringID 'cfst' /* CFString title string */
/*--------------------------wind <20> Extensible Window Resource Format------------------*/
/* The extensible window resource format is a flattened collection containing items */
/* stored by StoreWindowIntoCollection, plus possible application-specific items. */
type 'wind' as 'flac';
/*--------------------------wctb <20> Window Color Lookup Table--------------------------*/
/*
wctb_RezTemplateVersion:
0 - original
1 - more color parts and implicit header <-- default
*/
#ifndef wctb_RezTemplateVersion
#ifdef oldTemp /* grandfather in use of <20>oldTemp<6D> */
#define wctb_RezTemplateVersion 0
#else
#define wctb_RezTemplateVersion 1
#endif
#endif
type 'wctb' {
#if wctb_RezTemplateVersion == 0
unsigned hex longint; /* ctSeed */
integer; /* ctFlags */
#elif wctb_RezTemplateVersion == 1
unsigned hex longint = 0; /* ctSeed */
integer = 0; /* ctFlags */
#endif
integer = $$Countof(ColorSpec) - 1; /* ctSize */
wide array ColorSpec {
integer wContentColor, /* value */
wFrameColor,
wTextColor,
wHiliteColor,
wTitleBarColor,
wHiliteLight,
wHiliteDark,
wTitleBarLight,
wTitleBarDark,
wDialogLight,
wDialogDark,
wTingeLight,
wTingeDark;
unsigned integer; /* RGB: red */
unsigned integer; /* green */
unsigned integer; /* blue */
};
};
/*----------------------------WIND <20> Window Template------------------------------------*/
/*
WIND_RezTemplateVersion:
0 - original
1 - additional positioning info at end <-- default
*/
#ifndef WIND_RezTemplateVersion
#define WIND_RezTemplateVersion 1
#endif
type 'WIND' {
rect; /* boundsRect */
integer documentProc, /* procID */
dBoxProc,
plainDBox,
altDBoxProc,
noGrowDocProc,
movableDBoxProc,
zoomDocProc = 8,
zoomNoGrow = 12;
byte invisible, visible; /* visible */
fill byte;
byte noGoAway, goAway; /* goAway */
fill byte;
unsigned hex longint; /* refCon */
pstring Untitled = "Untitled"; /* title */
#if WIND_RezTemplateVersion == 1
/* The following are window positioning options used from Mac OS 7.0 forward */
align word;
unsigned integer noAutoCenter = 0x0000,
centerMainScreen = 0x280a,
alertPositionMainScreen = 0x300a,
staggerMainScreen = 0x380a,
centerParentWindow = 0xa80a,
alertPositionParentWindow = 0xb00a,
staggerParentWindow = 0xb80a,
centerParentWindowScreen = 0x680a,
alertPositionParentWindowScreen = 0x700a,
staggerParentWindowScreen = 0x780a;
#endif
};
#endif /* __MACWINDOWS_R__ */

View File

@@ -0,0 +1,272 @@
/*
File: Menus.r
Contains: Menu Manager Interfaces.
Copyright: <20> 1985-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __MENUS_R__
#define __MENUS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kMenuStdMenuProc 63
#define kMenuStdMenuBarProc 63
#define kMenuNoModifiers 0 /* Mask for no modifiers */
#define kMenuShiftModifier 0x01 /* Mask for shift key modifier */
#define kMenuOptionModifier 0x02 /* Mask for option key modifier */
#define kMenuControlModifier 0x04 /* Mask for control key modifier */
#define kMenuNoCommandModifier 0x08 /* Mask for no command key modifier */
#define kMenuNoIcon 0 /* No icon */
#define kMenuIconType 1 /* Type for ICON */
#define kMenuShrinkIconType 2 /* Type for ICON plotted 16 x 16 */
#define kMenuSmallIconType 3 /* Type for SICN */
#define kMenuColorIconType 4 /* Type for cicn */
#define kMenuIconSuiteType 5 /* Type for Icon Suite */
#define kMenuIconRefType 6 /* Type for Icon Ref */
#define kMenuCGImageRefType 7 /* Type for a CGImageRef (Mac OS X only) */
#define kMenuSystemIconSelectorType 8 /* Type for an OSType identifying an IconRef registered with Icon Services under kSystemIconsCreator (Mac OS X 10.1 and later only) */
#define kMenuIconResourceType 9 /* Type for a CFStringRef with the full name of a .icns resource in the main bundle of the process (Mac OS X 10.1 and later only) */
#define kMenuNullGlyph 0x00 /* Null (always glyph 1) */
#define kMenuTabRightGlyph 0x02 /* Tab to the right key (for left-to-right script systems) */
#define kMenuTabLeftGlyph 0x03 /* Tab to the left key (for right-to-left script systems) */
#define kMenuEnterGlyph 0x04 /* Enter key */
#define kMenuShiftGlyph 0x05 /* Shift key */
#define kMenuControlGlyph 0x06 /* Control key */
#define kMenuOptionGlyph 0x07 /* Option key */
#define kMenuSpaceGlyph 0x09 /* Space (always glyph 3) key */
#define kMenuDeleteRightGlyph 0x0A /* Delete to the right key (for right-to-left script systems) */
#define kMenuReturnGlyph 0x0B /* Return key (for left-to-right script systems) */
#define kMenuReturnR2LGlyph 0x0C /* Return key (for right-to-left script systems) */
#define kMenuNonmarkingReturnGlyph 0x0D /* Nonmarking return key */
#define kMenuPencilGlyph 0x0F /* Pencil key */
#define kMenuDownwardArrowDashedGlyph 0x10 /* Downward dashed arrow key */
#define kMenuCommandGlyph 0x11 /* Command key */
#define kMenuCheckmarkGlyph 0x12 /* Checkmark key */
#define kMenuDiamondGlyph 0x13 /* Diamond key */
#define kMenuAppleLogoFilledGlyph 0x14 /* Apple logo key (filled) */
#define kMenuParagraphKoreanGlyph 0x15 /* Unassigned (paragraph in Korean) */
#define kMenuDeleteLeftGlyph 0x17 /* Delete to the left key (for left-to-right script systems) */
#define kMenuLeftArrowDashedGlyph 0x18 /* Leftward dashed arrow key */
#define kMenuUpArrowDashedGlyph 0x19 /* Upward dashed arrow key */
#define kMenuRightArrowDashedGlyph 0x1A /* Rightward dashed arrow key */
#define kMenuEscapeGlyph 0x1B /* Escape key */
#define kMenuClearGlyph 0x1C /* Clear key */
#define kMenuLeftDoubleQuotesJapaneseGlyph 0x1D /* Unassigned (left double quotes in Japanese) */
#define kMenuRightDoubleQuotesJapaneseGlyph 0x1E /* Unassigned (right double quotes in Japanese) */
#define kMenuTrademarkJapaneseGlyph 0x1F /* Unassigned (trademark in Japanese) */
#define kMenuBlankGlyph 0x61 /* Blank key */
#define kMenuPageUpGlyph 0x62 /* Page up key */
#define kMenuCapsLockGlyph 0x63 /* Caps lock key */
#define kMenuLeftArrowGlyph 0x64 /* Left arrow key */
#define kMenuRightArrowGlyph 0x65 /* Right arrow key */
#define kMenuNorthwestArrowGlyph 0x66 /* Northwest arrow key */
#define kMenuHelpGlyph 0x67 /* Help key */
#define kMenuUpArrowGlyph 0x68 /* Up arrow key */
#define kMenuSoutheastArrowGlyph 0x69 /* Southeast arrow key */
#define kMenuDownArrowGlyph 0x6A /* Down arrow key */
#define kMenuPageDownGlyph 0x6B /* Page down key */
#define kMenuAppleLogoOutlineGlyph 0x6C /* Apple logo key (outline) */
#define kMenuContextualMenuGlyph 0x6D /* Contextual menu key */
#define kMenuPowerGlyph 0x6E /* Power key */
#define kMenuF1Glyph 0x6F /* F1 key */
#define kMenuF2Glyph 0x70 /* F2 key */
#define kMenuF3Glyph 0x71 /* F3 key */
#define kMenuF4Glyph 0x72 /* F4 key */
#define kMenuF5Glyph 0x73 /* F5 key */
#define kMenuF6Glyph 0x74 /* F6 key */
#define kMenuF7Glyph 0x75 /* F7 key */
#define kMenuF8Glyph 0x76 /* F8 key */
#define kMenuF9Glyph 0x77 /* F9 key */
#define kMenuF10Glyph 0x78 /* F10 key */
#define kMenuF11Glyph 0x79 /* F11 key */
#define kMenuF12Glyph 0x7A /* F12 key */
#define kMenuF13Glyph 0x87 /* F13 key */
#define kMenuF14Glyph 0x88 /* F14 key */
#define kMenuF15Glyph 0x89 /* F15 key */
#define kMenuControlISOGlyph 0x8A /* Control key (ISO standard) */
#define kMenuEjectGlyph 0x8C /* Eject key (available on Mac OS X 10.2 and later) */
#define kMenuEisuGlyph 0x8D /* Japanese eisu key (available in Mac OS X 10.4 and later) */
#define kMenuKanaGlyph 0x8E /* Japanese kana key (available in Mac OS X 10.4 and later) */
#define kMenuF16Glyph 0x8F /* F16 key (available in SnowLeopard and later) */
#define kMenuF17Glyph 0x90 /* F17 key (available in SnowLeopard and later) */
#define kMenuF18Glyph 0x91 /* F18 key (available in SnowLeopard and later) */
#define kMenuF19Glyph 0x92 /* F19 key (available in SnowLeopard and later) */
#define kMenuAttrExcludesMarkColumn 0x01
#define kMenuAttrAutoDisable 0x04
#define kMenuAttrUsePencilGlyph 0x08
#define kMenuAttrHidden 0x10
#define kMenuAttrCondenseSeparators 0x20
#define kMenuAttrDoNotCacheImage 0x40
#define kMenuAttrDoNotUseUserCommandKeys 0x80
#define kMenuItemAttrDisabled 0x01
#define kMenuItemAttrIconDisabled 0x02
#define kMenuItemAttrSubmenuParentChoosable 0x04
#define kMenuItemAttrDynamic 0x08
#define kMenuItemAttrNotPreviousAlternate 0x10
#define kMenuItemAttrHidden 0x20
#define kMenuItemAttrSeparator 0x40
#define kMenuItemAttrSectionHeader 0x80
#define kMenuItemAttrIgnoreMeta 0x0100
#define kMenuItemAttrAutoRepeat 0x0200
#define kMenuItemAttrUseVirtualKey 0x0400
#define kMenuItemAttrCustomDraw 0x0800
#define kMenuItemAttrIncludeInCmdKeyMatching 0x1000
#define kMenuItemAttrAutoDisable 0x2000
#define kMenuItemAttrUpdateSingleItem 0x4000
#define gestaltContextualMenuAttr 'cmnu'
#define gestaltContextualMenuUnusedBit 0
#define gestaltContextualMenuTrapAvailable 1
#define gestaltContextualMenuHasAttributeAndModifierKeys 2 /* Contextual Menu Manager supports keyContextualMenuAttributes and keyContextualMenuModifiers */
#define gestaltContextualMenuHasUnicodeSupport 3 /* Contextual Menu Manager supports typeUnicodeText and typeCFStringRef */
#define kCMHelpItemNoHelp 0
#define kCMHelpItemAppleGuide 1
#define kCMHelpItemOtherHelp 2
#define kCMHelpItemRemoveHelp 3
#define kCMNothingSelected 0
#define kCMMenuItemSelected 1
#define kCMShowHelpSelected 3
/*----------------------------MENU <20> Menu-----------------------------------------------*/
type 'MENU' {
integer; /* Menu ID */
fill word[2];
integer textMenuProc = 0; /* ID of menu def proc */
fill word;
unsigned hex bitstring[31]
allEnabled = 0x7FFFFFFF; /* Enable flags */
boolean disabled, enabled; /* Menu enable */
pstring apple = "\0x14"; /* Menu Title */
wide array {
pstring; /* Item title */
byte noIcon; /* Icon number */
char noKey = "\0x00", /* Key equivalent or */
hierarchicalMenu = "\0x1B"; /* hierarchical menu */
char noMark = "\0x00", /* Marking char or id */
check = "\0x12"; /* of hierarchical menu */
fill bit;
unsigned bitstring[7]
plain; /* Style */
};
byte = 0;
};
/*----------------------------MBAR <20> Menu Bar-------------------------------------------*/
type 'MBAR' {
integer = $$CountOf(MenuArray); /* Number of menus */
wide array MenuArray{
integer; /* Menu resource ID */
};
};
/*----------------------------mctb <20> Menu Color Lookup Table----------------------------*/
type 'mctb' {
integer = $$CountOf(MCTBArray); /* Color table count */
wide array MCTBArray {
integer mctbLast = -99; /* Menu resource ID */
integer; /* Menu Item */
wide array [4] {
unsigned integer; /* RGB: red */
unsigned integer; /* green */
unsigned integer; /* blue */
};
fill word; /* Reserved word */
};
};
/*-------------------------------xmnu <20> Extended menu resource---------------------------*/
type 'xmnu'
{
switch
{
case versionZero:
key integer = 0; /* version */
integer = $$Countof(ItemExtensions);
array ItemExtensions
{
switch
{
case skipItem:
key integer=0;
case dataItem:
key integer=1;
unsigned longint; /* Command ID */
unsigned hex byte; /* modifiers */
fill byte; /* icon type placeholder */
fill long; /* icon handle placeholder */
unsigned longint sysScript=-1, /* text encoding */
currScript=-2; /* (use currScript for default)*/
unsigned longint; /* refCon */
unsigned longint; /* refCon2 */
unsigned integer noHierID=0; /* hierarchical menu ID */
unsigned integer sysFont=0; /* font ID */
integer naturalGlyph=0; /* keyboard glyph */
};
};
case versionOne:
key integer = 1; /* version */
integer = $$Countof(ItemExtensions);
array ItemExtensions
{
switch
{
case skipItem:
key integer=0;
case dataItem:
key integer=1;
unsigned longint; /* Command ID */
unsigned hex byte; /* modifiers */
unsigned hex byte noVKey=0; /* virtual keycode for command key */
unsigned hex longint noAttributes=0; /* MenuItemAttributes */
unsigned longint sysScript=-1, /* text encoding */
currScript=-2; /* (use currScript for default)*/
unsigned longint; /* refCon */
unsigned longint noIndent=0; /* indent */
unsigned integer noHierID=0; /* hierarchical menu ID */
unsigned integer sysFont=0; /* font ID */
integer naturalGlyph=0; /* keyboard glyph */
};
};
};
};
#if TARGET_OS_WIN32
/*----------------------------MENA <20> Menu Accessory Key---------------------------------*/
type 'MENA' {
integer = $$CountOf(MenuArray); /* Number of keys */
longint; /* flags */
wide array MenuArray{
char; /* key */
};
};
#endif /* TARGET_OS_WIN32 */
#endif /* __MENUS_R__ */

View File

@@ -0,0 +1,141 @@
/*
File: HIToolbox/Notification.h
Contains: Notification Manager interfaces
Copyright: <20> 1989-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __NOTIFICATION__
#define __NOTIFICATION__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
typedef struct NMRec NMRec;
typedef NMRec * NMRecPtr;
typedef CALLBACK_API( void , NMProcPtr )(NMRecPtr nmReqPtr);
typedef STACK_UPP_TYPE(NMProcPtr) NMUPP;
struct NMRec {
QElemPtr qLink; /* next queue entry*/
short qType; /* queue type -- ORD(nmType) = 8*/
short nmFlags; /* reserved*/
SRefCon nmPrivate; /* reserved*/
short nmReserved; /* reserved*/
short nmMark; /* item to mark in Apple menu*/
Handle nmIcon; /* handle to small icon*/
Handle nmSound; /* handle to sound record*/
StringPtr nmStr; /* string to appear in alert*/
NMUPP nmResp; /* pointer to response routine*/
SRefCon nmRefCon; /* for application use*/
};
/*
* NewNMUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern NMUPP
NewNMUPP(NMProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* DisposeNMUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeNMUPP(NMUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* InvokeNMUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeNMUPP(
NMRecPtr nmReqPtr,
NMUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#if __MACH__
#ifdef __cplusplus
inline NMUPP NewNMUPP(NMProcPtr userRoutine) { return userRoutine; }
inline void DisposeNMUPP(NMUPP) { }
inline void InvokeNMUPP(NMRecPtr nmReqPtr, NMUPP userUPP) { (*userUPP)(nmReqPtr); }
#else
#define NewNMUPP(userRoutine) ((NMUPP)userRoutine)
#define DisposeNMUPP(userUPP)
#define InvokeNMUPP(nmReqPtr, userUPP) (*userUPP)(nmReqPtr)
#endif
#endif
#if !__LP64__
/*
* NMInstall()
*
* Mac OS X threading:
* Thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
NMInstall(NMRecPtr nmReqPtr) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* NMRemove()
*
* Mac OS X threading:
* Thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only]
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSErr
NMRemove(NMRecPtr nmReqPtr) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
#endif /* !__LP64__ */
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __NOTIFICATION__ */

View File

@@ -0,0 +1,660 @@
/*
File: HIToolbox/Scrap.h
Contains: Scrap Manager Interfaces.
Copyright: <20> 1985-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __SCRAP__
#define __SCRAP__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*
________________________________________________________________
UNIVERSAL SCRAP MANAGER INTERFACES
________________________________________________________________
The following interfaces are available when compiling for BOTH
Carbon AND Mac OS 8.
________________________________________________________________
*/
/*
While we're in here mucking about, we defined a new type to
to put some confusion to rest. The old calls, as well as the
new calls, use the new type. Existing clients should be
blissfully ignorant.
*/
typedef FourCharCode ScrapFlavorType;
enum {
kScrapFlavorTypePicture = 'PICT', /* contents of a PicHandle*/
kScrapFlavorTypeText = 'TEXT', /* stream of characters*/
kScrapFlavorTypeTextStyle = 'styl', /* see TEGetStyleScrapHandle*/
kScrapFlavorTypeMovie = 'moov', /* reference to a movie*/
kScrapFlavorTypeSound = 'snd ', /* see SndRecord and SndPlay*/
kScrapFlavorTypeUnicode = 'utxt', /* stream of UTF16 characters (internal representation)*/
kScrapFlavorTypeUTF16External = 'ut16', /* stream of UTF16 characters (external representation)*/
kScrapFlavorTypeUnicodeStyle = 'ustl' /* ATSUI defines; Textension uses*/
};
/*
If you are a Carbon client and you need to run on Mac OS 8,
you may still need to load and unload the scrap. Under Mac OS
X, the scrap is held by the pasteboard server instead of in a
handle in your app's heap, so LoadScrap and UnloadScrap do
nothing when called under Mac OS X.
*/
#if !__LP64__
/*
* LoadScrap() *** DEPRECATED ***
*
* Deprecated:
* LoadScrap does nothing on Mac OS X.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSStatus
LoadScrap(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* UnloadScrap() *** DEPRECATED ***
*
* Deprecated:
* UnloadScrap does nothing on Mac OS X.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in InterfaceLib 7.1 and later
*/
extern OSStatus
UnloadScrap(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
________________________________________________________________
CARBON SCRAP MANAGER INTERFACES
________________________________________________________________
The following interfaces are available only when compiling for
Carbon.
________________________________________________________________
*/
/*
When promising a scrap flavor, it's OK if you
don't yet know how big the flavor data will be.
In this case, just pass kScrapFlavorSizeUnknown
for the flavor data size.
*/
#endif /* !__LP64__ */
enum {
kScrapFlavorSizeUnknown = -1
};
/*
kScrapReservedFlavorType is a flavor type which is reserved
for use by Scrap Manager. If you pass it to Scrap Manager,
it will be rejected.
*/
enum {
kScrapReservedFlavorType = 'srft'
};
/*
We've added scrap flavor flags ala Drag Manager.
kScrapFlavorMaskNone means you want none of the flags.
kScrapFlavorSenderOnlyMask means only the process which
put the flavor on the scrap can see it. If some other
process put a flavor with this flag on the scrap,
your process will never see the flavor, so there's
no point in testing for this flag.
kScrapFlavorTranslated means the flavor was translated
from some other flavor in the scrap by Translation Manager.
Most callers should not care about this bit.
*/
enum {
kScrapFlavorMaskNone = 0x00000000,
kScrapFlavorMaskSenderOnly = 0x00000001,
kScrapFlavorMaskTranslated = 0x00000002
};
typedef UInt32 ScrapFlavorFlags;
/*
ScrapFlavorInfo describes a single flavor within
a scrap.
*/
struct ScrapFlavorInfo {
ScrapFlavorType flavorType;
ScrapFlavorFlags flavorFlags;
};
typedef struct ScrapFlavorInfo ScrapFlavorInfo;
typedef struct OpaqueScrapRef* ScrapRef;
/*
kScrapRefNone is guaranteed to be an invalid ScrapRef. This
is convenient when initializing application variables.
*/
#define kScrapRefNone ((ScrapRef)NULL)
/*
Defined Apple scrap names for GetScrapByName
kScrapClipboardScrap traditional clipboard scrap
kScrapFindScrap compatible with Cocoa's global find scrap
*/
#define kScrapClipboardScrap CFSTR("com.apple.scrap.clipboard")
#define kScrapFindScrap CFSTR("com.apple.scrap.find")
/* Enumerated options to be passed to GetScrapByName*/
enum {
kScrapGetNamedScrap = 0, /* get current named scrap without bumping*/
kScrapClearNamedScrap = (1L << 0) /* acquire the named scrap, bumping and clearing*/
};
/*
GetScrapByName allows access to an indefinite number of public or private
scraps. The constant kScrapClipboardScrap refers to the "current" scrap
we've all come to know and love. kScrapFindScrap allows Carbon apps to
interact seamlessly with Cocoa's global find scrap. Note that calling:
GetScrapByName( kScrapClipboardScrap, kScrapGetNamedScrap, &scrap );
is an exact match to the call:
GetCurrentScrap( &scrap );
Additionally, a call to:
GetScrapByName( kScrapClipboardScrap, kScrapClearNamedScrap, &scrap );
is a replacement for the sequence:
ClearCurrentScrap();
GetCurrentScrap( &scrap );
You can use this API to generate your own private scraps to use as a high
level interprocess communication between your main and helper apps. The Java
naming convention is suggested for your scraps ( ie. com.joeco.scrap.secret ).
CarbonLib does not support arbitrary named scraps; when calling this API on
CarbonLib, kScrapClipboardScrap is the only supported value for the name parameter.
*/
#if !__LP64__
/*
* GetScrapByName() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardCreate instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.1 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.5 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetScrapByName(
CFStringRef name,
OptionBits options,
ScrapRef * scrap) AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
GetCurrentScrap obtains a reference to the current scrap.
The ScrapRef obtained via GetCurrentScrap will become
invalid and unusable after the scrap is cleared.
*/
/*
* GetCurrentScrap() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardCreate instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetCurrentScrap(ScrapRef * scrap) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
GetScrapFlavorFlags tells you [a] whether the scrap contains
data for a particular flavor and [b] some things about that
flavor if it exists. This call never blocks, and is useful
for deciding whether to enable the Paste item in your Edit
menu, among other things.
*/
/*
* GetScrapFlavorFlags() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardGetItemFlavorFlags
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetScrapFlavorFlags(
ScrapRef scrap,
ScrapFlavorType flavorType,
ScrapFlavorFlags * flavorFlags) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
GetScrapFlavorSize gets the size of the data of the specified
flavor. This function blocks until the specified flavor
data is available. GetScrapFlavorSize is intended as a prelude
to allocating memory and calling GetScrapFlavorData.
*/
/*
* GetScrapFlavorSize() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardCopyItemFlavorData
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetScrapFlavorSize(
ScrapRef scrap,
ScrapFlavorType flavorType,
Size * byteCount) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
GetScrapFlavorData gets the data from the specified flavor in the
specified scrap. This function blocks until the specified flavor
data is available. Specify the maximum size your buffer can contain;
on output, this function produces the number of bytes that were
available (even if this is more than you requested).
*/
/*
* GetScrapFlavorData() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardCopyItemFlavorData
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetScrapFlavorData(
ScrapRef scrap,
ScrapFlavorType flavorType,
Size * byteCount,
void * destination) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
ClearCurrentScrap clears the current scrap. Call this
first when the user requests a Copy or Cut operation --
even if you maintain a private scrap! You should not wait
until receiving a suspend event to call ClearCurrentScrap. Call
it immediately after the user requests a Copy or Cut operation.
You don't need to put any data on the scrap immediately (although
it's perfectly fine to do so). You DO need to call GetCurrentScrap
after ClearCurrentScrap so you'll have a valid ScrapRef to pass
to other functions.
*/
/*
* ClearCurrentScrap() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardClear instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
ClearCurrentScrap(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
ClearScrap will clear the scrap passed in and return the bumped
ScrapRef value. ClearScrap behaves similarly to GetScrapByName
when called with the kScrapClearNamedScrap option with the
benefit of not requiring a name in the event one is not available.
CarbonLib does not support arbitrary named scraps; when calling this
API on CarbonLib, only clearing the current scrap is supported.
*/
/*
* ClearScrap() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardClear instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.1 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.5 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
ClearScrap(ScrapRef * inOutScrap) AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
PutScrapFlavor is a lot like PutScrap, with two differences:
we added a ScrapRef parameter at the beginning and you can
"promise" various aspects of a flavor. If you pass a NIL
data pointer, this is a promise that in the future you
will provide data for this flavor. Provide the data
through a subsequent call to PutScrapFlavor, either later
in the same code flow or during a scrap promise keeper proc.
If you know how big the data is, you can pass the size as
well, and this may allow subsequent callers of GetScrapFlavorInfo
to avoid blocking. If you don't know the size, pass -1.
If you pass a 0 size, you are telling Scrap Manager not to
expect any data for this flavor. In this case, the flavor
data pointer is ignored. NOTE: the last time you can provide
scrap flavor data is when your scrap promise keeper gets
called. It is NOT possible to call PutScrapFlavor while
handling a suspend event; suspend events under Carbon
simply don't work the way they do under Mac OS 8.
The method for setting Scrap Manager promises differs from that for Drag Manger promises.
This chart describes the method for setting scrap promises via PutScrapFlavor().
dataPtr dataSize result
pointer value actual data size The data of size dataSize pointed to by dataPtr is added to the scrap.
0 actual data size A promise for data of size dataSize is placed on the scrap.
0 -1 A promise for data of an undetermined size is placed on the scrap.
ignored 0 A flavor with no data expected is placed on the scrap. This is not a promise.
*/
/*
* PutScrapFlavor() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardPutItemFlavor
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
PutScrapFlavor(
ScrapRef scrap,
ScrapFlavorType flavorType,
ScrapFlavorFlags flavorFlags,
Size flavorSize,
const void * flavorData) /* can be NULL */ AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
ScrapPromiseKeeper is a function you write which is called by
Scrap Manager as needed to keep your earlier promise of a
particular scrap flavor. When your function is called, deliver
the requested data by calling PutScrapFlavor.
*/
#endif /* !__LP64__ */
typedef CALLBACK_API( OSStatus , ScrapPromiseKeeperProcPtr )(ScrapRef scrap, ScrapFlavorType flavorType, void *userData);
typedef STACK_UPP_TYPE(ScrapPromiseKeeperProcPtr) ScrapPromiseKeeperUPP;
/*
* NewScrapPromiseKeeperUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern ScrapPromiseKeeperUPP
NewScrapPromiseKeeperUPP(ScrapPromiseKeeperProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* DisposeScrapPromiseKeeperUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeScrapPromiseKeeperUPP(ScrapPromiseKeeperUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
* InvokeScrapPromiseKeeperUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern OSStatus
InvokeScrapPromiseKeeperUPP(
ScrapRef scrap,
ScrapFlavorType flavorType,
void * userData,
ScrapPromiseKeeperUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
#if __MACH__
#ifdef __cplusplus
inline ScrapPromiseKeeperUPP NewScrapPromiseKeeperUPP(ScrapPromiseKeeperProcPtr userRoutine) { return userRoutine; }
inline void DisposeScrapPromiseKeeperUPP(ScrapPromiseKeeperUPP) { }
inline OSStatus InvokeScrapPromiseKeeperUPP(ScrapRef scrap, ScrapFlavorType flavorType, void * userData, ScrapPromiseKeeperUPP userUPP) { return (*userUPP)(scrap, flavorType, userData); }
#else
#define NewScrapPromiseKeeperUPP(userRoutine) ((ScrapPromiseKeeperUPP)userRoutine)
#define DisposeScrapPromiseKeeperUPP(userUPP)
#define InvokeScrapPromiseKeeperUPP(scrap, flavorType, userData, userUPP) (*userUPP)(scrap, flavorType, userData)
#endif
#endif
/*
SetScrapPromiseKeeper associates a ScrapPromiseKeeper with a
scrap. You can remove a ScrapPromiseKeeper from a scrap by
passing a NIL ScrapPromiseKeeper to SetScrapPromiseKeeper.
Pass whatever you like in the last parameter; its value will
be passed to your ScrapPromiseKeeper, which can do whatever
it likes with the value. You might choose to pass a pointer
or handle to some private scrap data which the
ScrapPromiseKeeper could use in fabricating one or more
promised flavors.
*/
#if !__LP64__
/*
* SetScrapPromiseKeeper() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardSetPromiseKeeper
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
SetScrapPromiseKeeper(
ScrapRef scrap,
ScrapPromiseKeeperUPP upp,
const void * userData) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
GetScrapFlavorCount produces the number of
items which can be obtained by GetScrapFlavorInfoList.
*/
/*
* GetScrapFlavorCount() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardCopyItemFlavors
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetScrapFlavorCount(
ScrapRef scrap,
UInt32 * infoCount) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
GetScrapFlavorInfoList fills a list (array)
of items which each describe the corresponding
flavor in the scrap. It fills no more array
elements as are specified. On exit, it produces
the count of elements it filled (which may be
smaller than the count requested). Yes, YOU
must provide the memory for the array.
*/
/*
* GetScrapFlavorInfoList() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardCopyItemFlavors
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
GetScrapFlavorInfoList(
ScrapRef scrap,
UInt32 * infoCount,
ScrapFlavorInfo info[]) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
/*
CallInScrapPromises forces all promises to be kept.
If your application promises at least one flavor
AND it does NOT adopt the new event model, you
should call this function when your application
is about to quit. If your app promises no flavors,
there is no need to call this function, and if
your app adopts the new event model, this function
will be called automagically for you. It doesn't
hurt to call this function more than once, though
promise keepers may be asked to keep promises
they already tried and failed.
*/
/*
* CallInScrapPromises() *** DEPRECATED ***
*
* Deprecated:
* The Scrap Manager is deprecated. Use PasteboardResolvePromises
* instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.5
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
CallInScrapPromises(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5;
#endif /* !__LP64__ */
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __SCRAP__ */

View File

@@ -0,0 +1,278 @@
/*
File: HIToolbox/TSMTE.h
Contains: Text Services Manager for TextEdit Interfaces. All TextEdit functions as well all functions in
Copyright: <20> 1991-2008 by Apple Computer, Inc., all rights reserved
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
/*****************************************************************************************************************
All Textedit functions as well all functions in this file are deprecated for Mac OS 10.4. The Multilingual Text
Engine (MLTE) API is recommended instead. MLTE support for inline input is built-in so there is no need for an
API parallel to TSMTE on Mac OS X. Please see MacTextEditor.h file for a description of the MLTE API.
******************************************************************************************************************/
#ifndef __TSMTE__
#define __TSMTE__
#ifndef __TEXTEDIT__
#include <HIToolbox/TextEdit.h>
#endif
#ifndef __DIALOGS__
#include <HIToolbox/Dialogs.h>
#endif
#ifndef __TEXTSERVICES__
#include <HIToolbox/TextServices.h>
#endif
#include <ApplicationServices/ApplicationServices.h>
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/* signature, interface types*/
enum {
kTSMTESignature = 'tmTE',
kTSMTEInterfaceType = kTSMTEDocumentInterfaceType
};
/*
In Carbon, since DialogRef is opaque, the TSMDialogRecord is removed.
Only one kind of TSMTE dialog remains, with extended data managed by TSMTE.
Use kTSMTESignature for the dialog refCon, and use the accessors below,
i.e. GetTSMTEDialogTSMTERecHandle, to get at the old TSMDialogRecord info.
*/
#if CALL_NOT_IN_CARBON
enum {
kTSMTEDialog = 'tmDI'
};
#endif /* CALL_NOT_IN_CARBON */
/* update flag for TSMTERec*/
enum {
kTSMTEAutoScroll = 1
};
/* callback procedure definitions*/
typedef CALLBACK_API( void , TSMTEPreUpdateProcPtr )(TEHandle textH, long refCon);
typedef CALLBACK_API( void , TSMTEPostUpdateProcPtr )(TEHandle textH, long fixLen, long inputAreaStart, long inputAreaEnd, long pinStart, long pinEnd, long refCon);
typedef STACK_UPP_TYPE(TSMTEPreUpdateProcPtr) TSMTEPreUpdateUPP;
typedef STACK_UPP_TYPE(TSMTEPostUpdateProcPtr) TSMTEPostUpdateUPP;
/* data types*/
struct TSMTERec {
TEHandle textH;
TSMTEPreUpdateUPP preUpdateProc;
TSMTEPostUpdateUPP postUpdateProc;
long updateFlag;
long refCon;
};
typedef struct TSMTERec TSMTERec;
typedef TSMTERec * TSMTERecPtr;
typedef TSMTERecPtr * TSMTERecHandle;
/*
* NewTSMTEPreUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern TSMTEPreUpdateUPP
NewTSMTEPreUpdateUPP(TSMTEPreUpdateProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* NewTSMTEPostUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern TSMTEPostUpdateUPP
NewTSMTEPostUpdateUPP(TSMTEPostUpdateProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* DisposeTSMTEPreUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeTSMTEPreUpdateUPP(TSMTEPreUpdateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* DisposeTSMTEPostUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeTSMTEPostUpdateUPP(TSMTEPostUpdateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* InvokeTSMTEPreUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeTSMTEPreUpdateUPP(
TEHandle textH,
long refCon,
TSMTEPreUpdateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* InvokeTSMTEPostUpdateUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
InvokeTSMTEPostUpdateUPP(
TEHandle textH,
long fixLen,
long inputAreaStart,
long inputAreaEnd,
long pinStart,
long pinEnd,
long refCon,
TSMTEPostUpdateUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
#if __MACH__
#ifdef __cplusplus
inline TSMTEPreUpdateUPP NewTSMTEPreUpdateUPP(TSMTEPreUpdateProcPtr userRoutine) { return userRoutine; }
inline TSMTEPostUpdateUPP NewTSMTEPostUpdateUPP(TSMTEPostUpdateProcPtr userRoutine) { return userRoutine; }
inline void DisposeTSMTEPreUpdateUPP(TSMTEPreUpdateUPP) { }
inline void DisposeTSMTEPostUpdateUPP(TSMTEPostUpdateUPP) { }
inline void InvokeTSMTEPreUpdateUPP(TEHandle textH, long refCon, TSMTEPreUpdateUPP userUPP) { (*userUPP)(textH, refCon); }
inline void InvokeTSMTEPostUpdateUPP(TEHandle textH, long fixLen, long inputAreaStart, long inputAreaEnd, long pinStart, long pinEnd, long refCon, TSMTEPostUpdateUPP userUPP) { (*userUPP)(textH, fixLen, inputAreaStart, inputAreaEnd, pinStart, pinEnd, refCon); }
#else
#define NewTSMTEPreUpdateUPP(userRoutine) ((TSMTEPreUpdateUPP)userRoutine)
#define NewTSMTEPostUpdateUPP(userRoutine) ((TSMTEPostUpdateUPP)userRoutine)
#define DisposeTSMTEPreUpdateUPP(userUPP)
#define DisposeTSMTEPostUpdateUPP(userUPP)
#define InvokeTSMTEPreUpdateUPP(textH, refCon, userUPP) (*userUPP)(textH, refCon)
#define InvokeTSMTEPostUpdateUPP(textH, fixLen, inputAreaStart, inputAreaEnd, pinStart, pinEnd, refCon, userUPP) (*userUPP)(textH, fixLen, inputAreaStart, inputAreaEnd, pinStart, pinEnd, refCon)
#endif
#endif
#if !__LP64__
/*
* IsTSMTEDialog() *** DEPRECATED ***
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0.2 and later
* Non-Carbon CFM: in CarbonAccessors.o 1.0.2 and later
*/
extern Boolean
IsTSMTEDialog(DialogRef dialog) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/* Getters */
/*
* GetTSMTEDialogDocumentID() *** DEPRECATED ***
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0.2 and later
* Non-Carbon CFM: in CarbonAccessors.o 1.0.2 and later
*/
extern TSMDocumentID
GetTSMTEDialogDocumentID(DialogRef dialog) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* GetTSMTEDialogTSMTERecHandle() *** DEPRECATED ***
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0.2 and later
* Non-Carbon CFM: in CarbonAccessors.o 1.0.2 and later
*/
extern TSMTERecHandle
GetTSMTEDialogTSMTERecHandle(DialogRef dialog) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/* Setters */
/*
* SetTSMTEDialogDocumentID() *** DEPRECATED ***
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0.2 and later
* Non-Carbon CFM: in CarbonAccessors.o 1.0.2 and later
*/
extern void
SetTSMTEDialogDocumentID(
DialogRef dialog,
TSMDocumentID documentID) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* SetTSMTEDialogTSMTERecHandle() *** DEPRECATED ***
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0.2 and later
* Non-Carbon CFM: in CarbonAccessors.o 1.0.2 and later
*/
extern void
SetTSMTEDialogTSMTERecHandle(
DialogRef dialog,
TSMTERecHandle tsmteRecHandle) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
#endif /* !__LP64__ */
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __TSMTE__ */

View File

@@ -0,0 +1,347 @@
/*
File: HIToolbox/Translation.h
Contains: Translation Manager (Macintosh Easy Open) Interfaces.
Copyright: <20> 1991-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __TRANSLATION__
#define __TRANSLATION__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#ifndef __TRANSLATIONEXTENSIONS__
#include <HIToolbox/TranslationExtensions.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*
Carbon clients should use Translation Services. The definitions below will NOT work for Carbon and
are only defined for those files that need to build pre-Carbon applications.
*/
/* enumerated types on how a document can be opened*/
typedef short DocOpenMethod;
enum {
domCannot = 0,
domNative = 1,
domTranslateFirst = 2,
domWildcard = 3
};
/* 0L terminated array of OSTypes, or FileTypes*/
typedef OSType TypesBlock[64];
typedef OSType * TypesBlockPtr;
/* Progress dialog resource ID*/
enum {
kTranslationScrapProgressDialogID = -16555
};
/* block of data that describes how to translate*/
struct FileTranslationSpec {
OSType componentSignature;
const void * translationSystemInfo;
FileTypeSpec src;
FileTypeSpec dst;
};
typedef struct FileTranslationSpec FileTranslationSpec;
typedef FileTranslationSpec * FileTranslationSpecArrayPtr;
typedef FileTranslationSpecArrayPtr * FileTranslationSpecArrayHandle;
#if !__LP64__
/*
* GetFileTypesThatAppCanNativelyOpen() *** DEPRECATED ***
*
* Deprecated:
* There is no direct replacement at this time.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
GetFileTypesThatAppCanNativelyOpen(
short appVRefNumHint,
OSType appSignature,
FileType * nativeTypes) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* ExtendFileTypeList() *** DEPRECATED ***
*
* Deprecated:
* Use TranslationCreateWithSourceArray instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
ExtendFileTypeList(
const FileType * originalTypeList,
short numberOriginalTypes,
FileType * extendedTypeList,
short * numberExtendedTypes) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* CanDocBeOpened() *** DEPRECATED ***
*
* Deprecated:
* Use the Launch Services API instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
CanDocBeOpened(
const FSSpec * targetDocument,
short appVRefNumHint,
OSType appSignature,
const FileType * nativeTypes,
Boolean onlyNative,
DocOpenMethod * howToOpen,
FileTranslationSpec * howToTranslate) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* GetFileTranslationPaths() *** DEPRECATED ***
*
* Deprecated:
* Use TranslationCreateWithSourceArray instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern short
GetFileTranslationPaths(
const FSSpec * srcDocument,
FileType dstDocType,
unsigned short maxResultCount,
FileTranslationSpecArrayPtr resultBuffer) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* GetPathFromTranslationDialog() *** DEPRECATED ***
*
* Deprecated:
* There is no direct replacement at this time, but all the
* necessary information can be obtained from the Launch Services,
* Translation Services and Uniform Type Identification APIs.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
GetPathFromTranslationDialog(
const FSSpec * theDocument,
const FSSpec * theApplication,
TypesBlockPtr typeList,
DocOpenMethod * howToOpen,
FileTranslationSpec * howToTranslate) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* TranslateFile() *** DEPRECATED ***
*
* Deprecated:
* Use TranslationPerformForFile or TranslationPerformForURL instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
TranslateFile(
const FSSpec * sourceDocument,
const FSSpec * destinationDocument,
const FileTranslationSpec * howToTranslate) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* GetDocumentKindString() *** DEPRECATED ***
*
* Deprecated:
* Use the Launch Services API instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
GetDocumentKindString(
short docVRefNum,
OSType docType,
OSType docCreator,
Str63 kindString) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* GetTranslationExtensionName() *** DEPRECATED ***
*
* Deprecated:
* There is no direct replacement at this time, but
* TranslationCopySourceType and TranslationCopyDestinationType in
* conjunction with UTTypeCopyDescription will provide useful user
* level information.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
GetTranslationExtensionName(
const FileTranslationSpec * translationMethod,
Str31 extensionName) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
#endif /* !__LP64__ */
/*
* GetScrapDataProcPtr
*/
typedef CALLBACK_API( OSErr , GetScrapDataProcPtr )(ScrapType requestedFormat, Handle dataH, void *srcDataGetterRefCon);
typedef STACK_UPP_TYPE(GetScrapDataProcPtr) GetScrapDataUPP;
/*
* NewGetScrapDataUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern GetScrapDataUPP
NewGetScrapDataUPP(GetScrapDataProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* DisposeGetScrapDataUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeGetScrapDataUPP(GetScrapDataUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*
* InvokeGetScrapDataUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern OSErr
InvokeGetScrapDataUPP(
ScrapType requestedFormat,
Handle dataH,
void * srcDataGetterRefCon,
GetScrapDataUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
#if __MACH__
#ifdef __cplusplus
inline GetScrapDataUPP NewGetScrapDataUPP(GetScrapDataProcPtr userRoutine) { return userRoutine; }
inline void DisposeGetScrapDataUPP(GetScrapDataUPP) { }
inline OSErr InvokeGetScrapDataUPP(ScrapType requestedFormat, Handle dataH, void * srcDataGetterRefCon, GetScrapDataUPP userUPP) { return (*userUPP)(requestedFormat, dataH, srcDataGetterRefCon); }
#else
#define NewGetScrapDataUPP(userRoutine) ((GetScrapDataUPP)userRoutine)
#define DisposeGetScrapDataUPP(userUPP)
#define InvokeGetScrapDataUPP(requestedFormat, dataH, srcDataGetterRefCon, userUPP) (*userUPP)(requestedFormat, dataH, srcDataGetterRefCon)
#endif
#endif
typedef GetScrapDataUPP GetScrapData;
#if !__LP64__
/*
* TranslateScrap() *** DEPRECATED ***
*
* Deprecated:
* Use TranslationPerformForData instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
TranslateScrap(
GetScrapDataUPP sourceDataGetter,
void * sourceDataGetterRefCon,
ScrapType destinationFormat,
Handle destinationData,
short progressDialogID) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
#endif /* !__LP64__ */
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __TRANSLATION__ */

View File

@@ -0,0 +1,220 @@
/*
File: HIToolbox/TranslationExtensions.h
Contains: Macintosh Easy Open Translation Extension Interfaces.
Copyright: <20> 1993-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __TRANSLATIONEXTENSIONS__
#define __TRANSLATIONEXTENSIONS__
#ifndef __APPLICATIONSERVICES__
#include <ApplicationServices/ApplicationServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*
Translation Extensions are no longer supported. Carbon clients interested in extending translations
should use filter services as described in TranslationServices.h. The definitions below will NOT work
for Carbon and are only defined for those files that need to build pre-Carbon applications.
*/
enum {
kSupportsFileTranslation = 1,
kSupportsScrapTranslation = 2,
kTranslatorCanGenerateFilename = 4
};
/******************************************************************************************/
/* better names for 4-char codes*/
typedef OSType FileType;
typedef ResType ScrapType;
/******************************************************************************************/
typedef UInt32 TranslationAttributes;
enum {
taDstDocNeedsResourceFork = 1,
taDstIsAppTranslation = 2
};
/******************************************************************************************/
struct FileTypeSpec {
FileType format;
long hint;
TranslationAttributes flags; /* taDstDocNeedsResourceFork, taDstIsAppTranslation*/
OSType catInfoType;
OSType catInfoCreator;
};
typedef struct FileTypeSpec FileTypeSpec;
struct FileTranslationList {
unsigned long modDate;
unsigned long groupCount;
/* conceptual declarations:*/
/* unsigned long group1SrcCount;*/
/* unsigned long group1SrcEntrySize = sizeof(FileTypeSpec);*/
/* FileTypeSpec group1SrcTypes[group1SrcCount]*/
/* unsigned long group1DstCount;*/
/* unsigned long group1DstEntrySize = sizeof(FileTypeSpec);*/
/* FileTypeSpec group1DstTypes[group1DstCount]*/
};
typedef struct FileTranslationList FileTranslationList;
typedef FileTranslationList * FileTranslationListPtr;
typedef FileTranslationListPtr * FileTranslationListHandle;
/******************************************************************************************/
struct ScrapTypeSpec {
ScrapType format;
long hint;
};
typedef struct ScrapTypeSpec ScrapTypeSpec;
struct ScrapTranslationList {
unsigned long modDate;
unsigned long groupCount;
/* conceptual declarations:*/
/* unsigned long group1SrcCount;*/
/* unsigned long group1SrcEntrySize = sizeof(ScrapTypeSpec);*/
/* ScrapTypeSpec group1SrcTypes[group1SrcCount]*/
/* unsigned long group1DstCount;*/
/* unsigned long group1DstEntrySize = sizeof(ScrapTypeSpec);*/
/* ScrapTypeSpec group1DstTypes[group1DstCount]*/
};
typedef struct ScrapTranslationList ScrapTranslationList;
typedef ScrapTranslationList * ScrapTranslationListPtr;
typedef ScrapTranslationListPtr * ScrapTranslationListHandle;
/*******************************************************************************************
definition of callbacks to update progress dialog
*******************************************************************************************/
typedef long TranslationRefNum;
/*******************************************************************************************
This routine sets the advertisement in the top half of the progress dialog.
It is called once at the beginning of your DoTranslateFile routine.
Enter : refNum Translation reference supplied to DoTranslateFile.
advertisement A handle to the picture to display. This must be non-purgable.
Before returning from DoTranslateFile, you should dispose
of the memory. (Normally, it is in the temp translation heap
so it is cleaned up for you.)
Exit : returns noErr, paramErr, or memFullErr
*******************************************************************************************/
#if !__LP64__
/*
* SetTranslationAdvertisement() *** DEPRECATED ***
*
* Deprecated:
* There is no direct replacement at this time.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 thru 1.0.2
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
SetTranslationAdvertisement(
TranslationRefNum refNum,
PicHandle advertisement) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*******************************************************************************************
This routine updates the progress bar in the progress dialog.
It is called repeatedly from within your DoTranslateFile routine.
It should be called often, so that the user will get feedback if
he tries to cancel.
Enter : refNum translation reference supplied to DoTranslateFile.
progress percent complete (0-100)
Exit : canceled TRUE if the user clicked the Cancel button, FALSE otherwise
Return : noErr, paramErr, or memFullErr
*******************************************************************************************/
/*
* UpdateTranslationProgress() *** DEPRECATED ***
*
* Deprecated:
* There is no direct replacement at this time.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.3
* CarbonLib: in CarbonLib 1.0 thru 1.0.2
* Non-Carbon CFM: in Translation 1.0 and later
*/
extern OSErr
UpdateTranslationProgress(
TranslationRefNum refNum,
short percentDone,
Boolean * canceled) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
/*******************************************************************************************
Component Manager component selectors for translation extension routines
*******************************************************************************************/
#endif /* !__LP64__ */
enum {
kTranslateGetFileTranslationList = 0,
kTranslateIdentifyFile = 1,
kTranslateTranslateFile = 2,
kTranslateGetTranslatedFilename = 3,
kTranslateGetScrapTranslationList = 10,
kTranslateIdentifyScrap = 11,
kTranslateTranslateScrap = 12,
kTranslateGetScrapTranslationListConsideringData = 13
};
/*******************************************************************************************
routines which implement translation extensions
*******************************************************************************************/
typedef CALLBACK_API( ComponentResult , DoGetFileTranslationListProcPtr )(ComponentInstance self, FileTranslationListHandle translationList);
typedef CALLBACK_API( ComponentResult , DoIdentifyFileProcPtr )(ComponentInstance self, const FSSpec *theDocument, FileType *docType);
typedef CALLBACK_API( ComponentResult , DoTranslateFileProcPtr )(ComponentInstance self, TranslationRefNum refNum, const FSSpec *sourceDocument, FileType srcType, long srcTypeHint, const FSSpec *dstDoc, FileType dstType, long dstTypeHint);
typedef CALLBACK_API( ComponentResult , DoGetTranslatedFilenameProcPtr )(ComponentInstance self, FileType dstType, long dstTypeHint, FSSpec *theDocument);
typedef CALLBACK_API( ComponentResult , DoGetScrapTranslationListProcPtr )(ComponentInstance self, ScrapTranslationListHandle list);
typedef CALLBACK_API( ComponentResult , DoIdentifyScrapProcPtr )(ComponentInstance self, const void *dataPtr, Size dataLength, ScrapType *dataFormat);
typedef CALLBACK_API( ComponentResult , DoTranslateScrapProcPtr )(ComponentInstance self, TranslationRefNum refNum, const void *srcDataPtr, Size srcDataLength, ScrapType srcType, long srcTypeHint, Handle dstData, ScrapType dstType, long dstTypeHint);
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __TRANSLATIONEXTENSIONS__ */

View File

@@ -0,0 +1,28 @@
/*
File: TranslationExtensions.r
Contains: Macintosh Easy Open Translation Extension Interfaces.
Copyright: <20> 1993-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __TRANSLATIONEXTENSIONS_R__
#define __TRANSLATIONEXTENSIONS_R__
#ifndef __CORESERVICES_R__
#include <CoreServices/CoreServices.r>
#endif
#define kSupportsFileTranslation 1
#define kSupportsScrapTranslation 2
#define kTranslatorCanGenerateFilename 4
#endif /* __TRANSLATIONEXTENSIONS_R__ */

View File

@@ -0,0 +1,223 @@
/*
File: HIToolbox/TypeSelect.h
Contains: TypeSelect Utilties
Copyright: <20> 2000-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __TYPESELECT__
#define __TYPESELECT__
#ifndef __EVENTS__
#include <HIToolbox/Events.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
#pragma pack(push, 2)
/*
* TypeSelect
*
* Discussion:
* The TypeSelection API is deprecated in Mac OS X 10.4 and later,
* and is not included in the 64-bit version of HIToolbox.
* Applications should use the UCTypeSelect API in
* UnicodeUtilities.h.
*/
typedef SInt16 TSCode;
enum {
tsPreviousSelectMode = -1,
tsNormalSelectMode = 0,
tsNextSelectMode = 1
};
struct TypeSelectRecord {
UInt32 tsrLastKeyTime;
ScriptCode tsrScript;
Str63 tsrKeyStrokes;
};
typedef struct TypeSelectRecord TypeSelectRecord;
#if !__LP64__
typedef CALLBACK_API( Boolean , IndexToStringProcPtr )(short item, ScriptCode *itemsScript, StringPtr *itemsStringPtr, void *yourDataPtr);
typedef STACK_UPP_TYPE(IndexToStringProcPtr) IndexToStringUPP;
/*
* NewIndexToStringUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern IndexToStringUPP
NewIndexToStringUPP(IndexToStringProcPtr userRoutine) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* DisposeIndexToStringUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern void
DisposeIndexToStringUPP(IndexToStringUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* InvokeIndexToStringUPP()
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: available as macro/inline
*/
extern Boolean
InvokeIndexToStringUPP(
short item,
ScriptCode * itemsScript,
StringPtr * itemsStringPtr,
void * yourDataPtr,
IndexToStringUPP userUPP) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
#if __MACH__
#ifdef __cplusplus
inline IndexToStringUPP NewIndexToStringUPP(IndexToStringProcPtr userRoutine) { return userRoutine; }
inline void DisposeIndexToStringUPP(IndexToStringUPP) { }
inline Boolean InvokeIndexToStringUPP(short item, ScriptCode * itemsScript, StringPtr * itemsStringPtr, void * yourDataPtr, IndexToStringUPP userUPP) { return (*userUPP)(item, itemsScript, itemsStringPtr, yourDataPtr); }
#else
#define NewIndexToStringUPP(userRoutine) ((IndexToStringUPP)userRoutine)
#define DisposeIndexToStringUPP(userUPP)
#define InvokeIndexToStringUPP(item, itemsScript, itemsStringPtr, yourDataPtr, userUPP) (*userUPP)(item, itemsScript, itemsStringPtr, yourDataPtr)
#endif
#endif
#endif /* !__LP64__ */
#if !__LP64__
/*
* TypeSelectClear() *** DEPRECATED ***
*
* Deprecated:
* Use UCTypeSelectFlushSelectorData instead.
*
* Discussion:
* This function is no longer recommended. Please use
* UCTypeSelectFlushSelectorData instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern void
TypeSelectClear(TypeSelectRecord * tsr) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* TypeSelectNewKey() *** DEPRECATED ***
*
* Deprecated:
* Use UCTypeSelectAddKeyToSelector instead.
*
* Discussion:
* This function is no longer recommended. Please use
* UCTypeSelectAddKeyToSelector instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern Boolean
TypeSelectNewKey(
const EventRecord * theEvent,
TypeSelectRecord * tsr) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* TypeSelectFindItem() *** DEPRECATED ***
*
* Deprecated:
* Use UCTypeSelectFindItem instead.
*
* Discussion:
* This function is no longer recommended. Please use
* UCTypeSelectFindItem instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern short
TypeSelectFindItem(
const TypeSelectRecord * tsr,
short listSize,
TSCode selectMode,
IndexToStringUPP getStringProc,
void * yourDataPtr) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* TypeSelectCompare() *** DEPRECATED ***
*
* Deprecated:
* Use UCTypeSelectCompare instead.
*
* Discussion:
* This function is no longer recommended. Please use
* UCTypeSelectCompare instead.
*
* Mac OS X threading:
* Not thread safe
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework [32-bit only] but deprecated in 10.4
* CarbonLib: in CarbonLib 1.0 and later
* Non-Carbon CFM: not available
*/
extern short
TypeSelectCompare(
const TypeSelectRecord * tsr,
ScriptCode testStringScript,
StringPtr testStringPtr) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
#endif /* !__LP64__ */
#pragma pack(pop)
#ifdef __cplusplus
}
#endif
#endif /* __TYPESELECT__ */

View File

@@ -0,0 +1,230 @@
/*
File: Help/AppleHelp.h
Contains: Apple Help
Version: Help-36~232
Copyright: <20> 2000-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __APPLEHELP__
#define __APPLEHELP__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#include <AvailabilityMacros.h>
#if PRAGMA_ONCE
#pragma once
#endif
#ifdef __cplusplus
extern "C" {
#endif
/* AppleHelp Error Codes */
enum {
kAHInternalErr = -10790,
kAHInternetConfigPrefErr = -10791
};
typedef SInt16 AHTOCType;
enum {
kAHTOCTypeUser = 0,
kAHTOCTypeDeveloper = 1
};
/*
* AHSearch()
*
* Discussion:
* Delivers a request to perform the specified search to the Help
* Viewer application.
*
* Parameters:
*
* bookname:
* Optionally, the AppleTitle of the Help book to be searched. If
* NULL, all installed Help books are searched.
*
* query:
* The query to be made. This string can, if desired, have boolean
* operators or be a natural language phrase.
*
* Result:
* An operating system result code that indicates whether the
* request was successfully sent to the Help Viewer application.
* Possible values: noErr, paramErr, kAHInternalErr.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
AHSearch(
CFStringRef bookname,
CFStringRef query) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AHGotoMainTOC() *** DEPRECATED ***
*
* Discussion:
* Delivers a request to load the main table of contents of
* installed help books to the Help Viewer application. This method
* has been deprecated in Mac OS X 10.4. Instead, please use
* AHGotoPage to jump directly to different books or anchors.
*
* Parameters:
*
* toctype:
* The type of table of contents to be loaded: user or developer.
*
* Result:
* An operating system result code that indicates whether the
* request was successfully sent to the Help Viewer application.
* Possible values: noErr, paramErr, kAHInternalErr.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework but deprecated in 10.4
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
AHGotoMainTOC(AHTOCType toctype) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
/*
* AHGotoPage()
*
* Discussion:
* Delivers a request to load a specific text/html file to the Help
* Viewer application.
*
* Parameters:
*
* bookname:
* Optionally, the AppleTitle of an installed Help book. If NULL,
* the path parameter must be a full file: URL to the file to be
* opened.
*
* path:
* Optionally, one of two types of paths: 1) a URL-style path to a
* file that is relative to the main folder of the book supplied
* in the bookname parameter, or 2) if bookname is NULL, a full
* file: URL to the file to be opened. If this parameter is NULL,
* then bookname must not be NULL, and is used to open the Help
* Viewer to the main page of Help content for the specified book.
*
* anchor:
* Optionally, the name of anchor tag to scroll to in the newly
* opened file. Can be NULL.
*
* Result:
* An operating system result code that indicates whether the
* request was successfully sent to the Help Viewer application.
* Possible values: noErr, paramErr, kAHInternalErr.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
AHGotoPage(
CFStringRef bookname,
CFStringRef path,
CFStringRef anchor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AHLookupAnchor()
*
* Discussion:
* Delivers a request to perform an anchor lookup to the Help Viewer
* application. Note: anchor lookups will fail unless you have
* indexed your help content with anchor indexing turned on in the
* indexing tool's preferences panel.
*
* Parameters:
*
* bookname:
* Optionally, the AppleTitle of the Help book to searched. If
* NULL, the anchor lookup is performed using all installed Help
* books.
*
* anchor:
* The name of the anchor tag to look up.
*
* Result:
* An operating system result code that indicates whether the
* request was successfully sent to the Help Viewer application.
* Possible values: noErr, paramErr, kAHInternalErr.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
AHLookupAnchor(
CFStringRef bookname,
CFStringRef anchor) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
/*
* AHRegisterHelpBook()
*
* Discussion:
* Registers a book of Help content such that the book will appear
* in the current user's main table of contents (Help Center) in the
* Help Viewer application. To be used when help books reside
* outside of the known help folders (i.e. help books that are kept
* inside of application bundles).
*
* Parameters:
*
* appBundleRef:
* An FSRef pointer to the bundle within which one or more Help
* books is stored. This is likely an FSRef to your application's
* main bundle.
*
* Result:
* An operating system result code that indicates whether all help
* books contained within the specified bundle were registered.
* Possible values: noErr, paramErr, kAHInternalErr, dirNFErr.
*
* Availability:
* Mac OS X: in version 10.0 and later in Carbon.framework
* CarbonLib: in CarbonLib 1.1 and later
* Non-Carbon CFM: not available
*/
extern OSStatus
AHRegisterHelpBook(const FSRef * appBundleRef) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4;
extern OSStatus
AHRegisterHelpBookWithURL(const CFURLRef applicationURL) AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER;
#ifdef __cplusplus
}
#endif
#endif /* __APPLEHELP__ */

View File

@@ -0,0 +1,30 @@
/*
File: Help/Help.h
Contains: Master include for Help private framework
Version: Help-36~232
Copyright: <20> 1999-2008 by Apple Computer, Inc., all rights reserved.
Bugs?: For bug reports, consult the following page on
the World Wide Web:
http://developer.apple.com/bugreporter/
*/
#ifndef __HELP__
#define __HELP__
#ifndef __CORESERVICES__
#include <CoreServices/CoreServices.h>
#endif
#ifndef __APPLEHELP__
#include <Help/AppleHelp.h>
#endif
#endif /* __HELP__ */

View File

@@ -0,0 +1,28 @@
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: EE5FA0C7-753F-3232-8D72-F9E834BF16C0
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 3C094BDD-B284-36F4-917D-F3DFB2CD4319
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Help.framework/Versions/A/Help'
current-version: 71
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
allowable-clients:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
clients: [ PrintingUI ]
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _AHGotoApplicationHelp, _AHGotoMainTOC, _AHGotoPage, _AHLookupAnchor,
_AHRegisterHelpBook, _AHRegisterHelpBookWithURL, _AHSearch,
_AppendEncodingHint, _CFStringToCString, _CopyBookDetails,
_CreateBookDetailsFromAppBundle, _CreateBookDetailsFromAppBundleAtIndex,
_CreateBookDetailsWithBookNameAndID, _EscapeMacCharacters,
_MacPathToURLPath, _kANCHOR, _kBOOKID, _kDEFAULT_BUNDLE_ID,
_kFILE, _kOPENBOOK, _kSEARCH, _kSEARCHALL, _kSTRING ]
...

View File

@@ -0,0 +1,11 @@
/*
* ImageCapture/ImageCapture.h
*
* Copyright (c) 2004 Apple Computer, Inc., all rights reserved.
*
*/
#ifndef __IMAGECAPTURE__
#define __IMAGECAPTURE__
#endif

View File

@@ -0,0 +1,121 @@
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: 4FFADD43-2EC1-3A67-8C43-5E7EB7D73554
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 963345BE-8865-34F5-9500-6752AF50A1B3
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/ImageCapture.framework/Versions/A/ImageCapture'
current-version: 5
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _ICACloseSession, _ICAConvertJPEGDataToICADataInPlace, _ICAConvertTIFFDataToICADataInPlace,
_ICACopyMatchingDeviceDictionaries, _ICACopyObjectData, _ICACopyObjectPropertyDictionary,
_ICACopyObjectThumbnail, _ICACopyParameterBlockPtrForAsyncCall,
_ICACreateCutsomIconForImageAtPath, _ICACreateJPEGThumbnailDataFromURL,
_ICADictionaryApplierFunction, _ICADoMacho2CFMConversion,
_ICADownloadFile, _ICADownloadFileWithOptions, _ICAElapsedTime,
_ICAGetBehaviorFlags, _ICAGetChildCount, _ICAGetDateFromSeconds,
_ICAGetDateFromSecondsSince1904, _ICAGetDateFromSecondsSince1970,
_ICAGetDeviceList, _ICAGetEXIFDateCStringFromSecondsSince1904,
_ICAGetEXIFDateCStringFromSecondsSince1970, _ICAGetEXIFUTCDateCStringFromSecondsSince1904,
_ICAGetEXIFUTCDateCStringFromSecondsSince1970, _ICAGetICAObjectForFile,
_ICAGetICAObjectFromDict, _ICAGetLongValueFromDict, _ICAGetNthChild,
_ICAGetNthProperty, _ICAGetObjectInfo, _ICAGetObjectRefCon,
_ICAGetParentOfObject, _ICAGetParentOfProperty, _ICAGetPropertyByType,
_ICAGetPropertyCount, _ICAGetPropertyData, _ICAGetPropertyInfo,
_ICAGetPropertyRefCon, _ICAGetRootOfObject, _ICAGetRootOfProperty,
_ICAGetSInt16ValueFromDict, _ICAGetSInt32ValueFromDict, _ICAGetSInt64ValueFromDict,
_ICAGetUTCDateFromDateCString, _ICAGetUTCDateFromSeconds,
_ICAGetUTCDateFromSecondsSince1904, _ICAImportImage, _ICALoadDeviceModule,
_ICAObjectSendMessage, _ICAOpenSession, _ICARegisterEventNotification,
_ICARegisterForEventNotification, _ICAScannerCloseSession,
_ICAScannerGetParameters, _ICAScannerInitialize, _ICAScannerOpenSession,
_ICAScannerSetParameters, _ICAScannerStart, _ICAScannerStatus,
_ICASetBehaviorFlags, _ICASetICAObjectInDict, _ICASetLongValueInDict,
_ICASetObjectRefCon, _ICASetPropertyData, _ICASetPropertyRefCon,
_ICASetSInt16ValueInDict, _ICASetSInt32ValueInDict, _ICASetSInt64ValueInDict,
_ICASetUTF8StringInDict, _ICASharedMemoryCreate, _ICASharedMemoryDestroy,
_ICASharedMemoryMap, _ICASharedMemoryUnmap, _ICAShowDeviceBrowser,
_ICAUnloadDeviceModule, _ICAUpdateDeviceDictionary, _ICAUploadFile,
_ICDBulkNewObject, _ICDBulkNewProperty, _ICDDeviceNotification,
_ICDDeviceRegister, _ICDDeviceUnRegister, _ICDDisposeObject,
_ICDDisposeProperty, _ICDNewObject, _ICDNewProperty, _kICAAddMetaDataToFinderCommentKey,
_kICAAdjustCreationDateKey, _kICAAudioCodecsKey, _kICABIPVersionKey,
_kICABluetoothAddressKey, _kICABluetoothTransportType, _kICABonjourServiceNameKey,
_kICABonjourServiceTypeKey, _kICABonjourTXTRecordKey, _kICACreateCustomIconKey,
_kICACreationDateStringKey, _kICADataPropertyKey, _kICADataSizeKey,
_kICADataTypeKey, _kICADeleteAfterDownloadKey, _kICADeviceBrowserDeviceRefKey,
_kICADeviceCapabilitiesKey, _kICADeviceDatabaseKey, _kICADeviceIconPathKey,
_kICADeviceModulePathKey, _kICADeviceNameKey, _kICADevicePropArtist,
_kICADevicePropBatteryLevel, _kICADevicePropBurstInterval,
_kICADevicePropBurstNumber, _kICADevicePropCaptureDelay, _kICADevicePropCompressionSetting,
_kICADevicePropContrast, _kICADevicePropCopyrightInfo, _kICADevicePropDateTime,
_kICADevicePropDigitalZoom, _kICADevicePropEffectMode, _kICADevicePropExposureBiasCompensation,
_kICADevicePropExposureIndex, _kICADevicePropExposureMeteringMode,
_kICADevicePropExposureProgramMode, _kICADevicePropExposureTime,
_kICADevicePropFNumber, _kICADevicePropFlashMode, _kICADevicePropFocalLength,
_kICADevicePropFocusDistance, _kICADevicePropFocusMeteringMode,
_kICADevicePropFocusMode, _kICADevicePropFunctionalMode, _kICADevicePropImageSize,
_kICADevicePropRGBGain, _kICADevicePropSharpness, _kICADevicePropStillCaptureMode,
_kICADevicePropTimelapseInterval, _kICADevicePropTimelapseNumber,
_kICADevicePropUndefined, _kICADevicePropUploadURL, _kICADevicePropWhiteBalance,
_kICADeviceSharedKey, _kICADeviceTypeCamera, _kICADeviceTypeKey,
_kICADeviceTypeScanner, _kICADeviceUsedKey, _kICADeviceWebSharedKey,
_kICADevicesArrayKey, _kICADirPathKey, _kICADisplayNameKey,
_kICADontEmbedColorSyncProfileKey, _kICAErrorKey, _kICAExecutableArchitectureKey,
_kICAFileCreatorKey, _kICAFileTypeKey, _kICAFileUTTypeKey,
_kICAFireWireGUIDKey, _kICAFireWireTransportType, _kICAIOServicePathKey,
_kICAIPAddressKey, _kICAIPGUIDKey, _kICAIPNameKey, _kICAIPPortKey,
_kICAIconFilePathKey, _kICAInstancesKey, _kICAKeywordsKey,
_kICALockStatusKey, _kICAManualConnectDeviceRefKey, _kICAMediaDurationInSecondsKey,
_kICAMediaFormatsKey, _kICAMediaHeightKey, _kICAMediaMaxDurationKey,
_kICAMediaSizesKey, _kICAMediaWidthKey, _kICAModelNameKey,
_kICAModificationDateStringKey, _kICANotificationClassKey,
_kICANotificationClassPTPStandard, _kICANotificationClassPTPVendor,
_kICANotificationClassProprietary, _kICANotificationDataCookieKey,
_kICANotificationDataKey, _kICANotificationDataSizeKey, _kICANotificationDeviceICAObjectKey,
_kICANotificationDeviceListICAObjectKey, _kICANotificationICAObjectKey,
_kICANotificationImageBytesPerRowKey, _kICANotificationImageDataKey,
_kICANotificationImageDataSizeKey, _kICANotificationImageHeightKey,
_kICANotificationImageKey, _kICANotificationImageNumberOfRowsKey,
_kICANotificationImageStartRowKey, _kICANotificationImageWidthKey,
_kICANotificationNumerOfImagesRemainingKey, _kICANotificationPercentDownloadedKey,
_kICANotificationRawEventKey, _kICANotificationScannerButtonTypeKey,
_kICANotificationScannerDocumentNameKey, _kICANotificationSubTypeDocumentLoaded,
_kICANotificationSubTypeDocumentNotLoaded, _kICANotificationSubTypeKey,
_kICANotificationSubTypePerformOverviewScan, _kICANotificationSubTypeWarmUpDone,
_kICANotificationSubTypeWarmUpStarted, _kICANotificationTypeCaptureComplete,
_kICANotificationTypeDeviceAdded, _kICANotificationTypeDeviceConnectionProgress,
_kICANotificationTypeDeviceInfoChanged, _kICANotificationTypeDevicePropertyChanged,
_kICANotificationTypeDeviceRemoved, _kICANotificationTypeDeviceStatusError,
_kICANotificationTypeDeviceStatusInfo, _kICANotificationTypeDeviceWasReset,
_kICANotificationTypeDownloadProgressStatus, _kICANotificationTypeKey,
_kICANotificationTypeObjectAdded, _kICANotificationTypeObjectInfoChanged,
_kICANotificationTypeObjectRemoved, _kICANotificationTypeProprietary,
_kICANotificationTypeRequestObjectTransfer, _kICANotificationTypeScanProgressStatus,
_kICANotificationTypeScannerButtonPressed, _kICANotificationTypeScannerOverviewOverlayAvailable,
_kICANotificationTypeScannerPageDone, _kICANotificationTypeScannerScanDone,
_kICANotificationTypeScannerSessionClosed, _kICANotificationTypeStoreAdded,
_kICANotificationTypeStoreFull, _kICANotificationTypeStoreInfoChanged,
_kICANotificationTypeStoreRemoved, _kICANotificationTypeTransactionCanceled,
_kICANotificationTypeUnreportedStatus, _kICANotificationVendorErrorCodeKey,
_kICAOBEXVersionKey, _kICAObjectKey, _kICAObjectNameKey, _kICAOrientationKey,
_kICAOverwriteKey, _kICAPhysicalTransportsKey, _kICAPictureFolderKey,
_kICAProtocolKey, _kICARawKey, _kICARefconKey, _kICARemoteDeviceKey,
_kICASCSITransportType, _kICASaveAsFilenameKey, _kICASavedFilenameKey,
_kICAScreenHeightKey, _kICAScreenWidthKey, _kICASoundFolderKey,
_kICAStarRatingKey, _kICASupportedFeaturesKey, _kICASupportingSoftwaresKey,
_kICATCPIPTransportType, _kICATWAINDSPathKey, _kICATWAINTransportType,
_kICATelephoneNetworksKey, _kICAThumbnailPropertyKey, _kICAThumbnailSizeKey,
_kICATransportTypeKey, _kICAUSBLocationIDKey, _kICAUSBProductIDKey,
_kICAUSBTransportType, _kICAUSBVendorIDKey, _kICAUserAssignedDeviceNameKey,
_kICAVendorNameKey, _kICAVideoCodecsKey, _kICAVideoFolderKey,
_kICAWMCVersionKey, _kMetaDataDictionaryKey ]
...

View File

@@ -0,0 +1,25 @@
--- !tapi-tbd
tbd-version: 4
targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
uuids:
- target: x86_64-macos
value: B93B6A30-0B53-3834-87E8-AB39E50B7FCE
- target: arm64-macos
value: 00000000-0000-0000-0000-000000000000
- target: arm64e-macos
value: 4FF5F789-FA55-3B93-816F-2F21BB55AA30
install-name: '/System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Ink.framework/Versions/A/Ink'
current-version: 227
parent-umbrella:
- targets: [ x86_64-macos, arm64-macos, arm64e-macos ]
umbrella: Carbon
exports:
- targets: [ x86_64-macos, arm64e-macos, arm64-macos ]
symbols: [ _InkAddStrokeToCurrentPhrase, _InkIsPhraseInProgress, _InkSetApplicationRecognitionMode,
_InkSetApplicationWritingMode, _InkSetDrawingMode, _InkSetPhraseTerminationMode,
_InkStrokeGetPointCount, _InkStrokeGetPoints, _InkStrokeGetTypeID,
_InkTerminateCurrentPhrase, _InkTextAlternatesCount, _InkTextBounds,
_InkTextCopy, _InkTextCreateCFString, _InkTextCreateFromCFData,
_InkTextDraw, _InkTextFlatten, _InkTextGetStroke, _InkTextGetStrokeCount,
_InkTextGetTypeID, _InkTextKeyModifiers, _InkUserWritingMode ]
...

Some files were not shown because too many files have changed in this diff Show More