Re:DCR vs DCU
Remy Lebeau (TeamB) wrote:
Quote
For components written in C++, I suggest using .RES instead. .DCR is meant
for Delphi. I've been using .RES in my components for years without any
problem.
Thanks for the suggestion. I had in fact already asked to myself which the conceptual difference between DCR and RES
files could be, but you are now confirming to me that there is none, only one related to the language used.
Quote
I don't think 24-bit images are supported. I think you can use 8-bit
images, though.
Well I tried with 24-bit colors (8 bits per components R,G,B), and apparently they work.
No, it is not. A .DCU file is a compiled Pascal unit, similar to .obj for
.cpp files in C++. Component vendors who do not want to provide their
source code must provide .DCU files for each supported compiler version
instead.
Thanks. Mystery solved. But now I have another question....
When I compile my component library as a package, after the final linking I click on Component | Install Packeges...
then I select my library and click on Components. At this point I am able to see all my components with the correct
icons. Then I close the package and open a project that makes use of that library. When editing a form, on the right
side of the screen there is a palette of components that I can use on that form. I select the tab with the name I gave
to my library, but the components are then listed there with the default icon of three geometric shapes used when you
did not provide a DCR (or RES) file for that component.
And this is not the only weirdness... a few (only a few) of the components have an icon, but *not* the icon I put in the
DCR file... it is like the compiler had searched in the wrong place to find my icons...
Before you ask, yes, I made sure that the name of the bitmap in the DCR file was T followed by the name of the component
in capital case. and set to "Language Neutral"
I'm scratching my head on this already since some time, but haven't found so far a solution...
Thanks for any help
Alberto di Bene