Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 02/21/25 in Posts

  1. dummzeuch

    pasfmt out now!

    If only there was a code formatter written in Delphi that is open source!
  2. Stefan Glienke

    Guidance on FreeAndNil for Delphi noob

    The best practice is coding in a way that you don't need it
  3. pyscripter

    SynEdit now has annotated Scrollbars.

    A new powerful highlighter called Omni (for omnipotent) has been added to SynEdit. Importantly, this highlighter allows the saving/loading of highlighter settings to/from ini files. The project now includes 189 new ini-based highlighters in addition to the 75 ones that were already included. Sample using the PowerShell ini-based highlighter. Notice that code-folding is automatically supported. Structure highlighting is also supported: A component editor has also been added that can be used at both design and run-time. See this discussion for details. This is based on a significant code contribution by Jan Fiala, the author of PSPad. Kudos to Jan!
  4. Joshua Gardner

    pasfmt out now!

    We're excited to share the first public release of pasfmt, a free and open-source code formatter for Delphi. It is a complete and opinionated formatting tool. The latest release has support for: Complete line wrapping (and unwrapping) for all Delphi structures Configurable line length limit Removing trailing whitespace Change spacing around all tokens (e.g., operators and keywords) Parallel file formatting with directory traversal Removing repeated empty newlines Line ending normalisation To get started, either try our web demo, or download the executable (this one for Windows) and follow the getting started guide. Additionally, there is an IDE plugin with support for: In-editor formatting Format-on-save Cursor tracking You may be wondering how this tool compares to the existing formatters (e.g., GExperts, JEDI, Formatter.exe). This tool goes a lot further than the alternatives by having a complete opinion on how every line should be wrapped or unwrapped; the original layout is (almost) ignored. By ignoring most of the input format, it produces consistently styled code across a whole codebase. We hope that you enjoy pasfmt, let us know what you think!
  5. Glenn Dufke

    pasfmt out now!

    Don't worry, there will be lots of documentation. - And I might even be generous enough to open source it. I would, however, strongly recommend rewriting pasfmt in a more sane language sooner rather than later.
  6. Vincent Parrett

    pasfmt out now!

    Sadly not. I don't want to be littering my code with //formatting off/on etc. So I format by hand and it is what it is.
  7. Joshua Gardner

    pasfmt out now!

    It is a fair enough question. In the context of a code formatter, it means that it has a strong opinion on what the code should look like. Predominantly, this manifests in having few or no configuration options and a highly consistent style. Other formatters like prettier, biome, and google-java-format call themselves opinionated.
  8. Glenn Dufke

    pasfmt out now!

    Great idea crumbled by rust. There are other languages which would have been more appropriate to use for the implementation and would make contributions easier. Sad. And to expand on that: When picking an implementation language, besides evaluating what solves the problem at hand, you also have to consider target community and who are going to deal with it down the line - especially for open source projects and that weighs higher than one's favorite language. Rust has a toxic community, an ecosystem mess akin to npm and overall just a poorly designed language with unnecessary complexity driven up by hype. (I know this from first hand experience of having to deal with rust projects before and digging inside the rust compiler) While some have drunk the rust kool-aid, I'd rather have seen Modern Object Pascal used or, if you want to be fancy, Zig. There are good reasons why many prominent projects are abandoning rust.
  9. Stefan Glienke

    Looking but not finding...

    That comment didn't age well I guess
  10. Wow. A Microsoft scanner being lenient on an app written by a Microsoft compiler, and harder on an app written by a competitor's compiler. Who would have thought... 😜 And we all know how well AI writes good code...
  11. Uwe Raabe

    Keyboard shortcut stolen

    IIRC, Snagit has that as default shortcut.
  12. Kas Ob.

    TDirectory - file lock out on Win 10 LTSC

    TO be honest it is not exactly a service but stapled to one, see this cryptic error most likely caused and reported from User-Mode Driver, as kernel mode driver are more detailed error, yet in both cases these drivers belong and part of to an OS service as mentioned above, i think it is between System Restore, Defender or some network mapped drive.
  13. dummzeuch

    pasfmt out now!

    Hey, we have AI nowadays to solve that problem: Just tell it to convert the rust code to Object Pascal and be done. And if the first one does not succeed, try others.
  14. Dave Nottage

    pasfmt out now!

    None of them have a: "Don't touch my assignment alignments" option? 🙂
  15. Remy Lebeau

    Using a DLL in MSVC

    They are using the same DLL instance? That is not how you should make the import lib for MSVC. Use MSVC's command-line DUMPBIN and LIB tools to create a new import lib from the DLL itself. Use DUMPBIN to create a .DEF file for the DLL's exports, and then use LIB to generate a import lib from the .DEF file. Which items are you referring to exactly? There is nothing "bold" in what you showed. You really should not be calling Application->ProcessMessages() at all. What is the actual crash? What is the error message, verbatim? Does the crash happen while the DLL is being loaded into memory, or inside of DllEntryPoint()? Have you tried debugging the DLL in the IDE? Configure your DLL project with your MSVC app exe as its Host. Then put breakpoints in the DLL code as needed. When you run the DLL project, it will execute the MSVC app, which will then load your DLL, and the debugger should attach to it so it can step through the DLL code normally.
  16. bravesofts

    VCL UI Design Challenge for Delphi Developers 💡

    Windows Composition API Is Still WinAPI ? Even though it’s sometimes called the “composition API,” functions like SetWindowCompositionAttribute or DwmSetWindowAttribute are exported from system DLLs (e.g., user32.dll or dwmapi.dll) and thus part of the Windows API. On Windows 11, you can apply Acrylic (DWMSBT_ACRYLIC) or Mica (DWMSBT_MAINWINDOW) to a window without a custom GPU pipeline, and it’s still hardware-accelerated by DWM behind the scenes. Delphi Borderless Form Native Windows 11 Rounded Corners You can request real rounded corners via the Windows 11 API
  17. Rick_Delphi

    Looking but not finding...

    I have found a startup or two that is using Delphi. But, I'm not really looking for that kind of situation. Too much of a roller coaster ride for me.
  18. Dave Nottage

    Delphi iOS Push Notifications (APNS)

    My bad.. I had forgotten that I did some modifications to Grijjy.OAuth2.pas to allow signing with ES256 as well as RS256. For now, I've attached the modified unit here. Please place it in the same folder as the project. Grijjy.OAuth2.pas
  19. Dave Nottage

    Delphi iOS Push Notifications (APNS)

    These parts make the whole answer smell of AI - a bad one, since those folders do not exist
  20. dummzeuch

    pasfmt out now!

    Am I right in assuming that the plugin calls the executable to do the formatting? Calling an executable is rather expensive (meaning: slow) in Windows, it would be really nice it you could also produce a DLL, that can be called from this plugin (and possibly other tools). 32 and 64 bits, if possible.
  21. Lars Fosdal

    pasfmt out now!

    My formatting is so quirky that I prefer to hand-craft it.
  22. Must be something specific on your PC. Using Delphi 12.2 Patch 2 on Windows 10 64-bit, when I create an INI file with the specifications you have described, it takes only 150ms with TIniFile. Switch to TMemIniFile and that drops to under 5ms.
  23. GabrielMoraru

    I refactor your old code for free!

    Hi there I started my own Delphi YouTube channel and I want to create more content. Therefore, I came up with this idea. Let me know... O:-)
  24. A.M. Hoornweg

    What new features would you like to see in Delphi 13?

    I want "F2084 Internal Error L902" gone !!!
  25. Brandon Staggs

    What new features would you like to see in Delphi 13?

    Some of my stuff is in the QA portal (menu fixes I think) and I still have to use it despite the reports being marked "fixed." But most of my workarounds are done on-the-fly with my own inherited form and frame classes and would be too much bother for me to pull out to show anybody. I guess if I were to share a "feel" for how it's going, I'd say it's getting better. I think Embarcadero should force their developers to use their own IDE in a mixed-DPI environment in various configurations and not stop fixing scaling issues until they can do everything seamlessly. Who knows, maybe they already have, and they just aren't exposing the problems I run into.
×