Archive for the ‘Delphi’ Category
Posted by jpluimers on 2017/04/18
One of the reasons I favour using RTL based functionality over Delphi Intrinsic Routines like Length, Abs and others is that you cannot use compiler intrinsics in Generics. For instance Length is not compatible with TFunc<string, Integer> unless you declare it yourself like function StringLength(value: string): Integer; as otherwise you get en E2029 error (in this case the cryptic '(' expected but ';' found).
It’s one of the many areas where the Delphi compiler developers took a shortcut, but in this case I think the results are somewhat good.
Other reasons for using the RTL over compiler intrinsics have to do with scoping: the intrinsics are in the global scope which can clutter what you’re trying to work on.
So I much rather use the file and stream related functions when I’m actually working with a file or stream. For instance Assign for me has nothing to do with a file outside of a file context (it’s the reason AssignFile exists in the first place).
–jeroen
via: I cant use “Length” as a TFunc (tested in XE and XE6), but if…
Posted in Conference Topics, Conferences, Delphi, Delphi 10 Seattle, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Event, Software Development | 1 Comment »
Posted by jpluimers on 2017/03/29
Marco Cantú posted the below solution when ActiveX is missing in your File -> New dialog which I’ve paraphrased:
OK, you can try this.
- Close RAD Studio/Delphi.
- Open the registry editor.
- Under
HKEY_CURRENT_USER, open the Known IDE Packages\Delphi — that is something like HKEY_CURRENT_USER\SOFTWARE\Embarcadero\BDS\18.0\Known IDE Packages\Delphi —
- Search for the
delphicompro240.bpl, entry
- Edit it: remove the
__ (double-underscore) pre-pended to the value (Untitled). In other word, change “__(Untitled)” into “(Untitled)“.
- Close registry editor.
- Open the IDE.
I ran it it recently and was glad this worked.
–jeroen
Source: Hey! I have a new Delphi :)…Great! And what to do now with my favorite…
Posted in Delphi, Delphi 10.1 Berlin (BigBen), Development, Software Development | Leave a Comment »
Posted by jpluimers on 2017/03/23
A while ago – while researching yesterdays post – I came across the below article that I wrote back in august 2000 for The Delphi (by Pinnacle Publishing – long gone by now) and on-line at http://www.delphidevelopernewsletter.com/dd/DDMag.nsf/WebIndexByIssue/B8FC16D8103A3760852568F600559A83
I found a cached copy first at http://www.txsz.net/xs/delphi/2/%E6%8A%80%E5%B7%A7%E5%8F%8A%E7%BB%8F%E9%AA%8C/KYLIX%EF%BC%9A%20%E7%9C%9F%E7%9B%B8.HTM and back-tracked from there.
Since the wayback machine isn’t indexed, I salvaged the copy below.
On the Delphi Tokyo release yesterday [WayBack] Tokyo is available today! – Martin Sedgewick – Google+: I will only try that after Update 1 is released, but based on the [WayBack] What’s New – RAD Studio:
Like
- Reintroduction of Linux support. Finally.
- 64-bit as target: server side, the 32-bit days have been over for a long time
- one-based strings (boy, I’m glad they didn’t continue on the zero-based strings they did on mobile)
Dislike
- No openSUSE support where SuSE was the primary partner during Kylix development and launch, just search SuSE kylix; heck the registration guide is still up at [WayBack] SDB:Kylix – openSUSE
- LLVM compiler as it is way too slow for my development cycles
- ARC based
Time will tell if it works better for me than the .NET Core for Linux I’ve been using until now.
–jeroen
Read the rest of this entry »
Posted in *nix, Delphi, Development, History, Kylix, Linux, openSuSE, Power User, Software Development, SuSE Linux | 4 Comments »
Posted by jpluimers on 2017/03/22
Last year, when Warren Postma wrote, I started digging for some articles I wrote about Kylix (the Delphi for Linux at the start of this century).
The second article I found (Delphi for Linux is on the Way!) was actually the first one I wrote, so I’ve put the copy below. The second article will be in my blog tomorrow.
The article below first appeared at the Pinnacle Publishing site at http://www.pinpub.com/delphi/kylix1.htm as an article for “Delphi Developers Journal” that went out of business just like “Hardcore Delphi” and “Delphi Informant Magazine” went before (actually Blaise Pascal Magazine is about the only Delphi related magazine left).
I found the title of my article through http://www.newsmth.net/bbsanc.php?path=%2Fgroups%2Fcomp.faq%2FDelphi%2FAboutDelphi%2FKylix%2FM.967808208.A then back-tracked the title via http://www.inner-smile.com/delphin.phtml
–jeroen
Posted in Delphi, Development, History, Kylix, Software Development | Leave a Comment »
Posted by jpluimers on 2017/03/21
I totally forgot that GExperts can be under the Tools men
These keyboard shortcuts are only assigned when you install GExperts before you install ModelMaker Code Explorer.
If you reverse, then you have to fiddle by removing the ModelMaker Code Explorer expert, then re-add it.
Anyway: you can configure this in the “IDE” tab of the GExperts Configuration.
After that you have to restart the Delphi IDE to reflect the change.
–jeroen
Source: GExperts Help
Posted in Delphi, Development, GExperts, Keyboards and Keyboard Shortcuts, ModelMaker Code Explorer, Power User, Software Development | 2 Comments »
Posted by jpluimers on 2017/03/08
Last week there was a nice poke by Stefan Glienke around the Delphi nextgen compiler being used for the upcoming Intel x64 Linux support in Delphi (yes, no Arm there, hopefully somewhere in the future) at [Archive.is] Using Delphi nextgen compilers … https://xkcd.com/303/
It resulted into a nice thread of strengths and weaknesses of the classic and nextgen compilers.
I’m emphasising a long term wish for the Win32 platform to have two compilers: a classic one and an LLVM nextgen one.
Reasons include this:
- Various compiler architectures can emit code for the same end-platformm: Kylix Linux x86 support uses the classic compiler, new Linux x64 support is using the LLVM nextgen compiler
- Debugging non-Win32 (x86 on Windows) is slow and buggy at best
- LLVM nextgen compiler takes about 2 orders of magnitude longer than the classic compiler
- the classic compiler has various optimisation deficits for about 2 decades and won’t be fixed
- the LLVM nextgen compiler has many more optimisation opportunities than the classic compiler
- the LLVM nextgen compiler supports zerobased strings and ARC which are almost impossible to debug because of the debugger issues so writing truly cross platform code using Delphi is a drag
So, please please please Delphi team: provide an LLVM nextgen compiler for the Win32 platform.
via: [Archive.is] Using Delphi nextgen compilers … https://xkcd.com/303/
Recommended video: [WayBack] The recent next gen compiler debate reminded me of this nice talk.This is about c++ but it shows off nicely what a high quality compiler can achieve in terms of optimisation… – Christoph Hillefeld – Google+
–jeroen
Read the rest of this entry »
Posted in Delphi, Development, Software Development | 1 Comment »
Posted by jpluimers on 2017/02/28
[WayBack] New book by +Nick Hodges tech preview by +Stefan Glienke https://leanpub.com/dependencyinjectionindelphi – via Jeroen Wiert Pluimers – Google+:
This book covers Dependency Injection from A to Z. In it you’ll learn about Constructor Injection, Property Injection, and Method Injection. You’ll learn about the right and wrong way to use the Dependency Injection Container.
Source: Dependency Injection In Delphi by Nick Hodges [Leanpub PDF/iPad/Kindle]
This is the Chapter List:
- What is Dependency Injection
- Benefits of Dependency Injection
- Constructor Injection
- Property Injection
- Method Injection
- Using the Container
- A Simple Migration Example
- Advanced Uses of the Container
- Dependency Injection Anti-patterns
- A Full, Useful Example
- Final Thoughts
–jeroen
Source: New book by +Nick Hodges tech preview by +Stefan Glienke https://leanpub.com/…
Posted in Delphi, Delphi 10 Seattle, Delphi 10.1 Berlin (BigBen), Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Software Development | Leave a Comment »