Changeset 637 for cpp/frams


Ignore:
Timestamp:
12/03/16 02:21:40 (7 years ago)
Author:
Maciej Komosinski
Message:

Extended code so that NeuroClass? properties are described in more detail

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/model/modelparts.cpp

    r528 r637  
    163163                        {
    164164                        case 'd': t+=" integer";
    165                         {paInt a,b,c; if (p.getMinMax(i,a,b,c)>=2) t+=SString::sprintf(" %d..%d",a,b);}
     165                        {paInt a,b,c; int n=p.getMinMax(i,a,b,c); if (n>=2) t+=SString::sprintf(" %d..%d",a,b); if (n>=3) t+=SString::sprintf(" (default %d)",c);}
    166166                                break;
    167167                        case 'f': t+=" float";
    168                         {double a,b,c; if (p.getMinMax(i,a,b,c)>=2) t+=SString::sprintf(" %g..%g",a,b);}
     168                        {double a,b,c; int n=p.getMinMax(i,a,b,c); if (n>=2) t+=SString::sprintf(" %g..%g",a,b); if (n>=3) t+=SString::sprintf(" (default %g)",c);}
    169169                                break;
    170                         case 's': t+=" string"; break;
     170                        case 's': t+=" string";
     171                        {int a,b; SString c; int n=p.getMinMax(i,a,b,c); if ((n>=2)&&(b>0)) t+=SString::sprintf(", max %d chars",b); if (n>=3) t+=SString::sprintf(" (default \"%s\")",c.c_str());}
     172                                break;
    171173                        case 'x': t+=" anything"; break;
    172174                        }
Note: See TracChangeset for help on using the changeset viewer.