像這樣的接縫只適用於真正的德爾福怪才。
This is how it looks (sorry, can't post images)
Delphi IDE ugly toolbar
alt text http://i.piccy.info/i4/da/ac/ 6e4748778dcfdc13ec5fede3a7e0.png
What's wrong - disabled Delphi IDE toolbar and
menu buttons are ugly black/white images.
What I want to do - make them look
gray-scaled.
How? I made some research. Main problem in
virtual TCustomImageList.DoDraw
method. When paramater
Enabled = False
it paints ugly things (see disabled
buttons on screenshot). I created my own override for this function
and it paints gray-scaled images when Enabled =
False
現在我想在IDE中使用我自己的 替換默認的 DoDraw
(使用設計時包):
- 我想出了單元ImgList被編譯進了bds.exe,因此在
rtlXXX.bpl
中修補這個函數的技巧將不起作用。 - 搜索函數的正文內容沒有結果。看起來像
DoDraw
的bds.exe的實現(我是關於機器碼的talikng)有點不同。
Any suggestions or ideas of how can I make this possible? As
base example of runtime code patching I took Andy's Midas Speed
Fix: FindMethodPtr
, HookProc
,
UnhookProc