Example usage for javax.swing ListCellRenderer interface-usage

List of usage examples for javax.swing ListCellRenderer interface-usage

Introduction

In this page you can find the example usage for javax.swing ListCellRenderer interface-usage.

Usage

From source file Main.java

class FontCellRenderer implements ListCellRenderer {

    public Component getListCellRendererComponent(final JList list, final Object value, final int index,
            final boolean isSelected, final boolean cellHasFocus) {
        return new JPanel() {
            public void paintComponent(Graphics g) {

From source file ComboTableCellRenderer.java

class ComboTableCellRenderer implements ListCellRenderer, TableCellRenderer {
    DefaultListCellRenderer listRenderer = new DefaultListCellRenderer();

    DefaultTableCellRenderer tableRenderer = new DefaultTableCellRenderer();

    private void configureRenderer(JLabel renderer, Object value) {

From source file modmanager.swing.ImageListRenderer.java

/**
 *
 * @author ruman
 */
public class ImageListRenderer extends javax.swing.JPanel implements ListCellRenderer<String> {
    private HashMap<String, BufferedImage> images = new HashMap<>();

From source file Main.java

class Listm extends JTextArea implements ListCellRenderer {
    protected Listm(int rows, int cols) {
        super(rows, cols);
        setBorder(BorderFactory.createLineBorder(Color.blue));
    }

From source file org.trzcinka.intellitrac.view.toolwindow.tickets.ticket_editor.AttachmentsListCellRenderer.java

/**
 * Renders single attachment element.
 * <p/>
 * Created on: 2008-09-20 23:49:29 <br/>
 *
 * @author Michal Trzcinka

From source file Main.java

class ComplexCellRenderer implements ListCellRenderer {
    protected DefaultListCellRenderer defaultRenderer = new DefaultListCellRenderer();

    public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected,
            boolean cellHasFocus) {
        Font theFont = null;

From source file MainClass.java

class ComplexCellRenderer implements ListCellRenderer {
    protected DefaultListCellRenderer defaultRenderer = new DefaultListCellRenderer();

    public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected,
            boolean cellHasFocus) {
        Font theFont = null;

From source file CustomBorderSample.java

class FocusedTitleListCellRenderer implements ListCellRenderer {
    protected static Border noFocusBorder = new EmptyBorder(15, 1, 1, 1);

    protected static TitledBorder focusBorder = new TitledBorder(LineBorder.createGrayLineBorder(), "Focused");

    protected DefaultListCellRenderer defaultRenderer = new DefaultListCellRenderer();

From source file uk.nhs.cfh.dsp.yasb.searchpanel.renderer.SearchResultListCellRenderer.java

/**
 * <br>A custom {@link javax.swing.ListCellRenderer} for the displays results. This uses a
 * Lucene {@link org.apache.lucene.document.Document} object to render the label.
 * 
 * <br>Written by @author Jay Kola
 * <br>Created on Dec 23, 2008 at 4:26:13 PM

From source file Main.java

class MyComboBoxRenderer extends JLabel implements ListCellRenderer {
    private String _title;

    public MyComboBoxRenderer(String title) {
        _title = title;
    }