Shared.Struct.pas 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468
  1. unit Shared.Struct;
  2. {
  3. Inno Setup
  4. Copyright (C) 1997-2026 Jordan Russell
  5. Portions by Martijn Laan
  6. For conditions of distribution and use, see LICENSE.TXT.
  7. Various records and other types that are shared by the ISCmplr, Setup,
  8. SetupLdr, and Uninst projects
  9. }
  10. interface
  11. uses
  12. Windows, SHA256;
  13. const
  14. SetupTitle = 'Inno Setup';
  15. SetupVersion = '7.0.0-preview-1';
  16. SetupBinVersion = (7 shl 24) + (0 shl 16) + (0 shl 8) + 0;
  17. type
  18. TSetupID = array[0..63] of AnsiChar;
  19. TUninstallLogID = array[0..63] of AnsiChar;
  20. TMessagesHdrID = array[0..63] of AnsiChar;
  21. TMessagesLangOptionsID = array[1..8] of AnsiChar;
  22. TCompID = array[1..4] of AnsiChar;
  23. TDiskSliceID = array[1..8] of AnsiChar;
  24. const
  25. { SetupID is used by the Setup program to check if the Setup.0 file is
  26. compatible with it. If you make any modifications to the records in
  27. this file it's recommended you change SetupID. Any change will do (like
  28. changing the letters or numbers), as long as your format is
  29. unrecognizable by the standard Inno Setup. }
  30. SetupID: TSetupID = 'Inno Setup Setup Data (6.7.0)';
  31. UninstallLogID: array[Boolean] of TUninstallLogID =
  32. ('Inno Setup Uninstall Log (b)',
  33. 'Inno Setup Uninstall Log (b) 64-bit'); { '64-bit' refers to 64-bit install mode }
  34. MessagesHdrID: TMessagesHdrID = 'Inno Setup Messages (6.5.0) (u)';
  35. MessagesLangOptionsID: TMessagesLangOptionsID = '!mlo!670';
  36. ZLIBID: TCompID = 'zlb'#26;
  37. DiskSliceID: TDiskSliceID = 'idskb32'#26;
  38. type
  39. TSetupVersionDataVersion = packed record
  40. Build: Word;
  41. Minor, Major: Byte;
  42. end;
  43. PSetupVersionData = ^TSetupVersionData;
  44. TSetupVersionData = packed record
  45. WinVersion, NTVersion: Cardinal;
  46. NTServicePack: Word;
  47. end;
  48. TSetupHeaderOption = (shDisableStartupPrompt, shCreateAppDir,
  49. shAllowNoIcons, shAlwaysRestart, shAlwaysUsePersonalGroup,
  50. shEnableDirDoesntExistWarning, shPassword, shAllowRootDirectory,
  51. shDisableFinishedPage, shUpdateUninstallLogAppName, shDisableReadyMemo,
  52. shAlwaysShowComponentsList, shFlatComponentsList, shShowComponentSizes,
  53. shDisableReadyPage, shAlwaysShowDirOnReadyPage, shAlwaysShowGroupOnReadyPage,
  54. shAllowUNCPath, shUserInfoPage,
  55. shUninstallRestartComputer, shRestartIfNeededByRun, shShowTasksTreeLines,
  56. shAllowCancelDuringInstall, shWizardImageStretch, shAppendDefaultDirName,
  57. shAppendDefaultGroupName, shSetupLogging,
  58. shSignedUninstaller, shUsePreviousLanguage, shDisableWelcomePage,
  59. shCloseApplications, shRestartApplications, shAllowNetworkDrive,
  60. shForceCloseApplications, shAppNameHasConsts, shUsePreviousPrivileges,
  61. shUninstallLogging, shWizardModern, shWizardBorderStyled,
  62. shWizardKeepAspectRatio, shRedirectionGuard, shWizardBevelsHidden,
  63. shUnusedPadding = 56);
  64. { ^ Contains padding to raise the amount of flags to 57, ensuring the size of
  65. the set is 8 bytes (instead of less) in 32-bit builds. This prevents
  66. incompatibility with 64-bit builds, where the minimum size for a set with
  67. more than 32 flags is 8 bytes. Once the amount of actual flags reaches
  68. 57, the padding can be removed, as the set will then be naturally
  69. compatible again between 32-bit and 64-bit builds. Note that this is not
  70. necessary for sets with fewer than 32 flags, which is why only
  71. TSetupHeaderOption and TSetupFileEntry include this padding. Also see
  72. https://stackoverflow.com/questions/30336620/enumeration-set-size-in-x64 }
  73. TSetupHeaderOptions = packed set of TSetupHeaderOption;
  74. { ^ Adding more flags adds 1 byte for every 8 flags, in both 32-bit and
  75. 64-bit builds, even without specifying packed. But to be sure we specify
  76. it anyway. }
  77. TSetupLanguageDetectionMethod = (ldUILanguage, ldLocale, ldNone);
  78. TSetupCompressMethod = (cmStored, cmZip, cmBzip, cmLZMA, cmLZMA2);
  79. TSetupKDFSalt = array[0..15] of Byte;
  80. TSetupEncryptionKey = array[0..31] of Byte;
  81. TSetupEncryptionNonce = record
  82. RandomXorStartOffset: Int64;
  83. RandomXorFirstSlice: Int32;
  84. RemainingRandom: array[0..2] of Int32;
  85. end;
  86. TSetupProcessorArchitecture = (paUnknown, paX86, paX64, paArm32, paArm64);
  87. TSetupProcessorArchitectures = set of TSetupProcessorArchitecture;
  88. TSetupDisablePage = (dpAuto, dpNo, dpYes);
  89. TSetupPrivilegesRequired = (prNone, prPowerUser, prAdmin, prLowest);
  90. TSetupPrivilegesRequiredOverride = (proCommandLine, proDialog);
  91. TSetupPrivilegesRequiredOverrides = set of TSetupPrivilegesRequiredOverride;
  92. TSetupWizardDarkStyle = (wdsLight, wdsDark, wdsDynamic);
  93. TSetupWizardLightControlStyling = (wcsAll, wcsAllButButtons, wcsOnlyRequired);
  94. const
  95. SetupProcessorArchitectureNames: array[TSetupProcessorArchitecture] of String =
  96. ('Unknown', 'x86', 'x64', 'Arm32', 'Arm64');
  97. type
  98. { Should not contain strings }
  99. TSetupEncryptionHeader = packed record
  100. EncryptionUse: (euNone, euFiles, euFull);
  101. KDFSalt: TSetupKDFSalt;
  102. KDFIterations: Integer;
  103. BaseNonce: TSetupEncryptionNonce;
  104. PasswordTest: Integer;
  105. end;
  106. const
  107. SetupHeaderStrings = 39;
  108. SetupHeaderAnsiStrings = 4;
  109. type
  110. TSetupHeader = packed record
  111. AppName, AppVerName, AppId, AppCopyright, AppPublisher, AppPublisherURL,
  112. AppSupportPhone, AppSupportURL, AppUpdatesURL, AppVersion, DefaultDirName,
  113. DefaultGroupName, BaseFilename, UninstallFilesDir, UninstallDisplayName,
  114. UninstallDisplayIcon, AppMutex, DefaultUserInfoName, DefaultUserInfoOrg,
  115. DefaultUserInfoSerial, AppReadmeFile, AppContact, AppComments,
  116. AppModifyPath, CreateUninstallRegKey, Uninstallable, CloseApplicationsFilter,
  117. SetupMutex, ChangesEnvironment, ChangesAssociations,
  118. ArchitecturesAllowed, ArchitecturesInstallIn64BitMode, CloseApplicationsFilterExcludes,
  119. SevenZipLibraryName, UsePreviousAppDir, UsePreviousGroup, UsePreviousSetupType,
  120. UsePreviousTasks, UsePreviousUserInfo: String;
  121. LicenseText, InfoBeforeText, InfoAfterText, CompiledCodeText: AnsiString;
  122. NumLanguageEntries, NumCustomMessageEntries, NumPermissionEntries,
  123. NumTypeEntries, NumComponentEntries, NumTaskEntries, NumDirEntries,
  124. NumISSigKeyEntries, NumFileEntries, NumFileLocationEntries, NumIconEntries, NumIniEntries,
  125. NumRegistryEntries, NumInstallDeleteEntries, NumUninstallDeleteEntries,
  126. NumRunEntries, NumUninstallRunEntries: Integer;
  127. MinVersion, OnlyBelowVersion: TSetupVersionData;
  128. WizardSizePercentX, WizardSizePercentY: Integer;
  129. WizardDarkStyle: TSetupWizardDarkStyle;
  130. WizardImageAlphaFormat: (afIgnored, afDefined, afPremultiplied); // Must be same as Graphics.TAlphaFormat
  131. WizardImageBackColor, WizardSmallImageBackColor, WizardBackColor: Integer;
  132. WizardImageBackColorDynamicDark, WizardSmallImageBackColorDynamicDark, WizardBackColorDynamicDark: Integer;
  133. WizardImageOpacity, WizardBackImageOpacity: Byte;
  134. WizardLightControlStyling: TSetupWizardLightControlStyling;
  135. ExtraDiskSpaceRequired: Int64;
  136. SlicesPerDisk: Integer;
  137. UninstallLogMode: (lmAppend, lmNew, lmOverwrite);
  138. DirExistsWarning: (ddAuto, ddNo, ddYes);
  139. PrivilegesRequired: TSetupPrivilegesRequired;
  140. PrivilegesRequiredOverridesAllowed: TSetupPrivilegesRequiredOverrides;
  141. ShowLanguageDialog: (slYes, slNo, slAuto);
  142. LanguageDetectionMethod: TSetupLanguageDetectionMethod;
  143. CompressMethod: TSetupCompressMethod;
  144. DisableDirPage, DisableProgramGroupPage: TSetupDisablePage;
  145. UninstallDisplaySize: Int64;
  146. Options: TSetupHeaderOptions;
  147. end;
  148. const
  149. SetupPermissionEntryStrings = 0;
  150. SetupPermissionEntryAnsiStrings = 1;
  151. type
  152. PSetupPermissionEntry = ^TSetupPermissionEntry;
  153. TSetupPermissionEntry = packed record
  154. Permissions: AnsiString; { an array of TGrantPermissionEntry's }
  155. end;
  156. const
  157. SetupLanguageEntryStrings = 4;
  158. SetupLanguageEntryAnsiStrings = 4;
  159. type
  160. PSetupLanguageEntry = ^TSetupLanguageEntry;
  161. TSetupLanguageEntry = packed record
  162. Name, LanguageName, DialogFontName, WelcomeFontName: String;
  163. Data, LicenseText, InfoBeforeText, InfoAfterText: AnsiString;
  164. LanguageID: Word;
  165. DialogFontSize, DialogFontBaseScaleHeight, DialogFontBaseScaleWidth: Integer;
  166. WelcomeFontSize: Integer;
  167. RightToLeft: Boolean;
  168. end;
  169. const
  170. SetupCustomMessageEntryStrings = 2;
  171. SetupCustomMessageEntryAnsiStrings = 0;
  172. type
  173. PSetupCustomMessageEntry = ^TSetupCustomMessageEntry;
  174. TSetupCustomMessageEntry = packed record
  175. Name, Value: String;
  176. LangIndex: Integer;
  177. end;
  178. const
  179. SetupTypeEntryStrings = 4;
  180. SetupTypeEntryAnsiStrings = 0;
  181. type
  182. TSetupTypeOption = (toIsCustom);
  183. TSetupTypeOptions = set of TSetupTypeOption;
  184. TSetupTypeType = (ttUser, ttDefaultFull, ttDefaultCompact, ttDefaultCustom);
  185. PSetupTypeEntry = ^TSetupTypeEntry;
  186. TSetupTypeEntry = packed record
  187. Name, Description, Languages, CheckOnce: String;
  188. MinVersion, OnlyBelowVersion: TSetupVersionData;
  189. Options: TSetupTypeOptions;
  190. Typ: TSetupTypeType;
  191. { internally used: }
  192. Size: Int64;
  193. end;
  194. const
  195. SetupComponentEntryStrings = 5;
  196. SetupComponentEntryAnsiStrings = 0;
  197. type
  198. PSetupComponentEntry = ^TSetupComponentEntry;
  199. TSetupComponentEntry = packed record
  200. Name, Description, Types, Languages, CheckOnce: String;
  201. ExtraDiskSpaceRequired: Int64;
  202. Level: Byte;
  203. Used: Boolean;
  204. MinVersion, OnlyBelowVersion: TSetupVersionData;
  205. Options: set of (coFixed, coRestart, coDisableNoUninstallWarning,
  206. coExclusive, coDontInheritCheck);
  207. { internally used: }
  208. Size: Int64;
  209. end;
  210. const
  211. SetupTaskEntryStrings = 6;
  212. SetupTaskEntryAnsiStrings = 0;
  213. type
  214. PSetupTaskEntry = ^TSetupTaskEntry;
  215. TSetupTaskEntry = packed record
  216. Name, Description, GroupDescription, Components, Languages, Check: String;
  217. Level: Byte;
  218. Used: Boolean;
  219. MinVersion, OnlyBelowVersion: TSetupVersionData;
  220. Options: set of (toExclusive, toUnchecked, toRestart, toCheckedOnce,
  221. toDontInheritCheck);
  222. end;
  223. const
  224. SetupDirEntryStrings = 7;
  225. SetupDirEntryAnsiStrings = 0;
  226. type
  227. PSetupDirEntry = ^TSetupDirEntry;
  228. TSetupDirEntry = packed record
  229. DirName: String;
  230. Components, Tasks, Languages, Check, AfterInstall, BeforeInstall: String;
  231. Attribs: Integer;
  232. MinVersion, OnlyBelowVersion: TSetupVersionData;
  233. PermissionsEntry: Smallint;
  234. Options: set of (doUninsNeverUninstall, doDeleteAfterInstall,
  235. doUninsAlwaysUninstall, doSetNTFSCompression, doUnsetNTFSCompression);
  236. end;
  237. const
  238. SetupISSigKeyEntryStrings = 3;
  239. SetupISSigKeyEntryAnsiStrings = 0;
  240. type
  241. PSetupISSigKeyEntry = ^TSetupISSigKeyEntry;
  242. TSetupISSigKeyEntry = packed record
  243. PublicX, PublicY, RuntimeID: String;
  244. end;
  245. const
  246. SetupFileEntryStrings = 15;
  247. SetupFileEntryAnsiStrings = 1;
  248. type
  249. PSetupFileEntry = ^TSetupFileEntry;
  250. TSetupFileVerificationType = (fvNone, fvHash, fvISSig);
  251. TSetupFileVerification = packed record
  252. ISSigAllowedKeys: AnsiString; { Must be first }
  253. Hash: TSHA256Digest;
  254. Typ: TSetupFileVerificationType;
  255. end;
  256. TSetupFileEntryOption = (foConfirmOverwrite, foUninsNeverUninstall, foRestartReplace,
  257. foDeleteAfterInstall, foRegisterServer, foRegisterTypeLib, foSharedFile,
  258. foCompareTimeStamp, foFontIsntTrueType,
  259. foSkipIfSourceDoesntExist, foOverwriteReadOnly, foOverwriteSameVersion,
  260. foCustomDestName, foOnlyIfDestFileExists, foNoRegError,
  261. foUninsRestartDelete, foOnlyIfDoesntExist, foIgnoreVersion,
  262. foPromptIfOlder, foDontCopy, foUninsRemoveReadOnly,
  263. foRecurseSubDirsExternal, foReplaceSameVersionIfContentsDiffer,
  264. foDontVerifyChecksum, foUninsNoSharedFilePrompt, foCreateAllSubDirs,
  265. fo32Bit, fo64Bit, foExternalSizePreset, foSetNTFSCompression,
  266. foUnsetNTFSCompression, foGacInstall, foDownload,
  267. foExtractArchive, foUnusedPadding = 56);
  268. { ^ See TSetupHeaderOption above}
  269. TSetupFileEntryOptions = packed set of TSetupFileEntryOption;
  270. { ^ See TSetupHeaderOptions above}
  271. TSetupFileEntry = packed record
  272. SourceFilename, DestName, InstallFontName, StrongAssemblyName, Components,
  273. Tasks, Languages, Check, AfterInstall, BeforeInstall, Excludes,
  274. DownloadISSigSource, DownloadUserName, DownloadPassword, ExtractArchivePassword: String;
  275. Verification: TSetupFileVerification; { Must be first after strings }
  276. MinVersion, OnlyBelowVersion: TSetupVersionData;
  277. LocationEntry: Integer;
  278. Attribs: Integer;
  279. ExternalSize: Int64;
  280. PermissionsEntry: Smallint;
  281. Options: TSetupFileEntryOptions;
  282. FileType: (ftUserFile, ftUninstExe);
  283. end;
  284. const
  285. SetupFileLocationEntryStrings = 0;
  286. SetupFileLocationEntryAnsiStrings = 0;
  287. type
  288. PSetupFileLocationEntry = ^TSetupFileLocationEntry;
  289. TSetupFileLocationEntry = packed record
  290. FirstSlice, LastSlice: Integer;
  291. StartOffset: Int64;
  292. ChunkSuboffset: Int64;
  293. OriginalSize: Int64;
  294. ChunkCompressedSize: Int64;
  295. SHA256Sum: TSHA256Digest;
  296. TimeStamp: TFileTime;
  297. FileVersionMS, FileVersionLS: DWORD;
  298. Flags: set of (floVersionInfoValid, floTimeStampInUTC, floCallInstructionOptimized,
  299. floChunkEncrypted, floChunkCompressed);
  300. end;
  301. const
  302. SetupIconEntryStrings = 13;
  303. SetupIconEntryAnsiStrings = 0;
  304. type
  305. TSetupIconCloseOnExit = (icNoSetting, icYes, icNo);
  306. PSetupIconEntry = ^TSetupIconEntry;
  307. TSetupIconEntry = packed record
  308. IconName, Filename, Parameters, WorkingDir, IconFilename, Comment: String;
  309. Components, Tasks, Languages, Check, AfterInstall, BeforeInstall: String;
  310. AppUserModelID: String;
  311. AppUserModelToastActivatorCLSID: TGUID;
  312. MinVersion, OnlyBelowVersion: TSetupVersionData;
  313. IconIndex, ShowCmd: Integer;
  314. CloseOnExit: TSetupIconCloseOnExit;
  315. HotKey: Word;
  316. Options: set of (ioUninsNeverUninstall, ioCreateOnlyIfFileExists,
  317. ioUseAppPaths, ioExcludeFromShowInNewInstall,
  318. ioPreventPinning, ioHasAppUserModelToastActivatorCLSID);
  319. end;
  320. const
  321. SetupIniEntryStrings = 10;
  322. SetupIniEntryAnsiStrings = 0;
  323. type
  324. PSetupIniEntry = ^TSetupIniEntry;
  325. TSetupIniEntry = packed record
  326. Filename, Section, Entry, Value: String;
  327. Components, Tasks, Languages, Check, AfterInstall, BeforeInstall: String;
  328. MinVersion, OnlyBelowVersion: TSetupVersionData;
  329. Options: set of (ioCreateKeyIfDoesntExist, ioUninsDeleteEntry,
  330. ioUninsDeleteEntireSection, ioUninsDeleteSectionIfEmpty,
  331. { internally used: }
  332. ioHasValue);
  333. end;
  334. const
  335. SetupRegistryEntryStrings = 9;
  336. SetupRegistryEntryAnsiStrings = 0;
  337. type
  338. PSetupRegistryEntry = ^TSetupRegistryEntry;
  339. TSetupRegistryEntry = packed record
  340. Subkey, ValueName, ValueData: String;
  341. Components, Tasks, Languages, Check, AfterInstall, BeforeInstall: String;
  342. MinVersion, OnlyBelowVersion: TSetupVersionData;
  343. RootKey: UInt32; { Not using HKEY because it equals NativeUInt. UInt32 fits all predefined keys and utReg* use Integer to store it. }
  344. PermissionsEntry: Smallint;
  345. Typ: (rtNone, rtString, rtExpandString, rtDWord, rtBinary, rtMultiString, rtQWord);
  346. Options: set of (roCreateValueIfDoesntExist, roUninsDeleteValue,
  347. roUninsClearValue, roUninsDeleteEntireKey, roUninsDeleteEntireKeyIfEmpty,
  348. roPreserveStringType, roDeleteKey, roDeleteValue, roNoError,
  349. roDontCreateKey, ro32Bit, ro64Bit);
  350. end;
  351. const
  352. SetupDeleteEntryStrings = 7;
  353. SetupDeleteEntryAnsiStrings = 0;
  354. type
  355. TSetupDeleteType = (dfFiles, dfFilesAndOrSubdirs, dfDirIfEmpty);
  356. PSetupDeleteEntry = ^TSetupDeleteEntry;
  357. TSetupDeleteEntry = packed record
  358. Name: String;
  359. Components, Tasks, Languages, Check, AfterInstall, BeforeInstall: String;
  360. MinVersion, OnlyBelowVersion: TSetupVersionData;
  361. DeleteType: TSetupDeleteType;
  362. end;
  363. const
  364. SetupRunEntryStrings = 13;
  365. SetupRunEntryAnsiStrings = 0;
  366. type
  367. PSetupRunEntry = ^TSetupRunEntry;
  368. TSetupRunEntry = packed record
  369. Name, Parameters, WorkingDir, RunOnceId, StatusMsg, Verb: String;
  370. Description, Components, Tasks, Languages, Check, AfterInstall, BeforeInstall: String;
  371. MinVersion, OnlyBelowVersion: TSetupVersionData;
  372. ShowCmd: Integer;
  373. Wait: (rwWaitUntilTerminated, rwNoWait, rwWaitUntilIdle);
  374. Options: set of (roShellExec, roSkipIfDoesntExist,
  375. roPostInstall, roUnchecked, roSkipIfSilent, roSkipIfNotSilent,
  376. roHideWizard, roRun32Bit, roRun64Bit, roRunAsOriginalUser,
  377. roDontLogParameters, roLogOutput);
  378. end;
  379. const
  380. MaxGrantPermissionEntries = 32;
  381. type
  382. { TGrantPermissionEntry is stored inside string fields named 'Permissions' }
  383. TGrantPermissionSid = record
  384. Authority: TSIDIdentifierAuthority;
  385. SubAuthCount: Byte;
  386. SubAuth: array[0..1] of DWORD;
  387. end;
  388. TGrantPermissionEntry = record
  389. Sid: TGrantPermissionSid;
  390. AccessMask: DWORD;
  391. end;
  392. { A TDiskSliceHeader record follows DiskSliceID in a Setup-*.bin file }
  393. TDiskSliceHeader = packed record
  394. TotalSize: Int64;
  395. end;
  396. { A TMessageHeader record follows MessagesHdrID in a Setup.msg file }
  397. TMessagesHeader = packed record
  398. NumMessages: Cardinal;
  399. TotalSize: Cardinal;
  400. NotTotalSize: Cardinal;
  401. CRCMessages: Longint;
  402. end;
  403. { TSetupLdrOffsetTable is stored inside SetupLdr's SetupLdrOffsetTableResID
  404. RCDATA resource }
  405. PSetupLdrOffsetTable = ^TSetupLdrOffsetTable;
  406. TSetupLdrOffsetTable = record
  407. ID: array[1..12] of AnsiChar; { = SetupLdrOffsetTableID }
  408. Version: UInt32; { = SetupLdrOffsetTableVersion }
  409. TotalSize: Int64; { Minimum expected size of setup.exe }
  410. OffsetEXE: Int64; { Offset of compressed setup.e32/64 }
  411. UncompressedSizeEXE: UInt32; { Size of setup.e32/64 before compression }
  412. CRCEXE: Int32; { CRC of setup.e32/64 before compression }
  413. Offset0: Int64; { Offset of embedded setup-0.bin data }
  414. Offset1: Int64; { Offset of embedded setup-1.bin data,
  415. or 0 when DiskSpanning=yes }
  416. ReservedPadding: UInt32; { Not set (just provides padding) }
  417. TableCRC: Int32; { CRC of all prior fields in this record }
  418. end;
  419. { TMessagesLangOptions contains appearance settings used by the uninstaller
  420. and RegSvr, set when the .exe was last replaced, without being affected
  421. by any previously installed version. As a result, it is neither backward
  422. nor forward compatible, unlike TUninstallLogHeader. Be sure to update
  423. MessagesLangOptionsID whenever you make changes to this record. It is
  424. named TMessagesLangOptions because it is stored in the Setup.msg file,
  425. not because all options must be language-specific. }
  426. TMessagesLangOptionsFlag = (lfRightToLeft, lfWizardModern, lfWizardDarkStyleDark,
  427. lfWizardDarkStyleDynamic, lfWizardBorderStyled, lfWizardKeepAspectRatio,
  428. lfWizardBevelsHidden);
  429. TMessagesLangOptionsFlags = set of TMessagesLangOptionsFlag;
  430. TMessagesLangOptions = packed record
  431. ID: TMessagesLangOptionsID;
  432. DialogFontName: array[0..31] of Char;
  433. DialogFontSize, DialogFontBaseScaleWidth, DialogFontBaseScaleHeight: Integer;
  434. WizardSizePercentX, WizardSizePercentY: Integer;
  435. WizardBackColor, WizardBackColorDynamicDark: Integer;
  436. WizardLightControlStyling: TSetupWizardLightControlStyling;
  437. Flags: TMessagesLangOptionsFlags;
  438. end;
  439. TUninstallerMsgTail = packed record
  440. ID: Integer;
  441. Offset: Int64;
  442. end;
  443. const
  444. SetupLdrOffsetTableResID = 11111;
  445. SetupLdrOffsetTableID = 'rDlPtS'#$CD#$E6#$D7#$7B#$0B#$2A;
  446. SetupLdrOffsetTableVersion = 2;
  447. SetupExeModeOffset = $30;
  448. SetupExeModeUninstaller = $6E556E49;
  449. SetupExeModeRegSvr = $53526E49;
  450. UninstallerMsgTailID = $67734D49;
  451. implementation
  452. end.