How instruct to the Delphi IDE refresh the modified syntax highlight colors using OTA (Open Tools API)?

后端 未结 2 626
春和景丽
春和景丽 2021-01-11 12:46

I\'m writting a plugin to integrate the Delphi IDE Theme Editor with the Rad Studio IDE (the current version of this tool run as an external application) so far everything i

2条回答
  •  花落未央
    2021-01-11 13:33

    I'd say your best bet would be to snoop around coreide*.@Envoptions@TEnvironmentOptions@EditorSourceOptionsBeforeSave or coreide*.@Envoptions@TEnvironmentOptions@EditorSourceOptionsAfterSave

    These get called when the Ok button gets clicked. I'm not very good at reading assembly but from the looks of it the environment options are loaded from the registery during IDE initialization and any changes made are written back as needed but the IDE depends on the in memory instance of TEnvironmentOptions to be the authoritative representation of all environment options.

    coreide*.@Envoptions@TEnvironmentOptions@GetEdColors appears to be where the colors are retrieved from the environment options for editing by TEditorColor

    It's unfortunate none of these classes is exposed to the OTA or NTA.

提交回复
热议问题