# CAN_REPLACE -- Return true if the name of this keyword can be changed. # Certain keywords in the user area describe the layout of the image file # or have reserved meanings and cannot be changed. int procedure can_replace(key) char key[ARB] # Keyword to be checked (input) bool can_change int stridx() bool strne() begin can_change = true if (stridx(key[1],"CGHP") > 0) { can_change = can_change && strne(key,"COMMENT") can_change = can_change && strne(key,"GROUPS") can_change = can_change && strne(key,"GCOUNT") can_change = can_change && strne(key,"HISTORY") can_change = can_change && strne(key,"PCOUNT") can_change = can_change && strne(key,"PSIZE") } if (can_change) return(YES) else return(NO) end