void color() throws ScriptException {
		int argb;
		if (statementLength > 5 || statementLength < 2)
			badArgumentCount();
		int tok = statement[1].tok;
		switch (tok) {
		case Token.dollarsign:
			colorNamedObject(2);
			return;
		case Token.colorRGB:
		case Token.none:
		case Token.cpk:
		case Token.amino:
		case Token.chain:
		case Token.group:
		case Token.shapely:
		case Token.structure:
		case Token.temperature:
		case Token.fixedtemp:
		case Token.formalCharge:
		case Token.partialCharge:
		case Token.surfacedistance:
		case Token.user:
		case Token.monomer:
		case Token.molecule:
		case Token.altloc:
		case Token.insertion:
		case Token.translucent:
		case Token.opaque:
			colorObject(Token.atom, 1);
			return;
		case Token.jmol:
		case Token.rasmol:
			colorObject(Token.atom, 1);
			return;
		case Token.rubberband:
			viewer.setRubberbandArgb(getArgbParam(2));
			return;
		case Token.background:
			viewer.setBackgroundArgb(getArgbOrNoneParam(2));
			return;
		case Token.selectionHalo:
			argb = getArgbOrNoneParam(2);
			viewer.loadShape(JmolConstants.SHAPE_HALOS);
			viewer.setShapeProperty(JmolConstants.SHAPE_HALOS, "argbSelection", new Integer(argb));
			return;
		case Token.identifier:
		case Token.hydrogen:
			// color element
			argb = getArgbOrPaletteParam(2);
			String str = (String) statement[1].value;
			for (int i = JmolConstants.elementNumberMax; --i >= 0;) {
				if (str.equalsIgnoreCase(JmolConstants.elementNameFromNumber(i))) {
					viewer.setElementArgb(i, argb);
					return;
				}
			}
			for (int i = JmolConstants.altElementMax; --i >= 0;) {
				if (str.equalsIgnoreCase(JmolConstants.altElementNameFromIndex(i))) {
					viewer.setElementArgb(JmolConstants.altElementNumberFromIndex(i), argb);
					return;
				}
			}
			if (str.charAt(0) == '_') {
				for (int i = JmolConstants.elementNumberMax; --i >= 0;) {
					if (str.equalsIgnoreCase("_" + JmolConstants.elementSymbolFromNumber(i))) {
						viewer.setElementArgb(i, argb);
						return;
					}
				}
				for (int i = JmolConstants.altElementMax; --i >= JmolConstants.firstIsotope;) {
					if (str.equalsIgnoreCase("_" + JmolConstants.altElementSymbolFromIndex(i))) {
						viewer.setElementArgb(JmolConstants.altElementNumberFromIndex(i), argb);
						return;
					}
					if (str.equalsIgnoreCase("_" + JmolConstants.altIsotopeSymbolFromIndex(i))) {
						viewer.setElementArgb(JmolConstants.altElementNumberFromIndex(i), argb);
						return;
					}
				}
			}
			invalidArgument();
		default:
			if (tok == Token.bond) // special hack for bond/bonds confusion
				tok = Token.bonds;
			colorObject(tok, 2);
		}
	}