protected void paintComponent(Graphics g) {
        int height = getHeight();
        if (height < 30) {
            showSmallText = false;
        }
        
        removeAll();
        addTextLabel();
        
        //if using textures
        if (SHOW_TEXTURE) {
            int width = getWidth();
            if (texture == null || texture.isEmpty() ||tileImage == null) {
                super.paintComponent(g);
                return;
            }
            
            int imageW = tileImage.getWidth(this);
            int imageH = tileImage.getHeight(this);
     
            // Tile the image to fill our area.
            for (int x = 0; x < width; x += imageW) {
                for (int y = 0; y < height; y += imageH) {
                    g.drawImage(tileImage, x, y, this);
                }
            }
        } else {
            addSlider();
            validate();
            super.paintComponent(g);
        }
    }