Talk:Terminal control/Cursor movement: Difference between revisions

From Rosetta Code
Content added Content deleted
(added query concerning cursor edge movement. -- ~~~~)
 
(→‎task clarification: my thoughts)
Line 3: Line 3:


It's not stated, but I assume if the curson is at a terminal screen edge, and we want to move it past the edge, that it is assumed that we are to move to the cursor to the other side of the screen (that is, wrap it)? -- [[User:Gerard Schildberger|Gerard Schildberger]] 09:30, 16 August 2012 (UTC)
It's not stated, but I assume if the curson is at a terminal screen edge, and we want to move it past the edge, that it is assumed that we are to move to the cursor to the other side of the screen (that is, wrap it)? -- [[User:Gerard Schildberger|Gerard Schildberger]] 09:30, 16 August 2012 (UTC)
:As you say, it's not stated in the task. Perhaps some clarification is in order.
:Personally, I would do whatever is typical for your language of choice. (For example, this isn't a problem for BASIC, normally -- in MS BASIC, an attempt to place the text cursor off the screen using <code>LOCATE</code> results in an error ("Illegal function call"). The graphical cursor (which serves a completely different purpose) continues on to (effectively) infinity.)
:If there's no "standard" behavior for your chosen language... shrug. Do as you see fit. -- [[User:Eriksiers|Erik Siers]] 11:53, 16 August 2012 (UTC)

Revision as of 11:53, 16 August 2012

task clarification

It's not stated, but I assume if the curson is at a terminal screen edge, and we want to move it past the edge, that it is assumed that we are to move to the cursor to the other side of the screen (that is, wrap it)? -- Gerard Schildberger 09:30, 16 August 2012 (UTC)

As you say, it's not stated in the task. Perhaps some clarification is in order.
Personally, I would do whatever is typical for your language of choice. (For example, this isn't a problem for BASIC, normally -- in MS BASIC, an attempt to place the text cursor off the screen using LOCATE results in an error ("Illegal function call"). The graphical cursor (which serves a completely different purpose) continues on to (effectively) infinity.)
If there's no "standard" behavior for your chosen language... shrug. Do as you see fit. -- Erik Siers 11:53, 16 August 2012 (UTC)