Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
import java.awt.Color;

import java.awt.Font;

import javax.swing.JLabel;

public class Main {
    public static JLabel setTitleLabelFont(JLabel label) {
        return modifyLabelFont(label, Font.BOLD, 0);
    }

    public static JLabel modifyLabelFont(JLabel label, int style, int delta) {
        Font font = label.getFont();
        label.setFont(font.deriveFont(style, font.getSize() + delta));
        label.setForeground(new Color(140, 140, 140));
        return label;
    }
}