package parser.ServletParser.library;

import java.awt.*;
import javax.swing.*;
import javax.swing.table.TableCellRenderer;

public class MetricsInfoHeaderRenderer extends JLabel implements TableCellRenderer {
	public MetricsInfoHeaderRenderer() {
		super();
		setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
	}
	public Component getTableCellRendererComponent(JTable table,
			Object value,boolean isSelected,boolean hasFocus,int row,int column) {
		if (column == 0) {
			setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
			setText("  "+(String)value);
		} else {
			setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
			setText((String)value+" ");
		}
		LookAndFeel.installBorder(this,"TableHeader.cellBorder");
		return this;
	}
}