/jEdit/tags/jedit-4-5-pre1/org/gjt/sp/jedit/bsh/commands/printBanner.bsh
Unknown | 37 lines | 31 code | 6 blank | 0 comment | 0 complexity | 775459d73f47366999859870b1bfa1f8 MD5 | raw file
Possible License(s): BSD-3-Clause, AGPL-1.0, Apache-2.0, LGPL-2.0, LGPL-3.0, GPL-2.0, CC-BY-SA-3.0, LGPL-2.1, GPL-3.0, MPL-2.0-no-copyleft-exception, IPL-1.0
- /**
- Print the BeanShell banner (version and author line) - GUI or non GUI.
- @author Daniel Leuck
- */
- import javax.swing.ImageIcon;
- import java.awt.*;
- import org.gjt.sp.jedit.bsh.Interpreter;
- import org.gjt.sp.jedit.bsh.Capabilities;
- import org.gjt.sp.jedit.bsh.util.JConsole;
- /*
- Note: any errors thrown in here will be caught by interpreter and
- ignored... printing the default message.
- */
- printBanner()
- {
- if ( bsh.console != void
- && Capabilities.haveSwing()
- && (bsh.console instanceof JConsole) )
- {
- this.jconsole = bsh.console;
- jconsole.println(
- new ImageIcon( getResource("/bsh/util/lib/small_bean_shell.gif")) );
- jconsole.print(
- Interpreter.VERSION + " - by Pat Niemeyer (pat@pat.net)",
- new Font("SansSerif", Font.BOLD, 12),
- new Color(20,100,20) );
- jconsole.println();
- } else
- print( "BeanShell "
- + Interpreter.VERSION +" - by Pat Niemeyer (pat@pat.net)");
- }