int position = dataText.getCaretPosition();
int position = dataText.getCaretOffset();
	void showColorForData() {		int delimiterLength = dataText.getLineDelimiter().length();		int charactersPerLine = 6 + 3 * imageData.bytesPerLine + delimiterLength;		int position = dataText.getCaretPosition();		int y = position / charactersPerLine;		if ((position - y * charactersPerLine) < 6 || ((y + 1) * charactersPerLine - position) <= delimiterLength) {			statusLabel.setText("");			return;		}		int dataPosition = position - 6 * (y + 1) - delimiterLength * y;		int byteNumber = dataPosition / 3;		int where = dataPosition - byteNumber * 3;		int xByte = byteNumber % imageData.bytesPerLine;		int x = -1;		int depth = imageData.depth;		if (depth == 1) { // 8 pixels per byte (can only show 3 of 8)			if (where == 0) x = xByte * 8;			if (where == 1) x = xByte * 8 + 3;			if (where == 2) x = xByte * 8 + 7;		}		if (depth == 2) { // 4 pixels per byte (can only show 3 of 4)			if (where == 0) x = xByte * 4;			if (where == 1) x = xByte * 4 + 1;			if (where == 2) x = xByte * 4 + 3;		}		if (depth == 4) { // 2 pixels per byte			if (where == 0) x = xByte * 2;			if (where == 1) x = xByte * 2;			if (where == 2) x = xByte * 2 + 1;		}		if (depth == 8) { // 1 byte per pixel			x = xByte;		}		if (depth == 16) { // 2 bytes per pixel			x = xByte / 2;		}		if (depth == 24) { // 3 bytes per pixel			x = xByte / 3;		}		if (depth == 32) { // 4 bytes per pixel			x = xByte / 4;		}		if (x != -1) {			showColorForPixel(x, y);		} else {			statusLabel.setText("");		}	}