Dear Carnë,
Sorry for the late, I was a bit busy.
I looked at zenity_list.m it didn’t work with multiple values. I was because
of the separator. I guess it was because of the backslash (maybe because I use
linux it was interpreted). So i suggest those changes:
@@ -292,7 +292,7 @@ function [val, status] = zenity_list(col, data, varargin)
options.data = sprintf("\"%s\" ", data{:});
## Set separator
- options.separator = '--separator="/\\|/\\"'; # Will use /\|/\ as
separator
+ options.separator = '--separator="{|}"'; # Will use {|} as separator
pre_cmd = sprintf("%s ", ...
options.title, ...
@@ -356,12 +356,13 @@ function [val, status] = zenity_list(col, data,
varargin)
## When 'multiple' values are expected, always place the output in a cell
## array, even if only one file is selected.
if (multi)
- idx = strfind(output, '/\|/\');
+ idx = strfind(output, '{|}');
if (idx)
tmp_val = cell(length(idx)+1, 1);
- idx = [-4, idx, length(output)+1];
+ idx = [-2, idx, length(output)+1];
for i = 1 : (length(idx)-1)
- tmp_val{i} = output( idx(i)+5 : idx(i+1)-1 );
+ i
+ tmp_val{i} = output( idx(i)+3 : idx(i+1)-1 )
endfor
## Order of the output will have them ordered by row. Must create an
## inversed cell array to allocate the values and transverse it at
the end
–––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
But it would be easier to use the strsplit function.
There still a problem with the "numeric output" option. This is the error
message I get:
"error: element number 2 undefined in return list"
It’s because there’s no status returned with the str2double function. I didn’t
make a patch because I don’t know what behaviour you want.
––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
About the zenity_scale, it just works on my computer without any fgets…
Maybe it’s because I use Octave 3.4.0. I saw you use the 3.2.4 version
shouldn’t you make an update ?
Best regards
------------------------------------------------------------------------------
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today.
http://p.sf.net/sfu/quest-dev2dev2
_______________________________________________
Octave-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/octave-dev