Jump to content

Uwe Raabe

Members
  • Content Count

    2549
  • Joined

  • Last visited

  • Days Won

    148

Everything posted by Uwe Raabe

  1. Well, it doesn't - it stands for Light/Dark Theme and Desktop (at least the rectangle behind it).
  2. Talking about pedantic: The name len is probably misleading, as when it is used in MyArr[Len] it doesn't represent the actual length of the array any more. In contrast MyArr[High(MyArr)] is always correct. Nevertheless, caching the index might be a good idea anyway: It eliminates some checks - and High(x) needs one additional DEC operation compared to Length(x).
  3. In modern Delphi versions I try to combine record constructors and array concatenation to achieve that: program Project481; {$APPTYPE CONSOLE} type TSomeRec = record SomeField: Integer; public constructor Create(ASomeField: Integer); end; TMyArr = TArray<TSomeRec>; constructor TSomeRec.Create(ASomeField: Integer); begin SomeField := ASomeField; end; procedure Main; var myArr: TMyArr; myRec: TSomeRec; begin myArr := [TSomeRec.Create(0), TSomeRec.Create(1)]; myArr := myArr + [TSomeRec.Create(2)]; Insert([TSomeRec.Create(3)], myArr, 1); for myRec in myArr do begin Writeln(myRec.SomeField); end; Readln; end; begin Main; end.
  4. Project Magician and Selective Debugging are supporting Delphi 10.3 Rio. https://www.uweraabe.de/Blog/2018/11/23/delphi-10-3-rio/ (with download links)
  5. Nothing specific. Does it show in the Info - About dialog under Installed Products? Does the Project Magician menu item exist under the Project menu? BTW, the latter will also give you access to the Global settings.
  6. … reset the IDE Insight toolbar! When IDE Insight suddenly stops working…
  7. Exactly! Check Supported Target Platforms: http://docwiki.embarcadero.com/RADStudio/Rio/en/Supported_Target_Platforms
  8. Uwe Raabe

    Include unused class and its RTTI in the executable

    In case the compiler can evaluate that condition, that might be an issue, but there are many ways to play on the safe side there. Actually creating and freeing the class may come with some costs, though.
  9. Uwe Raabe

    Include unused class and its RTTI in the executable

    That is pretty similar to the original approach described in the topic. In addition, there it is wrapped in a never-true condition to avoid being executed.
  10. In addition you have to add a registry entry in the appropriate BDS Experts key similar to that in the Tokyo one. When I find some time I might add a proper setup.
  11. Uwe Raabe

    Format uses clauses for many units

    Not from inside MMX, but there is a command line tool (see attached). You only have to provide a settings file, like the example provided. UsesCleaner.zip
  12. Uwe Raabe

    ThemesEnabled deprecated..

    I am pretty sure that your code is inside a class derived from TCustomStyleServices (unless you are using with). As ThemesEnabled is a member of TCustomStyleServices so is Enabled. Simply change that ThemesEnabled to Enabled and you should be fine.
  13. Given that file access is almost sequential (remember how hard drives work), I assume that the OS will serialize those parallel tasks in the end anyway. But perhaps I am just missing something.
  14. Uwe Raabe

    MMX for Delphi 10.3 Rio

    Actually, I would hate reading such code. It is distracting and extends the amount to read with no real information gain. It's a TButton - I don't care where it is declared. If I want to know I use Code Insight. There already is such an AddIn and it is called Pascal Expert. The corresponding report is STWA2:
  15. Uwe Raabe

    MMX for Delphi 10.3 Rio

    If Contains means a simple text search and given your example above, that would return the first unit where TButton is used or declared. Actually, there exists something like that in MMX used for auto adding units to the uses clause when a specific type is used (see General Settings under Parsing). Unfortunately, in my opinion, that too often gives false results, because it relies on pre-scanned units and not resolving the units found inside the uses clauses.
  16. Uwe Raabe

    MMX for Delphi 10.3 Rio

    Let's take that as a sign that implementing this feature is probably far from easy.
  17. Uwe Raabe

    MMX for Delphi 10.3 Rio

    Unfortunately that is way more complicated than resolving the unit scope names. It requires to find out where that identifier is declared with respect to the current scope and uses clauses. While Code Insight does have this information and therefore can offer this "Find Declaration" functionality (with all its quirks), MMX does not and it is not planned to support it. Perhaps, when somewhere in the future MMX uses some sort of compile or syntax check, this might be easier to implement. For the moment it is simply out of bounds. BTW, one of the advantages of MMX is that it usually still works even when the code does not compile. That is because it doesn't use a compiler to analyze the sources.
  18. Uwe Raabe

    MMX for Delphi 10.3 Rio

    No.
  19. The idea was that the search paths are taken from the current project configuration. Seems like that is not the case here. I wonder if these settings will become obsolete whenever that mechanism actually works and they are auto-updated whenever the project or its current build configuration changes. That would leave the $IF Expressions and the Lattix LDP file as the only adjustable values (not sure if the latter is actually used by anyone else than myself).
  20. I wonder if the situation on G+ has been any different.
  21. Just uploaded V1.0.8 with Rio Support
  22. This release addresses problems with disabled IDE themes and Delphi 10.2 Tokyo releases below 10.2.3 (and some smaller bugs): https://www.mmx-delphi.de/2018/12/31/bugfix-release-for-mmx-code-explorer/
  23. Uwe Raabe

    Forward declarations

    Basically it is like declaring the class interface where it is needed and move the implementation to another unit. Very similar to interfaces - just another approach.
  24. Uwe Raabe

    Forward declarations

    No. you have to copy the methods from TPerson as abstract methods to TAbstractPerson. Any properties go to TAbstractPerson with abstract Getters and Setters.
  25. Uwe Raabe

    Forward declarations

    What about TPerson -> TAbstractPerson -> TAmStateObject ?
×