Logo Search packages:      
Sourcecode: inkscape version File versions

static void sp_feColorMatrix_set ( SPObject object,
unsigned int  key,
gchar const *  str 
) [static]

Sets a specific value in the SPFeColorMatrix.

Definition at line 138 of file sp-fecolormatrix.cpp.

{
    SPFeColorMatrix *feColorMatrix = SP_FECOLORMATRIX(object);
    (void)feColorMatrix;

    NR::FilterColorMatrixType read_type;
      /*DEAL WITH SETTING ATTRIBUTES HERE*/
    switch(key) {
        case SP_ATTR_TYPE:
            read_type = sp_feColorMatrix_read_type(str);
            if (feColorMatrix->type != read_type){
                feColorMatrix->type = read_type;
                object->parent->requestModified(SP_OBJECT_MODIFIED_FLAG);
            }
            break;
        case SP_ATTR_VALUES:
            if (str){
                feColorMatrix->values = helperfns_read_vector(str, 20);
                feColorMatrix->value = helperfns_read_number(str, HELPERFNS_NO_WARNING);
                object->parent->requestModified(SP_OBJECT_MODIFIED_FLAG);
            }
            break;
        default:
            if (((SPObjectClass *) feColorMatrix_parent_class)->set)
                ((SPObjectClass *) feColorMatrix_parent_class)->set(object, key, str);
            break;
    }
}


Generated by  Doxygen 1.6.0   Back to index