Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 06/27/20 in all areas

  1. The new features of this compiler are just untested/unfinished... Even the type helpers are broken with sub-types: if you define TMyInteger = type integer then you can't use myinteger.ToString... Non-inheritance is a "feature" which IMHO is wrong. What always work, and is the very same, is to write: TUsers = array of TUser; > Too bad we are working with Delphi where it does not matter because I can still assign a TUserName to TUserFirstName Yes, only var/out variables have compile-time strong checking... But at least you can read the code and verify the consistency either since the type (and RTTI) are explicit. And refer to the type definition comment as documentation. And it also helps writing more natural code, by having the type defined in the time, not in the parameter I prefer: function CopySession(source, dest: TSessionID): boolean; .... property session: TSessionID; instead of function CopySession(sourceSessionID, destSessionID: integer): boolean ... property sessionID: integer;
  2. Edwin Yip

    SynEdit preferred version?

    This is not the correct process as I understand it, you should: - Fork the repository on github web, so you that have your own repository that you can permission to make changes - Clone your forked repository to your local pc - Change the source code as needed (following the contribution rules, if any) - Commit and push your changes to your forked repository - Make a pull request to the original SynEdit2 repository, and wait for acceptance
  3. I have uploaded a new development snapshot for the (upcoming) IDE Fix Pack 6.5 IDE Fix Pack Snapshot Download What's new: Added: (IDE) Fix for RSP-23006: Edit controls in the ObjectInspector aren't clipped by the scrollbar anymore (10.3+) Added: (IDE) The compile progress dialog is updated only every 80 ms now. And if a remote desktop session is detected it is only updated every 250 ms. The IDE compiler runs in the main thread, so every GUI update affects the compilation time. Added: -x--jdbg compiler option extension that creates and attaches a jdbg-file. You don't need a detailed map file (-GD) anymore to create or attach a jdbg-file for the binary file. Attaching the jdbg PE section is done after the linker closed the binary file. -x--jdbg and -x--jdbg=1 create a jdbg-file -x--jdbg=2 attaches the jdbg data to the executable/dll/bpl. Question: "Why is the jdbg file smaller than my old file?" - Answer: "The old file was created with an older version of JclDebug.pas." Added: -x--unitstats compiler option extension outputs unit filenames for units with "unitname in 'filename'" entries. Added: -x-fvs compiler option extension also generates faster interface call stubs for virtual methods that are final or in a sealed class. Added: Package compilation is a lot faster in the linker and cleanup phase. Added: Faster ObjectTextToBinary (DFM) implementation by removing unnecessary string comparisons. This improves the linker's performance when it converts DFMs to resources. Added: Faster map file creation by using a much faster Sort-By-Address implementation and a faster \n to \r\n converter. Added: Faster unitname to unit filename resolving (unitname in 'filename') The compiler used a Byte as hash-value and a single linked list. The code is now replaced by a hash-map with a 32 bit hash-value. Added: Faster compiler inline handling for projects with lots of units. Added: The command line compiler uses a double linked unit list to remove and reorder items faster. The IDE compiler still uses the original single linked list because some other code in the IDE does something with it and I couldn't make it not crash. Added: LoadString cache for compiler error/warning/hint messages. The compiler loads the warning/hint string and then decides not to show it. The cache prevents the compiler from calling LoadString too often. Added: Some PAnsiChar/PWideChar RTL optimizations for the IDE and IDE Fix Pack. Fixed: Compiler option extensions didn't work in dcc*.cfg and project.cfg files. Now you can specify -x-* options also in *.cfg files. Fixed: Don't crash if a 3rdParty tool destroys the Castalia Clipboard Form. Fixed: -x-cgo compiler option extension crashed the 10.3 compiler. Removed: The "Exception catcher" patch for ErrorInsight is no more. It didn't have any functionality.
  4. santiago

    Ctrl Tab Ide Plugin

    The way the Ctrl+Tab shortcut works in the Delphi IDE was always very inconvenient for me. Actually the Delphi IDE is the only program I can think of that does not navigate open documents based on the order in which they were last activated but instead on the order in which the tabs are arranged in the editor. So if you are were working in DocumentPrevious and switch to DocumentNext, I am used to going back to DocumentPrevious by hitting Ctrl+Tab. But in the Delphi you will navigate to whatever document is on the right side of DocumentNext. This has always been very annoying for me. Anyhow I made plugin that makes Ctrl+Tab behave to what I am used to from other programs, like Visual Studio for example. Might be of use for some. https://github.com/santiagoIT/DelphiCtrlTab Precompiled binaries are available for Delphi Seattle, Rio and Sydney.
  5. MarkShark

    SynEdit preferred version?

    Hey all. I use SynEdit in a few projects and I was wondering if anyone has insight on which of the various version is the preferred one to use. I'm on 10.4 and don't need backwards compatibility btw. The one that is on "GetIt" appears to be an older version (1.5.) The one listed as SynEdit2 on github by pyscripter appears to be active, includes some nice changes (ole drag and drop for example) lots of fixes and cleanup (some related to removing support for older Delphi versions.) The one listed as SynEdit/SynEdit on github which seems to be more actively developed then the other two. I've worked with the second two and, as always, it seems when working with third party components I have to make a few changes to the source (adding some missing properties, fixing the extra space on word wrap lines (thanks to a stack overflow answer) and a few other minor issues) which have to be merged into each new update, so picking the "correct" one will obviously help. On a side note I have a feeling that the correct answer might be that there is no correct answer... Just looking for any feedback or thoughts. And this post wouldn't be complete without thanking and acknowledging all the great work people have done on these projects! -Mark
  6. Georgge Bakh

    Search for Usages not usable

    Find usages is one of the most useful and most frequently used features of a code editor. Must work flawlessly.
  7. santiago

    Ctrl Tab Ide Plugin

    @Dinar Thx for the feedback. You've got fast fingers :-). I have fixed the issue when Ctrl + Tab is pressed and released almost immediately. I will add support for resizing the Window. Once that is done I will publish new binaries to GitHub. I will be out of town for the weekend. So it will most likely happen on Monday. The Welcome Page issue I will have to look into. I never use that page, so I never noticed. I oriented the way the file names are displayed to how Ctrl Tab works inside Visual Studio. The list view displays only the file names, no paths. The full path for the selected file is displayed at the bottom of the list. I find it too cluttered when the full path names are displayed.
  8. Remy Lebeau

    TStrings properties

    Delphi XE Delphi 10.1 Berlin Delphi 8 or 2005, I'm not sure which (I don't have either to look at). It did not exist in Delphi 7, but did exist in 2005.
  9. Stefan Glienke

    TFixedCriticalSection

    Print TCriticalSection.InstanceSize and you know if it was fixed or not - spoiler: no, it was not. On Windows that is - on Posix TCriticalSection simply uses System.TMonitor which allocates at least the size of a cache line
  10. You are not very clear, I believe mars translates everything to unicode, I have no issues with UTF8 encoded content.
  11. Strong typing may be a good idea in some context. For instance, in DDD (Domain Driven Design) you should better define your genuine types. Instead of writing: type TUser = record Name: string; FirstName: string; end; You should rather define: type TUserName = type string; TUserFirstName = type string; TUser = record Name: TUserName; FirstName: TUserFirstName; end; TUsers = type TArray<TUser>; and so on for any service methods. Such strong typing (T* = type ### defines its own strong type) helps maintaining complex code. I always let people remember the https://en.wikipedia.org/wiki/Mars_Climate_Orbiter disaster. A strong type (as it should have been if ADA would still have been used for the software) would have ensured that the force would use the same unit in the inter-module computation (english vs metric systems). Specific types may help e.g. for "Design by contract". Of course, for a DTO you may just use plain string/TArray<string>. But if you want to have some maintainable long-term code, consider define your own types. See e.g. http://blog.synopse.info/post/2019/09/18/Introducing-Kingdom-Driven-Design-at-EKON-23
  12. Excellent news & thanks for the merge.
  13. MarkShark

    SynEdit preferred version?

    Thanks to everyone who responded to this! I'm new to git (and to contributing to open source projects) so I installed a bunch of stuff, cloned the SynEdit2 repository, made a branch (I think that's the correct thing), went to add the wordwrap fix I mentioned above... and found that pyscripter had already fixed it last December and I had totally missed it. Nice! I'm going to attempt a pull request on a very minor fix I have to try to get my feet wet on the process.
  14. pyscripter

    SynEdit preferred version?

    I will start with a bit of history. The Original Code is based on mwCustomEdit.pas by Martin Waldenburg, a great programmer. The key feature of the editor was fast syntax highlighting. This was more than 20 years ago. After a split of the community the SynEdit project was formed maintaining some of the key features of mwEdit. Over the years some of the best Delphi programmers contributed to the project. The list includes for example Gerald Nunn, Eric Grange, Jordan Russell and many many others. Flavio Etrusco added word wrap and Maël Hörz added unicode support (but in a rather idiosyncratic way). However the project management was very weak and the code gradually became very hard to maintain and improve. It aimed to support very old Delphi versions including Kylix and the code became full of IFDEFs and patches without an overall coherence. An early fork of Synedit is part of Lazarus but the two development efforts have diverged a great deal. When Embarcadero introduced the GetIt package manager they asked Roman Kassebaum to produce a version of SynEdit for GetIt. Roman did a general code cleanup removing support for early Delphi versions and Kylix (Turbo fork(s)). I have added support for code folding (the first major new feature for years) to both the Turbo fork and the main Synedit repository. However the Turbo fork(s) were not actively supported or developed beyond recompiling for new Delphi versions and the main Synedit branch was too hard to work with, hence the creation of SynEdit-2 as a fork of Turbo SynEdit. Main new features in SynEdit-2: Replaced SynRegExpr with the built-in RegularExpressions Move/Copy Line(s) Up/Down commands as in VS Code Delete Line command should work with multi-line selection Handle triple and quadruple clicks for selection Triple click and drag should select lines Double click and drag should select whole words Support OLE Drag & Drop What are the key features missing in Synedit: Better Unicode handling: Better support for wide characters e.g. Chinese ideograms (爾雅爾雅爾雅爾雅) Support for surrogate pairs (two widechars correspond to one glyph) Combining characters (e.g. Åström ḱṷṓn) Multi-cursor and multi-selection editing as in VS Code. When these features get implemented I think SynEdit will become comparable to some of the best editors around. But both of them require major rewriting of the code. Work on the second is well advanced and the unicode work is in the planning stage. Of course it is your choice as to which version of SynEdit to use, but if anyone wants to contribute to the development you are very welcome.
  15. Lars Fosdal

    ParnassusCoreEditor.dll AccessViolation

    10.4 has an update to Bookmarks and Navigator. It creates C:\Program Files (x86)\Common Files\ParnassusShared and places ParnassusBookmarks_XSydney.dll ParnassusCoreEditor_XSydney.dll ParnassusNavigator_XSydney.dll So, to cure the 10.3 ailments, copy from C:\Users\<username>\Documents\Embarcadero\Studio\20.0\CatalogRepository\ to the first mentioned common catalog Bookmarks-1.0\ParnassusBookmarks.dll to ParnassusBookmarks_XRio.dll ParnassusCoreEditor-1.0\ParnassusCoreEditor.dll to ParnassusCoreEditor_XRio.dll Navigator-1.0\ParnassusNavigator.dll to ParnassusNavigator_XRio.dll
  16. Anders Melander

    Search for Usages not usable

    Like I said: It work-ish
×