octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #51848] Variable editor should show text strin


From: John W. Eaton
Subject: [Octave-bug-tracker] [bug #51848] Variable editor should show text strings in one cell, not as separate chars each in distinct cells
Date: Mon, 29 Jan 2018 17:20:50 -0500 (EST)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Firefox/52.0

Follow-up Comment #5, bug #51848 (project octave):

RE comment #3:  Yes, so that's just the text that you would see in the command
window.  It's not something that can be edited, correct?

The problem with editing character arrays (AKA string and sq_string objects)
is that they don't behave like numeric arrays.  With numeric arrays, you can
enter arbitrary expressions.  As long as they evaluate to something that can
be assigned as a scalar element, things should work.

For character arrays, I assume that you would want the text entered verbatim,
not evaluated as an expression.  Should backslash escape sequences be
processed for double-quoted string objects?  I assume so, but not for
single-quoted string objects.  If you entered new text that was longer than
the longest existing row, should the object be resized and filled with
trailing blanks as necessary instead of throwing an error?  What if you
shortened the longest row?  Would you want the columns trimmed to the length
of the new longest row?

BTW, what does Matlab do if you are editing a row vector of numbers (say 1:3)
and you type "3:5" as a replacement for the third element?  Does it resize and
display an array with 5 elements (1:5) or does it fail?  I expect failure, but
it could be smart and provide this feature.

Also, does Matlab allow editing of its new string objects (created with the
string function or double quotes in very recent versions)?  If so, how does it
behave for display and when entering values in the editor cells?


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?51848>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]