@Override public void insertString(int offs, String str, AttributeSet a) throws BadLocationException {
		if(str == null) {
			return;
		} else if(str.length() + offs > maxLength) {
			return;
		}

		char[] letters = str.toCharArray();
		boolean numbers = true;

		for(char c : letters) {
			if(!Character.isDigit(c)) {
				numbers = false;
				break;
			}
		}

		if(numbers) {
			super.insertString(offs, new String(letters), a);
		}
	}