viktoras wrote:

> Richard Gaskin wrote:
>> That's the natural built-in behavior of the engine: when you strike
>> either the Enter or Return keys, the cursor in the field moves down
>> to the beginning of the next line.
>>
>> Is there something else at play here that I missed?
>
> Yes, therefore I wish to prevent this natural behaviour, as it also
> moves all the text into the new line. What I am after is blocking
> enter, return and passing arrow down instead, so the text in a field
> would remain intact, but cursor moves to the next line without any
> changes to the text.

Gotcha. Thanks for the clarification. Give this a whirl and see if it does what you need -- these handers would go in a field script:

---------


on enterInField
  DoMoveDown
end enterInField

on returnInField
  DoMoveDown
end returnInField

on DoMoveDown
  put (word 2 of the selectedLine) into tLine
  if tLine = the number of lines of me then
    put cr after me
  end if
  select before line (tLine+1) of me
end DoMoveDown




--
 Richard Gaskin
 Fourth World
 Revolution training and consulting: http://www.fourthworld.com
 Webzine for Rev developers: http://www.revjournal.com
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to