Personally I don't like the IFF function a lot. The C's "?:" operator is quite tricky and isn't easy to translate it to Pascal as you may think. Note that in C, when the "?:" operator is executed, only the "TRUE" part of the operator is executed (even if the compiler isn't configured to cut-away boolean expressions!) but in Pascal when the IFF function is called then both parts are executed, so side effects may occur (fortunately it isn't your case, but it might be!). Also it isn't too readable.

Personally I recommend you to use an IF ... THEN ... ELSE ... statement to assign a variable and then use that variable in the FOR loop:
Code:
  IF DragPnt.X > x2 THEN
    StartX :=  x2 - startpnt.x
  ELSE
    StartX :=  xselection;

  FOR X := StartX DOWNTO 0 DO
   ...
About the "if" statement inside "for" statement, it is not possible in Pascal (AFAIK). Note that in C (and in C++) everything is an expression, so everything return a value (sometimes its a void value, but it is a value). That allows you to do a lot of weird stuff like the "for( int i = elevator1CurrentStatus.floorNumber; (if(boundary == 9) i<boundary else i>boundary) ;i+=i+countDirection)" you linked. Even weirder:
Code:
int a[10];

a[2]=20;
3[a]=4; /* Assigning a value to an integer constant? */
It is "correct", compiles and runs in most major compilers*...

Again, I recommend you the IF .. THEN ... ELSE ... statement.

I really like C language but its "for" statement is actually "a WHILE loop with embedded entering section and two execution blocks specially designed to confuse you". It's so flexible that sometimes it brings you more problems than solutions, but it's a really nice feature that allows to hide your algorithms pretty well.