GestaltEqu.pas 103 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369
  1. {
  2. File: CarbonCore/Gestalt.h
  3. Contains: Gestalt Interfaces.
  4. The contents of this header file are deprecated.
  5. Use sysctl(3) instead.
  6. Copyright: © 1988-2011 by Apple Inc. All rights reserved.
  7. }
  8. { Pascal Translation Updated: Jonas Maebe, <[email protected]>, October 2009 }
  9. { Pascal Translation Updated: Gale R Paeper, <[email protected]>, June 2018 }
  10. {
  11. Modified for use with Free Pascal
  12. Version 308
  13. Please report any bugs to <[email protected]>
  14. }
  15. {$ifc not defined MACOSALLINCLUDE or not MACOSALLINCLUDE}
  16. {$mode macpas}
  17. {$modeswitch cblocks}
  18. {$packenum 1}
  19. {$macro on}
  20. {$inline on}
  21. {$calling mwpascal}
  22. {$IFNDEF FPC_DOTTEDUNITS}
  23. unit GestaltEqu;
  24. {$ENDIF FPC_DOTTEDUNITS}
  25. interface
  26. {$setc UNIVERSAL_INTERFACES_VERSION := $0400}
  27. {$setc GAP_INTERFACES_VERSION := $0308}
  28. {$ifc not defined USE_CFSTR_CONSTANT_MACROS}
  29. {$setc USE_CFSTR_CONSTANT_MACROS := TRUE}
  30. {$endc}
  31. {$ifc defined CPUPOWERPC and defined CPUI386}
  32. {$error Conflicting initial definitions for CPUPOWERPC and CPUI386}
  33. {$endc}
  34. {$ifc defined FPC_BIG_ENDIAN and defined FPC_LITTLE_ENDIAN}
  35. {$error Conflicting initial definitions for FPC_BIG_ENDIAN and FPC_LITTLE_ENDIAN}
  36. {$endc}
  37. {$ifc not defined __ppc__ and defined CPUPOWERPC32}
  38. {$setc __ppc__ := 1}
  39. {$elsec}
  40. {$setc __ppc__ := 0}
  41. {$endc}
  42. {$ifc not defined __ppc64__ and defined CPUPOWERPC64}
  43. {$setc __ppc64__ := 1}
  44. {$elsec}
  45. {$setc __ppc64__ := 0}
  46. {$endc}
  47. {$ifc not defined __i386__ and defined CPUI386}
  48. {$setc __i386__ := 1}
  49. {$elsec}
  50. {$setc __i386__ := 0}
  51. {$endc}
  52. {$ifc not defined __x86_64__ and defined CPUX86_64}
  53. {$setc __x86_64__ := 1}
  54. {$elsec}
  55. {$setc __x86_64__ := 0}
  56. {$endc}
  57. {$ifc not defined __arm__ and defined CPUARM}
  58. {$setc __arm__ := 1}
  59. {$elsec}
  60. {$setc __arm__ := 0}
  61. {$endc}
  62. {$ifc not defined __arm64__ and defined CPUAARCH64}
  63. {$setc __arm64__ := 1}
  64. {$elsec}
  65. {$setc __arm64__ := 0}
  66. {$endc}
  67. {$ifc defined cpu64}
  68. {$setc __LP64__ := 1}
  69. {$elsec}
  70. {$setc __LP64__ := 0}
  71. {$endc}
  72. {$ifc defined __ppc__ and __ppc__ and defined __i386__ and __i386__}
  73. {$error Conflicting definitions for __ppc__ and __i386__}
  74. {$endc}
  75. {$ifc defined __ppc__ and __ppc__}
  76. {$setc TARGET_CPU_PPC := TRUE}
  77. {$setc TARGET_CPU_PPC64 := FALSE}
  78. {$setc TARGET_CPU_X86 := FALSE}
  79. {$setc TARGET_CPU_X86_64 := FALSE}
  80. {$setc TARGET_CPU_ARM := FALSE}
  81. {$setc TARGET_CPU_ARM64 := FALSE}
  82. {$setc TARGET_OS_MAC := TRUE}
  83. {$setc TARGET_OS_IPHONE := FALSE}
  84. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  85. {$setc TARGET_OS_EMBEDDED := FALSE}
  86. {$elifc defined __ppc64__ and __ppc64__}
  87. {$setc TARGET_CPU_PPC := FALSE}
  88. {$setc TARGET_CPU_PPC64 := TRUE}
  89. {$setc TARGET_CPU_X86 := FALSE}
  90. {$setc TARGET_CPU_X86_64 := FALSE}
  91. {$setc TARGET_CPU_ARM := FALSE}
  92. {$setc TARGET_CPU_ARM64 := FALSE}
  93. {$setc TARGET_OS_MAC := TRUE}
  94. {$setc TARGET_OS_IPHONE := FALSE}
  95. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  96. {$setc TARGET_OS_EMBEDDED := FALSE}
  97. {$elifc defined __i386__ and __i386__}
  98. {$setc TARGET_CPU_PPC := FALSE}
  99. {$setc TARGET_CPU_PPC64 := FALSE}
  100. {$setc TARGET_CPU_X86 := TRUE}
  101. {$setc TARGET_CPU_X86_64 := FALSE}
  102. {$setc TARGET_CPU_ARM := FALSE}
  103. {$setc TARGET_CPU_ARM64 := FALSE}
  104. {$ifc defined iphonesim}
  105. {$setc TARGET_OS_MAC := FALSE}
  106. {$setc TARGET_OS_IPHONE := TRUE}
  107. {$setc TARGET_IPHONE_SIMULATOR := TRUE}
  108. {$elsec}
  109. {$setc TARGET_OS_MAC := TRUE}
  110. {$setc TARGET_OS_IPHONE := FALSE}
  111. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  112. {$endc}
  113. {$setc TARGET_OS_EMBEDDED := FALSE}
  114. {$elifc defined __x86_64__ and __x86_64__}
  115. {$setc TARGET_CPU_PPC := FALSE}
  116. {$setc TARGET_CPU_PPC64 := FALSE}
  117. {$setc TARGET_CPU_X86 := FALSE}
  118. {$setc TARGET_CPU_X86_64 := TRUE}
  119. {$setc TARGET_CPU_ARM := FALSE}
  120. {$setc TARGET_CPU_ARM64 := FALSE}
  121. {$ifc defined iphonesim}
  122. {$setc TARGET_OS_MAC := FALSE}
  123. {$setc TARGET_OS_IPHONE := TRUE}
  124. {$setc TARGET_IPHONE_SIMULATOR := TRUE}
  125. {$elsec}
  126. {$setc TARGET_OS_MAC := TRUE}
  127. {$setc TARGET_OS_IPHONE := FALSE}
  128. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  129. {$endc}
  130. {$setc TARGET_OS_EMBEDDED := FALSE}
  131. {$elifc defined __arm__ and __arm__}
  132. {$setc TARGET_CPU_PPC := FALSE}
  133. {$setc TARGET_CPU_PPC64 := FALSE}
  134. {$setc TARGET_CPU_X86 := FALSE}
  135. {$setc TARGET_CPU_X86_64 := FALSE}
  136. {$setc TARGET_CPU_ARM := TRUE}
  137. {$setc TARGET_CPU_ARM64 := FALSE}
  138. {$setc TARGET_OS_MAC := FALSE}
  139. {$setc TARGET_OS_IPHONE := TRUE}
  140. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  141. {$setc TARGET_OS_EMBEDDED := TRUE}
  142. {$elifc defined __arm64__ and __arm64__}
  143. {$setc TARGET_CPU_PPC := FALSE}
  144. {$setc TARGET_CPU_PPC64 := FALSE}
  145. {$setc TARGET_CPU_X86 := FALSE}
  146. {$setc TARGET_CPU_X86_64 := FALSE}
  147. {$setc TARGET_CPU_ARM := FALSE}
  148. {$setc TARGET_CPU_ARM64 := TRUE}
  149. {$ifc defined ios}
  150. {$setc TARGET_OS_MAC := FALSE}
  151. {$setc TARGET_OS_IPHONE := TRUE}
  152. {$setc TARGET_OS_EMBEDDED := TRUE}
  153. {$elsec}
  154. {$setc TARGET_OS_MAC := TRUE}
  155. {$setc TARGET_OS_IPHONE := FALSE}
  156. {$setc TARGET_OS_EMBEDDED := FALSE}
  157. {$endc}
  158. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  159. {$elsec}
  160. {$error __ppc__ nor __ppc64__ nor __i386__ nor __x86_64__ nor __arm__ nor __arm64__ is defined.}
  161. {$endc}
  162. {$ifc defined __LP64__ and __LP64__ }
  163. {$setc TARGET_CPU_64 := TRUE}
  164. {$elsec}
  165. {$setc TARGET_CPU_64 := FALSE}
  166. {$endc}
  167. {$ifc defined FPC_BIG_ENDIAN}
  168. {$setc TARGET_RT_BIG_ENDIAN := TRUE}
  169. {$setc TARGET_RT_LITTLE_ENDIAN := FALSE}
  170. {$elifc defined FPC_LITTLE_ENDIAN}
  171. {$setc TARGET_RT_BIG_ENDIAN := FALSE}
  172. {$setc TARGET_RT_LITTLE_ENDIAN := TRUE}
  173. {$elsec}
  174. {$error Neither FPC_BIG_ENDIAN nor FPC_LITTLE_ENDIAN are defined.}
  175. {$endc}
  176. {$setc ACCESSOR_CALLS_ARE_FUNCTIONS := TRUE}
  177. {$setc CALL_NOT_IN_CARBON := FALSE}
  178. {$setc OLDROUTINENAMES := FALSE}
  179. {$setc OPAQUE_TOOLBOX_STRUCTS := TRUE}
  180. {$setc OPAQUE_UPP_TYPES := TRUE}
  181. {$setc OTCARBONAPPLICATION := TRUE}
  182. {$setc OTKERNEL := FALSE}
  183. {$setc PM_USE_SESSION_APIS := TRUE}
  184. {$setc TARGET_API_MAC_CARBON := TRUE}
  185. {$setc TARGET_API_MAC_OS8 := FALSE}
  186. {$setc TARGET_API_MAC_OSX := TRUE}
  187. {$setc TARGET_CARBON := TRUE}
  188. {$setc TARGET_CPU_68K := FALSE}
  189. {$setc TARGET_CPU_MIPS := FALSE}
  190. {$setc TARGET_CPU_SPARC := FALSE}
  191. {$setc TARGET_OS_UNIX := FALSE}
  192. {$setc TARGET_OS_WIN32 := FALSE}
  193. {$setc TARGET_RT_MAC_68881 := FALSE}
  194. {$setc TARGET_RT_MAC_CFM := FALSE}
  195. {$setc TARGET_RT_MAC_MACHO := TRUE}
  196. {$setc TYPED_FUNCTION_POINTERS := TRUE}
  197. {$setc TYPE_BOOL := FALSE}
  198. {$setc TYPE_EXTENDED := FALSE}
  199. {$setc TYPE_LONGLONG := TRUE}
  200. {$IFDEF FPC_DOTTEDUNITS}
  201. uses MacOsApi.MacTypes;
  202. {$ELSE FPC_DOTTEDUNITS}
  203. uses MacTypes;
  204. {$ENDIF FPC_DOTTEDUNITS}
  205. {$endc} {not MACOSALLINCLUDE}
  206. {$ALIGN POWER}
  207. {$ifc TARGET_OS_MAC}
  208. type
  209. SelectorFunctionProcPtr = function( selector: OSType; var response: SInt32 ): OSErr;
  210. SelectorFunctionUPP = SelectorFunctionProcPtr;
  211. {
  212. * Gestalt()
  213. *
  214. * Summary:
  215. * Gestalt returns information about the operating environment.
  216. *
  217. * Discussion:
  218. * The Gestalt function places the information requested by the
  219. * selector parameter in the variable parameter response . Note that
  220. * Gestalt returns the response from all selectors in an SInt32,
  221. * which occupies 4 bytes. When not all 4 bytes are needed, the
  222. * significant information appears in the low-order byte or bytes.
  223. * Although the response parameter is declared as a variable
  224. * parameter, you cannot use it to pass information to Gestalt or to
  225. * a Gestalt selector function. Gestalt interprets the response
  226. * parameter as an address at which it is to place the result
  227. * returned by the selector function specified by the selector
  228. * parameter. Gestalt ignores any information already at that
  229. * address.
  230. *
  231. * The Apple-defined selector codes fall into two categories:
  232. * environmental selectors, which supply specific environmental
  233. * information you can use to control the behavior of your
  234. * application, and informational selectors, which supply
  235. * information you can't use to determine what hardware or software
  236. * features are available. You can use one of the selector codes
  237. * defined by Apple (listed in the "Constants" section beginning on
  238. * page 1-14 ) or a selector code defined by a third-party
  239. * product.
  240. *
  241. * The meaning of the value that Gestalt returns in the response
  242. * parameter depends on the selector code with which it was called.
  243. * For example, if you call Gestalt using the gestaltTimeMgrVersion
  244. * selector, it returns a version code in the response parameter. In
  245. * this case, a returned value of 3 indicates that the extended Time
  246. * Manager is available.
  247. *
  248. * In most cases, the last few characters in the selector's symbolic
  249. * name form a suffix that indicates what type of value you can
  250. * expect Gestalt to place in the response parameter. For example,
  251. * if the suffix in a Gestalt selector is Size , then Gestalt
  252. * returns a size in the response parameter.
  253. *
  254. * Attr: A range of 32 bits, the meanings of which are defined by a
  255. * list of constants. Bit 0 is the least significant bit of the
  256. * SInt32.
  257. * Count: A number indicating how many of the indicated type of item
  258. * exist.
  259. * Size: A size, usually in bytes.
  260. * Table: The base address of a table.
  261. * Type: An index to a list of feature descriptions.
  262. * Version: A version number, which can be either a constant with a
  263. * defined meaning or an actual version number, usually stored as
  264. * four hexadecimal digits in the low-order word of the return
  265. * value. Implied decimal points may separate digits. The value
  266. * $0701, for example, returned in response to the
  267. * gestaltSystemVersion selector, represents system software version
  268. * 7.0.1.
  269. *
  270. * Selectors that have the suffix Attr deserve special attention.
  271. * They cause Gestalt to return a bit field that your application
  272. * must interpret to determine whether a desired feature is present.
  273. * For example, the application-defined sample function
  274. * MyGetSoundAttr , defined in Listing 1-2 on page 1-6 , returns a
  275. * LongInt that contains the Sound Manager attributes field
  276. * retrieved from Gestalt . To determine whether a particular
  277. * feature is available, you need to look at the designated bit.
  278. *
  279. * Mac OS X threading:
  280. * Thread safe since version 10.3
  281. *
  282. * Parameters:
  283. *
  284. * selector:
  285. * The selector to return information for
  286. *
  287. * response:
  288. * On exit, the requested information whose format depends on the
  289. * selector specified.
  290. *
  291. * Availability:
  292. * Mac OS X: in version 10.0 and later in CoreServices.framework
  293. * CarbonLib: in CarbonLib 1.0 and later
  294. * Non-Carbon CFM: in InterfaceLib 7.1 and later
  295. }
  296. function Gestalt( selector: OSType; var response: SInt32 ): OSErr; external name '_Gestalt';
  297. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  298. {$ifc not TARGET_CPU_64}
  299. {
  300. * ReplaceGestalt() *** DEPRECATED ***
  301. *
  302. * Deprecated:
  303. * Use NewGestaltValue instead wherever possible.
  304. *
  305. * Summary:
  306. * Replaces the gestalt function associated with a selector.
  307. *
  308. * Discussion:
  309. * The ReplaceGestalt function replaces the selector function
  310. * associated with an existing selector code.
  311. *
  312. * So that your function can call the function previously associated
  313. * with the selector, ReplaceGestalt places the address of the old
  314. * selector function in the oldGestaltFunction parameter. If
  315. * ReplaceGestalt returns an error of any type, then the value of
  316. * oldGestaltFunction is undefined.
  317. *
  318. * Mac OS X threading:
  319. * Thread safe since version 10.3
  320. *
  321. * Parameters:
  322. *
  323. * selector:
  324. * the selector to replace
  325. *
  326. * gestaltFunction:
  327. * a UPP for the new selector function
  328. *
  329. * oldGestaltFunction:
  330. * on exit, a pointer to the UPP of the previously associated with
  331. * the specified selector
  332. *
  333. * Availability:
  334. * Mac OS X: in version 10.0 and later in CoreServices.framework [32-bit only] but deprecated in 10.3
  335. * CarbonLib: in CarbonLib 1.0 and later
  336. * Non-Carbon CFM: in InterfaceLib 7.1 and later
  337. }
  338. function ReplaceGestalt( selector: OSType; gestaltFunction: SelectorFunctionUPP; var oldGestaltFunction: SelectorFunctionUPP ): OSErr; external name '_ReplaceGestalt';
  339. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_3, __IPHONE_NA, __IPHONE_NA) *)
  340. {$endc} {not TARGET_CPU_64}
  341. {$ifc not TARGET_CPU_64}
  342. {
  343. * NewGestalt() *** DEPRECATED ***
  344. *
  345. * Deprecated:
  346. * Use NewGestaltValue instead wherever possible.
  347. *
  348. * Summary:
  349. * Adds a selector code to those already recognized by Gestalt.
  350. *
  351. * Discussion:
  352. * The NewGestalt function registers a specified selector code with
  353. * the Gestalt Manager so that when the Gestalt function is called
  354. * with that selector code, the specified selector function is
  355. * executed. Before calling NewGestalt, you must define a selector
  356. * function callback. See SelectorFunctionProcPtr for a description
  357. * of how to define your selector function.
  358. *
  359. * Registering with the Gestalt Manager is a way for software such
  360. * as system extensions to make their presence known to potential
  361. * users of their services.
  362. *
  363. * In Mac OS X, the selector and replacement value are on a
  364. * per-context basis. That means they are available only to the
  365. * application or other code that installs them. You cannot use this
  366. * function to make information available to another process.
  367. *
  368. * A Gestalt selector registered with NewGestalt() can not be
  369. * deleted.
  370. *
  371. * Mac OS X threading:
  372. * Thread safe since version 10.3
  373. *
  374. * Parameters:
  375. *
  376. * selector:
  377. * the selector to create
  378. *
  379. * gestaltFunction:
  380. * a UPP for the new selector function, which Gestalt executes
  381. * when it receives the new selector code. See
  382. * SelectorFunctionProcPtr for more information on the callback
  383. * you need to provide.
  384. *
  385. * Availability:
  386. * Mac OS X: in version 10.0 and later in CoreServices.framework [32-bit only] but deprecated in 10.3
  387. * CarbonLib: in CarbonLib 1.0 and later
  388. * Non-Carbon CFM: in InterfaceLib 7.1 and later
  389. }
  390. function NewGestalt( selector: OSType; gestaltFunction: SelectorFunctionUPP ): OSErr; external name '_NewGestalt';
  391. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_3, __IPHONE_NA, __IPHONE_NA) *)
  392. {$endc} {not TARGET_CPU_64}
  393. {
  394. * NewGestaltValue()
  395. *
  396. * Summary:
  397. * Adds a selector code to those already recognized by Gestalt.
  398. *
  399. * Discussion:
  400. * The NewGestalt function registers a specified selector code with
  401. * the Gestalt Manager so that when the Gestalt function is called
  402. * with that selector code, the specified selector function is
  403. * executed. Before calling NewGestalt, you must define a selector
  404. * function callback. See SelectorFunctionProcPtr for a description
  405. * of how to define your selector function.
  406. *
  407. * Registering with the Gestalt Manager is a way for software such
  408. * as system extensions to make their presence known to potential
  409. * users of their services.
  410. *
  411. * In Mac OS X, the selector and replacement value are on a
  412. * per-context basis. That means they are available only to the
  413. * application or other code that installs them. You cannot use this
  414. * function to make information available to another process.
  415. *
  416. * Mac OS X threading:
  417. * Thread safe since version 10.3
  418. *
  419. * Parameters:
  420. *
  421. * selector:
  422. * the selector to create
  423. *
  424. * newValue:
  425. * the value to return for the new selector code.
  426. *
  427. * Availability:
  428. * Mac OS X: in version 10.0 and later in CoreServices.framework
  429. * CarbonLib: in CarbonLib 1.0 and later
  430. * Non-Carbon CFM: in InterfaceLib 7.5 and later
  431. }
  432. function NewGestaltValue( selector: OSType; newValue: SInt32 ): OSErr; external name '_NewGestaltValue';
  433. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  434. {
  435. * ReplaceGestaltValue()
  436. *
  437. * Summary:
  438. * Replaces the value that the function Gestalt returns for a
  439. * specified selector code with the value provided to the function.
  440. *
  441. * Discussion:
  442. * You use the function ReplaceGestaltValue to replace an existing
  443. * value. You should not call this function to introduce a value
  444. * that doesn't already exist; instead call the function
  445. * NewGestaltValue.
  446. *
  447. * In Mac OS X, the selector and replacement value are on a
  448. * per-context basis. That means they are available only to the
  449. * application or other code that installs them. You cannot use this
  450. * function to make information available to another process.
  451. *
  452. * Mac OS X threading:
  453. * Thread safe since version 10.3
  454. *
  455. * Parameters:
  456. *
  457. * selector:
  458. * the selector to create
  459. *
  460. * replacementValue:
  461. * the new value to return for the new selector code.
  462. *
  463. * Availability:
  464. * Mac OS X: in version 10.0 and later in CoreServices.framework
  465. * CarbonLib: in CarbonLib 1.0 and later
  466. * Non-Carbon CFM: in InterfaceLib 7.5 and later
  467. }
  468. function ReplaceGestaltValue( selector: OSType; replacementValue: SInt32 ): OSErr; external name '_ReplaceGestaltValue';
  469. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  470. {
  471. * SetGestaltValue()
  472. *
  473. * Summary:
  474. * Sets the value the function Gestalt will return for a specified
  475. * selector code, installing the selector if it was not already
  476. * installed.
  477. *
  478. * Discussion:
  479. * You use SetGestaltValue to establish a value for a selector,
  480. * without regard to whether the selector was already installed.
  481. *
  482. * In Mac OS X, the selector and replacement value are on a
  483. * per-context basis. That means they are available only to the
  484. * application or other code that installs them. You cannot use this
  485. * function to make information available to another process.
  486. *
  487. * Mac OS X threading:
  488. * Thread safe since version 10.3
  489. *
  490. * Parameters:
  491. *
  492. * selector:
  493. * the selector to create
  494. *
  495. * newValue:
  496. * the new value to return for the new selector code.
  497. *
  498. * Availability:
  499. * Mac OS X: in version 10.0 and later in CoreServices.framework
  500. * CarbonLib: in CarbonLib 1.0 and later
  501. * Non-Carbon CFM: in InterfaceLib 7.5 and later
  502. }
  503. function SetGestaltValue( selector: OSType; newValue: SInt32 ): OSErr; external name '_SetGestaltValue';
  504. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  505. {
  506. * DeleteGestaltValue()
  507. *
  508. * Summary:
  509. * Deletes a Gestalt selector code so that it is no longer
  510. * recognized by Gestalt.
  511. *
  512. * Discussion:
  513. * After calling this function, subsequent query or replacement
  514. * calls for the selector code will fail as if the selector had
  515. * never been installed
  516. *
  517. * In Mac OS X, the selector and replacement value are on a
  518. * per-context basis. That means they are available only to the
  519. * application or other code that installs them.
  520. *
  521. * Mac OS X threading:
  522. * Thread safe since version 10.3
  523. *
  524. * Parameters:
  525. *
  526. * selector:
  527. * the selector to delete
  528. *
  529. * Availability:
  530. * Mac OS X: in version 10.0 and later in CoreServices.framework
  531. * CarbonLib: in CarbonLib 1.0 and later
  532. * Non-Carbon CFM: in InterfaceLib 7.5 and later
  533. }
  534. function DeleteGestaltValue( selector: OSType ): OSErr; external name '_DeleteGestaltValue';
  535. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  536. {
  537. * NewSelectorFunctionUPP()
  538. *
  539. * Availability:
  540. * Mac OS X: in version 10.0 and later in CoreServices.framework
  541. * CarbonLib: in CarbonLib 1.0 and later
  542. * Non-Carbon CFM: available as macro/inline
  543. }
  544. function NewSelectorFunctionUPP( userRoutine: SelectorFunctionProcPtr ): SelectorFunctionUPP; external name '_NewSelectorFunctionUPP';
  545. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  546. {
  547. * DisposeSelectorFunctionUPP()
  548. *
  549. * Availability:
  550. * Mac OS X: in version 10.0 and later in CoreServices.framework
  551. * CarbonLib: in CarbonLib 1.0 and later
  552. * Non-Carbon CFM: available as macro/inline
  553. }
  554. procedure DisposeSelectorFunctionUPP( userUPP: SelectorFunctionUPP ); external name '_DisposeSelectorFunctionUPP';
  555. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  556. {
  557. * InvokeSelectorFunctionUPP()
  558. *
  559. * Availability:
  560. * Mac OS X: in version 10.0 and later in CoreServices.framework
  561. * CarbonLib: in CarbonLib 1.0 and later
  562. * Non-Carbon CFM: available as macro/inline
  563. }
  564. function InvokeSelectorFunctionUPP( selector: OSType; var response: SInt32; userUPP: SelectorFunctionUPP ): OSErr; external name '_InvokeSelectorFunctionUPP';
  565. (* __OSX_AVAILABLE_BUT_DEPRECATED(__MAC_10_0, __MAC_10_8, __IPHONE_NA, __IPHONE_NA) *)
  566. { Environment Selectors }
  567. const
  568. gestaltAddressingModeAttr = FourCharCode('addr'); { addressing mode attributes }
  569. gestalt32BitAddressing = 0; { using 32-bit addressing mode }
  570. gestalt32BitSysZone = 1; { 32-bit compatible system zone }
  571. gestalt32BitCapable = 2; { Machine is 32-bit capable }
  572. const
  573. gestaltAFPClient = FourCharCode('afps');
  574. gestaltAFPClientVersionMask = $0000FFFF; { low word of SInt32 is the }
  575. { client version 0x0001 -> 0x0007}
  576. gestaltAFPClient3_5 = $0001;
  577. gestaltAFPClient3_6 = $0002;
  578. gestaltAFPClient3_6_1 = $0003;
  579. gestaltAFPClient3_6_2 = $0004;
  580. gestaltAFPClient3_6_3 = $0005; { including 3.6.4, 3.6.5}
  581. gestaltAFPClient3_7 = $0006; { including 3.7.1}
  582. gestaltAFPClient3_7_2 = $0007; { including 3.7.3, 3.7.4}
  583. gestaltAFPClient3_8 = $0008;
  584. gestaltAFPClient3_8_1 = $0009; { including 3.8.2 }
  585. gestaltAFPClient3_8_3 = $000A;
  586. gestaltAFPClient3_8_4 = $000B; { including 3.8.5, 3.8.6 }
  587. gestaltAFPClientAttributeMask = $FFFF0000; { high word of response is a }
  588. { set of attribute bits}
  589. gestaltAFPClientCfgRsrc = 16; { Client uses config resources}
  590. gestaltAFPClientSupportsIP = 29; { Client supports AFP over TCP/IP}
  591. gestaltAFPClientVMUI = 30; { Client can put up UI from the PBVolMount trap}
  592. gestaltAFPClientMultiReq = 31; { Client supports multiple outstanding requests}
  593. const
  594. gestaltAliasMgrAttr = FourCharCode('alis'); { Alias Mgr Attributes }
  595. gestaltAliasMgrPresent = 0; { True if the Alias Mgr is present }
  596. gestaltAliasMgrSupportsRemoteAppletalk = 1; { True if the Alias Mgr knows about Remote Appletalk }
  597. gestaltAliasMgrSupportsAOCEKeychain = 2; { True if the Alias Mgr knows about the AOCE Keychain }
  598. gestaltAliasMgrResolveAliasFileWithMountOptions = 3; { True if the Alias Mgr implements gestaltAliasMgrResolveAliasFileWithMountOptions() and IsAliasFile() }
  599. gestaltAliasMgrFollowsAliasesWhenResolving = 4;
  600. gestaltAliasMgrSupportsExtendedCalls = 5;
  601. gestaltAliasMgrSupportsFSCalls = 6; { true if Alias Mgr supports HFS+ Calls }
  602. gestaltAliasMgrPrefersPath = 7; { True if the Alias Mgr prioritizes the path over file id during resolution by default }
  603. gestaltAliasMgrRequiresAccessors = 8; { Set if Alias Manager requires accessors for size and usertype }
  604. { Gestalt selector and values for the Appearance Manager }
  605. const
  606. gestaltAppearanceAttr = FourCharCode('appr');
  607. gestaltAppearanceExists = 0;
  608. gestaltAppearanceCompatMode = 1;
  609. { Gestalt selector for determining Appearance Manager version }
  610. { If this selector does not exist, but gestaltAppearanceAttr }
  611. { does, it indicates that the 1.0 version is installed. This }
  612. { gestalt returns a BCD number representing the version of the }
  613. { Appearance Manager that is currently running, e.g. 0x0101 for }
  614. { version 1.0.1. }
  615. const
  616. gestaltAppearanceVersion = FourCharCode('apvr');
  617. const
  618. gestaltArbitorAttr = FourCharCode('arb ');
  619. gestaltSerialArbitrationExists = 0; { this bit if the serial port arbitrator exists}
  620. const
  621. gestaltAppleScriptVersion = FourCharCode('ascv'); { AppleScript version}
  622. const
  623. gestaltAppleScriptAttr = FourCharCode('ascr'); { AppleScript attributes}
  624. gestaltAppleScriptPresent = 0;
  625. gestaltAppleScriptPowerPCSupport = 1;
  626. const
  627. gestaltATAAttr = FourCharCode('ata '); { ATA is the driver to support IDE hard disks }
  628. gestaltATAPresent = 0; { if set, ATA Manager is present }
  629. const
  630. gestaltATalkVersion = FourCharCode('atkv'); { Detailed AppleTalk version; see comment above for format }
  631. const
  632. gestaltAppleTalkVersion = FourCharCode('atlk'); { appletalk version }
  633. {
  634. FORMAT OF gestaltATalkVersion RESPONSE
  635. --------------------------------------
  636. The version is stored in the high three bytes of the response value. Let us number
  637. the bytes in the response value from 0 to 3, where 0 is the least-significant byte.
  638. Byte#: 3 2 1 0
  639. Value: 0xMMNNRR00
  640. Byte 3 (MM) contains the major revision number, byte 2 (NN) contains the minor
  641. revision number, and byte 1 (RR) contains a constant that represents the release
  642. stage. Byte 0 always contains 0x00. The constants for the release stages are:
  643. development = 0x20
  644. alpha = 0x40
  645. beta = 0x60
  646. final = 0x80
  647. release = 0x80
  648. For example, if you call Gestalt with the 'atkv' selector when AppleTalk version 57
  649. is loaded, you receive the integer response value 0x39008000.
  650. }
  651. const
  652. gestaltAUXVersion = FourCharCode('a/ux'); { a/ux version, if present }
  653. const
  654. gestaltMacOSCompatibilityBoxAttr = FourCharCode('bbox'); { Classic presence and features }
  655. gestaltMacOSCompatibilityBoxPresent = 0; { True if running under the Classic }
  656. gestaltMacOSCompatibilityBoxHasSerial = 1; { True if Classic serial support is implemented. }
  657. gestaltMacOSCompatibilityBoxless = 2; { True if we're Boxless (screen shared with Carbon/Cocoa) }
  658. const
  659. gestaltBusClkSpeed = FourCharCode('bclk'); { main I/O bus clock speed in hertz }
  660. const
  661. gestaltBusClkSpeedMHz = FourCharCode('bclm'); { main I/O bus clock speed in megahertz ( a UInt32 ) }
  662. const
  663. gestaltCloseViewAttr = FourCharCode('BSDa'); { CloseView attributes }
  664. gestaltCloseViewEnabled = 0; { Closeview enabled (dynamic bit - returns current state) }
  665. gestaltCloseViewDisplayMgrFriendly = 1; { Closeview compatible with Display Manager (FUTURE) }
  666. const
  667. gestaltCarbonVersion = FourCharCode('cbon'); { version of Carbon API present in system }
  668. const
  669. gestaltCFMAttr = FourCharCode('cfrg'); { Selector for information about the Code Fragment Manager }
  670. gestaltCFMPresent = 0; { True if the Code Fragment Manager is present }
  671. gestaltCFMPresentMask = $0001;
  672. gestaltCFM99Present = 2; { True if the CFM-99 features are present. }
  673. gestaltCFM99PresentMask = $0004;
  674. const
  675. gestaltProcessorCacheLineSize = FourCharCode('csiz'); { The size, in bytes, of the processor cache line. }
  676. const
  677. gestaltCollectionMgrVersion = FourCharCode('cltn'); { Collection Manager version }
  678. const
  679. gestaltColorMatchingAttr = FourCharCode('cmta'); { ColorSync attributes }
  680. gestaltHighLevelMatching = 0;
  681. gestaltColorMatchingLibLoaded = 1;
  682. const
  683. gestaltColorMatchingVersion = FourCharCode('cmtc');
  684. gestaltColorSync10 = $0100; { 0x0100 & 0x0110 _Gestalt versions for 1.0-1.0.3 product }
  685. gestaltColorSync11 = $0110; { 0x0100 == low-level matching only }
  686. gestaltColorSync104 = $0104; { Real version, by popular demand }
  687. gestaltColorSync105 = $0105;
  688. gestaltColorSync20 = $0200; { ColorSync 2.0 }
  689. gestaltColorSync21 = $0210;
  690. gestaltColorSync211 = $0211;
  691. gestaltColorSync212 = $0212;
  692. gestaltColorSync213 = $0213;
  693. gestaltColorSync25 = $0250;
  694. gestaltColorSync26 = $0260;
  695. gestaltColorSync261 = $0261;
  696. gestaltColorSync30 = $0300;
  697. const
  698. gestaltControlMgrVersion = FourCharCode('cmvr'); { NOTE: The first version we return is 3.0.1, on Mac OS X plus update 2}
  699. const
  700. gestaltControlMgrAttr = FourCharCode('cntl'); { Control Mgr}
  701. gestaltControlMgrPresent = 1 shl 0; { NOTE: this is a bit mask, whereas all other Gestalt constants of}
  702. { this type are bit index values. Universal Interfaces 3.2 slipped}
  703. { out the door with this mistake.}
  704. gestaltControlMgrPresentBit = 0; { bit number}
  705. gestaltControlMsgPresentMask = 1 shl gestaltControlMgrPresentBit;
  706. const
  707. gestaltConnMgrAttr = FourCharCode('conn'); { connection mgr attributes }
  708. gestaltConnMgrPresent = 0;
  709. gestaltConnMgrCMSearchFix = 1; { Fix to CMAddSearch? }
  710. gestaltConnMgrErrorString = 2; { has CMGetErrorString() }
  711. gestaltConnMgrMultiAsyncIO = 3; { CMNewIOPB, CMDisposeIOPB, CMPBRead, CMPBWrite, CMPBIOKill }
  712. const
  713. gestaltColorPickerVersion = FourCharCode('cpkr'); { returns version of ColorPicker }
  714. gestaltColorPicker = FourCharCode('cpkr'); { gestaltColorPicker is old name for gestaltColorPickerVersion }
  715. const
  716. gestaltComponentMgr = FourCharCode('cpnt'); { Component Mgr version }
  717. gestaltComponentPlatform = FourCharCode('copl'); { Component Platform number }
  718. {
  719. The gestaltNativeCPUtype ('cput') selector can be used to determine the
  720. native CPU type for all Macs running System 7.5 or later.
  721. However, the use of these selectors for pretty much anything is discouraged.
  722. If you are trying to determine if you can use a particular processor or
  723. operating system feature, it would be much better to check directly for that
  724. feature using one of the apis for doing so -- like, sysctl() or sysctlbyname().
  725. Those apis return information directly from the operating system and kernel. By
  726. using those apis you may be able to avoid linking against Frameworks which you
  727. otherwise don't need, and may lessen the memory and code footprint of your
  728. applications.
  729. The gestaltNativeCPUfamily ('cpuf') selector can be used to determine the
  730. general family the native CPU is in.
  731. gestaltNativeCPUfamily uses the same results as gestaltNativeCPUtype, but
  732. will only return certain CPU values.
  733. IMPORTANT NOTE: gestaltNativeCPUFamily may no longer be updated for any new
  734. processor families introduced after the 970. If there are
  735. processor specific features you need to be checking for in
  736. your code, use one of the appropriate apis to get for those
  737. exact features instead of assuming that all members of a given
  738. cpu family exhibit the same behaviour. The most appropriate api
  739. to look at is sysctl() and sysctlbyname(), which return information
  740. direct from the kernel about the system.
  741. }
  742. const
  743. gestaltNativeCPUtype = FourCharCode('cput'); { Native CPU type }
  744. gestaltNativeCPUfamily = FourCharCode('cpuf'); { Native CPU family }
  745. gestaltCPU68000 = 0; { Various 68k CPUs... }
  746. gestaltCPU68010 = 1;
  747. gestaltCPU68020 = 2;
  748. gestaltCPU68030 = 3;
  749. gestaltCPU68040 = 4;
  750. gestaltCPU601 = $0101; { IBM 601 }
  751. gestaltCPU603 = $0103;
  752. gestaltCPU604 = $0104;
  753. gestaltCPU603e = $0106;
  754. gestaltCPU603ev = $0107;
  755. gestaltCPU750 = $0108; { Also 740 - "G3" }
  756. gestaltCPU604e = $0109;
  757. gestaltCPU604ev = $010A; { Mach 5, 250Mhz and up }
  758. gestaltCPUG4 = $010C; { Max }
  759. gestaltCPUG47450 = $0110; { Vger , Altivec }
  760. const
  761. gestaltCPUApollo = $0111; { Apollo , Altivec, G4 7455 }
  762. gestaltCPUG47447 = $0112;
  763. gestaltCPU750FX = $0120; { Sahara,G3 like thing }
  764. gestaltCPU970 = $0139; { G5 }
  765. gestaltCPU970FX = $013C; { another G5 }
  766. gestaltCPU970MP = $0144;
  767. const
  768. { x86 CPUs all start with 'i' in the high nybble }
  769. gestaltCPU486 = FourCharCode('i486');
  770. gestaltCPUPentium = FourCharCode('i586');
  771. gestaltCPUPentiumPro = FourCharCode('i5pr');
  772. gestaltCPUPentiumII = FourCharCode('i5ii');
  773. gestaltCPUX86 = FourCharCode('ixxx');
  774. gestaltCPUPentium4 = FourCharCode('i5iv');
  775. const
  776. gestaltCRMAttr = FourCharCode('crm '); { comm resource mgr attributes }
  777. gestaltCRMPresent = 0;
  778. gestaltCRMPersistentFix = 1; { fix for persistent tools }
  779. gestaltCRMToolRsrcCalls = 2; { has CRMGetToolResource/ReleaseToolResource }
  780. const
  781. gestaltControlStripVersion = FourCharCode('csvr'); { Control Strip version (was 'sdvr') }
  782. const
  783. gestaltCountOfCPUs = FourCharCode('cpus'); { the number of CPUs on the computer, Mac OS X 10.4 and later }
  784. const
  785. gestaltCTBVersion = FourCharCode('ctbv'); { CommToolbox version }
  786. const
  787. gestaltDBAccessMgrAttr = FourCharCode('dbac'); { Database Access Mgr attributes }
  788. gestaltDBAccessMgrPresent = 0; { True if Database Access Mgr present }
  789. const
  790. gestaltDiskCacheSize = FourCharCode('dcsz'); { Size of disk cache's buffers, in bytes }
  791. const
  792. gestaltSDPFindVersion = FourCharCode('dfnd'); { OCE Standard Directory Panel}
  793. const
  794. gestaltDictionaryMgrAttr = FourCharCode('dict'); { Dictionary Manager attributes }
  795. gestaltDictionaryMgrPresent = 0; { Dictionary Manager attributes }
  796. const
  797. gestaltDITLExtAttr = FourCharCode('ditl'); { AppenDITL, etc. calls from CTB }
  798. gestaltDITLExtPresent = 0; { True if calls are present }
  799. gestaltDITLExtSupportsIctb = 1; { True if AppendDITL, ShortenDITL support 'ictb's }
  800. const
  801. gestaltDialogMgrAttr = FourCharCode('dlog'); { Dialog Mgr}
  802. gestaltDialogMgrPresent = 1 shl 0; { NOTE: this is a bit mask, whereas all other Gestalt constants of}
  803. { this type are bit index values. Universal Interfaces 3.2 slipped}
  804. { out the door with this mistake.}
  805. gestaltDialogMgrPresentBit = 0; { bit number}
  806. gestaltDialogMgrHasAquaAlertBit = 2; { bit number}
  807. gestaltDialogMgrPresentMask = 1 shl gestaltDialogMgrPresentBit;
  808. gestaltDialogMgrHasAquaAlertMask = 1 shl gestaltDialogMgrHasAquaAlertBit;
  809. gestaltDialogMsgPresentMask = gestaltDialogMgrPresentMask; { compatibility mask}
  810. const
  811. gestaltDesktopPicturesAttr = FourCharCode('dkpx'); { Desktop Pictures attributes }
  812. gestaltDesktopPicturesInstalled = 0; { True if control panel is installed }
  813. gestaltDesktopPicturesDisplayed = 1; { True if a picture is currently displayed }
  814. const
  815. gestaltDisplayMgrVers = FourCharCode('dplv'); { Display Manager version }
  816. const
  817. gestaltDisplayMgrAttr = FourCharCode('dply'); { Display Manager attributes }
  818. gestaltDisplayMgrPresent = 0; { True if Display Mgr is present }
  819. gestaltDisplayMgrCanSwitchMirrored = 2; { True if Display Mgr can switch modes on mirrored displays }
  820. gestaltDisplayMgrSetDepthNotifies = 3; { True SetDepth generates displays mgr notification }
  821. gestaltDisplayMgrCanConfirm = 4; { True Display Manager supports DMConfirmConfiguration }
  822. gestaltDisplayMgrColorSyncAware = 5; { True if Display Manager supports profiles for displays }
  823. gestaltDisplayMgrGeneratesProfiles = 6; { True if Display Manager will automatically generate profiles for displays }
  824. gestaltDisplayMgrSleepNotifies = 7; { True if Display Mgr generates "displayWillSleep", "displayDidWake" notifications }
  825. const
  826. gestaltDragMgrAttr = FourCharCode('drag'); { Drag Manager attributes }
  827. gestaltDragMgrPresent = 0; { Drag Manager is present }
  828. gestaltDragMgrFloatingWind = 1; { Drag Manager supports floating windows }
  829. gestaltPPCDragLibPresent = 2; { Drag Manager PPC DragLib is present }
  830. gestaltDragMgrHasImageSupport = 3; { Drag Manager allows SetDragImage call }
  831. gestaltCanStartDragInFloatWindow = 4; { Drag Manager supports starting a drag in a floating window }
  832. gestaltSetDragImageUpdates = 5; { Drag Manager supports drag image updating via SetDragImage }
  833. const
  834. gestaltDrawSprocketVersion = FourCharCode('dspv'); { Draw Sprocket version (as a NumVersion) }
  835. const
  836. gestaltDigitalSignatureVersion = FourCharCode('dsig'); { returns Digital Signature Toolbox version in low-order word}
  837. {
  838. Desktop Printing Feature Gestalt
  839. Use this gestalt to check if third-party printer driver support is available
  840. }
  841. const
  842. gestaltDTPFeatures = FourCharCode('dtpf');
  843. kDTPThirdPartySupported = $00000004; { mask for checking if third-party drivers are supported}
  844. {
  845. Desktop Printer Info Gestalt
  846. Use this gestalt to get a hold of information for all of the active desktop printers
  847. }
  848. const
  849. gestaltDTPInfo = FourCharCode('dtpx'); { returns GestaltDTPInfoHdle}
  850. const
  851. gestaltEasyAccessAttr = FourCharCode('easy'); { Easy Access attributes }
  852. gestaltEasyAccessOff = 0; { if Easy Access present, but off (no icon) }
  853. gestaltEasyAccessOn = 1; { if Easy Access "On" }
  854. gestaltEasyAccessSticky = 2; { if Easy Access "Sticky" }
  855. gestaltEasyAccessLocked = 3; { if Easy Access "Locked" }
  856. const
  857. gestaltEditionMgrAttr = FourCharCode('edtn'); { Edition Mgr attributes }
  858. gestaltEditionMgrPresent = 0; { True if Edition Mgr present }
  859. gestaltEditionMgrTranslationAware = 1; { True if edition manager is translation manager aware }
  860. const
  861. gestaltAppleEventsAttr = FourCharCode('evnt'); { Apple Events attributes }
  862. gestaltAppleEventsPresent = 0; { True if Apple Events present }
  863. gestaltScriptingSupport = 1;
  864. gestaltOSLInSystem = 2; { OSL is in system so donÕt use the one linked in to app }
  865. gestaltSupportsApplicationURL = 4; { Supports the typeApplicationURL addressing mode }
  866. const
  867. gestaltExtensionTableVersion = FourCharCode('etbl'); { ExtensionTable version }
  868. const
  869. gestaltFBCIndexingState = FourCharCode('fbci'); { Find By Content indexing state}
  870. gestaltFBCindexingSafe = 0; { any search will result in synchronous wait}
  871. gestaltFBCindexingCritical = 1; { any search will execute immediately}
  872. const
  873. gestaltFBCVersion = FourCharCode('fbcv'); { Find By Content version}
  874. gestaltFBCCurrentVersion = $0011; { First release for OS 8/9}
  875. gestaltOSXFBCCurrentVersion = $0100; { First release for OS X}
  876. const
  877. gestaltFileMappingAttr = FourCharCode('flmp'); { File mapping attributes}
  878. gestaltFileMappingPresent = 0; { bit is set if file mapping APIs are present}
  879. gestaltFileMappingMultipleFilesFix = 1; { bit is set if multiple files per volume can be mapped}
  880. const
  881. gestaltFloppyAttr = FourCharCode('flpy'); { Floppy disk drive/driver attributes }
  882. gestaltFloppyIsMFMOnly = 0; { Floppy driver only supports MFM disk formats }
  883. gestaltFloppyIsManualEject = 1; { Floppy drive, driver, and file system are in manual-eject mode }
  884. gestaltFloppyUsesDiskInPlace = 2; { Floppy drive must have special DISK-IN-PLACE output; standard DISK-CHANGED not used }
  885. const
  886. gestaltFinderAttr = FourCharCode('fndr'); { Finder attributes }
  887. gestaltFinderDropEvent = 0; { Finder recognizes drop event }
  888. gestaltFinderMagicPlacement = 1; { Finder supports magic icon placement }
  889. gestaltFinderCallsAEProcess = 2; { Finder calls AEProcessAppleEvent }
  890. gestaltOSLCompliantFinder = 3; { Finder is scriptable and recordable }
  891. gestaltFinderSupports4GBVolumes = 4; { Finder correctly handles 4GB volumes }
  892. gestaltFinderHasClippings = 6; { Finder supports Drag Manager clipping files }
  893. gestaltFinderFullDragManagerSupport = 7; { Finder accepts 'hfs ' flavors properly }
  894. gestaltFinderFloppyRootComments = 8; { in MacOS 8 and later, will be set if Finder ever supports comments on Floppy icons }
  895. gestaltFinderLargeAndNotSavedFlavorsOK = 9; { in MacOS 8 and later, this bit is set if drags with >1024-byte flavors and flavorNotSaved flavors work reliably }
  896. gestaltFinderUsesExtensibleFolderManager = 10; { Finder uses Extensible Folder Manager (for example, for Magic Routing) }
  897. gestaltFinderUnderstandsRedirectedDesktopFolder = 11; { Finder deals with startup disk's desktop folder residing on another disk }
  898. const
  899. gestaltFindFolderAttr = FourCharCode('fold'); { Folder Mgr attributes }
  900. gestaltFindFolderPresent = 0; { True if Folder Mgr present }
  901. gestaltFolderDescSupport = 1; { True if Folder Mgr has FolderDesc calls }
  902. gestaltFolderMgrFollowsAliasesWhenResolving = 2; { True if Folder Mgr follows folder aliases }
  903. gestaltFolderMgrSupportsExtendedCalls = 3; { True if Folder Mgr supports the Extended calls }
  904. gestaltFolderMgrSupportsDomains = 4; { True if Folder Mgr supports domains for the first parameter to FindFolder }
  905. gestaltFolderMgrSupportsFSCalls = 5; { True if FOlder manager supports __FindFolderFSRef & __FindFolderExtendedFSRef }
  906. const
  907. gestaltFindFolderRedirectionAttr = FourCharCode('fole');
  908. const
  909. gestaltFontMgrAttr = FourCharCode('font'); { Font Mgr attributes }
  910. gestaltOutlineFonts = 0; { True if Outline Fonts supported }
  911. const
  912. gestaltFPUType = FourCharCode('fpu '); { fpu type }
  913. gestaltNoFPU = 0; { no FPU }
  914. gestalt68881 = 1; { 68881 FPU }
  915. gestalt68882 = 2; { 68882 FPU }
  916. gestalt68040FPU = 3; { 68040 built-in FPU }
  917. const
  918. gestaltFSAttr = FourCharCode('fs '); { file system attributes }
  919. gestaltFullExtFSDispatching = 0; { has really cool new HFSDispatch dispatcher }
  920. gestaltHasFSSpecCalls = 1; { has FSSpec calls }
  921. gestaltHasFileSystemManager = 2; { has a file system manager }
  922. gestaltFSMDoesDynamicLoad = 3; { file system manager supports dynamic loading }
  923. gestaltFSSupports4GBVols = 4; { file system supports 4 gigabyte volumes }
  924. gestaltFSSupports2TBVols = 5; { file system supports 2 terabyte volumes }
  925. gestaltHasExtendedDiskInit = 6; { has extended Disk Initialization calls }
  926. gestaltDTMgrSupportsFSM = 7; { Desktop Manager support FSM-based foreign file systems }
  927. gestaltFSNoMFSVols = 8; { file system doesn't supports MFS volumes }
  928. gestaltFSSupportsHFSPlusVols = 9; { file system supports HFS Plus volumes }
  929. gestaltFSIncompatibleDFA82 = 10; { VCB and FCB structures changed; DFA 8.2 is incompatible }
  930. const
  931. gestaltFSSupportsDirectIO = 11; { file system supports DirectIO }
  932. const
  933. gestaltHasHFSPlusAPIs = 12; { file system supports HFS Plus APIs }
  934. gestaltMustUseFCBAccessors = 13; { FCBSPtr and FSFCBLen are invalid - must use FSM FCB accessor functions}
  935. gestaltFSUsesPOSIXPathsForConversion = 14; { The path interchange routines operate on POSIX paths instead of HFS paths }
  936. gestaltFSSupportsExclusiveLocks = 15; { File system uses POSIX O_EXLOCK for opens }
  937. gestaltFSSupportsHardLinkDetection = 16; { File system returns if an item is a hard link }
  938. gestaltFSAllowsConcurrentAsyncIO = 17; { File Manager supports concurrent async reads and writes }
  939. const
  940. gestaltAdminFeaturesFlagsAttr = FourCharCode('fred'); { a set of admin flags, mostly useful internally. }
  941. gestaltFinderUsesSpecialOpenFoldersFile = 0; { the Finder uses a special file to store the list of open folders }
  942. const
  943. gestaltFSMVersion = FourCharCode('fsm '); { returns version of HFS External File Systems Manager (FSM) }
  944. const
  945. gestaltFXfrMgrAttr = FourCharCode('fxfr'); { file transfer manager attributes }
  946. gestaltFXfrMgrPresent = 0;
  947. gestaltFXfrMgrMultiFile = 1; { supports FTSend and FTReceive }
  948. gestaltFXfrMgrErrorString = 2; { supports FTGetErrorString }
  949. gestaltFXfrMgrAsync = 3; {supports FTSendAsync, FTReceiveAsync, FTCompletionAsync}
  950. const
  951. gestaltGraphicsAttr = FourCharCode('gfxa'); { Quickdraw GX attributes selector }
  952. gestaltGraphicsIsDebugging = $00000001;
  953. gestaltGraphicsIsLoaded = $00000002;
  954. gestaltGraphicsIsPowerPC = $00000004;
  955. const
  956. gestaltGraphicsVersion = FourCharCode('grfx'); { Quickdraw GX version selector }
  957. gestaltCurrentGraphicsVersion = $00010200; { the version described in this set of headers }
  958. const
  959. gestaltHardwareAttr = FourCharCode('hdwr'); { hardware attributes }
  960. gestaltHasVIA1 = 0; { VIA1 exists }
  961. gestaltHasVIA2 = 1; { VIA2 exists }
  962. gestaltHasASC = 3; { Apple Sound Chip exists }
  963. gestaltHasSCC = 4; { SCC exists }
  964. gestaltHasSCSI = 7; { SCSI exists }
  965. gestaltHasSoftPowerOff = 19; { Capable of software power off }
  966. gestaltHasSCSI961 = 21; { 53C96 SCSI controller on internal bus }
  967. gestaltHasSCSI962 = 22; { 53C96 SCSI controller on external bus }
  968. gestaltHasUniversalROM = 24; { Do we have a Universal ROM? }
  969. gestaltHasEnhancedLtalk = 30; { Do we have Enhanced LocalTalk? }
  970. const
  971. gestaltHelpMgrAttr = FourCharCode('help'); { Help Mgr Attributes }
  972. gestaltHelpMgrPresent = 0; { true if help mgr is present }
  973. gestaltHelpMgrExtensions = 1; { true if help mgr extensions are installed }
  974. gestaltAppleGuideIsDebug = 30;
  975. gestaltAppleGuidePresent = 31; { true if AppleGuide is installed }
  976. const
  977. gestaltHardwareVendorCode = FourCharCode('hrad'); { Returns hardware vendor information }
  978. gestaltHardwareVendorApple = FourCharCode('Appl'); { Hardware built by Apple }
  979. const
  980. gestaltCompressionMgr = FourCharCode('icmp'); { returns version of the Image Compression Manager }
  981. const
  982. gestaltIconUtilitiesAttr = FourCharCode('icon'); { Icon Utilities attributes (Note: available in System 7.0, despite gestalt) }
  983. gestaltIconUtilitiesPresent = 0; { true if icon utilities are present }
  984. gestaltIconUtilitiesHas48PixelIcons = 1; { true if 48x48 icons are supported by IconUtilities }
  985. gestaltIconUtilitiesHas32BitIcons = 2; { true if 32-bit deep icons are supported }
  986. gestaltIconUtilitiesHas8BitDeepMasks = 3; { true if 8-bit deep masks are supported }
  987. gestaltIconUtilitiesHasIconServices = 4; { true if IconServices is present }
  988. const
  989. gestaltInternalDisplay = FourCharCode('idsp'); { slot number of internal display location }
  990. {
  991. To obtain information about the connected keyboard(s), one should
  992. use the ADB Manager API. See Technical Note OV16 for details.
  993. }
  994. const
  995. gestaltKeyboardType = FourCharCode('kbd '); { keyboard type }
  996. gestaltMacKbd = 1;
  997. gestaltMacAndPad = 2;
  998. gestaltMacPlusKbd = 3; { OBSOLETE: This pre-ADB keyboard is not supported by any Mac OS X hardware and this value now means gestaltUnknownThirdPartyKbd }
  999. gestaltUnknownThirdPartyKbd = 3; { Unknown 3rd party keyboard. }
  1000. gestaltExtADBKbd = 4;
  1001. gestaltStdADBKbd = 5;
  1002. gestaltPrtblADBKbd = 6;
  1003. gestaltPrtblISOKbd = 7;
  1004. gestaltStdISOADBKbd = 8;
  1005. gestaltExtISOADBKbd = 9;
  1006. gestaltADBKbdII = 10;
  1007. gestaltADBISOKbdII = 11;
  1008. gestaltPwrBookADBKbd = 12;
  1009. gestaltPwrBookISOADBKbd = 13;
  1010. gestaltAppleAdjustKeypad = 14;
  1011. gestaltAppleAdjustADBKbd = 15;
  1012. gestaltAppleAdjustISOKbd = 16;
  1013. gestaltJapanAdjustADBKbd = 17; { Japan Adjustable Keyboard }
  1014. gestaltPwrBkExtISOKbd = 20; { PowerBook Extended International Keyboard with function keys }
  1015. gestaltPwrBkExtJISKbd = 21; { PowerBook Extended Japanese Keyboard with function keys }
  1016. gestaltPwrBkExtADBKbd = 24; { PowerBook Extended Domestic Keyboard with function keys }
  1017. gestaltPS2Keyboard = 27; { PS2 keyboard }
  1018. gestaltPwrBkSubDomKbd = 28; { PowerBook Subnote Domestic Keyboard with function keys w/ inverted T }
  1019. gestaltPwrBkSubISOKbd = 29; { PowerBook Subnote International Keyboard with function keys w/ inverted T }
  1020. gestaltPwrBkSubJISKbd = 30; { PowerBook Subnote Japanese Keyboard with function keys w/ inverted T }
  1021. gestaltPortableUSBANSIKbd = 37; { Powerbook USB-based internal keyboard, ANSI layout }
  1022. gestaltPortableUSBISOKbd = 38; { Powerbook USB-based internal keyboard, ISO layout }
  1023. gestaltPortableUSBJISKbd = 39; { Powerbook USB-based internal keyboard, JIS layout }
  1024. gestaltThirdPartyANSIKbd = 40; { Third party keyboard, ANSI layout. Returned in Mac OS X Tiger and later. }
  1025. gestaltThirdPartyISOKbd = 41; { Third party keyboard, ISO layout. Returned in Mac OS X Tiger and later. }
  1026. gestaltThirdPartyJISKbd = 42; { Third party keyboard, JIS layout. Returned in Mac OS X Tiger and later. }
  1027. gestaltPwrBkEKDomKbd = 195; { (0xC3) PowerBook Domestic Keyboard with Embedded Keypad, function keys & inverted T }
  1028. gestaltPwrBkEKISOKbd = 196; { (0xC4) PowerBook International Keyboard with Embedded Keypad, function keys & inverted T }
  1029. gestaltPwrBkEKJISKbd = 197; { (0xC5) PowerBook Japanese Keyboard with Embedded Keypad, function keys & inverted T }
  1030. gestaltUSBCosmoANSIKbd = 198; { (0xC6) original USB Domestic (ANSI) Keyboard }
  1031. gestaltUSBCosmoISOKbd = 199; { (0xC7) original USB International (ISO) Keyboard }
  1032. gestaltUSBCosmoJISKbd = 200; { (0xC8) original USB Japanese (JIS) Keyboard }
  1033. gestaltPwrBk99JISKbd = 201; { (0xC9) '99 PowerBook JIS Keyboard with Embedded Keypad, function keys & inverted T }
  1034. gestaltUSBAndyANSIKbd = 204; { (0xCC) USB Pro Keyboard Domestic (ANSI) Keyboard }
  1035. gestaltUSBAndyISOKbd = 205; { (0xCD) USB Pro Keyboard International (ISO) Keyboard }
  1036. gestaltUSBAndyJISKbd = 206; { (0xCE) USB Pro Keyboard Japanese (JIS) Keyboard }
  1037. const
  1038. gestaltPortable2001ANSIKbd = 202; { (0xCA) PowerBook and iBook Domestic (ANSI) Keyboard with 2nd cmd key right & function key moves. }
  1039. gestaltPortable2001ISOKbd = 203; { (0xCB) PowerBook and iBook International (ISO) Keyboard with 2nd cmd key right & function key moves. }
  1040. gestaltPortable2001JISKbd = 207; { (0xCF) PowerBook and iBook Japanese (JIS) Keyboard with function key moves. }
  1041. const
  1042. gestaltUSBProF16ANSIKbd = 34; { (0x22) USB Pro Keyboard w/ F16 key Domestic (ANSI) Keyboard }
  1043. gestaltUSBProF16ISOKbd = 35; { (0x23) USB Pro Keyboard w/ F16 key International (ISO) Keyboard }
  1044. gestaltUSBProF16JISKbd = 36; { (0x24) USB Pro Keyboard w/ F16 key Japanese (JIS) Keyboard }
  1045. gestaltProF16ANSIKbd = 31; { (0x1F) Pro Keyboard w/F16 key Domestic (ANSI) Keyboard }
  1046. gestaltProF16ISOKbd = 32; { (0x20) Pro Keyboard w/F16 key International (ISO) Keyboard }
  1047. gestaltProF16JISKbd = 33; { (0x21) Pro Keyboard w/F16 key Japanese (JIS) Keyboard }
  1048. {
  1049. This gestalt indicates the highest UDF version that the active UDF implementation supports.
  1050. The value should be assembled from a read version (upper word) and a write version (lower word)
  1051. }
  1052. const
  1053. gestaltUDFSupport = FourCharCode('kudf'); { Used for communication between UDF implementations}
  1054. const
  1055. gestaltLowMemorySize = FourCharCode('lmem'); { size of low memory area }
  1056. const
  1057. gestaltLogicalRAMSize = FourCharCode('lram'); { logical ram size }
  1058. {
  1059. MACHINE TYPE CONSTANTS NAMING CONVENTION
  1060. All future machine type constant names take the following form:
  1061. gestalt<lineName><modelNumber>
  1062. Line Names
  1063. The following table contains the lines currently produced by Apple and the
  1064. lineName substrings associated with them:
  1065. Line lineName
  1066. ------------------------- ------------
  1067. Macintosh LC "MacLC"
  1068. Macintosh Performa "Performa"
  1069. Macintosh PowerBook "PowerBook"
  1070. Macintosh PowerBook Duo "PowerBookDuo"
  1071. Power Macintosh "PowerMac"
  1072. Apple Workgroup Server "AWS"
  1073. The following table contains lineNames for some discontinued lines:
  1074. Line lineName
  1075. ------------------------- ------------
  1076. Macintosh Quadra "MacQuadra" (preferred)
  1077. "Quadra" (also used, but not preferred)
  1078. Macintosh Centris "MacCentris"
  1079. Model Numbers
  1080. The modelNumber is a string representing the specific model of the machine
  1081. within its particular line. For example, for the Power Macintosh 8100/80,
  1082. the modelNumber is "8100".
  1083. Some Performa & LC model numbers contain variations in the rightmost 1 or 2
  1084. digits to indicate different RAM and Hard Disk configurations. A single
  1085. machine type is assigned for all variations of a specific model number. In
  1086. this case, the modelNumber string consists of the constant leftmost part
  1087. of the model number with 0s for the variant digits. For example, the
  1088. Performa 6115 and Performa 6116 are both return the same machine type
  1089. constant: gestaltPerforma6100.
  1090. OLD NAMING CONVENTIONS
  1091. The "Underscore Speed" suffix
  1092. In the past, Apple differentiated between machines that had the same model
  1093. number but different speeds. For example, the Power Macintosh 8100/80 and
  1094. Power Macintosh 8100/100 return different machine type constants. This is
  1095. why some existing machine type constant names take the form:
  1096. gestalt<lineName><modelNumber>_<speed>
  1097. e.g.
  1098. gestaltPowerMac8100_110
  1099. gestaltPowerMac7100_80
  1100. gestaltPowerMac7100_66
  1101. It is no longer necessary to use the "underscore speed" suffix. Starting with
  1102. the Power Surge machines (Power Macintosh 7200, 7500, 8500 and 9500), speed is
  1103. no longer used to differentiate between machine types. This is why a Power
  1104. Macintosh 7200/75 and a Power Macintosh 7200/90 return the same machine type
  1105. constant: gestaltPowerMac7200.
  1106. The "Screen Type" suffix
  1107. All PowerBook models prior to the PowerBook 190, and all PowerBook Duo models
  1108. before the PowerBook Duo 2300 take the form:
  1109. gestalt<lineName><modelNumber><screenType>
  1110. Where <screenType> is "c" or the empty string.
  1111. e.g.
  1112. gestaltPowerBook100
  1113. gestaltPowerBookDuo280
  1114. gestaltPowerBookDuo280c
  1115. gestaltPowerBook180
  1116. gestaltPowerBook180c
  1117. Starting with the PowerBook 190 series and the PowerBook Duo 2300 series, machine
  1118. types are no longer differentiated based on screen type. This is why a PowerBook
  1119. 5300cs/100 and a PowerBook 5300c/100 both return the same machine type constant:
  1120. gestaltPowerBook5300.
  1121. Macintosh LC 630 gestaltMacLC630
  1122. Macintosh Performa 6200 gestaltPerforma6200
  1123. Macintosh Quadra 700 gestaltQuadra700
  1124. Macintosh PowerBook 5300 gestaltPowerBook5300
  1125. Macintosh PowerBook Duo 2300 gestaltPowerBookDuo2300
  1126. Power Macintosh 8500 gestaltPowerMac8500
  1127. }
  1128. const
  1129. gestaltMachineType = FourCharCode('mach'); { machine type }
  1130. gestaltClassic = 1;
  1131. gestaltMacXL = 2;
  1132. gestaltMac512KE = 3;
  1133. gestaltMacPlus = 4;
  1134. gestaltMacSE = 5;
  1135. gestaltMacII = 6;
  1136. gestaltMacIIx = 7;
  1137. gestaltMacIIcx = 8;
  1138. gestaltMacSE030 = 9;
  1139. gestaltPortable = 10;
  1140. gestaltMacIIci = 11;
  1141. gestaltPowerMac8100_120 = 12;
  1142. gestaltMacIIfx = 13;
  1143. gestaltMacClassic = 17;
  1144. gestaltMacIIsi = 18;
  1145. gestaltMacLC = 19;
  1146. gestaltMacQuadra900 = 20;
  1147. gestaltPowerBook170 = 21;
  1148. gestaltMacQuadra700 = 22;
  1149. gestaltClassicII = 23;
  1150. gestaltPowerBook100 = 24;
  1151. gestaltPowerBook140 = 25;
  1152. gestaltMacQuadra950 = 26;
  1153. gestaltMacLCIII = 27;
  1154. gestaltPerforma450 = gestaltMacLCIII;
  1155. gestaltPowerBookDuo210 = 29;
  1156. gestaltMacCentris650 = 30;
  1157. gestaltPowerBookDuo230 = 32;
  1158. gestaltPowerBook180 = 33;
  1159. gestaltPowerBook160 = 34;
  1160. gestaltMacQuadra800 = 35;
  1161. gestaltMacQuadra650 = 36;
  1162. gestaltMacLCII = 37;
  1163. gestaltPowerBookDuo250 = 38;
  1164. gestaltAWS9150_80 = 39;
  1165. gestaltPowerMac8100_110 = 40;
  1166. gestaltAWS8150_110 = gestaltPowerMac8100_110;
  1167. gestaltPowerMac5200 = 41;
  1168. gestaltPowerMac5260 = gestaltPowerMac5200;
  1169. gestaltPerforma5300 = gestaltPowerMac5200;
  1170. gestaltPowerMac6200 = 42;
  1171. gestaltPerforma6300 = gestaltPowerMac6200;
  1172. gestaltMacIIvi = 44;
  1173. gestaltMacIIvm = 45;
  1174. gestaltPerforma600 = gestaltMacIIvm;
  1175. gestaltPowerMac7100_80 = 47;
  1176. gestaltMacIIvx = 48;
  1177. gestaltMacColorClassic = 49;
  1178. gestaltPerforma250 = gestaltMacColorClassic;
  1179. gestaltPowerBook165c = 50;
  1180. gestaltMacCentris610 = 52;
  1181. gestaltMacQuadra610 = 53;
  1182. gestaltPowerBook145 = 54;
  1183. gestaltPowerMac8100_100 = 55;
  1184. gestaltMacLC520 = 56;
  1185. gestaltAWS9150_120 = 57;
  1186. gestaltPowerMac6400 = 58;
  1187. gestaltPerforma6400 = gestaltPowerMac6400;
  1188. gestaltPerforma6360 = gestaltPerforma6400;
  1189. gestaltMacCentris660AV = 60;
  1190. gestaltMacQuadra660AV = gestaltMacCentris660AV;
  1191. gestaltPerforma46x = 62;
  1192. gestaltPowerMac8100_80 = 65;
  1193. gestaltAWS8150_80 = gestaltPowerMac8100_80;
  1194. gestaltPowerMac9500 = 67;
  1195. gestaltPowerMac9600 = gestaltPowerMac9500;
  1196. gestaltPowerMac7500 = 68;
  1197. gestaltPowerMac7600 = gestaltPowerMac7500;
  1198. gestaltPowerMac8500 = 69;
  1199. gestaltPowerMac8600 = gestaltPowerMac8500;
  1200. gestaltAWS8550 = gestaltPowerMac7500;
  1201. gestaltPowerBook180c = 71;
  1202. gestaltPowerBook520 = 72;
  1203. gestaltPowerBook520c = gestaltPowerBook520;
  1204. gestaltPowerBook540 = gestaltPowerBook520;
  1205. gestaltPowerBook540c = gestaltPowerBook520;
  1206. gestaltPowerMac5400 = 74;
  1207. gestaltPowerMac6100_60 = 75;
  1208. gestaltAWS6150_60 = gestaltPowerMac6100_60;
  1209. gestaltPowerBookDuo270c = 77;
  1210. gestaltMacQuadra840AV = 78;
  1211. gestaltPerforma550 = 80;
  1212. gestaltPowerBook165 = 84;
  1213. gestaltPowerBook190 = 85;
  1214. gestaltMacTV = 88;
  1215. gestaltMacLC475 = 89;
  1216. gestaltPerforma47x = gestaltMacLC475;
  1217. gestaltMacLC575 = 92;
  1218. gestaltMacQuadra605 = 94;
  1219. gestaltMacQuadra630 = 98;
  1220. gestaltMacLC580 = 99;
  1221. gestaltPerforma580 = gestaltMacLC580;
  1222. gestaltPowerMac6100_66 = 100;
  1223. gestaltAWS6150_66 = gestaltPowerMac6100_66;
  1224. gestaltPowerBookDuo280 = 102;
  1225. gestaltPowerBookDuo280c = 103;
  1226. gestaltPowerMacLC475 = 104; { Mac LC 475 & PPC Processor Upgrade Card}
  1227. gestaltPowerMacPerforma47x = gestaltPowerMacLC475;
  1228. gestaltPowerMacLC575 = 105; { Mac LC 575 & PPC Processor Upgrade Card }
  1229. gestaltPowerMacPerforma57x = gestaltPowerMacLC575;
  1230. gestaltPowerMacQuadra630 = 106; { Quadra 630 & PPC Processor Upgrade Card}
  1231. gestaltPowerMacLC630 = gestaltPowerMacQuadra630; { Mac LC 630 & PPC Processor Upgrade Card}
  1232. gestaltPowerMacPerforma63x = gestaltPowerMacQuadra630; { Performa 63x & PPC Processor Upgrade Card}
  1233. gestaltPowerMac7200 = 108;
  1234. gestaltPowerMac7300 = 109;
  1235. gestaltPowerMac7100_66 = 112;
  1236. gestaltPowerBook150 = 115;
  1237. gestaltPowerMacQuadra700 = 116; { Quadra 700 & Power PC Upgrade Card}
  1238. gestaltPowerMacQuadra900 = 117; { Quadra 900 & Power PC Upgrade Card }
  1239. gestaltPowerMacQuadra950 = 118; { Quadra 950 & Power PC Upgrade Card }
  1240. gestaltPowerMacCentris610 = 119; { Centris 610 & Power PC Upgrade Card }
  1241. gestaltPowerMacCentris650 = 120; { Centris 650 & Power PC Upgrade Card }
  1242. gestaltPowerMacQuadra610 = 121; { Quadra 610 & Power PC Upgrade Card }
  1243. gestaltPowerMacQuadra650 = 122; { Quadra 650 & Power PC Upgrade Card }
  1244. gestaltPowerMacQuadra800 = 123; { Quadra 800 & Power PC Upgrade Card }
  1245. gestaltPowerBookDuo2300 = 124;
  1246. gestaltPowerBook500PPCUpgrade = 126;
  1247. gestaltPowerBook5300 = 128;
  1248. gestaltPowerBook1400 = 310;
  1249. gestaltPowerBook3400 = 306;
  1250. gestaltPowerBook2400 = 307;
  1251. gestaltPowerBookG3Series = 312;
  1252. gestaltPowerBookG3 = 313;
  1253. gestaltPowerBookG3Series2 = 314;
  1254. gestaltPowerMacNewWorld = 406; { All NewWorld architecture Macs (iMac, blue G3, etc.)}
  1255. gestaltPowerMacG3 = 510;
  1256. gestaltPowerMac5500 = 512;
  1257. gestalt20thAnniversary = gestaltPowerMac5500;
  1258. gestaltPowerMac6500 = 513;
  1259. gestaltPowerMac4400_160 = 514; { slower machine has different machine ID}
  1260. gestaltPowerMac4400 = 515;
  1261. gestaltMacOSCompatibility = 1206; { Mac OS Compatibility on Mac OS X (Classic)}
  1262. const
  1263. gestaltQuadra605 = gestaltMacQuadra605;
  1264. gestaltQuadra610 = gestaltMacQuadra610;
  1265. gestaltQuadra630 = gestaltMacQuadra630;
  1266. gestaltQuadra650 = gestaltMacQuadra650;
  1267. gestaltQuadra660AV = gestaltMacQuadra660AV;
  1268. gestaltQuadra700 = gestaltMacQuadra700;
  1269. gestaltQuadra800 = gestaltMacQuadra800;
  1270. gestaltQuadra840AV = gestaltMacQuadra840AV;
  1271. gestaltQuadra900 = gestaltMacQuadra900;
  1272. gestaltQuadra950 = gestaltMacQuadra950;
  1273. const
  1274. kMachineNameStrID = -16395;
  1275. const
  1276. gestaltSMPMailerVersion = FourCharCode('malr'); { OCE StandardMail}
  1277. const
  1278. gestaltMediaBay = FourCharCode('mbeh'); { media bay driver type }
  1279. gestaltMBLegacy = 0; { media bay support in PCCard 2.0 }
  1280. gestaltMBSingleBay = 1; { single bay media bay driver }
  1281. gestaltMBMultipleBays = 2; { multi-bay media bay driver }
  1282. const
  1283. gestaltMessageMgrVersion = FourCharCode('mess'); { GX Printing Message Manager Gestalt Selector }
  1284. { Menu Manager Gestalt (Mac OS 8.5 and later)}
  1285. const
  1286. gestaltMenuMgrAttr = FourCharCode('menu'); { If this Gestalt exists, the Mac OS 8.5 Menu Manager is installed }
  1287. gestaltMenuMgrPresent = 1 shl 0; { NOTE: this is a bit mask, whereas all other Gestalt constants of this nature }
  1288. { are bit index values. 3.2 interfaces slipped out with this mistake unnoticed. }
  1289. { Sincere apologies for any inconvenience.}
  1290. gestaltMenuMgrPresentBit = 0; { bit number }
  1291. gestaltMenuMgrAquaLayoutBit = 1; { menus have the Aqua 1.0 layout}
  1292. gestaltMenuMgrMultipleItemsWithCommandIDBit = 2; { CountMenuItemsWithCommandID/GetIndMenuItemWithCommandID support multiple items with the same command ID}
  1293. gestaltMenuMgrRetainsIconRefBit = 3; { SetMenuItemIconHandle, when passed an IconRef, calls AcquireIconRef}
  1294. gestaltMenuMgrSendsMenuBoundsToDefProcBit = 4; { kMenuSizeMsg and kMenuPopUpMsg have menu bounding rect information}
  1295. gestaltMenuMgrMoreThanFiveMenusDeepBit = 5; { the Menu Manager supports hierarchical menus more than five deep}
  1296. gestaltMenuMgrCGImageMenuTitleBit = 6; { SetMenuTitleIcon supports CGImageRefs}
  1297. { masks for the above bits}
  1298. gestaltMenuMgrPresentMask = 1 shl gestaltMenuMgrPresentBit;
  1299. gestaltMenuMgrAquaLayoutMask = 1 shl gestaltMenuMgrAquaLayoutBit;
  1300. gestaltMenuMgrMultipleItemsWithCommandIDMask = 1 shl gestaltMenuMgrMultipleItemsWithCommandIDBit;
  1301. gestaltMenuMgrRetainsIconRefMask = 1 shl gestaltMenuMgrRetainsIconRefBit;
  1302. gestaltMenuMgrSendsMenuBoundsToDefProcMask = 1 shl gestaltMenuMgrSendsMenuBoundsToDefProcBit;
  1303. gestaltMenuMgrMoreThanFiveMenusDeepMask = 1 shl gestaltMenuMgrMoreThanFiveMenusDeepBit;
  1304. gestaltMenuMgrCGImageMenuTitleMask = 1 shl gestaltMenuMgrCGImageMenuTitleBit;
  1305. const
  1306. gestaltMultipleUsersState = FourCharCode('mfdr'); { Gestalt selector returns MultiUserGestaltHandle (in Folders.h)}
  1307. const
  1308. gestaltMachineIcon = FourCharCode('micn'); { machine icon }
  1309. const
  1310. gestaltMiscAttr = FourCharCode('misc'); { miscellaneous attributes }
  1311. gestaltScrollingThrottle = 0; { true if scrolling throttle on }
  1312. gestaltSquareMenuBar = 2; { true if menu bar is square }
  1313. {
  1314. The name gestaltMixedModeVersion for the 'mixd' selector is semantically incorrect.
  1315. The same selector has been renamed gestaltMixedModeAttr to properly reflect the
  1316. Inside Mac: PowerPC System Software documentation. The gestaltMixedModeVersion
  1317. symbol has been preserved only for backwards compatibility.
  1318. Developers are forewarned that gestaltMixedModeVersion has a limited lifespan and
  1319. will be removed in a future release of the Interfaces.
  1320. For the first version of Mixed Mode, both meanings of the 'mixd' selector are
  1321. functionally identical. They both return 0x00000001. In subsequent versions
  1322. of Mixed Mode, however, the 'mixd' selector will not respond with an increasing
  1323. version number, but rather, with 32 attribute bits with various meanings.
  1324. }
  1325. const
  1326. gestaltMixedModeVersion = FourCharCode('mixd'); { returns version of Mixed Mode }
  1327. const
  1328. gestaltMixedModeAttr = FourCharCode('mixd'); { returns Mixed Mode attributes }
  1329. gestaltMixedModePowerPC = 0; { true if Mixed Mode supports PowerPC ABI calling conventions }
  1330. gestaltPowerPCAware = 0; { old name for gestaltMixedModePowerPC }
  1331. gestaltMixedModeCFM68K = 1; { true if Mixed Mode supports CFM-68K calling conventions }
  1332. gestaltMixedModeCFM68KHasTrap = 2; { true if CFM-68K Mixed Mode implements _MixedModeDispatch (versions 1.0.1 and prior did not) }
  1333. gestaltMixedModeCFM68KHasState = 3; { true if CFM-68K Mixed Mode exports Save/RestoreMixedModeState }
  1334. const
  1335. gestaltQuickTimeConferencing = FourCharCode('mtlk'); { returns QuickTime Conferencing version }
  1336. const
  1337. gestaltMemoryMapAttr = FourCharCode('mmap'); { Memory map type }
  1338. gestaltMemoryMapSparse = 0; { Sparse memory is on }
  1339. const
  1340. gestaltMMUType = FourCharCode('mmu '); { mmu type }
  1341. gestaltNoMMU = 0; { no MMU }
  1342. gestaltAMU = 1; { address management unit }
  1343. gestalt68851 = 2; { 68851 PMMU }
  1344. gestalt68030MMU = 3; { 68030 built-in MMU }
  1345. gestalt68040MMU = 4; { 68040 built-in MMU }
  1346. gestaltEMMU1 = 5; { Emulated MMU type 1 }
  1347. const
  1348. { On Mac OS X, the user visible machine name may something like "PowerMac3,4", which is}
  1349. { a unique string for each signifigant Macintosh computer which Apple creates, but is}
  1350. { not terribly useful as a user visible string.}
  1351. gestaltUserVisibleMachineName = FourCharCode('mnam'); { Coerce response into a StringPtr to get a user visible machine name }
  1352. const
  1353. gestaltMPCallableAPIsAttr = FourCharCode('mpsc'); { Bitmap of toolbox/OS managers that can be called from MPLibrary MPTasks }
  1354. gestaltMPFileManager = 0; { True if File Manager calls can be made from MPTasks }
  1355. gestaltMPDeviceManager = 1; { True if synchronous Device Manager calls can be made from MPTasks }
  1356. gestaltMPTrapCalls = 2; { True if most trap-based calls can be made from MPTasks }
  1357. const
  1358. gestaltStdNBPAttr = FourCharCode('nlup'); { standard nbp attributes }
  1359. gestaltStdNBPPresent = 0;
  1360. gestaltStdNBPSupportsAutoPosition = 1; { StandardNBP takes (-1,-1) to mean alert position main screen }
  1361. const
  1362. gestaltNotificationMgrAttr = FourCharCode('nmgr'); { notification manager attributes }
  1363. gestaltNotificationPresent = 0; { notification manager exists }
  1364. const
  1365. gestaltNameRegistryVersion = FourCharCode('nreg'); { NameRegistryLib version number, for System 7.5.2+ usage }
  1366. const
  1367. gestaltNuBusSlotCount = FourCharCode('nubs'); { count of logical NuBus slots present }
  1368. const
  1369. gestaltOCEToolboxVersion = FourCharCode('ocet'); { OCE Toolbox version }
  1370. gestaltOCETB = $0102; { OCE Toolbox version 1.02 }
  1371. gestaltSFServer = $0100; { S&F Server version 1.0 }
  1372. const
  1373. gestaltOCEToolboxAttr = FourCharCode('oceu'); { OCE Toolbox attributes }
  1374. gestaltOCETBPresent = $01; { OCE toolbox is present, not running }
  1375. gestaltOCETBAvailable = $02; { OCE toolbox is running and available }
  1376. gestaltOCESFServerAvailable = $04; { S&F Server is running and available }
  1377. gestaltOCETBNativeGlueAvailable = $10; { Native PowerPC Glue routines are availible }
  1378. const
  1379. gestaltOpenFirmwareInfo = FourCharCode('opfw'); { Open Firmware info }
  1380. const
  1381. gestaltOSAttr = FourCharCode('os '); { o/s attributes }
  1382. gestaltSysZoneGrowable = 0; { system heap is growable }
  1383. gestaltLaunchCanReturn = 1; { can return from launch }
  1384. gestaltLaunchFullFileSpec = 2; { can launch from full file spec }
  1385. gestaltLaunchControl = 3; { launch control support available }
  1386. gestaltTempMemSupport = 4; { temp memory support }
  1387. gestaltRealTempMemory = 5; { temp memory handles are real }
  1388. gestaltTempMemTracked = 6; { temporary memory handles are tracked }
  1389. gestaltIPCSupport = 7; { IPC support is present }
  1390. gestaltSysDebuggerSupport = 8; { system debugger support is present }
  1391. gestaltNativeProcessMgrBit = 19; { the process manager itself is native }
  1392. gestaltAltivecRegistersSwappedCorrectlyBit = 20; { Altivec registers are saved correctly on process switches }
  1393. const
  1394. gestaltOSTable = FourCharCode('ostt'); { OS trap table base }
  1395. {******************************************************************************
  1396. * Gestalt Selectors for Open Transport Network Setup
  1397. *
  1398. * Note: possible values for the version "stage" byte are:
  1399. * development = 0x20, alpha = 0x40, beta = 0x60, final & release = 0x80
  1400. *******************************************************************************}
  1401. const
  1402. gestaltOpenTptNetworkSetup = FourCharCode('otcf');
  1403. gestaltOpenTptNetworkSetupLegacyImport = 0;
  1404. gestaltOpenTptNetworkSetupLegacyExport = 1;
  1405. gestaltOpenTptNetworkSetupSupportsMultihoming = 2;
  1406. const
  1407. gestaltOpenTptNetworkSetupVersion = FourCharCode('otcv');
  1408. {******************************************************************************
  1409. * Gestalt Selectors for Open Transport-based Remote Access/PPP
  1410. *
  1411. * Note: possible values for the version "stage" byte are:
  1412. * development = 0x20, alpha = 0x40, beta = 0x60, final & release = 0x80
  1413. *******************************************************************************}
  1414. const
  1415. gestaltOpenTptRemoteAccess = FourCharCode('otra');
  1416. gestaltOpenTptRemoteAccessPresent = 0;
  1417. gestaltOpenTptRemoteAccessLoaded = 1;
  1418. gestaltOpenTptRemoteAccessClientOnly = 2;
  1419. gestaltOpenTptRemoteAccessPServer = 3;
  1420. gestaltOpenTptRemoteAccessMPServer = 4;
  1421. gestaltOpenTptPPPPresent = 5;
  1422. gestaltOpenTptARAPPresent = 6;
  1423. const
  1424. gestaltOpenTptRemoteAccessVersion = FourCharCode('otrv');
  1425. { ***** Open Transport Gestalt *****}
  1426. const
  1427. gestaltOpenTptVersions = FourCharCode('otvr'); { Defined by OT 1.1 and higher, response is NumVersion.}
  1428. const
  1429. gestaltOpenTpt = FourCharCode('otan'); { Defined by all versions, response is defined below.}
  1430. gestaltOpenTptPresentMask = $00000001;
  1431. gestaltOpenTptLoadedMask = $00000002;
  1432. gestaltOpenTptAppleTalkPresentMask = $00000004;
  1433. gestaltOpenTptAppleTalkLoadedMask = $00000008;
  1434. gestaltOpenTptTCPPresentMask = $00000010;
  1435. gestaltOpenTptTCPLoadedMask = $00000020;
  1436. gestaltOpenTptIPXSPXPresentMask = $00000040;
  1437. gestaltOpenTptIPXSPXLoadedMask = $00000080;
  1438. gestaltOpenTptPresentBit = 0;
  1439. gestaltOpenTptLoadedBit = 1;
  1440. gestaltOpenTptAppleTalkPresentBit = 2;
  1441. gestaltOpenTptAppleTalkLoadedBit = 3;
  1442. gestaltOpenTptTCPPresentBit = 4;
  1443. gestaltOpenTptTCPLoadedBit = 5;
  1444. gestaltOpenTptIPXSPXPresentBit = 6;
  1445. gestaltOpenTptIPXSPXLoadedBit = 7;
  1446. const
  1447. gestaltPCCard = FourCharCode('pccd'); { PC Card attributes}
  1448. gestaltCardServicesPresent = 0; { PC Card 2.0 (68K) API is present}
  1449. gestaltPCCardFamilyPresent = 1; { PC Card 3.x (PowerPC) API is present}
  1450. gestaltPCCardHasPowerControl = 2; { PCCardSetPowerLevel is supported}
  1451. gestaltPCCardSupportsCardBus = 3; { CardBus is supported}
  1452. const
  1453. gestaltProcClkSpeed = FourCharCode('pclk'); { processor clock speed in hertz (a UInt32) }
  1454. const
  1455. gestaltProcClkSpeedMHz = FourCharCode('mclk'); { processor clock speed in megahertz (a UInt32) }
  1456. const
  1457. gestaltPCXAttr = FourCharCode('pcxg'); { PC Exchange attributes }
  1458. gestaltPCXHas8and16BitFAT = 0; { PC Exchange supports both 8 and 16 bit FATs }
  1459. gestaltPCXHasProDOS = 1; { PC Exchange supports ProDOS }
  1460. gestaltPCXNewUI = 2;
  1461. gestaltPCXUseICMapping = 3; { PC Exchange uses InternetConfig for file mappings }
  1462. const
  1463. gestaltLogicalPageSize = FourCharCode('pgsz'); { logical page size }
  1464. { System 7.6 and later. If gestaltScreenCaptureMain is not implemented,
  1465. PictWhap proceeds with screen capture in the usual way.
  1466. The high word of gestaltScreenCaptureMain is reserved (use 0).
  1467. To disable screen capture to disk, put zero in the low word. To
  1468. specify a folder for captured pictures, put the vRefNum in the
  1469. low word of gestaltScreenCaptureMain, and put the directory ID in
  1470. gestaltScreenCaptureDir.
  1471. }
  1472. const
  1473. gestaltScreenCaptureMain = FourCharCode('pic1'); { Zero, or vRefNum of disk to hold picture }
  1474. gestaltScreenCaptureDir = FourCharCode('pic2'); { Directory ID of folder to hold picture }
  1475. const
  1476. gestaltGXPrintingMgrVersion = FourCharCode('pmgr'); { QuickDraw GX Printing Manager Version}
  1477. const
  1478. gestaltPopupAttr = FourCharCode('pop!'); { popup cdef attributes }
  1479. gestaltPopupPresent = 0;
  1480. const
  1481. gestaltPowerMgrAttr = FourCharCode('powr'); { power manager attributes }
  1482. gestaltPMgrExists = 0;
  1483. gestaltPMgrCPUIdle = 1;
  1484. gestaltPMgrSCC = 2;
  1485. gestaltPMgrSound = 3;
  1486. gestaltPMgrDispatchExists = 4;
  1487. gestaltPMgrSupportsAVPowerStateAtSleepWake = 5;
  1488. const
  1489. gestaltPowerMgrVers = FourCharCode('pwrv'); { power manager version }
  1490. {
  1491. * PPC will return the combination of following bit fields.
  1492. * e.g. gestaltPPCSupportsRealTime +gestaltPPCSupportsIncoming + gestaltPPCSupportsOutGoing
  1493. * indicates PPC is cuurently is only supports real time delivery
  1494. * and both incoming and outgoing network sessions are allowed.
  1495. * By default local real time delivery is supported as long as PPCInit has been called.}
  1496. const
  1497. gestaltPPCToolboxAttr = FourCharCode('ppc '); { PPC toolbox attributes }
  1498. gestaltPPCToolboxPresent = $0000; { PPC Toolbox is present Requires PPCInit to be called }
  1499. gestaltPPCSupportsRealTime = $1000; { PPC Supports real-time delivery }
  1500. gestaltPPCSupportsIncoming = $0001; { PPC will allow incoming network requests }
  1501. gestaltPPCSupportsOutGoing = $0002; { PPC will allow outgoing network requests }
  1502. gestaltPPCSupportsTCP_IP = $0004; { PPC supports TCP/IP transport }
  1503. gestaltPPCSupportsIncomingAppleTalk = $0010;
  1504. gestaltPPCSupportsIncomingTCP_IP = $0020;
  1505. gestaltPPCSupportsOutgoingAppleTalk = $0100;
  1506. gestaltPPCSupportsOutgoingTCP_IP = $0200;
  1507. {
  1508. Programs which need to know information about particular features of the processor should
  1509. migrate to using sysctl() and sysctlbyname() to get this kind of information. No new
  1510. information will be added to the 'ppcf' selector going forward.
  1511. }
  1512. const
  1513. gestaltPowerPCProcessorFeatures = FourCharCode('ppcf'); { Optional PowerPC processor features }
  1514. gestaltPowerPCHasGraphicsInstructions = 0; { has fres, frsqrte, and fsel instructions }
  1515. gestaltPowerPCHasSTFIWXInstruction = 1; { has stfiwx instruction }
  1516. gestaltPowerPCHasSquareRootInstructions = 2; { has fsqrt and fsqrts instructions }
  1517. gestaltPowerPCHasDCBAInstruction = 3; { has dcba instruction }
  1518. gestaltPowerPCHasVectorInstructions = 4; { has vector instructions }
  1519. gestaltPowerPCHasDataStreams = 5; { has dst, dstt, dstst, dss, and dssall instructions }
  1520. gestaltPowerPCHas64BitSupport = 6; { double word LSU/ALU, etc. }
  1521. gestaltPowerPCHasDCBTStreams = 7; { TH field of DCBT recognized }
  1522. gestaltPowerPCASArchitecture = 8; { chip uses new 'A/S' architecture }
  1523. gestaltPowerPCIgnoresDCBST = 9; { }
  1524. const
  1525. gestaltProcessorType = FourCharCode('proc'); { processor type }
  1526. gestalt68000 = 1;
  1527. gestalt68010 = 2;
  1528. gestalt68020 = 3;
  1529. gestalt68030 = 4;
  1530. gestalt68040 = 5;
  1531. const
  1532. gestaltSDPPromptVersion = FourCharCode('prpv'); { OCE Standard Directory Panel}
  1533. const
  1534. gestaltParityAttr = FourCharCode('prty'); { parity attributes }
  1535. gestaltHasParityCapability = 0; { has ability to check parity }
  1536. gestaltParityEnabled = 1; { parity checking enabled }
  1537. const
  1538. gestaltQD3DVersion = FourCharCode('q3v '); { Quickdraw 3D version in pack BCD}
  1539. const
  1540. gestaltQD3DViewer = FourCharCode('q3vc'); { Quickdraw 3D viewer attributes}
  1541. gestaltQD3DViewerPresent = 0; { bit 0 set if QD3D Viewer is available}
  1542. {$ifc OLDROUTINENAMES}
  1543. const
  1544. gestaltQD3DViewerNotPresent = 0 shl gestaltQD3DViewerPresent;
  1545. gestaltQD3DViewerAvailable = 1 shl gestaltQD3DViewerPresent;
  1546. {$endc} {OLDROUTINENAMES}
  1547. const
  1548. gestaltQuickdrawVersion = FourCharCode('qd '); { quickdraw version }
  1549. gestaltOriginalQD = $0000; { original 1-bit QD }
  1550. gestalt8BitQD = $0100; { 8-bit color QD }
  1551. gestalt32BitQD = $0200; { 32-bit color QD }
  1552. gestalt32BitQD11 = $0201; { 32-bit color QDv1.1 }
  1553. gestalt32BitQD12 = $0220; { 32-bit color QDv1.2 }
  1554. gestalt32BitQD13 = $0230; { 32-bit color QDv1.3 }
  1555. gestaltAllegroQD = $0250; { Allegro QD OS 8.5 }
  1556. gestaltMacOSXQD = $0300; { 0x310, 0x320 etc. for 10.x.y }
  1557. const
  1558. gestaltQD3D = FourCharCode('qd3d'); { Quickdraw 3D attributes}
  1559. gestaltQD3DPresent = 0; { bit 0 set if QD3D available}
  1560. {$ifc OLDROUTINENAMES}
  1561. const
  1562. gestaltQD3DNotPresent = 0 shl gestaltQD3DPresent;
  1563. gestaltQD3DAvailable = 1 shl gestaltQD3DPresent;
  1564. {$endc} {OLDROUTINENAMES}
  1565. const
  1566. gestaltGXVersion = FourCharCode('qdgx'); { Overall QuickDraw GX Version}
  1567. const
  1568. gestaltQuickdrawFeatures = FourCharCode('qdrw'); { quickdraw features }
  1569. gestaltHasColor = 0; { color quickdraw present }
  1570. gestaltHasDeepGWorlds = 1; { GWorlds can be deeper than 1-bit }
  1571. gestaltHasDirectPixMaps = 2; { PixMaps can be direct (16 or 32 bit) }
  1572. gestaltHasGrayishTextOr = 3; { supports text mode grayishTextOr }
  1573. gestaltSupportsMirroring = 4; { Supports video mirroring via the Display Manager. }
  1574. gestaltQDHasLongRowBytes = 5; { Long rowBytes supported in GWorlds }
  1575. const
  1576. gestaltQDTextVersion = FourCharCode('qdtx'); { QuickdrawText version }
  1577. gestaltOriginalQDText = $0000; { up to and including 8.1 }
  1578. gestaltAllegroQDText = $0100; { starting with 8.5 }
  1579. gestaltMacOSXQDText = $0200; { we are in Mac OS X }
  1580. const
  1581. gestaltQDTextFeatures = FourCharCode('qdtf'); { QuickdrawText features }
  1582. gestaltWSIISupport = 0; { bit 0: WSII support included }
  1583. gestaltSbitFontSupport = 1; { sbit-only fonts supported }
  1584. gestaltAntiAliasedTextAvailable = 2; { capable of antialiased text }
  1585. gestaltOFA2available = 3; { OFA2 available }
  1586. gestaltCreatesAliasFontRsrc = 4; { "real" datafork font support }
  1587. gestaltNativeType1FontSupport = 5; { we have scaler for Type1 fonts }
  1588. gestaltCanUseCGTextRendering = 6;
  1589. const
  1590. gestaltQuickTimeConferencingInfo = FourCharCode('qtci'); { returns pointer to QuickTime Conferencing information }
  1591. const
  1592. gestaltQuickTimeVersion = FourCharCode('qtim'); { returns version of QuickTime }
  1593. gestaltQuickTime = FourCharCode('qtim'); { gestaltQuickTime is old name for gestaltQuickTimeVersion }
  1594. const
  1595. gestaltQuickTimeFeatures = FourCharCode('qtrs');
  1596. gestaltPPCQuickTimeLibPresent = 0; { PowerPC QuickTime glue library is present }
  1597. const
  1598. gestaltQuickTimeStreamingFeatures = FourCharCode('qtsf');
  1599. const
  1600. gestaltQuickTimeStreamingVersion = FourCharCode('qtst');
  1601. const
  1602. gestaltQuickTimeThreadSafeFeaturesAttr = FourCharCode('qtth'); { Quicktime thread safety attributes }
  1603. gestaltQuickTimeThreadSafeICM = 0;
  1604. gestaltQuickTimeThreadSafeMovieToolbox = 1;
  1605. gestaltQuickTimeThreadSafeMovieImport = 2;
  1606. gestaltQuickTimeThreadSafeMovieExport = 3;
  1607. gestaltQuickTimeThreadSafeGraphicsImport = 4;
  1608. gestaltQuickTimeThreadSafeGraphicsExport = 5;
  1609. gestaltQuickTimeThreadSafeMoviePlayback = 6;
  1610. const
  1611. gestaltQTVRMgrAttr = FourCharCode('qtvr'); { QuickTime VR attributes }
  1612. gestaltQTVRMgrPresent = 0; { QTVR API is present }
  1613. gestaltQTVRObjMoviesPresent = 1; { QTVR runtime knows about object movies }
  1614. gestaltQTVRCylinderPanosPresent = 2; { QTVR runtime knows about cylindrical panoramic movies }
  1615. gestaltQTVRCubicPanosPresent = 3; { QTVR runtime knows about cubic panoramic movies }
  1616. const
  1617. gestaltQTVRMgrVers = FourCharCode('qtvv'); { QuickTime VR version }
  1618. {
  1619. Because some PowerPC machines now support very large physical memory capacities, including
  1620. some above the maximum value which can held in a 32 bit quantity, there is now a new selector,
  1621. gestaltPhysicalRAMSizeInMegabytes, which returns the size of physical memory scaled
  1622. in megabytes. It is recommended that code transition to using this new selector if
  1623. it wants to get a useful value for the amount of physical memory on the system. Code can
  1624. also use the sysctl() and sysctlbyname() BSD calls to get these kinds of values.
  1625. For compatability with code which assumed that the value in returned by the
  1626. gestaltPhysicalRAMSize selector would be a signed quantity of bytes, this selector will
  1627. now return 2 gigabytes-1 ( INT_MAX ) if the system has 2 gigabytes of physical memory or more.
  1628. }
  1629. const
  1630. gestaltPhysicalRAMSize = FourCharCode('ram '); { physical RAM size, in bytes }
  1631. const
  1632. gestaltPhysicalRAMSizeInMegabytes = FourCharCode('ramm'); { physical RAM size, scaled in megabytes }
  1633. const
  1634. gestaltRBVAddr = FourCharCode('rbv '); { RBV base address }
  1635. const
  1636. gestaltROMSize = FourCharCode('rom '); { rom size }
  1637. const
  1638. gestaltROMVersion = FourCharCode('romv'); { rom version }
  1639. const
  1640. gestaltResourceMgrAttr = FourCharCode('rsrc'); { Resource Mgr attributes }
  1641. gestaltPartialRsrcs = 0; { True if partial resources exist }
  1642. gestaltHasResourceOverrides = 1; { Appears in the ROM; so put it here. }
  1643. const
  1644. gestaltResourceMgrBugFixesAttrs = FourCharCode('rmbg'); { Resource Mgr bug fixes }
  1645. gestaltRMForceSysHeapRolledIn = 0;
  1646. gestaltRMFakeAppleMenuItemsRolledIn = 1;
  1647. gestaltSanityCheckResourceFiles = 2; { Resource manager does sanity checking on resource files before opening them }
  1648. gestaltSupportsFSpResourceFileAlreadyOpenBit = 3; { The resource manager supports GetResFileRefNum and FSpGetResFileRefNum and FSpResourceFileAlreadyOpen }
  1649. gestaltRMSupportsFSCalls = 4; { The resource manager supports OpenResFileFSRef, CreateResFileFSRef and ResourceFileAlreadyOpenFSRef }
  1650. gestaltRMTypeIndexOrderingReverse = 8; { GetIndType() calls return resource types in opposite order to original 68k resource manager }
  1651. const
  1652. gestaltRealtimeMgrAttr = FourCharCode('rtmr'); { Realtime manager attributes }
  1653. gestaltRealtimeMgrPresent = 0; { true if the Realtime manager is present }
  1654. const
  1655. gestaltSafeOFAttr = FourCharCode('safe');
  1656. gestaltVMZerosPagesBit = 0;
  1657. gestaltInitHeapZerosOutHeapsBit = 1;
  1658. gestaltNewHandleReturnsZeroedMemoryBit = 2;
  1659. gestaltNewPtrReturnsZeroedMemoryBit = 3;
  1660. gestaltFileAllocationZeroedBlocksBit = 4;
  1661. const
  1662. gestaltSCCReadAddr = FourCharCode('sccr'); { scc read base address }
  1663. const
  1664. gestaltSCCWriteAddr = FourCharCode('sccw'); { scc read base address }
  1665. const
  1666. gestaltScrapMgrAttr = FourCharCode('scra'); { Scrap Manager attributes }
  1667. gestaltScrapMgrTranslationAware = 0; { True if scrap manager is translation aware }
  1668. const
  1669. gestaltScriptMgrVersion = FourCharCode('scri'); { Script Manager version number }
  1670. const
  1671. gestaltScriptCount = FourCharCode('scr#'); { number of active script systems }
  1672. const
  1673. gestaltSCSI = FourCharCode('scsi'); { SCSI Manager attributes }
  1674. gestaltAsyncSCSI = 0; { Supports Asynchronous SCSI }
  1675. gestaltAsyncSCSIINROM = 1; { Async scsi is in ROM (available for booting) }
  1676. gestaltSCSISlotBoot = 2; { ROM supports Slot-style PRAM for SCSI boots (PDM and later) }
  1677. gestaltSCSIPollSIH = 3; { SCSI Manager will poll for interrupts if Secondary Interrupts are busy. }
  1678. const
  1679. gestaltControlStripAttr = FourCharCode('sdev'); { Control Strip attributes }
  1680. gestaltControlStripExists = 0; { Control Strip is installed }
  1681. gestaltControlStripVersionFixed = 1; { Control Strip version Gestalt selector was fixed }
  1682. gestaltControlStripUserFont = 2; { supports user-selectable font/size }
  1683. gestaltControlStripUserHotKey = 3; { support user-selectable hot key to show/hide the window }
  1684. const
  1685. gestaltSDPStandardDirectoryVersion = FourCharCode('sdvr'); { OCE Standard Directory Panel}
  1686. const
  1687. gestaltSerialAttr = FourCharCode('ser '); { Serial attributes }
  1688. gestaltHasGPIaToDCDa = 0; { GPIa connected to DCDa}
  1689. gestaltHasGPIaToRTxCa = 1; { GPIa connected to RTxCa clock input}
  1690. gestaltHasGPIbToDCDb = 2; { GPIb connected to DCDb }
  1691. gestaltHidePortA = 3; { Modem port (A) should be hidden from users }
  1692. gestaltHidePortB = 4; { Printer port (B) should be hidden from users }
  1693. gestaltPortADisabled = 5; { Modem port (A) disabled and should not be used by SW }
  1694. gestaltPortBDisabled = 6; { Printer port (B) disabled and should not be used by SW }
  1695. const
  1696. gestaltShutdownAttributes = FourCharCode('shut'); { ShutDown Manager Attributes }
  1697. gestaltShutdownHassdOnBootVolUnmount = 0; { True if ShutDown Manager unmounts boot & VM volume at shutdown time. }
  1698. const
  1699. gestaltNuBusConnectors = FourCharCode('sltc'); { bitmap of NuBus connectors}
  1700. const
  1701. gestaltSlotAttr = FourCharCode('slot'); { slot attributes }
  1702. gestaltSlotMgrExists = 0; { true is slot mgr exists }
  1703. gestaltNuBusPresent = 1; { NuBus slots are present }
  1704. gestaltSESlotPresent = 2; { SE PDS slot present }
  1705. gestaltSE30SlotPresent = 3; { SE/30 slot present }
  1706. gestaltPortableSlotPresent = 4; { PortableÕs slot present }
  1707. const
  1708. gestaltFirstSlotNumber = FourCharCode('slt1'); { returns first physical slot }
  1709. const
  1710. gestaltSoundAttr = FourCharCode('snd '); { sound attributes }
  1711. gestaltStereoCapability = 0; { sound hardware has stereo capability }
  1712. gestaltStereoMixing = 1; { stereo mixing on external speaker }
  1713. gestaltSoundIOMgrPresent = 3; { The Sound I/O Manager is present }
  1714. gestaltBuiltInSoundInput = 4; { built-in Sound Input hardware is present }
  1715. gestaltHasSoundInputDevice = 5; { Sound Input device available }
  1716. gestaltPlayAndRecord = 6; { built-in hardware can play and record simultaneously }
  1717. gestalt16BitSoundIO = 7; { sound hardware can play and record 16-bit samples }
  1718. gestaltStereoInput = 8; { sound hardware can record stereo }
  1719. gestaltLineLevelInput = 9; { sound input port requires line level }
  1720. { the following bits are not defined prior to Sound Mgr 3.0 }
  1721. gestaltSndPlayDoubleBuffer = 10; { SndPlayDoubleBuffer available, set by Sound Mgr 3.0 and later }
  1722. gestaltMultiChannels = 11; { multiple channel support, set by Sound Mgr 3.0 and later }
  1723. gestalt16BitAudioSupport = 12; { 16 bit audio data supported, set by Sound Mgr 3.0 and later }
  1724. const
  1725. gestaltSplitOSAttr = FourCharCode('spos');
  1726. gestaltSplitOSBootDriveIsNetworkVolume = 0; { the boot disk is a network 'disk', from the .LANDisk drive. }
  1727. gestaltSplitOSAware = 1; { the system includes the code to deal with a split os situation. }
  1728. gestaltSplitOSEnablerVolumeIsDifferentFromBootVolume = 2; { the active enabler is on a different volume than the system file. }
  1729. gestaltSplitOSMachineNameSetToNetworkNameTemp = 3; { The machine name was set to the value given us from the BootP server }
  1730. gestaltSplitOSMachineNameStartupDiskIsNonPersistent = 5; { The startup disk ( vRefNum == -1 ) is non-persistent, meaning changes won't persist across a restart. }
  1731. const
  1732. gestaltSMPSPSendLetterVersion = FourCharCode('spsl'); { OCE StandardMail}
  1733. const
  1734. gestaltSpeechRecognitionAttr = FourCharCode('srta'); { speech recognition attributes }
  1735. gestaltDesktopSpeechRecognition = 1; { recognition thru the desktop microphone is available }
  1736. gestaltTelephoneSpeechRecognition = 2; { recognition thru the telephone is available }
  1737. const
  1738. gestaltSpeechRecognitionVersion = FourCharCode('srtb'); { speech recognition version (0x0150 is the first version that fully supports the API) }
  1739. const
  1740. gestaltSoftwareVendorCode = FourCharCode('srad'); { Returns system software vendor information }
  1741. gestaltSoftwareVendorApple = FourCharCode('Appl'); { System software sold by Apple }
  1742. gestaltSoftwareVendorLicensee = FourCharCode('Lcns'); { System software sold by licensee }
  1743. const
  1744. gestaltStandardFileAttr = FourCharCode('stdf'); { Standard File attributes }
  1745. gestaltStandardFile58 = 0; { True if selectors 5-8 (StandardPutFile-CustomGetFile) are supported }
  1746. gestaltStandardFileTranslationAware = 1; { True if standard file is translation manager aware }
  1747. gestaltStandardFileHasColorIcons = 2; { True if standard file has 16x16 color icons }
  1748. gestaltStandardFileUseGenericIcons = 3; { Standard file LDEF to use only the system generic icons if true }
  1749. gestaltStandardFileHasDynamicVolumeAllocation = 4; { True if standard file supports more than 20 volumes }
  1750. const
  1751. gestaltSysArchitecture = FourCharCode('sysa'); { Native System Architecture }
  1752. gestalt68k = 1; { Motorola MC68k architecture }
  1753. gestaltPowerPC = 2; { IBM PowerPC architecture }
  1754. gestaltIntel = 10; { Intel x86 architecture }
  1755. const
  1756. gestaltSystemUpdateVersion = FourCharCode('sysu'); { System Update version }
  1757. {
  1758. Returns the system version as a 32 bit packed BCD ( binary coded decimal )
  1759. version representation. Bits 0 through 3 are the "bug fix" revision number.
  1760. Bits 4 through 7 are the minor revision, and bits 8 through 31 are the bcd
  1761. decimal digits of the major release version.
  1762. Value: 0xMMMMMMRB = M.R.B Example: 0x00001023 = 10.2.3
  1763. ^^^^^^ major rev ^^^^^^ major rev = 10
  1764. ^ minor rev ^ minor rev = 2
  1765. ^ bug fix rev ^ bug fix rev = 3
  1766. If the values of the minor or bug fix revision are larger than 9, then
  1767. gestaltSystemVersion will substitute the value 9 for them. For example,
  1768. Mac OS X 10.3.15 will be returned as 0x1039, and Mac OS X 10.10.5 will
  1769. return 0x1095.
  1770. A better way to get version information with the deprecated Gestalt API
  1771. would be to use the gestaltSystemVersionMajor, gestaltSystemVersionMinor,
  1772. and gestaltSystemVersionBugFix selectors, which don't have arbitrary limits
  1773. on the values returned. However, because Gestalt is deprecated, you should
  1774. use NSProcessInfo's operatingSystemVersion property instead.
  1775. If you want to know the product build version string, product name, or
  1776. the user visible version string you should read in the system version
  1777. information from the file /System/Library/CoreServices/SystemVersion.plist.
  1778. }
  1779. const
  1780. gestaltSystemVersion = FourCharCode('sysv'); { system version}
  1781. gestaltSystemVersionMajor = FourCharCode('sys1'); { The major system version number; in 10.4.17 this would be the decimal value 10 }
  1782. gestaltSystemVersionMinor = FourCharCode('sys2'); { The minor system version number; in 10.4.17 this would be the decimal value 4 }
  1783. gestaltSystemVersionBugFix = FourCharCode('sys3'); { The bug fix system version number; in 10.4.17 this would be the decimal value 17 }
  1784. const
  1785. gestaltToolboxTable = FourCharCode('tbtt'); { OS trap table base }
  1786. const
  1787. gestaltTextEditVersion = FourCharCode('te '); { TextEdit version number }
  1788. gestaltTE1 = 1; { TextEdit in MacIIci ROM }
  1789. gestaltTE2 = 2; { TextEdit with 6.0.4 Script Systems on MacIIci (Script bug fixes for MacIIci) }
  1790. gestaltTE3 = 3; { TextEdit with 6.0.4 Script Systems all but MacIIci }
  1791. gestaltTE4 = 4; { TextEdit in System 7.0 }
  1792. gestaltTE5 = 5; { TextWidthHook available in TextEdit }
  1793. const
  1794. gestaltTE6 = 6; { TextEdit with integrated TSMTE and improved UI }
  1795. const
  1796. gestaltTEAttr = FourCharCode('teat'); { TextEdit attributes }
  1797. gestaltTEHasGetHiliteRgn = 0; { TextEdit has TEGetHiliteRgn }
  1798. gestaltTESupportsInlineInput = 1; { TextEdit does Inline Input }
  1799. gestaltTESupportsTextObjects = 2; { TextEdit does Text Objects }
  1800. gestaltTEHasWhiteBackground = 3; { TextEdit supports overriding the TERec's background to white }
  1801. const
  1802. gestaltTeleMgrAttr = FourCharCode('tele'); { Telephone manager attributes }
  1803. gestaltTeleMgrPresent = 0;
  1804. gestaltTeleMgrPowerPCSupport = 1;
  1805. gestaltTeleMgrSoundStreams = 2;
  1806. gestaltTeleMgrAutoAnswer = 3;
  1807. gestaltTeleMgrIndHandset = 4;
  1808. gestaltTeleMgrSilenceDetect = 5;
  1809. gestaltTeleMgrNewTELNewSupport = 6;
  1810. const
  1811. gestaltTermMgrAttr = FourCharCode('term'); { terminal mgr attributes }
  1812. gestaltTermMgrPresent = 0;
  1813. gestaltTermMgrErrorString = 2;
  1814. const
  1815. gestaltThreadMgrAttr = FourCharCode('thds'); { Thread Manager attributes }
  1816. gestaltThreadMgrPresent = 0; { bit true if Thread Mgr is present }
  1817. gestaltSpecificMatchSupport = 1; { bit true if Thread Mgr supports exact match creation option }
  1818. gestaltThreadsLibraryPresent = 2; { bit true if Thread Mgr shared library is present }
  1819. const
  1820. gestaltTimeMgrVersion = FourCharCode('tmgr'); { time mgr version }
  1821. gestaltStandardTimeMgr = 1; { standard time mgr is present }
  1822. gestaltRevisedTimeMgr = 2; { revised time mgr is present }
  1823. gestaltExtendedTimeMgr = 3; { extended time mgr is present }
  1824. gestaltNativeTimeMgr = 4; { PowerPC native TimeMgr is present }
  1825. const
  1826. gestaltTSMTEVersion = FourCharCode('tmTV');
  1827. gestaltTSMTE1 = $0100; { Original version of TSMTE }
  1828. gestaltTSMTE15 = $0150; { System 8.0 }
  1829. gestaltTSMTE152 = $0152; { System 8.2 }
  1830. const
  1831. gestaltTSMTEAttr = FourCharCode('tmTE');
  1832. gestaltTSMTEPresent = 0;
  1833. gestaltTSMTE = 0; { gestaltTSMTE is old name for gestaltTSMTEPresent }
  1834. const
  1835. gestaltAVLTreeAttr = FourCharCode('tree'); { AVLTree utility routines attributes. }
  1836. gestaltAVLTreePresentBit = 0; { if set, then the AVL Tree routines are available. }
  1837. gestaltAVLTreeSupportsHandleBasedTreeBit = 1; { if set, then the AVL Tree routines can store tree data in a single handle }
  1838. gestaltAVLTreeSupportsTreeLockingBit = 2; { if set, the AVLLockTree() and AVLUnlockTree() routines are available. }
  1839. const
  1840. gestaltALMAttr = FourCharCode('trip'); { Settings Manager attributes (see also gestaltALMVers) }
  1841. gestaltALMPresent = 0; { bit true if ALM is available }
  1842. gestaltALMHasSFGroup = 1; { bit true if Put/Get/Merge Group calls are implmented }
  1843. gestaltALMHasCFMSupport = 2; { bit true if CFM-based modules are supported }
  1844. gestaltALMHasRescanNotifiers = 3; { bit true if Rescan notifications/events will be sent to clients }
  1845. const
  1846. gestaltALMHasSFLocation = gestaltALMHasSFGroup;
  1847. const
  1848. gestaltTSMgrVersion = FourCharCode('tsmv'); { Text Services Mgr version, if present }
  1849. gestaltTSMgr15 = $0150;
  1850. gestaltTSMgr20 = $0200; { Version 2.0 as of MacOSX 10.0 }
  1851. gestaltTSMgr22 = $0220; { Version 2.2 as of MacOSX 10.3 }
  1852. gestaltTSMgr23 = $0230; { Version 2.3 as of MacOSX 10.4 }
  1853. const
  1854. gestaltTSMgrAttr = FourCharCode('tsma'); { Text Services Mgr attributes, if present }
  1855. gestaltTSMDisplayMgrAwareBit = 0; { TSM knows about display manager }
  1856. gestaltTSMdoesTSMTEBit = 1; { TSM has integrated TSMTE }
  1857. const
  1858. gestaltSpeechAttr = FourCharCode('ttsc'); { Speech Manager attributes }
  1859. gestaltSpeechMgrPresent = 0; { bit set indicates that Speech Manager exists }
  1860. gestaltSpeechHasPPCGlue = 1; { bit set indicates that native PPC glue for Speech Manager API exists }
  1861. const
  1862. gestaltTVAttr = FourCharCode('tv '); { TV version }
  1863. gestaltHasTVTuner = 0; { supports Philips FL1236F video tuner }
  1864. gestaltHasSoundFader = 1; { supports Philips TEA6330 Sound Fader chip }
  1865. gestaltHasHWClosedCaptioning = 2; { supports Philips SAA5252 Closed Captioning }
  1866. gestaltHasIRRemote = 3; { supports CyclopsII Infra Red Remote control }
  1867. gestaltHasVidDecoderScaler = 4; { supports Philips SAA7194 Video Decoder/Scaler }
  1868. gestaltHasStereoDecoder = 5; { supports Sony SBX1637A-01 stereo decoder }
  1869. gestaltHasSerialFader = 6; { has fader audio in serial with system audio }
  1870. gestaltHasFMTuner = 7; { has FM Tuner from donnybrook card }
  1871. gestaltHasSystemIRFunction = 8; { Infra Red button function is set up by system and not by Video Startup }
  1872. gestaltIRDisabled = 9; { Infra Red remote is not disabled. }
  1873. gestaltINeedIRPowerOffConfirm = 10; { Need IR power off confirm dialog. }
  1874. gestaltHasZoomedVideo = 11; { Has Zoomed Video PC Card video input. }
  1875. const
  1876. gestaltATSUVersion = FourCharCode('uisv');
  1877. gestaltOriginalATSUVersion = 1 shl 16; { ATSUI version 1.0 }
  1878. gestaltATSUUpdate1 = 2 shl 16; { ATSUI version 1.1 }
  1879. gestaltATSUUpdate2 = 3 shl 16; { ATSUI version 1.2 }
  1880. gestaltATSUUpdate3 = 4 shl 16; { ATSUI version 2.0 }
  1881. gestaltATSUUpdate4 = 5 shl 16; { ATSUI version in Mac OS X - SoftwareUpdate 1-4 for Mac OS 10.0.1 - 10.0.4 }
  1882. gestaltATSUUpdate5 = 6 shl 16; { ATSUI version 2.3 in MacOS 10.1 }
  1883. gestaltATSUUpdate6 = 7 shl 16; { ATSUI version 2.4 in MacOS 10.2 }
  1884. gestaltATSUUpdate7 = 8 shl 16; { ATSUI version 2.5 in MacOS 10.3 }
  1885. const
  1886. gestaltATSUFeatures = FourCharCode('uisf');
  1887. gestaltATSUTrackingFeature = $00000001; { feature introduced in ATSUI version 1.1 }
  1888. gestaltATSUMemoryFeature = $00000001; { feature introduced in ATSUI version 1.1 }
  1889. gestaltATSUFallbacksFeature = $00000001; { feature introduced in ATSUI version 1.1 }
  1890. gestaltATSUGlyphBoundsFeature = $00000001; { feature introduced in ATSUI version 1.1 }
  1891. gestaltATSULineControlFeature = $00000001; { feature introduced in ATSUI version 1.1 }
  1892. gestaltATSULayoutCreateAndCopyFeature = $00000001; { feature introduced in ATSUI version 1.1 }
  1893. gestaltATSULayoutCacheClearFeature = $00000001; { feature introduced in ATSUI version 1.1 }
  1894. gestaltATSUTextLocatorUsageFeature = $00000002; { feature introduced in ATSUI version 1.2 }
  1895. gestaltATSULowLevelOrigFeatures = $00000004; { first low-level features introduced in ATSUI version 2.0 }
  1896. gestaltATSUFallbacksObjFeatures = $00000008; { feature introduced - ATSUFontFallbacks objects introduced in ATSUI version 2.3 }
  1897. gestaltATSUIgnoreLeadingFeature = $00000008; { feature introduced - kATSLineIgnoreFontLeading LineLayoutOption introduced in ATSUI version 2.3 }
  1898. gestaltATSUByCharacterClusterFeature = $00000010; { ATSUCursorMovementTypes introduced in ATSUI version 2.4 }
  1899. gestaltATSUAscentDescentControlsFeature = $00000010; { attributes introduced in ATSUI version 2.4 }
  1900. gestaltATSUHighlightInactiveTextFeature = $00000010; { feature introduced in ATSUI version 2.4 }
  1901. gestaltATSUPositionToCursorFeature = $00000010; { features introduced in ATSUI version 2.4 }
  1902. gestaltATSUBatchBreakLinesFeature = $00000010; { feature introduced in ATSUI version 2.4 }
  1903. gestaltATSUTabSupportFeature = $00000010; { features introduced in ATSUI version 2.4 }
  1904. gestaltATSUDirectAccess = $00000010; { features introduced in ATSUI version 2.4 }
  1905. gestaltATSUDecimalTabFeature = $00000020; { feature introduced in ATSUI version 2.5 }
  1906. gestaltATSUBiDiCursorPositionFeature = $00000020; { feature introduced in ATSUI version 2.5 }
  1907. gestaltATSUNearestCharLineBreakFeature = $00000020; { feature introduced in ATSUI version 2.5 }
  1908. gestaltATSUHighlightColorControlFeature = $00000020; { feature introduced in ATSUI version 2.5 }
  1909. gestaltATSUUnderlineOptionsStyleFeature = $00000020; { feature introduced in ATSUI version 2.5 }
  1910. gestaltATSUStrikeThroughStyleFeature = $00000020; { feature introduced in ATSUI version 2.5 }
  1911. gestaltATSUDropShadowStyleFeature = $00000020; { feature introduced in ATSUI version 2.5 }
  1912. const
  1913. gestaltUSBAttr = FourCharCode('usb '); { USB Attributes }
  1914. gestaltUSBPresent = 0; { USB Support available }
  1915. gestaltUSBHasIsoch = 1; { USB Isochronous features available }
  1916. const
  1917. gestaltUSBVersion = FourCharCode('usbv'); { USB version }
  1918. const
  1919. gestaltVersion = FourCharCode('vers'); { gestalt version }
  1920. gestaltValueImplementedVers = 5; { version of gestalt where gestaltValue is implemented. }
  1921. const
  1922. gestaltVIA1Addr = FourCharCode('via1'); { via 1 base address }
  1923. const
  1924. gestaltVIA2Addr = FourCharCode('via2'); { via 2 base address }
  1925. const
  1926. gestaltVMAttr = FourCharCode('vm '); { virtual memory attributes }
  1927. gestaltVMPresent = 0; { true if virtual memory is present }
  1928. gestaltVMHasLockMemoryForOutput = 1; { true if LockMemoryForOutput is available }
  1929. gestaltVMFilemappingOn = 3; { true if filemapping is available }
  1930. gestaltVMHasPagingControl = 4; { true if MakeMemoryResident, MakeMemoryNonResident, FlushMemory, and ReleaseMemoryData are available }
  1931. const
  1932. gestaltVMInfoType = FourCharCode('vmin'); { Indicates how the Finder should display information about VM in }
  1933. { the Finder about box. }
  1934. gestaltVMInfoSizeStorageType = 0; { Display VM on/off, backing store size and name }
  1935. gestaltVMInfoSizeType = 1; { Display whether VM is on or off and the size of the backing store }
  1936. gestaltVMInfoSimpleType = 2; { Display whether VM is on or off }
  1937. gestaltVMInfoNoneType = 3; { Display no VM information }
  1938. const
  1939. gestaltVMBackingStoreFileRefNum = FourCharCode('vmbs'); { file refNum of virtual memory's main backing store file (returned in low word of result) }
  1940. const
  1941. gestaltALMVers = FourCharCode('walk'); { Settings Manager version (see also gestaltALMAttr) }
  1942. const
  1943. gestaltWindowMgrAttr = FourCharCode('wind'); { If this Gestalt exists, the Mac OS 8.5 Window Manager is installed}
  1944. gestaltWindowMgrPresent = 1 shl 0; { NOTE: this is a bit mask, whereas all other Gestalt constants of}
  1945. { this type are bit index values. Universal Interfaces 3.2 slipped}
  1946. { out the door with this mistake.}
  1947. gestaltWindowMgrPresentBit = 0; { bit number}
  1948. gestaltExtendedWindowAttributes = 1; { Has ChangeWindowAttributes; GetWindowAttributes works for all windows}
  1949. gestaltExtendedWindowAttributesBit = 1; { Has ChangeWindowAttributes; GetWindowAttributes works for all windows}
  1950. gestaltHasFloatingWindows = 2; { Floating window APIs work}
  1951. gestaltHasFloatingWindowsBit = 2; { Floating window APIs work}
  1952. gestaltHasWindowBuffering = 3; { This system has buffering available}
  1953. gestaltHasWindowBufferingBit = 3; { This system has buffering available}
  1954. gestaltWindowLiveResizeBit = 4; { live resizing of windows is available}
  1955. gestaltWindowMinimizeToDockBit = 5; { windows minimize to the dock and do not windowshade (Mac OS X)}
  1956. gestaltHasWindowShadowsBit = 6; { windows have shadows}
  1957. gestaltSheetsAreWindowModalBit = 7; { sheet windows are modal only to their parent window}
  1958. gestaltFrontWindowMayBeHiddenBit = 8; { FrontWindow and related APIs will return the front window even when the app is hidden}
  1959. { masks for the above bits}
  1960. gestaltWindowMgrPresentMask = 1 shl gestaltWindowMgrPresentBit;
  1961. gestaltExtendedWindowAttributesMask = 1 shl gestaltExtendedWindowAttributesBit;
  1962. gestaltHasFloatingWindowsMask = 1 shl gestaltHasFloatingWindowsBit;
  1963. gestaltHasWindowBufferingMask = 1 shl gestaltHasWindowBufferingBit;
  1964. gestaltWindowLiveResizeMask = 1 shl gestaltWindowLiveResizeBit;
  1965. gestaltWindowMinimizeToDockMask = 1 shl gestaltWindowMinimizeToDockBit;
  1966. gestaltHasWindowShadowsMask = 1 shl gestaltHasWindowShadowsBit;
  1967. gestaltSheetsAreWindowModalMask = 1 shl gestaltSheetsAreWindowModalBit;
  1968. gestaltFrontWindowMayBeHiddenMask = 1 shl gestaltFrontWindowMayBeHiddenBit;
  1969. const
  1970. gestaltHasSingleWindowModeBit = 8; { This system supports single window mode}
  1971. gestaltHasSingleWindowModeMask = 1 shl gestaltHasSingleWindowModeBit;
  1972. { gestaltX86Features is a convenience for 'cpuid' instruction. Note
  1973. that even though the processor may support a specific feature, the
  1974. OS may not support all of these features. These bitfields
  1975. correspond directly to the bits returned by cpuid }
  1976. const
  1977. gestaltX86Features = FourCharCode('x86f');
  1978. gestaltX86HasFPU = 0; { has an FPU that supports the 387 instructions}
  1979. gestaltX86HasVME = 1; { supports Virtual-8086 Mode Extensions}
  1980. gestaltX86HasDE = 2; { supports I/O breakpoints (Debug Extensions)}
  1981. gestaltX86HasPSE = 3; { supports 4-Mbyte pages (Page Size Extension)}
  1982. gestaltX86HasTSC = 4; { supports RTDSC instruction (Time Stamp Counter)}
  1983. gestaltX86HasMSR = 5; { supports Model Specific Registers}
  1984. gestaltX86HasPAE = 6; { supports physical addresses > 32 bits (Physical Address Extension)}
  1985. gestaltX86HasMCE = 7; { supports Machine Check Exception}
  1986. gestaltX86HasCX8 = 8; { supports CMPXCHG8 instructions (Compare Exchange 8 bytes)}
  1987. gestaltX86HasAPIC = 9; { contains local APIC}
  1988. gestaltX86HasSEP = 11; { supports fast system call (SysEnter Present)}
  1989. gestaltX86HasMTRR = 12; { supports Memory Type Range Registers}
  1990. gestaltX86HasPGE = 13; { supports Page Global Enable}
  1991. gestaltX86HasMCA = 14; { supports Machine Check Architecture}
  1992. gestaltX86HasCMOV = 15; { supports CMOVcc instruction (Conditional Move).}
  1993. { If FPU bit is also set, supports FCMOVcc and FCOMI, too}
  1994. gestaltX86HasPAT = 16; { supports Page Attribute Table}
  1995. gestaltX86HasPSE36 = 17; { supports 36-bit Page Size Extension}
  1996. gestaltX86HasPSN = 18; { Processor Serial Number}
  1997. gestaltX86HasCLFSH = 19; { CLFLUSH Instruction supported}
  1998. gestaltX86Serviced20 = 20; { do not count on this bit value}
  1999. gestaltX86HasDS = 21; { Debug Store}
  2000. gestaltX86ResACPI = 22; { Thermal Monitor, SW-controlled clock}
  2001. gestaltX86HasMMX = 23; { supports MMX instructions}
  2002. gestaltX86HasFXSR = 24; { Supports FXSAVE and FXRSTOR instructions (fast FP save/restore)}
  2003. gestaltX86HasSSE = 25; { Streaming SIMD extensions}
  2004. gestaltX86HasSSE2 = 26; { Streaming SIMD extensions 2}
  2005. gestaltX86HasSS = 27; { Self-Snoop}
  2006. gestaltX86HasHTT = 28; { Hyper-Threading Technology}
  2007. gestaltX86HasTM = 29; { Thermal Monitor}
  2008. { 'cpuid' now returns a 64 bit value, and the following
  2009. gestalt selector and field definitions apply
  2010. to the extended form of this instruction }
  2011. const
  2012. gestaltX86AdditionalFeatures = FourCharCode('x86a');
  2013. gestaltX86HasSSE3 = 0; { Prescott New Inst.}
  2014. gestaltX86HasMONITOR = 3; { Monitor/mwait}
  2015. gestaltX86HasDSCPL = 4; { Debug Store CPL}
  2016. gestaltX86HasVMX = 5; { VMX}
  2017. gestaltX86HasSMX = 6; { SMX}
  2018. gestaltX86HasEST = 7; { Enhanced SpeedsTep (GV3)}
  2019. gestaltX86HasTM2 = 8; { Thermal Monitor 2}
  2020. gestaltX86HasSupplementalSSE3 = 9; { Supplemental SSE3 instructions}
  2021. gestaltX86HasCID = 10; { L1 Context ID}
  2022. gestaltX86HasCX16 = 13; { CmpXchg16b instruction}
  2023. gestaltX86HasxTPR = 14; { Send Task PRiority msgs}
  2024. const
  2025. gestaltTranslationAttr = FourCharCode('xlat'); { Translation Manager attributes }
  2026. gestaltTranslationMgrExists = 0; { True if translation manager exists }
  2027. gestaltTranslationMgrHintOrder = 1; { True if hint order reversal in effect }
  2028. gestaltTranslationPPCAvail = 2;
  2029. gestaltTranslationGetPathAPIAvail = 3;
  2030. const
  2031. gestaltExtToolboxTable = FourCharCode('xttt'); { Extended Toolbox trap table base }
  2032. const
  2033. gestaltUSBPrinterSharingVersion = FourCharCode('zak '); { USB Printer Sharing Version}
  2034. gestaltUSBPrinterSharingVersionMask = $0000FFFF; { mask for bits in version}
  2035. gestaltUSBPrinterSharingAttr = FourCharCode('zak '); { USB Printer Sharing Attributes}
  2036. gestaltUSBPrinterSharingAttrMask = $FFFF0000; { mask for attribute bits}
  2037. gestaltUSBPrinterSharingAttrRunning = $80000000; { printer sharing is running}
  2038. gestaltUSBPrinterSharingAttrBooted = $40000000; { printer sharing was installed at boot time}
  2039. {WorldScript settings;}
  2040. const
  2041. gestaltWorldScriptIIVersion = FourCharCode('doub');
  2042. gestaltWorldScriptIIAttr = FourCharCode('wsat');
  2043. gestaltWSIICanPrintWithoutPrGeneralBit = 0; { bit 0 is on if WS II knows about PrinterStatus callback }
  2044. {$endc} {TARGET_OS_MAC}
  2045. {$ifc not defined MACOSALLINCLUDE or not MACOSALLINCLUDE}
  2046. end.
  2047. {$endc} {not MACOSALLINCLUDE}