[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Experimental matrix editor patch
From: |
John W. Eaton |
Subject: |
Experimental matrix editor patch |
Date: |
Wed, 01 May 2013 14:47:45 -0400 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:10.0.11) Gecko/20121122 Icedove/10.0.11 |
I've uploaded a patch to implement an experimental spreadsheet-like
matrix editor for the GUI here:
https://savannah.gnu.org/patch/index.php?8039
This is a very bare-bones proof-of-concept implementation.
To use it, apply the patch to the development branch, rebuild Octave,
then right click a variable name in the workspace viewer and select
"Open in Variable Editor" from the context menu.
There are many things left to do, and many decisions to be made about
what exactly we would want from something like this. For example,
* it currently only handles double precision values (should we be
able to edit arbitrary Octave data structures, or just numeric
data?)
* it doesn't preserve full precision (moving data in and out is done
by converting to/from text)
* resizing the matrix isn't possible
* inserting rows or columns isn't possible
* applying functions or performing arithmetic on the data (or
regions) is not possible
* editing is possible, but normal spreadsheet operations like filling
a region is not possible
* you are not prevented from inserting non-numeric data
* things like "Inf" and "NaN" aren't recognized
* only 2D arrays are handled properly
* only one variable may be edited at a time (I guess we could use a
tabbed editor, or some other way of managing multiple matrix edit
windows)
* we don't keep track of the original scope of the variable, so if
you start editing a variable, then use the debugger and step into a
function, then click "done" in the matrix editor, the variable will
be inserted into the current scope, which is the one the debugger
is visiting
* and many other things, I'm sure...
So clearly this patch is not ready to be committed, but I wanted to
see if I could get a relatively simple structure in place for doing
this job.
jwe
- Experimental matrix editor patch,
John W. Eaton <=