Jump to content

Anders Melander

Members
  • Content Count

    2289
  • Joined

  • Last visited

  • Days Won

    117

Everything posted by Anders Melander

  1. Anders Melander

    Adding an icon for an ActiveX control

    https://docs.microsoft.com/en-us/windows/win32/com/activex-controls-registry-information You can add the 16x15 bitmap to your Delphi project using Project > Resources and Images. Searching the Delphi source for "ToolboxBitmap32" I can see that TActiveXControlFactory has a ToolboxBitmapID property which you can use to specify the resource ID of the bitmap. The value of this property is written to the registry when the ActiveX control is registered. A .dcr file usually just contains the Delphi design time glyph of a component - I.e. the glyph you see on the component palette in Delphi. It has nothing to do with ActiveX controls.
  2. https://en.wikipedia.org/wiki/Law_of_triviality
  3. Exactly. It's pretty pointless to suggest different ways of doing conversion if the conversion will be done with TryStrToFloat, StrToFloat or the like. And it's even more pointless when this is in all likelihood premature optimization.
  4. The only built-in way to determine if a string can be converted by TryStrToFloat is to use TryStrToFloat. You could reverse engineer TryStrToFloat to make a version that only parsed the string and didn't actually do the conversion but my guess is that the majority of time used by TryStrToFloat is used by the parser, not by the conversion. But if you are reading from a text file then it's likely that the I/O will be your real bottleneck and as David hints at, you should profile first and optimize next.
  5. It depends on what you mean by "can be converted to number". If your definition is that TryStrToFloat returns True, then the answer is no. If you're willing to give up some of the features of TryStrToFloat then the answer is yes, but you are going to have to implement it yourself - in assembler. But why do you need it to be faster? Is it a bottleneck for you?
  6. Anders Melander

    rabbitmq-delphi release

    https://www.rabbitmq.com/protocols.html#amqp-10
  7. Anders Melander

    rabbitmq-delphi release

    Are you asking if RabbitMQ supports AMQP 1.0?
  8. Anders Melander

    document projects

    You don't need to add your own sub-fora. Just post in the main Delphi Third-Party.
  9. Anders Melander

    document projects

  10. Anders Melander

    document projects

    This belongs in Delphi Third Party.
  11. Anders Melander

    Herb Sutter on C++20

    Well, it's not that I don't envy the versatility of C++ but I really don't enjoy trying to maintain (or even just read) code that fully uses that versatility.
  12. Anders Melander

    Herb Sutter on C++20

    One hour into the video I wanted to shoot myself in the head - But then I remembered that I no longer program in C++ 🙂 Apart from that; Good stuff. When I heard Bjarne at the end I thought: He sounds tired of C++. Maybe he should try Delphi 🙂
  13. Anders Melander

    Is Graphics32 ready for Delphi 11 yet?

    That request is almost older than Delphi itself. I get that they're not interested in making it easier to use old versions of the product, but I don't get that they aren't interested in making the lives of 3rd party developers easier (in this regard at least).
  14. Anders Melander

    Looking for Spreadsheet component

    I haven't used the Develop Express spreadsheet (except that it seems that all their other controls now has dependencies on it 😞) but I would think it'd be trivial to maintain a dictionary on the side that links objects to cells...? type TCellReference = record Row: integer; Column: integer; end; TCellStuff = TObjectDictionary<TCellReference, TObject>; Also, if the spreadsheet architecture is anything like their other controls, then you should be able to customize what class is used to represent cells.
  15. Anders Melander

    Async Tasks in VCL Projects

    Y-key broken?
  16. Anders Melander

    Is Graphics32 ready for Delphi 11 yet?

    I agree. In my own code I assume "unknown version" = Last known version+1. That way new versions doesn't break the code and I very rarely need to update the include file.
  17. Anders Melander

    Is Graphics32 ready for Delphi 11 yet?

    I've just committed updated packages for Delphi 11 and added Delphi 11 to GR32_Compiler.inc (and cleaned it up a bit).
  18. Anders Melander

    Is Graphics32 ready for Delphi 11 yet?

    I would think that it's just a matter of adjusting the dependencies of the existing packages with the corresponding D11 dependencies and recompile, but I'll look into it.
  19. Anders Melander

    What is ProDellInterface27 in the Delphi IDE???

    There's only one L in ProDelInterface27.
  20. Anders Melander

    Exception classes implementing interfaces

    How is more clear than ?
  21. Anders Melander

    Exception classes implementing interfaces

    Yes, it probably could be done, but should it? It's not a bad idea, but without low level compiler support (on E: IMyError do ... ) I wouldn't do it. Personally I want my error handling to be as simple and robust as possible so it doesn't potentially make a bad situation worse.
  22. Anders Melander

    One-button app to stop all explorer windows from flashing.

    Upgrade from Windows 2000 🙂
  23. Anders Melander

    Hot Reload in Delphi?

    I'm not questioning the usefulness of it. I would absolutely love that feature. I'm questioning why Embarcadero would want to invite the inevitable complaints when the feature, inevitably, failed to work 100% of the time - or even just not as good as VC/VC++. AFAIK, what UE does is just reloading dynamic DLLs if you recompile them. Not really comparable I think.
  24. Anders Melander

    Hot Reload in Delphi?

    Makes sense. Thanks.
  25. Anders Melander

    Hot Reload in Delphi?

    I know you're just venting, but I can't see how they could achieve it even if the debugger was better... or why they should.
×