A Dark Pattern is a type of user interface that appears to have been carefully crafted to trick users into doing things, such as buying insurance with their purchase or signing up for recurring bills.
We developers have a big responsibility. Martin Fowler and Erik Dörnenburg (both ThoughtWorks) did a great presentation about that at the GOTO Aarhus 2014 Conference.
A quote:
“The developer who wrote that code is every bit as responsible as the person who told them to do it. You have a choice. You have a responsibility to ensure that your users are well treated and to reject dark patterns,” says Fowler. “We have a whole profession of people writing software and doing enormous things to change the way we live in the world.”
The Delphi MESSAGE directive is a very powerful one, you can generate compiler hints, warnings and errors with it, even fatal ones that abort compilation.
The compiler will return error codes H1054 (hint), W1054 (warning), E1054 (error) or F1054 (fatal error), which in the documentation are known under the catch-all x1054.
You need to take a bit of care with message directives, especially with the quotes. For instance
{$Message Error 'Not implemented'}
gives you the error below, but continues compiling:
[DCC Error] E1054 Not implemented
However, if you forget the single quotes
{$Message Error Not implemented}
it gives you error E1030 (not x1054), which is a bit confusing as it is a catch-all for invalid directives:
Delphi and 3rd party tools keep some of the settings in your %AppData% directory. Much more convenient than the registry as they are easier to read and modify when needed (also easier to damage <g>). We’ll start with an overview where various versions of Delphi store their configuration files, then show how the Favourites on the Welcome Page are stored, then end with an overview of BDS, Company Names and Product Names. Read the rest of this entry »
I’ve been experimenting with the Delphi hinting directives lately to make it easier to migrate some libraries to newer versions of Delphi and newer platforms.
Up to Delphi 5 you didn’t have any means to declare code obsolete. You had to find clever ways around it.
Warnings for hinting directives
When referring to identifiers marked with a hinting directive, you can get various warning messages that depend on the kind of identifier: unit, or other symbol. Read the rest of this entry »
At a client without my own VMs, I wanted to create a DebugBreak like function in Delphi, which I remembered from my Turbo Pascal days to be something like Inline($CC). So searching for both Delphi and INT 3, I found an EXE injection page at NTCore.