Archive for the ‘Delphi’ Category
Posted by jpluimers on 2015/12/15
Bug, also in Delphi 2007:
Just hit Insert twice (which changes the text entry mode between Insert and Overwrite and then back) and your text selection will be back to working normally.
Source: delphi – RAD Studio 2009 Persistent Selection Issue: Bug or Feature? – Stack Overflow
–jeroen
Posted in Delphi, Development, Software Development | Leave a Comment »
Posted by jpluimers on 2015/12/08
Interesting reads despite the level of English:
GUI-testing. Table of contents
–jeroen
via: 18-ть лет с Delphi: GUI-testing. Table of contents
Posted in Delphi, Development, Software Development | Leave a Comment »
Posted by jpluimers on 2015/12/03
Nested DataSet fields assume identical naming of fields and parameters as Richard Stevens did comment in So I’m in total n00b mode here. I’m trying to set up a master/detail….
Of course the documentation for that is easy to find. Not.
Even this article by Cary Jensen doesn’t reveal the issue: Nesting DataSets in ClientDataSets.
So thanks Richard for clearing that up!
–jeroen
Posted in Delphi, Delphi 10 Seattle, Delphi 2007, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Software Development | Leave a Comment »
Posted by jpluimers on 2015/12/02
Reading a thread with ramblings on failing to understand that packed records overrides the $ALING directive, I found out that there is also an Undocumented Delphi record alignment directive – Chee Wee’s blog: IT solutions for Singapore and companies worldwide.
David Heffernan mentioned some nice permutations in the first thread.Chee Wee Chua “documents” the second. Both provide great reference material.
Note that both directive require a const expressions evaluating to a power of two. If you don’t, you get the same error: E2573 Illegal value for the ALIGN directive (valid for one of 1, 2, 4, 8 or 16) (Delphi) – RAD Studio
–jeroen
via:
Posted in Delphi, Delphi 10 Seattle, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Software Development | 2 Comments »
Posted by jpluimers on 2015/12/02
A small video reference to the work that Peter Sollich did for the Pascal world is at around 38:20 in this video: https://www.youtube.com/watch?v=btGj-PocjeU#t=2298
It is where Allen Bauer talks about his early years at Borland. He talks about a German guy there without naming him. It is Peter Sollich (he names them a few time in the newsgroups though).
Peter Sollich came from Germany where he had written a Turbo Pascal compatible compiler for the Atari ST (it used a m68k Motorola 68000 CPU which is a 32-bit processor on the internal side with a 16-bit wide data bus (transporting 16-bit words) on the outside using a 24-bit address (so it can address 16 mebibytes of memory) – hence ST for Sixteen/Thirtytwo).
Borland bought the source code which formed the base for the current 32-bit x86 compiler implementations of both Delphi and C++ Builder (they hired him as a contractor to do the port).
Rumour goes that Peter wrote many parts of the x86 code emitter on the flight from Europe to the USA.
Before the ST era there was already a CP/M Modula-2 compiler written by Peter Sollich and Martin Odersky which Borland bought even earlier and was turned into Turbo Modula-2.
For people interested, here are some links with ore details – where possible I saved them in the WayBack machine as sites tend to Ditch historically important information:
–jeroen
Posted in .NET, Borland Pascal, Delphi, Development, Pascal, Software Development, Turbo Pascal | 4 Comments »
Posted by jpluimers on 2015/12/01
On the todo list:
Interesting use of an IDE plugin: Copy a string from a “Watch” entry to the clipboard without quotes. – Thomas Mueller (dummzeuch) – Google+
Source: delphi – Can I change the display format for strings in the watch list? – Stack Overflow:
Every now and then I use the watch window to display strings which contain sql statements.Now I select Copy Value from the context menu and get
'SELECT NAME FROM SAMPLE_TABLE WHERE FIRST_NAME = ''George'''#$D#$A
but want
SELECT NAME FROM SAMPLE_TABLE WHERE FIRST_NAME = 'George'
The answer by MartynA has an OTA plugin that could be integrated with something like GExperts.
–jeroen
via: Interesting use of an IDE plugin: Copy a string from a “Watch” entry to the clipboard…
Posted in Delphi, Delphi 10 Seattle, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 7, Delphi x64, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Software Development | Leave a Comment »
Posted by jpluimers on 2015/11/24
A while ago, I came across a class having (among other members) two methods named like this:
Within one of the other members of the class, I had to (temporarily) Stop processing, then Start it again.
But I couldn’t, as neither Start, nor Stop would make a record of the state it left the instance in.
Always ensure you know the state of an instance.
So I added the state, and tests to ensure a Stop/Start change was indeed not breaking things.
–jeroen
Posted in .NET, .NET 1.x, .NET 2.0, .NET 3.0, .NET 3.5, .NET 4.0, .NET 4.5, C#, C# 1.0, C# 2.0, C# 3.0, C# 4.0, C# 5.0, C# 6 (Roslyn), Delphi, Delphi 10 Seattle, Delphi 2007, Delphi 2009, Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Software Development | 1 Comment »
Posted by jpluimers on 2015/11/18
I missed when the StackExchange App for Android was finally launched, but I totally agree with Paul Lammertsma:
Exceeds expectations This was a long time coming, but it didn’t disappoint. It’s a great aid for a regular on Stack Overflow like me!
–jeroen
via Stack Exchange – Android Apps on Google Play.
Posted in .NET, Delphi, Development, Pingback, Power User, Software Development, Stackoverflow | Leave a Comment »
Posted by jpluimers on 2015/11/04
From a chat with a co-worker a while ago:
|
I’m not against properties. Just something against properties properties that are objects with writeable fields.
|
So even if you expose such a property as read-only, it can still get its writeable fields overwritten.
That is a pain when those are part of the state of the underlying object.
In other words: encapsulate your state changes.
Here we solved it by making
- the type of the property immutable
- the property writeable
- react on state changes during the write
Proper encapsulation.
In this case it was a project mixing C# and Delphi, but you can easily apply the above to any language featuring classes and properties.
Another solution would have been to extend the type of the property so it can expose an event that fires during change. Much more convoluted.
–jeroen
Posted in .NET, C#, C# 1.0, C# 2.0, C# 3.0, C# 4.0, C# 5.0, C# 6 (Roslyn), Delphi, Delphi 10 Seattle, Delphi 2007, Delphi 2009, Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Delphi XE8, Development, Software Development | 2 Comments »