public PieceView(Piece piece) { super(); piece.addPieceObserver(this); setHorizontalAlignment(CENTER); setFont(new Font("Sans Serif", Font.BOLD, 10)); String playerName = piece.getOwner().getName(); setText(playerName.substring(playerName.length() - 1, playerName.length())); }