Pupils often use code like
if thestring[n] = 'Ä' then begin
...
end;
Now explain them why that doesn't work but
if thestring[n] = 'A' then begin
...
end;
is OK. BTW there are not only pupils who like to use " if thecharacter = 'Ä' then". ;-)
Regarding pupils, I often see Lazarus homework code like
thedisplaylabel.text = inttostr(strtoint(theedit1.text) + strtoint(theedit2.text));
I think there should be an initiative to build a set of easy to use dedicated dataedit and datadisplay widgets with a unified interface as MSEgui provides. In MSEgui above code looks like
thedisplay.value:= theedit1.value + theedit2.value;
All data editwidgets have "onsetvalue" with a dedicated "value" parameter and "ondataentered" events:
setintegereventty = procedure(const sender: tobject; var avalue: integer;
var accept: boolean) of object;
setbooleaneventty = procedure(const sender: tobject; var avalue: boolean;
var accept: boolean) of object;
...
notifyeventty = procedure (const sender: tobject) of object; //for ondataentered
fpGUI has a similar approach AFAIK.
In my opinion Lazarus often provides suboptimal solutions probably mostly because of the Delphi compatibility corset and the argument "if it is good enough for Delphi it is good enough for Lazarus". But that is wrong because for Delphi there are many high quality third party component sets available which can be used in place of the very limited original Delphi components.