public Tile(Chapter selection, Interface inter, TileBarView t, int starting, int ending, int moveX, int moveY, final int bookNumber, String text) {
        super(text);
        this.bookNumber = bookNumber;
        startingPage = starting;
    	endingPage = ending;
    	block = selection;
    	menu = inter;
    	tv = t;
    	keepTrackOfPixelsAlreadyColored = new int[ending-starting+1];
    	if(ending - starting != 0){
    		pointersToRecolors = new JPanel[ending-starting+1];
    		for(int i = 0;i < pointersToRecolors.length;i++){
    			pointersToRecolors[i] = null;
    		}
    	}
    	else {
    		pointersToRecolors = null;
    	}
    	for(int i = 0;i < keepTrackOfPixelsAlreadyColored.length;i++){
    		keepTrackOfPixelsAlreadyColored[i] = 0;
    	}
        super.setContentAreaFilled(false);
        this.setBorder(new MatteBorder(2,0,2,0,Color.BLACK));
        this.setLayout(null);
        this.addActionListener(new ActionListener() {
        	@Override
        	public void actionPerformed(ActionEvent e){
        		if(!isSelected){
        			isSelected = true;
        			setSelected(isSelected);
        		}
        		else {
        			isSelected = false;
        			setSelected(isSelected);
        		}
				//menu.getInfoPane().revalidate();
				//menu.getInfoPane().repaint();
				menu.setSelectedChapter(block.getChapterNumber(), bookNumber);
        	}
        });
        /*
        this.getModel().addChangeListener(new ChangeListener(){
        	@Override
        	public void stateChanged(ChangeEvent e) {
        		ButtonModel model = (ButtonModel) e.getSource();
        		if(model.isRollover()) {
        			menu.getInfoPane().setText(block.toString());
        		}
        	}
        });
        */
        //Set tooltip hover text.
        //Need to wrap the string in html tags for multi-line tooltips.
  		String rawString = block.toString();
  		String withStartAndEndTags = "<html>"+rawString+"</html>";
  		//Replace all new lines with breaks.
  		Scanner removeNewLines = new Scanner(withStartAndEndTags);
  		String breakString = "";
  		while(removeNewLines.hasNext()){
  			String currentLine = removeNewLines.nextLine();
  			if(removeNewLines.hasNext()){
  				breakString += currentLine+"<br>";
  			}
  			else {
  				breakString += currentLine;
  			}
  		}
  		removeNewLines.close();
  		//Replace all tabs with white space padding.
  		String returnString = breakString.replace("\t", new String("&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"));
        this.setToolTipText(returnString);
    }