# HG changeset patch # User paramaniac # Date 1329671111 0 # Node ID 7ff457d1d892dd42f9593bd9a53ffe0d7786ddd0 # Parent 11e7128a79dcb02f2ca92b8646a460096c88eb62 control-devel: save draft code diff -r 11e7128a79dc -r 7ff457d1d892 extra/control-devel/inst/@iddata/display.m --- a/extra/control-devel/inst/@iddata/display.m Sun Feb 19 14:10:05 2012 +0000 +++ b/extra/control-devel/inst/@iddata/display.m Sun Feb 19 17:05:11 2012 +0000 @@ -38,11 +38,32 @@ disp (""); disp (str); + + disp (__col2str__ (exname, "Experiment")); + disp (__col2str__ (outname, "Output Channel")); + disp (__col2str__ (inname, "Input Channel")); + %{ - str = strvcat (exname) - space = (repmat (" ", e, 1)) - %str = [space, exname] - class (space) - class (str) + str = strjust (strvcat (exname), "left"); + space = (repmat (" ", e, 1)); + str = [space, str]; %} endfunction + +%{ +function str = __ + + space = repmat (" ", len+2, 1); + str = [space, str]; + +endfunction +%} + +function str = __col2str__ (col, title) + + len = rows (col); + str = strjust (strvcat (col), "left"); + str = [repmat(" ", len, 1), str]; + str = strvcat (title, str); + +endfunction