[SCM] libjgoodies-looks-java packaging branch, upstream, updated. upstream/2.5.0-1-g3cdba0a
gregor herrmann
gregoa at debian.org
Thu May 31 15:31:02 UTC 2012
The following commit has been merged in the upstream branch:
commit 3cdba0a48fdfa22b979a6fcd2e19af1a3c6b1f94
Author: gregor herrmann <gregoa at debian.org>
Date: Fri May 25 20:40:15 2012 +0200
Imported Upstream version 2.5.1
diff --git a/README.html b/README.html
index 73afa8c..8a65ce7 100644
--- a/README.html
+++ b/README.html
@@ -45,13 +45,12 @@
<p>
<a class="nav" href="docs/api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
@@ -66,7 +65,7 @@
<table width="530" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
- <h1>:: Readme :: Looks 2.5 ::</h1>
+ <h1>:: Readme :: Looks 2.5.1 ::</h1>
The JGoodies Looks make your Swing applications and applets look better.
The package consists of a Windows look&feel and
@@ -74,92 +73,11 @@
These have been optimized for readability, precise micro-design and usability.
<p>
- Since version 2.5 the JGoodies Looks requires Java 6 or later
- and the JGoodies Common library.
- Looks versions for Java 1.4 and Java 1.5 are available in the
+ The Looks requires Java 6 or later and the JGoodies Common library.
+ Looks releases for older Java versions are available in the
<a href="http://www.jgoodies.com/downloads/archive.html">JGoodies Archive</a>.
- <h2>Top Questions</h2>
-
- :: <a href="https://looks.java.net/faq.html#benefits">What are the main benefits?</a>
- <br>:: <a href="https://looks.java.net/faq.html#commercialUse">Can I use the Looks in a commercial product?</a>
- <br>:: <a href="https://looks.java.net/faq.html#howToGetStarted">How to get started?</a>
- <br>:: <a href="https://looks.java.net/faq.html#support">Where do I get support?</a>
- <br>:: <a href="https://looks.java.net/faq.html#howToReportAProblem">How to report a problem?</a>
- <br>:: <a href="https://looks.java.net/faq.html#differencesSun">What are the differences between the Sun and JGoodies Windows L&Fs?</a>
-
-
- <h2>Distribution Contents</h2>
-
- <table border="0" cellspacing="0" cellpadding="0">
- <tr>
- <td><tt>jgoodies-looks-2.5.0.jar</tt></td>
- <td> </td>
- <td>the library jar</td>
- </tr>
- <tr><td colspan="3"> </td></tr>
- <tr>
- <td><tt>docs/api</tt></td>
- <td width="10"> </td>
- <td>JavaDocs directory</td>
- </tr>
- <tr>
- <td><tt>docs/guide</tt></td>
- <td> </td>
- <td>User's Guide</td>
- </tr>
- <tr><td colspan="3"> </td></tr>
- <tr>
- <td><tt>lib</tt></td>
- <td> </td>
- <td>required libraries</td>
- </tr>
- <tr><td colspan="3"> </td></tr>
- <tr>
- <td><tt>src/core</tt></td>
- <td> </td>
- <td>Java sources for the library core</td>
- </tr>
- <tr>
- <td><tt>src/test</tt></td>
- <td> </td>
- <td>Java sources for unit tests</td>
- </tr>
- <tr>
- <td><tt>src/icons</tt></td>
- <td> </td>
- <td>Design time Plastic icon resources in SVG format</td>
- </tr>
- <tr><td colspan="3"> </td></tr>
- <tr>
- <td><tt>LICENSE.txt</tt></td>
- <td> </td>
- <td>the BSD license agreement</td>
- </tr>
- <tr>
- <td><tt>README.html</tt></td>
- <td> </td>
- <td>this readme file</td>
- </tr>
- <tr>
- <td><tt>RELEASE-NOTES.txt</tt></td>
- <td> </td>
- <td>Release Notes</td>
- </tr>
- <tr>
- <td><tt>build.xml</tt></td>
- <td> </td>
- <td>ANT build file</td>
- </tr>
- <tr>
- <td><tt>default.properties</tt></td>
- <td> </td>
- <td>ANT default build properties</td>
- </tr>
- </table>
-
-
<h2>Acknowledgements</h2>
The Looks project has been financed by customers of the
diff --git a/RELEASE-NOTES.txt b/RELEASE-NOTES.txt
index 09ca983..f631f47 100644
--- a/RELEASE-NOTES.txt
+++ b/RELEASE-NOTES.txt
@@ -3,6 +3,11 @@
Release Notes
+CHANGES IN 2.5.1 --------------------------------------------------------
+
+ o The javadocs, main and test sources are delivered as JARs.
+
+
CHANGES IN 2.5.0 --------------------------------------------------------
o Requires Java 6 and JGoodies Common 1.3.
diff --git a/build.xml b/build.xml
deleted file mode 100644
index b38f26b..0000000
--- a/build.xml
+++ /dev/null
@@ -1,354 +0,0 @@
-<?xml version="1.0"?>
-<!--
- $Id: build.xml,v 1.31 2010/01/11 22:48:55 karsten Exp $
-
- This is a build file for use with the Jakarta Ant build tool, see
- http://jakarta.apache.org/ant/index.html
-
- To build, go to the directory where this file is located and run
- ant <target>
- with one of the following targets:
-
- clean removes temporary files and directories
- compile compiles the framework, extras, tutorial and tests
- javadoc creates the API documentation
- test compiles and runs the unit tests
- jar creates a library jar
- create-dist-dir creates a distribution tree: docs, sources, jar
- create-dist-zip creates a zipped distribution
- create-maven-bundle creates a Maven bundle
- create-all creates the distribution zip and Maven bundle
-
- To compile, you MUST set the property "build.boot.classpath",
- for example in your user build.properties file a line like:
- build.boot.classpath=C:/Java/Jdk1.5.0_11/jre/lib/rt.jar
-
- To run the unit tests you MUST set the junit.jar property,
- for example in your user build.properties file.
-
--->
-
-<project default="create-all" basedir="." name="JGoodies Looks" >
-
- <!-- ***************************************************************** -->
- <!-- Give users a chance to override build properties. -->
- <!-- ***************************************************************** -->
- <property file="${user.home}/looks.build.properties" />
- <property file="${user.home}/build.properties" />
- <property file="${basedir}/build.properties" />
- <property file="${basedir}/default.properties" />
-
-
- <!-- ***************************************************************** -->
- <!-- P A T H S -->
- <!-- ***************************************************************** -->
- <path id="classpath.core">
- <pathelement location="${build.core.dir}" />
- <pathelement location="${lib.common.jar}" />
- </path>
-
- <path id="classpath.tests">
- <pathelement location="${build.core.dir}" />
- <pathelement location="${build.test.dir}" />
- <pathelement location="${lib.common.jar}" />
- <pathelement location="${junit4.jar}" />
- </path>
-
- <path id="classpath.javadoc">
- <pathelement location="${lib.common.jar}" />
- </path>
-
-
- <!-- ***************************************************************** -->
- <!-- C L E A N -->
- <!-- ***************************************************************** -->
- <target name="clean"
- description="Removes all temporary files and directories." >
-
- <delete dir="${build.dir}" />
- <delete dir="${dist.dir}" />
- </target>
-
-
- <!-- ***************************************************************** -->
- <!-- P R E P A R A T I O N -->
- <!-- ***************************************************************** -->
- <target name="prepare"
- description="Prepares the build and distribution targets." >
-
- <tstamp>
- <format property="DATE" pattern="yyyy-MM-dd hh:mm:ss" />
- </tstamp>
-
- <mkdir dir="${build.core.dir}" />
-
- <available
- property="junit.task.present"
- classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTask"
- />
- <available
- property="junit.jar.present"
- file="${junit.jar}"
- />
- </target>
-
-
- <!-- ***************************************************************** -->
- <!-- C O M P I L A T I O N -->
- <!-- ***************************************************************** -->
- <target name="compile"
- depends="compile-core, compile-tests"
- description="Compiles the l&fs, and tests." />
-
- <!-- ***************************************************************** -->
- <target name="compile-core" depends="prepare"
- description="Compiles all library sources." >
- <javac
- srcdir ="${src.core.dir}"
- destdir ="${build.core.dir}"
- encoding ="${build.encoding}"
- executable ="${build.compile.executable}"
- fork ="${build.compile.fork}"
- debug ="${build.compile.debug}"
- depend ="${build.compile.depend}"
- deprecation ="${build.compile.deprecation}"
- nowarn ="${build.compile.nowarn}"
- optimize ="${build.compile.optimize}"
- source ="${build.compile.source}"
- target ="${build.compile.target}"
- verbose ="${build.compile.verbose}"
- bootclasspath="${build.boot.classpath}"
- classpathref ="classpath.core"
- includeAntRuntime="false" />
-
- <copy toDir="${build.core.dir}" >
- <fileset dir="${src.core.dir}"
- includes="com/jgoodies/looks/common/shadow.png,
- com/jgoodies/looks/plastic/icons/**/*,
- com/jgoodies/looks/windows/icons/**/*" />
- </copy>
- </target>
-
-
- <!-- ***************************************************************** -->
- <target name="compile-tests" depends="compile-core" if="junit.jar.present"
- description="Compiles the unit tests." >
- <mkdir dir="${build.test.dir}"/>
- <javac
- srcdir ="${src.test.dir}"
- destdir ="${build.test.dir}"
- encoding ="${build.encoding}"
- executable ="${build.compile.executable}"
- fork ="${build.compile.fork}"
- debug ="${build.compile.debug}"
- depend ="${build.compile.depend}"
- deprecation ="${build.compile.deprecation}"
- nowarn ="${build.compile.nowarn}"
- optimize ="${build.compile.optimize}"
- source ="${build.compile.source}"
- target ="${build.compile.target}"
- verbose ="${build.compile.verbose}"
- bootclasspath="${build.boot.classpath}"
- classpathref ="classpath.tests"
- includeAntRuntime="false" />
- </target>
-
-
-
- <!-- ***************************************************************** -->
- <!-- J A V A D O C -->
- <!-- ***************************************************************** -->
- <target name="javadoc" depends="prepare"
- description="Creates the API documentation using JavaDoc." >
- <mkdir dir="${build.javadocs.dir}" />
- <javadoc
- sourcepath="${src.core.dir}"
- packagenames="${javadoc.packages}"
- destdir="${build.javadocs.dir}"
- encoding="${build.encoding}"
- access="protected"
- author="true"
- version="true"
- use="true"
- link="${javadoc.link}"
- overview="${javadoc.overview}"
- windowtitle="${Name} ${spec.version} API"
- doctitle="${Name} ${spec.version} API"
- bottom="${copyright.message}"
- classpathref ="classpath.javadoc" >
- </javadoc>
- </target>
-
-
- <!-- ***************************************************************** -->
- <!-- U N I T T E S T S -->
- <!-- ***************************************************************** -->
- <target name="test" depends="compile-tests" if="junit.task.present"
- description="Compiles and runs the unit tests." >
- <mkdir dir="${build.reports.dir}"/>
- <junit printsummary="yes" haltonfailure="no" >
- <classpath refid="classpath.tests"/>
- <formatter type="plain" />
- <batchtest fork="yes" todir="${build.reports.dir}">
- <fileset dir="${src.test.dir}" includes="**/*Test.java" />
- </batchtest>
- </junit>
- </target>
-
-
- <!-- ***************************************************************** -->
- <!-- J A R -->
- <!-- ***************************************************************** -->
- <target name="jar"
- depends="jar-all, jar-plastic, jar-windows"
- description="Creates library and example jars." >
- </target>
-
- <!-- ***************************************************************** -->
- <target name="manifest" depends="prepare"
- description="Creates the manifest file." >
- <manifest file="${build.manifest}">
- <attribute name ="Built-By"
- value="${user.name}"/>
- <attribute name ="Specification-Title"
- value="${spec.title}" />
- <attribute name ="Specification-Vendor"
- value="${spec.vendor}" />
- <attribute name ="Specification-Version"
- value="${spec.version}" />
- <attribute name ="Implementation-Title"
- value="${impl.title}" />
- <attribute name ="Implementation-Vendor"
- value="${impl.vendor}" />
- <attribute name ="Implementation-Version"
- value="${impl.version} ${DATE}" />
- </manifest>
- </target>
-
- <!-- ***************************************************************** -->
- <target name="jar-all" depends="compile, manifest"
- description="Creates the library jar with all JGoodies l&fs." >
-
- <jar
- destfile="${build.all.jar}"
- manifest="${build.manifest}" >
- <fileset dir="${build.core.dir}" />
- <zipfileset dir="${descriptors.dir}"
- includes="all.txt"
- fullpath="META-INF/services/javax.swing.LookAndFeel" />
- </jar>
- </target>
-
- <!-- ***************************************************************** -->
- <target name="jar-plastic" depends="compile, manifest"
- description="Creates the library jar for the Plastic l&fs." >
-
- <jar
- destfile="${build.plastic.jar}"
- manifest="${build.manifest}" >
- <fileset dir="${build.core.dir}"
- excludes="com/jgoodies/looks/windows/**/*" />
- <zipfileset dir="${descriptors.dir}"
- includes="plastic.txt"
- fullpath="META-INF/services/javax.swing.LookAndFeel" />
- </jar>
- </target>
-
- <!-- ***************************************************************** -->
- <target name="jar-windows" depends="compile, manifest"
- description="Creates the library jar for the windows l&f." >
- <jar
- destfile="${build.windows.jar}"
- manifest="${build.manifest}" >
- <fileset dir="${build.core.dir}"
- excludes="com/jgoodies/looks/plastic/**/*" />
- <zipfileset dir="${descriptors.dir}"
- includes="windows.txt"
- fullpath="META-INF/services/javax.swing.LookAndFeel" />
- </jar>
- </target>
-
- <!-- ***************************************************************** -->
- <!-- C R E A T E -->
- <!-- ***************************************************************** -->
- <target name="create-all" depends="create-dist-zip, create-maven-bundle"
- description="Creates the distribution zip and Maven bundle." >
- </target>
-
-
- <target name="create-dist-dir" depends="clean, compile, javadoc, test, jar"
- description="Creates the distribution directory tree." >
-
- <mkdir dir="${dist.dir}" />
-
- <!-- Compile the documentation. -->
- <copy todir="${dist.docs.dir}" >
- <fileset dir="${docs.dir}" />
- </copy>
- <move todir="${dist.docs.dir}" file="${build.javadocs.dir}" />
-
- <!-- Copy the source directories. -->
- <copy todir="${dist.src.dir}" >
- <fileset dir="${src.dir}" />
- </copy>
-
- <!-- Copy the required libraries. -->
- <copy todir="${dist.lib.dir}" file="${lib.common.jar}" />
-
- <!-- Copy the distribution files. -->
- <copy todir="${dist.dir}" >
- <fileset dir="${top.dir}"
- includes="*.txt, *.html, *.xml, *.properties"
- excludes="todo.txt" />
- <filterset>
- <filter token="impl.version" value="${impl.version}" />
- <filter token="version.name" value="${version.name}" />
- <filter token="copyright.message" value="${copyright.message}" />
- <filter token="copyright.short" value="${copyright.short}" />
- </filterset>
- </copy>
-
- <!-- Copy the jar files. -->
- <copy tofile="${dist.all.jar}" file="${build.all.jar}" />
- <!--
- <copy tofile="${dist.plastic.jar}" file="${build.plastic.jar}" />
- <copy tofile="${dist.windows.jar}" file="${build.windows.jar}" />
- // -->
-
- </target>
-
- <!-- ***************************************************************** -->
- <target name="create-dist-zip" depends="create-dist-dir"
- description="Packages the distribution as a zip file." >
-
- <zip
- destfile="${dist.zip}"
- basedir="${dist.root.dir}"
- includes="${dist.subdir}/**/*" />
- </target>
-
- <!-- ***************************************************************** -->
- <target name="create-maven-bundle" depends="create-dist-dir"
- description="Creates a Maven bundle for the Ibiblio upload." >
-
- <!-- Copy the Maven pom template. -->
- <copy
- tofile="${dist.maven.pom}"
- file="${build.maven.pom.template}" >
- <filterset>
- <filter token="impl.version" value="${impl.version}" />
- <filter token="shortname" value="${shortname}" />
- </filterset>
- </copy>
-
- <copy tofile="${dist.maven.bin.jar}" file="${build.all.jar}" />
- <jar
- destfile="${dist.maven.src.jar}"
- basedir="${dist.src.dir}" />
- <jar
- destfile="${dist.maven.bundle}"
- basedir="${build.maven.dir}" />
- </target>
-
-
-</project>
\ No newline at end of file
diff --git a/default.properties b/default.properties
deleted file mode 100644
index c56cc63..0000000
--- a/default.properties
+++ /dev/null
@@ -1,99 +0,0 @@
-# -------------------------------------------------------------
-# DEFAULT JGOODIES LOOKS BUILD PROPERTIES
-# -------------------------------------------------------------
-#
-# DO NOT EDIT THIS FILE IN ORDER TO CUSTOMIZE BUILD PROPERTIES.
-# CREATE AND EDIT build.properties FILE INSTEAD.
-#
-
-# Project Properties ------------------------------------------
-Name=JGoodies Looks
-shortname=looks
-name=jgoodies-looks
-spec.version=2.5
-impl.version=2.5.0
-version.name=2.5
-dist.version=2_5_0-20120205
-spec.title=${Name} API Specification
-impl.title=${Name}
-spec.vendor=JGoodies Karsten Lentzsch
-impl.vendor=JGoodies Karsten Lentzsch
-copyright.date=2001-2012
-copyright.owner=JGoodies Karsten Lentzsch
-copyright.message=Copyright © ${copyright.date} ${copyright.owner}. All Rights Reserved.
-
-jar.all.name =jgoodies-looks
-jar.plastic.name=jgoodies-plastic
-jar.windows.name=jgoodies-looks-win
-
-top.dir=${basedir}
-
-# Source Properties -------------------------------------------
-src.dir = ${top.dir}/src
-src.core.dir = ${src.dir}/core
-src.test.dir = ${src.dir}/test
-docs.dir = ${top.dir}/docs
-
-descriptors.dir = ${top.dir}/conf/service descriptors
-
-
-# Library Properties ------------------------------------------
-lib.dir = ${top.dir}/../Repository/lib
-
-lib.common.jar = ${lib.dir}/jgoodies-common-1.3.0.jar
-
-
-# JavaDoc Properties ------------------------------------------
-javadoc.link=http://download.oracle.com/javase/1.6.0/docs/api/
-javadoc.packages=com.jgoodies.*
-javadoc.overview=${src.core.dir}/overview.html
-
-
-# Build Properties --------------------------------------------
-build.compiler.pedantic=false
-build.compile.debug=on
-build.compile.deprecation=off
-build.compile.fork=no
-build.compile.nowarn=on
-build.compile.source=1.6
-build.compile.target=1.6
-build.encoding=ISO-8859-1
-
-build.dir = ${top.dir}/build
-build.classes.dir = ${build.dir}/classes
-build.core.dir = ${build.classes.dir}/core
-build.test.dir = ${build.classes.dir}/test
-build.manifest = ${build.dir}/manifest.mf
-build.docs.dir = ${build.dir}/docs
-build.javadocs.dir = ${build.docs.dir}/api
-build.reports.dir = ${build.dir}/test-reports
-
-build.all.jar = ${build.dir}/${jar.all.name}.jar
-build.plastic.jar = ${build.dir}/${jar.plastic.name}.jar
-build.windows.jar = ${build.dir}/${jar.windows.name}.jar
-
-build.maven.dir = ${build.dir}/maven
-build.maven.pom.template = ${top.dir}/conf/maven-pom-template.xml
-
-
-# Dist Properties -----------------------------------------------
-dist.root.dir = ${top.dir}/dist
-dist.name = ${name}-${impl.version}
-deploy.name = ${name}-${dist.version}
-dist.subdir = ${dist.name}
-dist.dir = ${dist.root.dir}/${dist.subdir}
-dist.zip = ${dist.root.dir}/${deploy.name}.zip
-dist.src.dir = ${dist.dir}/src
-dist.docs.dir = ${dist.dir}/docs
-dist.lib.dir = ${dist.dir}/lib
-
-dist.all.name = ${jar.all.name}-${impl.version}.jar
-dist.all.jar = ${dist.dir}/${dist.all.name}
-dist.all.src.zip = ${dist.dir}/${jar.all.name}-${impl.version}-src.zip
-dist.plastic.jar = ${dist.dir}/${jar.plastic.name}-${impl.version}.jar
-dist.windows.jar = ${dist.dir}/${jar.windows.name}-${impl.version}.jar
-
-dist.maven.pom = ${build.maven.dir}/pom.xml
-dist.maven.bin.jar = ${build.maven.dir}/${dist.name}.jar
-dist.maven.src.jar = ${build.maven.dir}/${dist.name}-sources.jar
-dist.maven.bundle = ${dist.root.dir}/${dist.name}-bundle.jar
diff --git a/docs/api/allclasses-frame.html b/docs/api/allclasses-frame.html
index 9e170f2..e04135a 100644
--- a/docs/api/allclasses-frame.html
+++ b/docs/api/allclasses-frame.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
All Classes (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/allclasses-noframe.html b/docs/api/allclasses-noframe.html
index aa6145d..0a9482b 100644
--- a/docs/api/allclasses-noframe.html
+++ b/docs/api/allclasses-noframe.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
All Classes (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/BorderStyle.html b/docs/api/com/jgoodies/looks/BorderStyle.html
index 959cd2f..83a2c5f 100644
--- a/docs/api/com/jgoodies/looks/BorderStyle.html
+++ b/docs/api/com/jgoodies/looks/BorderStyle.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
BorderStyle (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/FontPolicies.html b/docs/api/com/jgoodies/looks/FontPolicies.html
index 62c5157..a556fb5 100644
--- a/docs/api/com/jgoodies/looks/FontPolicies.html
+++ b/docs/api/com/jgoodies/looks/FontPolicies.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
FontPolicies (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/FontPolicy.html b/docs/api/com/jgoodies/looks/FontPolicy.html
index 7ae2278..64a8bc0 100644
--- a/docs/api/com/jgoodies/looks/FontPolicy.html
+++ b/docs/api/com/jgoodies/looks/FontPolicy.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
FontPolicy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/FontSet.html b/docs/api/com/jgoodies/looks/FontSet.html
index 67b165a..a7826ae 100644
--- a/docs/api/com/jgoodies/looks/FontSet.html
+++ b/docs/api/com/jgoodies/looks/FontSet.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
FontSet (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/FontSets.html b/docs/api/com/jgoodies/looks/FontSets.html
index b334ffd..e717cfc 100644
--- a/docs/api/com/jgoodies/looks/FontSets.html
+++ b/docs/api/com/jgoodies/looks/FontSets.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
FontSets (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/Fonts.html b/docs/api/com/jgoodies/looks/Fonts.html
index b2d7f87..8b2ac08 100644
--- a/docs/api/com/jgoodies/looks/Fonts.html
+++ b/docs/api/com/jgoodies/looks/Fonts.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
Fonts (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/HeaderStyle.html b/docs/api/com/jgoodies/looks/HeaderStyle.html
index d2f8afd..383a96f 100644
--- a/docs/api/com/jgoodies/looks/HeaderStyle.html
+++ b/docs/api/com/jgoodies/looks/HeaderStyle.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
HeaderStyle (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/LookUtils.html b/docs/api/com/jgoodies/looks/LookUtils.html
index edba3b8..d584c1b 100644
--- a/docs/api/com/jgoodies/looks/LookUtils.html
+++ b/docs/api/com/jgoodies/looks/LookUtils.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
LookUtils (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/MicroLayout.html b/docs/api/com/jgoodies/looks/MicroLayout.html
index d9cc135..61166d7 100644
--- a/docs/api/com/jgoodies/looks/MicroLayout.html
+++ b/docs/api/com/jgoodies/looks/MicroLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
MicroLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/MicroLayoutPolicies.html b/docs/api/com/jgoodies/looks/MicroLayoutPolicies.html
index 2ed1b5e..bd2030b 100644
--- a/docs/api/com/jgoodies/looks/MicroLayoutPolicies.html
+++ b/docs/api/com/jgoodies/looks/MicroLayoutPolicies.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
MicroLayoutPolicies (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/MicroLayoutPolicy.html b/docs/api/com/jgoodies/looks/MicroLayoutPolicy.html
index 0afe689..5ee26df 100644
--- a/docs/api/com/jgoodies/looks/MicroLayoutPolicy.html
+++ b/docs/api/com/jgoodies/looks/MicroLayoutPolicy.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
MicroLayoutPolicy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/MicroLayouts.html b/docs/api/com/jgoodies/looks/MicroLayouts.html
index 5659852..be1f373 100644
--- a/docs/api/com/jgoodies/looks/MicroLayouts.html
+++ b/docs/api/com/jgoodies/looks/MicroLayouts.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
MicroLayouts (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/Options.html b/docs/api/com/jgoodies/looks/Options.html
index 758337b..123556e 100644
--- a/docs/api/com/jgoodies/looks/Options.html
+++ b/docs/api/com/jgoodies/looks/Options.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:25 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
Options (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/BorderStyle.html b/docs/api/com/jgoodies/looks/class-use/BorderStyle.html
index 64e2289..e3a67fb 100644
--- a/docs/api/com/jgoodies/looks/class-use/BorderStyle.html
+++ b/docs/api/com/jgoodies/looks/class-use/BorderStyle.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.BorderStyle (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/FontPolicies.html b/docs/api/com/jgoodies/looks/class-use/FontPolicies.html
index b84a316..3edcd5d 100644
--- a/docs/api/com/jgoodies/looks/class-use/FontPolicies.html
+++ b/docs/api/com/jgoodies/looks/class-use/FontPolicies.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.FontPolicies (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/FontPolicy.html b/docs/api/com/jgoodies/looks/class-use/FontPolicy.html
index 65b7b22..ea13bcf 100644
--- a/docs/api/com/jgoodies/looks/class-use/FontPolicy.html
+++ b/docs/api/com/jgoodies/looks/class-use/FontPolicy.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Interface com.jgoodies.looks.FontPolicy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/FontSet.html b/docs/api/com/jgoodies/looks/class-use/FontSet.html
index 13e48eb..bad5751 100644
--- a/docs/api/com/jgoodies/looks/class-use/FontSet.html
+++ b/docs/api/com/jgoodies/looks/class-use/FontSet.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Interface com.jgoodies.looks.FontSet (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/FontSets.html b/docs/api/com/jgoodies/looks/class-use/FontSets.html
index d5f7014..4c78fa4 100644
--- a/docs/api/com/jgoodies/looks/class-use/FontSets.html
+++ b/docs/api/com/jgoodies/looks/class-use/FontSets.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.FontSets (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/Fonts.html b/docs/api/com/jgoodies/looks/class-use/Fonts.html
index b940fe5..9c4dd47 100644
--- a/docs/api/com/jgoodies/looks/class-use/Fonts.html
+++ b/docs/api/com/jgoodies/looks/class-use/Fonts.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.Fonts (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/HeaderStyle.html b/docs/api/com/jgoodies/looks/class-use/HeaderStyle.html
index eb699be..99b5402 100644
--- a/docs/api/com/jgoodies/looks/class-use/HeaderStyle.html
+++ b/docs/api/com/jgoodies/looks/class-use/HeaderStyle.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.HeaderStyle (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/LookUtils.html b/docs/api/com/jgoodies/looks/class-use/LookUtils.html
index 2fa51f1..009046c 100644
--- a/docs/api/com/jgoodies/looks/class-use/LookUtils.html
+++ b/docs/api/com/jgoodies/looks/class-use/LookUtils.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.LookUtils (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/MicroLayout.html b/docs/api/com/jgoodies/looks/class-use/MicroLayout.html
index 4b494d4..019443d 100644
--- a/docs/api/com/jgoodies/looks/class-use/MicroLayout.html
+++ b/docs/api/com/jgoodies/looks/class-use/MicroLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.MicroLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicies.html b/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicies.html
index e04364c..7fe2775 100644
--- a/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicies.html
+++ b/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicies.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.MicroLayoutPolicies (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicy.html b/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicy.html
index 5e526d1..47d4d03 100644
--- a/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicy.html
+++ b/docs/api/com/jgoodies/looks/class-use/MicroLayoutPolicy.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Interface com.jgoodies.looks.MicroLayoutPolicy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/MicroLayouts.html b/docs/api/com/jgoodies/looks/class-use/MicroLayouts.html
index e000cf2..ae125a7 100644
--- a/docs/api/com/jgoodies/looks/class-use/MicroLayouts.html
+++ b/docs/api/com/jgoodies/looks/class-use/MicroLayouts.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.MicroLayouts (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/class-use/Options.html b/docs/api/com/jgoodies/looks/class-use/Options.html
index 2dc201e..33345dc 100644
--- a/docs/api/com/jgoodies/looks/class-use/Options.html
+++ b/docs/api/com/jgoodies/looks/class-use/Options.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.Options (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ComboBoxEditorTextField.html b/docs/api/com/jgoodies/looks/common/ComboBoxEditorTextField.html
index 9081ad9..55b6be0 100644
--- a/docs/api/com/jgoodies/looks/common/ComboBoxEditorTextField.html
+++ b/docs/api/com/jgoodies/looks/common/ComboBoxEditorTextField.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:23 CEST 2012 -->
<TITLE>
ComboBoxEditorTextField (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ExtBasicCheckBoxMenuItemUI.html b/docs/api/com/jgoodies/looks/common/ExtBasicCheckBoxMenuItemUI.html
index 492d5a4..ec9ac2f 100644
--- a/docs/api/com/jgoodies/looks/common/ExtBasicCheckBoxMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/common/ExtBasicCheckBoxMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ExtBasicCheckBoxMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ExtBasicMenuItemUI.html b/docs/api/com/jgoodies/looks/common/ExtBasicMenuItemUI.html
index 38efe04..7559726 100644
--- a/docs/api/com/jgoodies/looks/common/ExtBasicMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/common/ExtBasicMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ExtBasicMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ExtBasicMenuUI.html b/docs/api/com/jgoodies/looks/common/ExtBasicMenuUI.html
index 1cf6c4e..8d99f12 100644
--- a/docs/api/com/jgoodies/looks/common/ExtBasicMenuUI.html
+++ b/docs/api/com/jgoodies/looks/common/ExtBasicMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ExtBasicMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ExtBasicPopupMenuSeparatorUI.html b/docs/api/com/jgoodies/looks/common/ExtBasicPopupMenuSeparatorUI.html
index 3a41afe..d0d1cae 100644
--- a/docs/api/com/jgoodies/looks/common/ExtBasicPopupMenuSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/common/ExtBasicPopupMenuSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ExtBasicPopupMenuSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ExtBasicRadioButtonMenuItemUI.html b/docs/api/com/jgoodies/looks/common/ExtBasicRadioButtonMenuItemUI.html
index dc7f74a..716206c 100644
--- a/docs/api/com/jgoodies/looks/common/ExtBasicRadioButtonMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/common/ExtBasicRadioButtonMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ExtBasicRadioButtonMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ExtBasicSpinnerLayout.html b/docs/api/com/jgoodies/looks/common/ExtBasicSpinnerLayout.html
index 8cd8d6f..ef41dcd 100644
--- a/docs/api/com/jgoodies/looks/common/ExtBasicSpinnerLayout.html
+++ b/docs/api/com/jgoodies/looks/common/ExtBasicSpinnerLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ExtBasicSpinnerLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ExtButtonAreaLayout.html b/docs/api/com/jgoodies/looks/common/ExtButtonAreaLayout.html
index c76b3cc..db27eb2 100644
--- a/docs/api/com/jgoodies/looks/common/ExtButtonAreaLayout.html
+++ b/docs/api/com/jgoodies/looks/common/ExtButtonAreaLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ExtButtonAreaLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/MenuItemRenderer.html b/docs/api/com/jgoodies/looks/common/MenuItemRenderer.html
index ac10906..8e98146 100644
--- a/docs/api/com/jgoodies/looks/common/MenuItemRenderer.html
+++ b/docs/api/com/jgoodies/looks/common/MenuItemRenderer.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
MenuItemRenderer (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/MenuSelectionProcessor.html b/docs/api/com/jgoodies/looks/common/MenuSelectionProcessor.html
index 1958773..4e57388 100644
--- a/docs/api/com/jgoodies/looks/common/MenuSelectionProcessor.html
+++ b/docs/api/com/jgoodies/looks/common/MenuSelectionProcessor.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
MenuSelectionProcessor (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/MinimumSizedCheckIcon.html b/docs/api/com/jgoodies/looks/common/MinimumSizedCheckIcon.html
index c476c7a..356ec30 100644
--- a/docs/api/com/jgoodies/looks/common/MinimumSizedCheckIcon.html
+++ b/docs/api/com/jgoodies/looks/common/MinimumSizedCheckIcon.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
MinimumSizedCheckIcon (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/MinimumSizedIcon.html b/docs/api/com/jgoodies/looks/common/MinimumSizedIcon.html
index 5edf200..9e3bf96 100644
--- a/docs/api/com/jgoodies/looks/common/MinimumSizedIcon.html
+++ b/docs/api/com/jgoodies/looks/common/MinimumSizedIcon.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
MinimumSizedIcon (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/PopupMenuLayout.html b/docs/api/com/jgoodies/looks/common/PopupMenuLayout.html
index b6535dc..764e3bb 100644
--- a/docs/api/com/jgoodies/looks/common/PopupMenuLayout.html
+++ b/docs/api/com/jgoodies/looks/common/PopupMenuLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
PopupMenuLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/RGBGrayFilter.html b/docs/api/com/jgoodies/looks/common/RGBGrayFilter.html
index 1d545df..5046f95 100644
--- a/docs/api/com/jgoodies/looks/common/RGBGrayFilter.html
+++ b/docs/api/com/jgoodies/looks/common/RGBGrayFilter.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
RGBGrayFilter (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ShadowPopup.html b/docs/api/com/jgoodies/looks/common/ShadowPopup.html
index 99d0866..3ddd0c1 100644
--- a/docs/api/com/jgoodies/looks/common/ShadowPopup.html
+++ b/docs/api/com/jgoodies/looks/common/ShadowPopup.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ShadowPopup (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/ShadowPopupFactory.html b/docs/api/com/jgoodies/looks/common/ShadowPopupFactory.html
index 9fd14f1..6f82798 100644
--- a/docs/api/com/jgoodies/looks/common/ShadowPopupFactory.html
+++ b/docs/api/com/jgoodies/looks/common/ShadowPopupFactory.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
ShadowPopupFactory (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ComboBoxEditorTextField.html b/docs/api/com/jgoodies/looks/common/class-use/ComboBoxEditorTextField.html
index 1735c73..2d749f6 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ComboBoxEditorTextField.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ComboBoxEditorTextField.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ComboBoxEditorTextField (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicCheckBoxMenuItemUI.html b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicCheckBoxMenuItemUI.html
index a9d6fb2..0facc79 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicCheckBoxMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicCheckBoxMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ExtBasicCheckBoxMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuItemUI.html b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuItemUI.html
index e5f5371..211d087 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ExtBasicMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuUI.html b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuUI.html
index ea55f9a..564c14e 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuUI.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ExtBasicMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicPopupMenuSeparatorUI.html b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicPopupMenuSeparatorUI.html
index d903910..0bcb7f2 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicPopupMenuSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicPopupMenuSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ExtBasicPopupMenuSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicRadioButtonMenuItemUI.html b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicRadioButtonMenuItemUI.html
index 114d6e4..9124a77 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicRadioButtonMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicRadioButtonMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ExtBasicRadioButtonMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicSpinnerLayout.html b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicSpinnerLayout.html
index 1c10753..e01c303 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ExtBasicSpinnerLayout.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ExtBasicSpinnerLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ExtBasicSpinnerLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ExtButtonAreaLayout.html b/docs/api/com/jgoodies/looks/common/class-use/ExtButtonAreaLayout.html
index 1c32cec..8aa0fb0 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ExtButtonAreaLayout.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ExtButtonAreaLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ExtButtonAreaLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/MenuItemRenderer.html b/docs/api/com/jgoodies/looks/common/class-use/MenuItemRenderer.html
index ad6d77b..9e30008 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/MenuItemRenderer.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/MenuItemRenderer.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.MenuItemRenderer (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/MenuSelectionProcessor.html b/docs/api/com/jgoodies/looks/common/class-use/MenuSelectionProcessor.html
index c26ebca..7f0c16f 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/MenuSelectionProcessor.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/MenuSelectionProcessor.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.MenuSelectionProcessor (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedCheckIcon.html b/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedCheckIcon.html
index 0d214d7..bef501b 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedCheckIcon.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedCheckIcon.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.MinimumSizedCheckIcon (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedIcon.html b/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedIcon.html
index f82ff71..f914dad 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedIcon.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/MinimumSizedIcon.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.MinimumSizedIcon (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/PopupMenuLayout.html b/docs/api/com/jgoodies/looks/common/class-use/PopupMenuLayout.html
index 033a7a9..d88d3a8 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/PopupMenuLayout.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/PopupMenuLayout.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.PopupMenuLayout (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/RGBGrayFilter.html b/docs/api/com/jgoodies/looks/common/class-use/RGBGrayFilter.html
index 8ec09be..c422480 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/RGBGrayFilter.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/RGBGrayFilter.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.RGBGrayFilter (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ShadowPopup.html b/docs/api/com/jgoodies/looks/common/class-use/ShadowPopup.html
index 4b71802..c847aa0 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ShadowPopup.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ShadowPopup.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ShadowPopup (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/class-use/ShadowPopupFactory.html b/docs/api/com/jgoodies/looks/common/class-use/ShadowPopupFactory.html
index dfc220f..c99e972 100644
--- a/docs/api/com/jgoodies/looks/common/class-use/ShadowPopupFactory.html
+++ b/docs/api/com/jgoodies/looks/common/class-use/ShadowPopupFactory.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.common.ShadowPopupFactory (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/package-frame.html b/docs/api/com/jgoodies/looks/common/package-frame.html
index 90d7630..cd9ef7e 100644
--- a/docs/api/com/jgoodies/looks/common/package-frame.html
+++ b/docs/api/com/jgoodies/looks/common/package-frame.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.common (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/package-summary.html b/docs/api/com/jgoodies/looks/common/package-summary.html
index 5d22c81..36e6a91 100644
--- a/docs/api/com/jgoodies/looks/common/package-summary.html
+++ b/docs/api/com/jgoodies/looks/common/package-summary.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.common (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/package-tree.html b/docs/api/com/jgoodies/looks/common/package-tree.html
index 79d3e7b..879b122 100644
--- a/docs/api/com/jgoodies/looks/common/package-tree.html
+++ b/docs/api/com/jgoodies/looks/common/package-tree.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.common Class Hierarchy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/common/package-use.html b/docs/api/com/jgoodies/looks/common/package-use.html
index 60aea87..5a49fcd 100644
--- a/docs/api/com/jgoodies/looks/common/package-use.html
+++ b/docs/api/com/jgoodies/looks/common/package-use.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Package com.jgoodies.looks.common (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/package-frame.html b/docs/api/com/jgoodies/looks/package-frame.html
index cde2f49..42c65e3 100644
--- a/docs/api/com/jgoodies/looks/package-frame.html
+++ b/docs/api/com/jgoodies/looks/package-frame.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
com.jgoodies.looks (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/package-summary.html b/docs/api/com/jgoodies/looks/package-summary.html
index 023a96a..1f71a51 100644
--- a/docs/api/com/jgoodies/looks/package-summary.html
+++ b/docs/api/com/jgoodies/looks/package-summary.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/package-tree.html b/docs/api/com/jgoodies/looks/package-tree.html
index 51905c8..e49a8fe 100644
--- a/docs/api/com/jgoodies/looks/package-tree.html
+++ b/docs/api/com/jgoodies/looks/package-tree.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks Class Hierarchy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/package-use.html b/docs/api/com/jgoodies/looks/package-use.html
index 9145254..35d14df 100644
--- a/docs/api/com/jgoodies/looks/package-use.html
+++ b/docs/api/com/jgoodies/looks/package-use.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Package com.jgoodies.looks (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/Plastic3DLookAndFeel.html b/docs/api/com/jgoodies/looks/plastic/Plastic3DLookAndFeel.html
index 9b6066a..1325ea1 100644
--- a/docs/api/com/jgoodies/looks/plastic/Plastic3DLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/plastic/Plastic3DLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
Plastic3DLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticButtonUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticButtonUI.html
index 7f2e245..e16e643 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticButtonUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
PlasticButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticComboBoxUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticComboBoxUI.html
index 886ff02..853d95d 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticComboBoxUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticComboBoxUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
PlasticComboBoxUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticFileChooserUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticFileChooserUI.html
index 1c1058e..1882cd5 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticFileChooserUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticFileChooserUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
PlasticFileChooserUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticFormattedTextFieldUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticFormattedTextFieldUI.html
index e36c344..686b273 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticFormattedTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticFormattedTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
PlasticFormattedTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameTitlePane.html b/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameTitlePane.html
index 5a80e84..562ec0b 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameTitlePane.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameTitlePane.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:26 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:24 CEST 2012 -->
<TITLE>
PlasticInternalFrameTitlePane (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameUI.html
index 1151e32..260a1e0 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticInternalFrameUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticInternalFrameUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticLookAndFeel.html b/docs/api/com/jgoodies/looks/plastic/PlasticLookAndFeel.html
index 08cd332..2e9f9ba 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticMenuBarUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticMenuBarUI.html
index c444829..c590ffb 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticMenuBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticMenuBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticMenuBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticMenuUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticMenuUI.html
index edb6373..a3716dc 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticMenuUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticOptionPaneUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticOptionPaneUI.html
index 65f346b..d7363ba 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticOptionPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticOptionPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticOptionPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticPasswordFieldUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticPasswordFieldUI.html
index 8a05dce..154b191 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticPasswordFieldUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticPasswordFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticPasswordFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticPopupMenuUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticPopupMenuUI.html
index f1a6152..cb69be7 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticPopupMenuUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticPopupMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticPopupMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticScrollBarUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticScrollBarUI.html
index 03d903f..e69311c 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticScrollBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticScrollBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticScrollBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticScrollPaneUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticScrollPaneUI.html
index bc71096..9697aac 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticScrollPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticScrollPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticScrollPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticSeparatorUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticSeparatorUI.html
index 7ba7b6f..fae710a 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticSpinnerUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticSpinnerUI.html
index 1fd76c8..b61d3b6 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticSpinnerUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticSpinnerUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticSpinnerUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticSplitPaneUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticSplitPaneUI.html
index 48cc52b..95b6194 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticSplitPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticSplitPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticSplitPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticTabbedPaneUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticTabbedPaneUI.html
index 3c7252c..bf621bb 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticTabbedPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticTabbedPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticTabbedPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticTextAreaUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticTextAreaUI.html
index def149e..72196c3 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticTextAreaUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticTextAreaUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticTextAreaUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticTextFieldUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticTextFieldUI.html
index 9d02e0b..91828bc 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticTheme.html b/docs/api/com/jgoodies/looks/plastic/PlasticTheme.html
index 971eb37..7a2a791 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticTheme.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticTheme.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticTheme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticToggleButtonUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticToggleButtonUI.html
index 30055fa..95f9315 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticToggleButtonUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticToggleButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticToggleButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticToolBarSeparatorUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticToolBarSeparatorUI.html
index b383a95..d0b7e74 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticToolBarSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticToolBarSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticToolBarSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticToolBarUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticToolBarUI.html
index a1ff754..7126ee0 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticTreeUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticTreeUI.html
index f40013a..5ec7ab4 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticTreeUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticTreeUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticTreeUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticUtils.html b/docs/api/com/jgoodies/looks/plastic/PlasticUtils.html
index 9ed7612..28e5b10 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticUtils.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticUtils.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticUtils (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticXPCheckBoxUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticXPCheckBoxUI.html
index ff637a2..907571c 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticXPCheckBoxUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticXPCheckBoxUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticXPCheckBoxUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticXPIconFactory.html b/docs/api/com/jgoodies/looks/plastic/PlasticXPIconFactory.html
index 46ae9f3..8658284 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticXPIconFactory.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticXPIconFactory.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticXPIconFactory (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticXPLookAndFeel.html b/docs/api/com/jgoodies/looks/plastic/PlasticXPLookAndFeel.html
index f7a66ac..ac185bd 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticXPLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticXPLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticXPLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticXPRadioButtonUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticXPRadioButtonUI.html
index 4766929..8b1c3cb 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticXPRadioButtonUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticXPRadioButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticXPRadioButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticXPSpinnerUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticXPSpinnerUI.html
index 1ec4297..7e8eeb8 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticXPSpinnerUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticXPSpinnerUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticXPSpinnerUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticXPToolBarUI.html b/docs/api/com/jgoodies/looks/plastic/PlasticXPToolBarUI.html
index 0d9a182..d1439ca 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticXPToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticXPToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticXPToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/PlasticXPUtils.html b/docs/api/com/jgoodies/looks/plastic/PlasticXPUtils.html
index 3b5e847..b1a8ab6 100644
--- a/docs/api/com/jgoodies/looks/plastic/PlasticXPUtils.html
+++ b/docs/api/com/jgoodies/looks/plastic/PlasticXPUtils.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
PlasticXPUtils (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/Plastic3DLookAndFeel.html b/docs/api/com/jgoodies/looks/plastic/class-use/Plastic3DLookAndFeel.html
index b7341f1..3b9d9d6 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/Plastic3DLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/Plastic3DLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.Plastic3DLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticButtonUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticButtonUI.html
index fb11421..010050d 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticButtonUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticComboBoxUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticComboBoxUI.html
index f2db02e..eaaa7a2 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticComboBoxUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticComboBoxUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticComboBoxUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFileChooserUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFileChooserUI.html
index 367a1eb..c419341 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFileChooserUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFileChooserUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticFileChooserUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFormattedTextFieldUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFormattedTextFieldUI.html
index 2d5282e..2a385e3 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFormattedTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticFormattedTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticFormattedTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameTitlePane.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameTitlePane.html
index a8eed17..f1d25b1 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameTitlePane.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameTitlePane.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticInternalFrameTitlePane (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameUI.html
index 74d19cb..2145de0 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticInternalFrameUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticInternalFrameUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticLookAndFeel.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticLookAndFeel.html
index 1cafbee..f4a0606 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuBarUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuBarUI.html
index 326fc00..cd8ad0a 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticMenuBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuUI.html
index 4bc3d5c..5688007 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticOptionPaneUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticOptionPaneUI.html
index cc17f14..6a22a3e 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticOptionPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticOptionPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticOptionPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPasswordFieldUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPasswordFieldUI.html
index 809cc28..597ebbd 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPasswordFieldUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPasswordFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticPasswordFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPopupMenuUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPopupMenuUI.html
index 5972bc6..3f34bc0 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPopupMenuUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticPopupMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticPopupMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollBarUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollBarUI.html
index c38dc75..dfd1827 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticScrollBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollPaneUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollPaneUI.html
index 1991f85..a973849 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticScrollPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticScrollPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSeparatorUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSeparatorUI.html
index 6e23277..52e9157 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSpinnerUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSpinnerUI.html
index 46791de..19a9eab 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSpinnerUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSpinnerUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticSpinnerUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSplitPaneUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSplitPaneUI.html
index 367903a..be7a4aa 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSplitPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticSplitPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticSplitPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTabbedPaneUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTabbedPaneUI.html
index 64d43e7..cafad46 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTabbedPaneUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTabbedPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticTabbedPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextAreaUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextAreaUI.html
index d301fb4..f31481e 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextAreaUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextAreaUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticTextAreaUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextFieldUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextFieldUI.html
index 3115768..5c561c7 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTheme.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTheme.html
index a6e0490..47d04bf 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTheme.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTheme.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticTheme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToggleButtonUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToggleButtonUI.html
index a7c3ba1..fccc73e 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToggleButtonUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToggleButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticToggleButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarSeparatorUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarSeparatorUI.html
index 9b781a5..205a327 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticToolBarSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarUI.html
index af6b38e..62964e3 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTreeUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTreeUI.html
index c9f702d..9c44790 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTreeUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticTreeUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticTreeUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticUtils.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticUtils.html
index 7a0dcdd..6a40553 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticUtils.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticUtils.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticUtils (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPCheckBoxUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPCheckBoxUI.html
index 3614c86..229bbce 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPCheckBoxUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPCheckBoxUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticXPCheckBoxUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPIconFactory.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPIconFactory.html
index 2268e0d..bc78496 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPIconFactory.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPIconFactory.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticXPIconFactory (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPLookAndFeel.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPLookAndFeel.html
index 0699354..73c94bb 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticXPLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPRadioButtonUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPRadioButtonUI.html
index b25f369..ecfaefa 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPRadioButtonUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPRadioButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticXPRadioButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPSpinnerUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPSpinnerUI.html
index 38e4f0c..3a15667 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPSpinnerUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPSpinnerUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticXPSpinnerUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPToolBarUI.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPToolBarUI.html
index 4dfae07..f62bd2a 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticXPToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPUtils.html b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPUtils.html
index 38bf7ef..a5d93de 100644
--- a/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPUtils.html
+++ b/docs/api/com/jgoodies/looks/plastic/class-use/PlasticXPUtils.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.PlasticXPUtils (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/package-frame.html b/docs/api/com/jgoodies/looks/plastic/package-frame.html
index 4c6fe3c..19a6bdb 100644
--- a/docs/api/com/jgoodies/looks/plastic/package-frame.html
+++ b/docs/api/com/jgoodies/looks/plastic/package-frame.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.plastic (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/package-summary.html b/docs/api/com/jgoodies/looks/plastic/package-summary.html
index e919945..9f97068 100644
--- a/docs/api/com/jgoodies/looks/plastic/package-summary.html
+++ b/docs/api/com/jgoodies/looks/plastic/package-summary.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.plastic (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/package-tree.html b/docs/api/com/jgoodies/looks/plastic/package-tree.html
index eee8472..d0a5089 100644
--- a/docs/api/com/jgoodies/looks/plastic/package-tree.html
+++ b/docs/api/com/jgoodies/looks/plastic/package-tree.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.plastic Class Hierarchy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/package-use.html b/docs/api/com/jgoodies/looks/plastic/package-use.html
index 085fc29..95e8ce5 100644
--- a/docs/api/com/jgoodies/looks/plastic/package-use.html
+++ b/docs/api/com/jgoodies/looks/plastic/package-use.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Package com.jgoodies.looks.plastic (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/AbstractSkyTheme.html b/docs/api/com/jgoodies/looks/plastic/theme/AbstractSkyTheme.html
index 0f294d9..81bb9fb 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/AbstractSkyTheme.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/AbstractSkyTheme.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
AbstractSkyTheme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/BrownSugar.html b/docs/api/com/jgoodies/looks/plastic/theme/BrownSugar.html
index 31ecb28..f286be6 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/BrownSugar.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/BrownSugar.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:25 CEST 2012 -->
<TITLE>
BrownSugar (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/DarkStar.html b/docs/api/com/jgoodies/looks/plastic/theme/DarkStar.html
index ebc7e8a..bb7f625 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/DarkStar.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/DarkStar.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
DarkStar (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/DesertBlue.html b/docs/api/com/jgoodies/looks/plastic/theme/DesertBlue.html
index 91e0860..bd49aa7 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/DesertBlue.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/DesertBlue.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
DesertBlue (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/DesertBluer.html b/docs/api/com/jgoodies/looks/plastic/theme/DesertBluer.html
index 3797c16..b488cb3 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/DesertBluer.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/DesertBluer.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
DesertBluer (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/DesertGreen.html b/docs/api/com/jgoodies/looks/plastic/theme/DesertGreen.html
index c1ef0d3..d482882 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/DesertGreen.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/DesertGreen.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
DesertGreen (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/DesertRed.html b/docs/api/com/jgoodies/looks/plastic/theme/DesertRed.html
index d27a408..5b065b3 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/DesertRed.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/DesertRed.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
DesertRed (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/DesertYellow.html b/docs/api/com/jgoodies/looks/plastic/theme/DesertYellow.html
index 11c64e6..1e40dc7 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/DesertYellow.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/DesertYellow.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:27 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
DesertYellow (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/ExperienceBlue.html b/docs/api/com/jgoodies/looks/plastic/theme/ExperienceBlue.html
index 2d1873a..1983fbf 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/ExperienceBlue.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/ExperienceBlue.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
ExperienceBlue (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/ExperienceGreen.html b/docs/api/com/jgoodies/looks/plastic/theme/ExperienceGreen.html
index d2da49b..c73be03 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/ExperienceGreen.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/ExperienceGreen.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
ExperienceGreen (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/ExperienceRoyale.html b/docs/api/com/jgoodies/looks/plastic/theme/ExperienceRoyale.html
index 2bc7a5a..7a40468 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/ExperienceRoyale.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/ExperienceRoyale.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
ExperienceRoyale (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/InvertedColorTheme.html b/docs/api/com/jgoodies/looks/plastic/theme/InvertedColorTheme.html
index 0830e67..3e825b1 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/InvertedColorTheme.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/InvertedColorTheme.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
InvertedColorTheme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/LightGray.html b/docs/api/com/jgoodies/looks/plastic/theme/LightGray.html
index 268a27b..24352e6 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/LightGray.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/LightGray.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
LightGray (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/Silver.html b/docs/api/com/jgoodies/looks/plastic/theme/Silver.html
index c7a93cd..857b7e6 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/Silver.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/Silver.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
Silver (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/SkyBlue.html b/docs/api/com/jgoodies/looks/plastic/theme/SkyBlue.html
index 509ae96..b1b3a59 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/SkyBlue.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/SkyBlue.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
SkyBlue (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/SkyBluer.html b/docs/api/com/jgoodies/looks/plastic/theme/SkyBluer.html
index 1fb794f..34b7a82 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/SkyBluer.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/SkyBluer.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
SkyBluer (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/SkyGreen.html b/docs/api/com/jgoodies/looks/plastic/theme/SkyGreen.html
index 542f14f..c9fbba0 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/SkyGreen.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/SkyGreen.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
SkyGreen (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/SkyKrupp.html b/docs/api/com/jgoodies/looks/plastic/theme/SkyKrupp.html
index 13466da..f500833 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/SkyKrupp.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/SkyKrupp.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
SkyKrupp (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/SkyPink.html b/docs/api/com/jgoodies/looks/plastic/theme/SkyPink.html
index 43fe483..ba88ee4 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/SkyPink.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/SkyPink.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
SkyPink (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/SkyRed.html b/docs/api/com/jgoodies/looks/plastic/theme/SkyRed.html
index 2b3f05b..095ab63 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/SkyRed.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/SkyRed.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
SkyRed (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/SkyYellow.html b/docs/api/com/jgoodies/looks/plastic/theme/SkyYellow.html
index 519382e..191db0f 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/SkyYellow.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/SkyYellow.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
SkyYellow (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/AbstractSkyTheme.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/AbstractSkyTheme.html
index 1536f2a..cf1023e 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/AbstractSkyTheme.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/AbstractSkyTheme.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.AbstractSkyTheme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/BrownSugar.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/BrownSugar.html
index 3281f86..b15595c 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/BrownSugar.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/BrownSugar.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.BrownSugar (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DarkStar.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DarkStar.html
index 0123564..07e33ec 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DarkStar.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DarkStar.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.DarkStar (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBlue.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBlue.html
index b28c12d..6a9f61b 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBlue.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBlue.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.DesertBlue (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBluer.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBluer.html
index b7476f2..d5f3371 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBluer.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertBluer.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.DesertBluer (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertGreen.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertGreen.html
index b764265..2503088 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertGreen.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertGreen.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.DesertGreen (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertRed.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertRed.html
index dbb3e42..b99b7b5 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertRed.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertRed.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.DesertRed (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertYellow.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertYellow.html
index c7b9e6f..e774ac4 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertYellow.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/DesertYellow.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.DesertYellow (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceBlue.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceBlue.html
index 78a895a..7577e63 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceBlue.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceBlue.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.ExperienceBlue (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceGreen.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceGreen.html
index 369002d..1408037 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceGreen.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceGreen.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.ExperienceGreen (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceRoyale.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceRoyale.html
index 2402f7c..f6549d0 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceRoyale.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/ExperienceRoyale.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.ExperienceRoyale (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/InvertedColorTheme.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/InvertedColorTheme.html
index da54d67..2e56d5a 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/InvertedColorTheme.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/InvertedColorTheme.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.InvertedColorTheme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/LightGray.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/LightGray.html
index f2928c3..4274685 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/LightGray.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/LightGray.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.LightGray (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/Silver.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/Silver.html
index 6442e14..3dfd5d6 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/Silver.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/Silver.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.Silver (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBlue.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBlue.html
index ade295a..68bc4cd 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBlue.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBlue.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.SkyBlue (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBluer.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBluer.html
index 8d81bc8..dae140c 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBluer.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyBluer.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.SkyBluer (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyGreen.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyGreen.html
index dc2fc7f..bf80a64 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyGreen.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyGreen.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.SkyGreen (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyKrupp.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyKrupp.html
index 1f96c65..929e144 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyKrupp.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyKrupp.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.SkyKrupp (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyPink.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyPink.html
index 942e2b9..63cceae 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyPink.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyPink.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.SkyPink (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyRed.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyRed.html
index c246002..0ef63b5 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyRed.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyRed.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.SkyRed (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyYellow.html b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyYellow.html
index 412f774..a827529 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyYellow.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/class-use/SkyYellow.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:28 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.plastic.theme.SkyYellow (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/package-frame.html b/docs/api/com/jgoodies/looks/plastic/theme/package-frame.html
index b270d89..ec3655b 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/package-frame.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/package-frame.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.plastic.theme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/package-summary.html b/docs/api/com/jgoodies/looks/plastic/theme/package-summary.html
index 1ea9b10..6108884 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/package-summary.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/package-summary.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.plastic.theme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/package-tree.html b/docs/api/com/jgoodies/looks/plastic/theme/package-tree.html
index cfea057..3794dd3 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/package-tree.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/package-tree.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.plastic.theme Class Hierarchy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/plastic/theme/package-use.html b/docs/api/com/jgoodies/looks/plastic/theme/package-use.html
index 078bd4b..15ef2d0 100644
--- a/docs/api/com/jgoodies/looks/plastic/theme/package-use.html
+++ b/docs/api/com/jgoodies/looks/plastic/theme/package-use.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Package com.jgoodies.looks.plastic.theme (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsButtonUI.html b/docs/api/com/jgoodies/looks/windows/WindowsButtonUI.html
index b891de1..64f6701 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsButtonUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsComboBoxUI.html b/docs/api/com/jgoodies/looks/windows/WindowsComboBoxUI.html
index 5ccfb7e..b71f77e 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsComboBoxUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsComboBoxUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsComboBoxUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsFormattedTextFieldUI.html b/docs/api/com/jgoodies/looks/windows/WindowsFormattedTextFieldUI.html
index 0332fba..b2d1423 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsFormattedTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsFormattedTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsFormattedTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsLookAndFeel.html b/docs/api/com/jgoodies/looks/windows/WindowsLookAndFeel.html
index 7db2692..e047cf2 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsMenuBarUI.html b/docs/api/com/jgoodies/looks/windows/WindowsMenuBarUI.html
index 00d8a55..0e34e72 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsMenuBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsMenuBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsMenuBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsMenuItemUI.html b/docs/api/com/jgoodies/looks/windows/WindowsMenuItemUI.html
index 3af763e..8d5ed26 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsOptionPaneUI.html b/docs/api/com/jgoodies/looks/windows/WindowsOptionPaneUI.html
index b3c0997..fd0823a 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsOptionPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsOptionPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsOptionPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsPasswordFieldUI.html b/docs/api/com/jgoodies/looks/windows/WindowsPasswordFieldUI.html
index 21d37fe..f12fd97 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsPasswordFieldUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsPasswordFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsPasswordFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsPopupMenuUI.html b/docs/api/com/jgoodies/looks/windows/WindowsPopupMenuUI.html
index 452e0a8..1ddc45d 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsPopupMenuUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsPopupMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsPopupMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsScrollBarUI.html b/docs/api/com/jgoodies/looks/windows/WindowsScrollBarUI.html
index 737259e..d0f9de7 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsScrollBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsScrollBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsScrollBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsScrollPaneUI.html b/docs/api/com/jgoodies/looks/windows/WindowsScrollPaneUI.html
index 803ce65..587dbae 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsScrollPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsScrollPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsScrollPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsSeparatorUI.html b/docs/api/com/jgoodies/looks/windows/WindowsSeparatorUI.html
index 2ec4fc9..251996c 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsSpinnerUI.html b/docs/api/com/jgoodies/looks/windows/WindowsSpinnerUI.html
index 26a2f41..6876b39 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsSpinnerUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsSpinnerUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsSpinnerUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsSplitPaneUI.html b/docs/api/com/jgoodies/looks/windows/WindowsSplitPaneUI.html
index 59fec23..ae08533 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsSplitPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsSplitPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsSplitPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsTabbedPaneUI.html b/docs/api/com/jgoodies/looks/windows/WindowsTabbedPaneUI.html
index 83218fd..8d83024 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsTabbedPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsTabbedPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsTabbedPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsTextAreaUI.html b/docs/api/com/jgoodies/looks/windows/WindowsTextAreaUI.html
index 328a5e6..1f37cd5 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsTextAreaUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsTextAreaUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsTextAreaUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsTextFieldUI.html b/docs/api/com/jgoodies/looks/windows/WindowsTextFieldUI.html
index c282e84..46b31f5 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsToolBarSeparatorUI.html b/docs/api/com/jgoodies/looks/windows/WindowsToolBarSeparatorUI.html
index 51fb8ae..0b4c06d 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsToolBarSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsToolBarSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsToolBarSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsToolBarUI.html b/docs/api/com/jgoodies/looks/windows/WindowsToolBarUI.html
index 086ed6c..692684a 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsTreeUI.html b/docs/api/com/jgoodies/looks/windows/WindowsTreeUI.html
index 1cd2bc6..f7768f6 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsTreeUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsTreeUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsTreeUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsXPMenuUI.html b/docs/api/com/jgoodies/looks/windows/WindowsXPMenuUI.html
index 32e4ec4..555b34b 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsXPMenuUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsXPMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsXPMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsXPTableHeaderUI.html b/docs/api/com/jgoodies/looks/windows/WindowsXPTableHeaderUI.html
index 6713579..d9a925b 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsXPTableHeaderUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsXPTableHeaderUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsXPTableHeaderUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/WindowsXPToolBarUI.html b/docs/api/com/jgoodies/looks/windows/WindowsXPToolBarUI.html
index 03839fb..4c0db1f 100644
--- a/docs/api/com/jgoodies/looks/windows/WindowsXPToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/WindowsXPToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
WindowsXPToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsButtonUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsButtonUI.html
index 3667bcd..06bf37a 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsButtonUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsButtonUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsButtonUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsComboBoxUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsComboBoxUI.html
index f0cabb0..ede2cf2 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsComboBoxUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsComboBoxUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsComboBoxUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsFormattedTextFieldUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsFormattedTextFieldUI.html
index 15a346c..1ff1b12 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsFormattedTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsFormattedTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsFormattedTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsLookAndFeel.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsLookAndFeel.html
index 05fa823..964f39b 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsLookAndFeel.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsLookAndFeel.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsLookAndFeel (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuBarUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuBarUI.html
index 2249d99..0b49ecb 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsMenuBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuItemUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuItemUI.html
index 7a6dab5..e9b8f5d 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuItemUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsMenuItemUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsMenuItemUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsOptionPaneUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsOptionPaneUI.html
index 87f1b83..89b2566 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsOptionPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsOptionPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsOptionPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsPasswordFieldUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsPasswordFieldUI.html
index 7293ecf..f65bfc0 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsPasswordFieldUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsPasswordFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsPasswordFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsPopupMenuUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsPopupMenuUI.html
index 13c444d..d0d433e 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsPopupMenuUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsPopupMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsPopupMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollBarUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollBarUI.html
index ed0a120..251636e 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsScrollBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollPaneUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollPaneUI.html
index f6c92dd..4733f53 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsScrollPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsScrollPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsSeparatorUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsSeparatorUI.html
index 9afec23..5abb125 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsSpinnerUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsSpinnerUI.html
index bdb9650..7caae8a 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsSpinnerUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsSpinnerUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsSpinnerUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsSplitPaneUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsSplitPaneUI.html
index 346814f..4a7fa3d 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsSplitPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsSplitPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsSplitPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTabbedPaneUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTabbedPaneUI.html
index 717e1bf..bdca14e 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTabbedPaneUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTabbedPaneUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsTabbedPaneUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextAreaUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextAreaUI.html
index 6cc7225..011a4c5 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextAreaUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextAreaUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsTextAreaUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextFieldUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextFieldUI.html
index 5c8e615..0aa4712 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextFieldUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTextFieldUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsTextFieldUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarSeparatorUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarSeparatorUI.html
index e1d7e32..376d4f2 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarSeparatorUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarSeparatorUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsToolBarSeparatorUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarUI.html
index 3e02a34..6afac26 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTreeUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTreeUI.html
index f3611e5..4563b0a 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsTreeUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsTreeUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsTreeUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPMenuUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPMenuUI.html
index fcc8586..693acff 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPMenuUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPMenuUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsXPMenuUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPTableHeaderUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPTableHeaderUI.html
index e5d94a0..7a9146e 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPTableHeaderUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPTableHeaderUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsXPTableHeaderUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPToolBarUI.html b/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPToolBarUI.html
index b1a7261..4654f2a 100644
--- a/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPToolBarUI.html
+++ b/docs/api/com/jgoodies/looks/windows/class-use/WindowsXPToolBarUI.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:30 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Class com.jgoodies.looks.windows.WindowsXPToolBarUI (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/package-frame.html b/docs/api/com/jgoodies/looks/windows/package-frame.html
index e390106..55e10ec 100644
--- a/docs/api/com/jgoodies/looks/windows/package-frame.html
+++ b/docs/api/com/jgoodies/looks/windows/package-frame.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.windows (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/package-summary.html b/docs/api/com/jgoodies/looks/windows/package-summary.html
index 1077f14..2081775 100644
--- a/docs/api/com/jgoodies/looks/windows/package-summary.html
+++ b/docs/api/com/jgoodies/looks/windows/package-summary.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.windows (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/package-tree.html b/docs/api/com/jgoodies/looks/windows/package-tree.html
index 3b16c26..d268864 100644
--- a/docs/api/com/jgoodies/looks/windows/package-tree.html
+++ b/docs/api/com/jgoodies/looks/windows/package-tree.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
com.jgoodies.looks.windows Class Hierarchy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/com/jgoodies/looks/windows/package-use.html b/docs/api/com/jgoodies/looks/windows/package-use.html
index 16f3e8d..3e4c936 100644
--- a/docs/api/com/jgoodies/looks/windows/package-use.html
+++ b/docs/api/com/jgoodies/looks/windows/package-use.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Uses of Package com.jgoodies.looks.windows (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
diff --git a/docs/api/constant-values.html b/docs/api/constant-values.html
index 89c2226..74c1b1c 100644
--- a/docs/api/constant-values.html
+++ b/docs/api/constant-values.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Constant Field Values (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/deprecated-list.html b/docs/api/deprecated-list.html
index 1f2ed9c..036de1a 100644
--- a/docs/api/deprecated-list.html
+++ b/docs/api/deprecated-list.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Deprecated List (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/help-doc.html b/docs/api/help-doc.html
index c6b5193..938ee3f 100644
--- a/docs/api/help-doc.html
+++ b/docs/api/help-doc.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
API Help (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/index-all.html b/docs/api/index-all.html
index e7ac07c..11a7b52 100644
--- a/docs/api/index-all.html
+++ b/docs/api/index-all.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Index (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="./stylesheet.css" TITLE="Style">
diff --git a/docs/api/index.html b/docs/api/index.html
index 24f7936..d12d103 100644
--- a/docs/api/index.html
+++ b/docs/api/index.html
@@ -2,7 +2,7 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc on Sun Feb 05 13:56:31 CET 2012-->
+<!-- Generated by javadoc on Thu May 03 18:14:29 CEST 2012-->
<TITLE>
JGoodies Looks 2.5 API
</TITLE>
diff --git a/docs/api/overview-frame.html b/docs/api/overview-frame.html
index 3363143..a6a80a1 100644
--- a/docs/api/overview-frame.html
+++ b/docs/api/overview-frame.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:28 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:26 CEST 2012 -->
<TITLE>
Overview List (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/overview-summary.html b/docs/api/overview-summary.html
index 6de3081..98875f0 100644
--- a/docs/api/overview-summary.html
+++ b/docs/api/overview-summary.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Overview (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/overview-tree.html b/docs/api/overview-tree.html
index ec795c1..c63c264 100644
--- a/docs/api/overview-tree.html
+++ b/docs/api/overview-tree.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:31 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:29 CEST 2012 -->
<TITLE>
Class Hierarchy (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/api/serialized-form.html b/docs/api/serialized-form.html
index 4fadf6d..1e67a5f 100644
--- a/docs/api/serialized-form.html
+++ b/docs/api/serialized-form.html
@@ -2,12 +2,12 @@
<!--NewPage-->
<HTML>
<HEAD>
-<!-- Generated by javadoc (build 1.6.0_30) on Sun Feb 05 13:56:29 CET 2012 -->
+<!-- Generated by javadoc (build 1.6.0_31) on Thu May 03 18:14:27 CEST 2012 -->
<TITLE>
Serialized Form (JGoodies Looks 2.5 API)
</TITLE>
-<META NAME="date" CONTENT="2012-02-05">
+<META NAME="date" CONTENT="2012-05-03">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
diff --git a/docs/examples.html b/docs/examples.html
index a9a8cb9..bcb427e 100644
--- a/docs/examples.html
+++ b/docs/examples.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/guide/3d.html b/docs/guide/3d.html
index 6b6568a..0e5a508 100644
--- a/docs/guide/3d.html
+++ b/docs/guide/3d.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="../api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/guide/bars.html b/docs/guide/bars.html
index e3052f7..c152a1f 100644
--- a/docs/guide/bars.html
+++ b/docs/guide/bars.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="../api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/guide/fonts.html b/docs/guide/fonts.html
index cf017d3..e3bca42 100644
--- a/docs/guide/fonts.html
+++ b/docs/guide/fonts.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="../api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/guide/index.html b/docs/guide/index.html
index 1900109..1171bfc 100644
--- a/docs/guide/index.html
+++ b/docs/guide/index.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="../api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/guide/lookandtheme.html b/docs/guide/lookandtheme.html
index 5fab780..b1cf4c6 100644
--- a/docs/guide/lookandtheme.html
+++ b/docs/guide/lookandtheme.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="../api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/guide/other.html b/docs/guide/other.html
index bc0692d..8505ca3 100644
--- a/docs/guide/other.html
+++ b/docs/guide/other.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="../api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/guide/plastic.html b/docs/guide/plastic.html
index 711cbbd..5240617 100644
--- a/docs/guide/plastic.html
+++ b/docs/guide/plastic.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="../api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/quickstart.html b/docs/quickstart.html
index abc3ce2..e9e07f6 100644
--- a/docs/quickstart.html
+++ b/docs/quickstart.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/docs/tips.html b/docs/tips.html
index e03ed16..fa794e5 100644
--- a/docs/tips.html
+++ b/docs/tips.html
@@ -46,13 +46,12 @@
<p>
<a class="nav" href="api/index.html"><b>API Docs</b></a>
<p>
- <b>Web Pages</b>
- <br>:: <a class="nav" href="http://looks.java.net/">Project Home</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectDocumentList">Downloads</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectNewsList">Announcements</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectMailingListList">Mailing Lists</a>
- <br>:: <a class="nav" href="http://looks.java.net/servlets/ProjectIssues">Issue Tracker</a>
- <br>:: <a class="nav" href="http://www.jgoodies.com/freeware/">More Examples</a>
+ <b>Web Pages</b>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/">Project Home</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/libraries.html">Download</a>
+ <br>:: <a class="nav" href="http://www.jgoodies.com/downloads/archive.html">Archive</a>
+ <br>:: <a class="nav" href="http://java.net/projects/looks/lists">Mailing Lists</a>
+ <br>:: <a class="nav" href="http://java.net/jira/browse/LOOKS">Issue Tracker</a>
<!-- *********** Ende der Seitennavigation ******************************* -->
diff --git a/jgoodies-looks-2.5.1-javadoc.jar b/jgoodies-looks-2.5.1-javadoc.jar
new file mode 100644
index 0000000..8de6eab
Binary files /dev/null and b/jgoodies-looks-2.5.1-javadoc.jar differ
diff --git a/jgoodies-looks-2.5.1-sources.jar b/jgoodies-looks-2.5.1-sources.jar
new file mode 100644
index 0000000..c26e380
Binary files /dev/null and b/jgoodies-looks-2.5.1-sources.jar differ
diff --git a/jgoodies-looks-2.5.1-tests.jar b/jgoodies-looks-2.5.1-tests.jar
new file mode 100644
index 0000000..9fd7672
Binary files /dev/null and b/jgoodies-looks-2.5.1-tests.jar differ
diff --git a/jgoodies-looks-2.5.0.jar b/jgoodies-looks-2.5.1.jar
similarity index 90%
rename from jgoodies-looks-2.5.0.jar
rename to jgoodies-looks-2.5.1.jar
index 0194ab1..90fddfb 100644
Binary files a/jgoodies-looks-2.5.0.jar and b/jgoodies-looks-2.5.1.jar differ
diff --git a/lib/jgoodies-common-1.3.0.jar b/lib/jgoodies-common-1.3.0.jar
deleted file mode 100644
index 7978e04..0000000
Binary files a/lib/jgoodies-common-1.3.0.jar and /dev/null differ
diff --git a/pom.xml b/pom.xml
new file mode 100644
index 0000000..ba119af
--- /dev/null
+++ b/pom.xml
@@ -0,0 +1,67 @@
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>com.jgoodies</groupId>
+ <artifactId>jgoodies-looks</artifactId>
+ <version>@impl.version</version>
+ <packaging>jar</packaging>
+ <name>JGoodies Looks</name>
+ <url>https://looks.java.net/</url>
+ <description>The JGoodies Looks make your Swing applications and
+ applets look better. They have been optimized for readability,
+ precise micro-design and usability. And they simplify
+ the multi-platform support by using similar widget dimensions.
+ In addition, many people have reviewed them as elegant.</description>
+ <dependencies>
+ <dependency>
+ <groupId>com.jgoodies</groupId>
+ <artifactId>jgoodies-common</artifactId>
+ <version>1.3.1</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.0</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+ <licenses>
+ <license>
+ <name>The BSD License</name>
+ <url>http://www.opensource.org/licenses/bsd-license.html</url>
+ </license>
+ </licenses>
+ <organization>
+ <name>JGoodies</name>
+ <url>http://www.jgoodies.com/</url>
+ </organization>
+ <developers>
+ <developer>
+ <id>karsten</id>
+ <name>Karsten Lentzsch</name>
+ <organization>JGoodies</organization>
+ <organizationUrl>http://www.jgoodies.com/</organizationUrl>
+ <timezone>+0100</timezone>
+ <roles>
+ <role>Project owner</role>
+ <role>Developer</role>
+ </roles>
+ </developer>
+ </developers>
+ <issueManagement>
+ <system>JIRA</system>
+ <url>http://java.net/jira/browse/LOOKS/</url>
+ </issueManagement>
+ <mailingLists>
+ <mailingList>
+ <name>User List</name>
+ <archive>http://http://java.net/projects/looks/lists/users/archive</archive>
+ <post>users at looks.java.net</post>
+ </mailingList>
+ </mailingLists>
+ <scm>
+ <connection>scm:svn:https://svn.java.net/svn/looks~svn</connection>
+ <tag>head</tag>
+ <url>https://svn.java.net/svn/looks~svn</url>
+ </scm>
+</project>
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/BorderStyle.java b/src/core/com/jgoodies/looks/BorderStyle.java
deleted file mode 100644
index 2afece2..0000000
--- a/src/core/com/jgoodies/looks/BorderStyle.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import javax.swing.JComponent;
-import javax.swing.JMenuBar;
-import javax.swing.JToolBar;
-
-/**
- * Describes the border styles for JMenuBar and JToolBar. Border styles are
- * look-dependent and shadow look-independent {@code HeaderStyle}s.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see HeaderStyle
- */
-public final class BorderStyle {
-
- public static final BorderStyle EMPTY = new BorderStyle("Empty");
- public static final BorderStyle SEPARATOR = new BorderStyle("Separator");
- public static final BorderStyle ETCHED = new BorderStyle("Etched");
-
- private final String name;
-
-
- // Instance Creation ******************************************************
-
- private BorderStyle(String name) {
- this.name = name;
- }
-
-
- // ************************************************************************
-
- /**
- * Looks up the client property for the header style from the JToolBar.
- *
- * @param toolBar the tool bar to inspect
- * @param clientPropertyKey the key used to lookup the property
- * @return the border style used to choose a border in the UI delegate
- */
- public static BorderStyle from(JToolBar toolBar, String clientPropertyKey) {
- return from0(toolBar, clientPropertyKey);
- }
-
- /**
- * Looks up the client property for the header style from the JMenuBar.
- *
- * @param menuBar the menu bar to inspect
- * @param clientPropertyKey the key used to lookup the property
- * @return the border style used to choose a border in the UI delegate
- */
- public static BorderStyle from(JMenuBar menuBar, String clientPropertyKey) {
- return from0(menuBar, clientPropertyKey);
- }
-
- /**
- * Looks up the client property for the header style from the specified
- * JComponent.
- *
- * @param c the compoent to inspect
- * @param clientPropertyKey
- * the key used to lookup the property
- * @return the border style used to choose a border in the UI delegate
- */
- private static BorderStyle from0(JComponent c, String clientPropertyKey) {
- Object value = c.getClientProperty(clientPropertyKey);
- if (value instanceof BorderStyle) {
- return (BorderStyle) value;
- }
-
- if (value instanceof String) {
- return BorderStyle.valueOf((String) value);
- }
-
- return null;
- }
-
- private static BorderStyle valueOf(String name) {
- if (name.equalsIgnoreCase(EMPTY.name)) {
- return EMPTY;
- } else if (name.equalsIgnoreCase(SEPARATOR.name)) {
- return SEPARATOR;
- } else if (name.equalsIgnoreCase(ETCHED.name)) {
- return ETCHED;
- } else {
- throw new IllegalArgumentException("Invalid BorderStyle name "
- + name);
- }
- }
-
- @Override
- public String toString() {
- return name;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/FontPolicies.java b/src/core/com/jgoodies/looks/FontPolicies.java
deleted file mode 100644
index c91d9eb..0000000
--- a/src/core/com/jgoodies/looks/FontPolicies.java
+++ /dev/null
@@ -1,410 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import java.awt.Font;
-
-import javax.swing.UIDefaults;
-
-import com.jgoodies.common.base.SystemUtils;
-
-
-/**
- * Provides predefined FontPolicy implementations.<p>
- *
- * <strong>Note:</strong> The available policies work well on Windows.
- * On other platforms the fonts specified by the runtime environment
- * are chosen. I plan to provide more logic or options for other platforms,
- * for example that a Linux system checks for a Tahoma or Segoe UI.<p>
- *
- * TODO: Add a check for a custom font policy set in the System properties.<p>
- *
- * TODO: Add policies that emulate different Windows setups:
- * default XP on 96dpi with normal fonts ("XP-normal-96"),
- * Vista on 120dpi with large fonts ("Vista-large-120"), etc.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.14 $
- *
- * @see FontPolicy
- * @see FontSet
- * @see FontSets
- * @see Fonts
- *
- * @since 2.0
- */
-public final class FontPolicies {
-
-
- private FontPolicies() {
- // Override default constructor; prevents instantation.
- }
-
-
- // Getting a FontPolicy *********************************************
-
- /**
- * Returns a font policy that in turn always returns the specified FontSet.
- * The FontSet will be fixed, but the FontSet itself may
- * return different fonts in different environments.
- *
- * @param fontSet the FontSet to be return by this policy
- * @return a font policy that returns the specified FontSet.
- */
- public static FontPolicy createFixedPolicy(FontSet fontSet) {
- return new FixedPolicy(fontSet);
- }
-
-
- /**
- * Returns a font policy that checks for a custom FontPolicy
- * and a custom FontSet specified in the System settings or UIManager.
- * If no custom settings are available, the given default policy will
- * be used to look up the FontSet.
- *
- * @param defaultPolicy the policy used if there are no custom settings
- * @return a FontPolicy that checks for custom settings
- * before the default policy is returned.
- */
- public static FontPolicy customSettingsPolicy(FontPolicy defaultPolicy) {
- return new CustomSettingsPolicy(defaultPolicy);
- }
-
-
-// /**
-// * Returns the default platform independent font choice policy.<p>
-// *
-// * The current implementation just returns the logical fonts.
-// * A future version shall check for available good fonts
-// * and shall use them before it falls back to the logical fonts.
-// *
-// * @return the default platform independent font choice policy.
-// */
-// public static FontPolicy getDefaultCrossPlatformPolicy() {
-// return new DefaultCrossPlatformPolicy();
-// }
-
-
- /**
- * Returns the default font policy for Plastic on the Windows platform.
- * It differs from the default Windows policy in that it uses a bold font
- * for TitledBorders, titles, and titled separators.
- *
- * @return the default font policy for Plastic on the Windows platform.
- */
- public static FontPolicy getDefaultPlasticOnWindowsPolicy() {
- return new DefaultPlasticOnWindowsPolicy();
- }
-
-
- /**
- * Returns the default Plastic FontPolicy that may vary
- * with the platform and environment.
- * On Windows, the PlasticOnWindowsPolicy is returned that
- * is much like the defualt WindowsPolicy but uses a bold title font.
- * On other Platforms, the logical fonts policy is returned
- * that uses the logical fonts as specified by the Java runtime environment.
- *
- * @return a Windows-like policy on Windows, a logical fonts policy
- * on all other platforms
- */
- public static FontPolicy getDefaultPlasticPolicy() {
- if (SystemUtils.IS_OS_WINDOWS) {
- return getDefaultPlasticOnWindowsPolicy();
- }
- return getLogicalFontsPolicy();
-// return getDefaultCrossPlatformPolicy();
- }
-
-
- /**
- * Returns the default font policy for the Windows platform.
- * It aims to return a FontSet that is close to the native guidelines
- * and useful for the current Java environment.<p>
- *
- * The control font scales with the platform screen resolution
- * (96dpi/101dpi/120dpi/144dpi/...) and honors the desktop font settings
- * (normal/large/extra large).
- *
- * @return the default font policy for the Windows platform.
- */
- public static FontPolicy getDefaultWindowsPolicy() {
- return new DefaultWindowsPolicy();
- }
-
-
- /**
- * Returns a font policy that returns the logical fonts
- * as specified by the Java runtime environment.
- *
- * @return a font policy that returns logical fonts.
- */
- public static FontPolicy getLogicalFontsPolicy() {
- return createFixedPolicy(FontSets.getLogicalFontSet());
- }
-
-
- /**
- * Returns a font policy for getting a Plastic appearance that aims to be
- * visual backward compatible with the JGoodies Looks version 1.x.
- * It uses a font choice similar to the choice implemented
- * by the Plastic L&fs in the JGoodies Looks version 1.x.
- *
- * @return a font policy that aims to reproduce the Plastic font choice
- * in the JGoodies Looks 1.x.
- */
- public static FontPolicy getLooks1xPlasticPolicy() {
- Font controlFont = Fonts.getDefaultGUIFontWesternModernWindowsNormal();
- Font menuFont = controlFont;
- Font titleFont = controlFont.deriveFont(Font.BOLD);
- FontSet fontSet = FontSets.createDefaultFontSet(controlFont, menuFont, titleFont);
- return createFixedPolicy(fontSet);
- }
-
-
- /**
- * Returns a font policy for getting a Windows appearance that aims to be
- * visual backward compatible with the JGoodies Looks version 1.x.
- * It uses a font choice similar to the choice implemented
- * by the Windows L&f in the JGoodies Looks version 1.x.
- *
- * @return a font policy that aims to reproduce the Windows font choice
- * in the JGoodies Looks 1.x.
- */
- public static FontPolicy getLooks1xWindowsPolicy() {
- return new Looks1xWindowsPolicy();
- }
-
-
- /**
- * Returns a font policy intended for API users that want to
- * move Plastic code from the Looks 1.x to the Looks 2.0.
- * On Windows, it uses the Looks 2.0 Plastic fonts,
- * on other platforms it uses the Looks 1.x Plastic fonts.
- *
- * @return the recent Plastic font policy on Windows,
- * the JGoodies Looks 1.x on other Platforms.
- */
- public static FontPolicy getTransitionalPlasticPolicy() {
- return SystemUtils.IS_OS_WINDOWS
- ? getDefaultPlasticOnWindowsPolicy()
- : getLooks1xPlasticPolicy();
- }
-
-
- // Utility Methods ********************************************************
-
- /**
- * Looks up and returns a custom FontSet for the given
- * Look&Feel name, or {@code null} if no custom font set
- * has been defined for this Look&Feel.
- *
- * @param the name of the Look&Feel, one of {@code "Plastic"} or
- * {@code "Windows"}
- * @return a custom FontPolicy - if any - or otherwise {@code null}
- */
- private static FontSet getCustomFontSet(String lafName) {
- String controlFontKey = lafName + ".controlFont";
- String menuFontKey = lafName + ".menuFont";
- String decodedControlFont = LookUtils.getSystemProperty(controlFontKey);
- if (decodedControlFont == null) {
- return null;
- }
- Font controlFont = Font.decode(decodedControlFont);
- String decodedMenuFont = LookUtils.getSystemProperty(menuFontKey);
- Font menuFont = decodedMenuFont != null
- ? Font.decode(decodedMenuFont)
- : null;
- Font titleFont = "Plastic".equals(lafName)
- ? controlFont.deriveFont(Font.BOLD)
- : controlFont;
- return FontSets.createDefaultFontSet(controlFont, menuFont, titleFont);
- }
-
-
- /**
- * Looks up and returns a custom FontPolicy for the given
- * Look&Feel name, or {@code null} if no custom policy has been
- * defined for this Look&Feel.
- *
- * @param the name of the Look&Feel, one of {@code "Plastic"} or
- * {@code "Windows"}
- * @return a custom FontPolicy - if any - or otherwise {@code null}
- */
- private static FontPolicy getCustomPolicy(String lafName) {
- // TODO: Look up predefined font choice policies
- return null;
- }
-
-
- private static final class CustomSettingsPolicy implements FontPolicy {
-
- private final FontPolicy wrappedPolicy;
-
- CustomSettingsPolicy(FontPolicy wrappedPolicy) {
- this.wrappedPolicy = wrappedPolicy;
- }
-
- @Override
- public FontSet getFontSet(String lafName, UIDefaults table) {
- FontPolicy customPolicy = getCustomPolicy(lafName);
- if (customPolicy != null) {
- return customPolicy.getFontSet(null, table);
- }
- FontSet customFontSet = getCustomFontSet(lafName);
- if (customFontSet != null) {
- return customFontSet;
- }
- return wrappedPolicy.getFontSet(lafName, table);
- }
- }
-
-
-// private static final class DefaultCrossPlatformPolicy implements FontPolicy {
-//
-// public FontSet getFontSet(String lafName, UIDefaults table) {
-// // TODO: If Tahoma or Segoe UI is available, return them
-// // in a size appropriate for the screen resolution.
-// // Otherwise return the logical font set.
-// return FontSets.getLogicalFontSet();
-// }
-// }
-
-
- /**
- * Implements the default font lookup for the Plastic L&f family
- * when running in a Windows environment.
- */
- private static final class DefaultPlasticOnWindowsPolicy implements FontPolicy {
-
- @Override
- public FontSet getFontSet(String lafName, UIDefaults table) {
- Font windowsControlFont = Fonts.getWindowsControlFont();
- Font controlFont;
- if (windowsControlFont != null) {
- controlFont = windowsControlFont;
- } else if (table != null) {
- controlFont = table.getFont("Button.font");
- } else {
- controlFont = new Font("Dialog", Font.PLAIN, 12);
- }
-
- Font menuFont = table == null
- ? controlFont
- : table.getFont("Menu.font");
- Font titleFont = controlFont.deriveFont(Font.BOLD);
-
- return FontSets.createDefaultFontSet(controlFont, menuFont, titleFont);
- }
- }
-
-
- /**
- * Implements the default font lookup on the Windows platform.
- */
- private static final class DefaultWindowsPolicy implements FontPolicy {
-
- @Override
- public FontSet getFontSet(String lafName, UIDefaults table) {
- Font windowsControlFont = Fonts.getWindowsControlFont();
- Font controlFont;
- if (windowsControlFont != null) {
- controlFont = windowsControlFont;
- } else if (table != null) {
- controlFont = table.getFont("Button.font");
- } else {
- controlFont = new Font("Dialog", Font.PLAIN, 12);
- }
- Font menuFont = table == null
- ? controlFont
- : table.getFont("Menu.font");
- Font titleFont = controlFont;
- Font messageFont = table == null
- ? controlFont
- : table.getFont("OptionPane.font");
- Font smallFont = table == null
- ? controlFont.deriveFont(controlFont.getSize2D() - 2f)
- : table.getFont("ToolTip.font");
- Font windowTitleFont = table == null
- ? controlFont
- : table.getFont("InternalFrame.titleFont");
- return FontSets.createDefaultFontSet(
- controlFont,
- menuFont,
- titleFont,
- messageFont,
- smallFont,
- windowTitleFont);
- }
- }
-
-
- /**
- * A FontPolicy that returns a fixed FontSet and that ignores
- * the laf name and UIDefaults table.
- */
- private static final class FixedPolicy implements FontPolicy {
-
- private final FontSet fontSet;
-
- FixedPolicy(FontSet fontSet) {
- this.fontSet = fontSet;
- }
-
- @Override
- public FontSet getFontSet(String lafName, UIDefaults table) {
- return fontSet;
- }
- }
-
-
- /**
- * Aims to mimic the font choice as used in the JGoodies Looks 1.x.
- */
- private static final class Looks1xWindowsPolicy implements FontPolicy {
-
- @Override
- public FontSet getFontSet(String lafName, UIDefaults table) {
- Font windowsControlFont = Fonts.getLooks1xWindowsControlFont();
- Font controlFont;
- if (windowsControlFont != null) {
- controlFont = windowsControlFont;
- } else if (table != null) {
- controlFont = table.getFont("Button.font");
- } else {
- controlFont = new Font("Dialog", Font.PLAIN, 12);
- }
- return FontSets.createDefaultFontSet(controlFont);
- }
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/FontPolicy.java b/src/core/com/jgoodies/looks/FontPolicy.java
deleted file mode 100644
index 6f04021..0000000
--- a/src/core/com/jgoodies/looks/FontPolicy.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import javax.swing.UIDefaults;
-
-
-/**
- * Looks up and returns a FontSet.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.6 $
- *
- * @see FontSet
- * @see FontPolicies
- *
- * @since 2.0
- */
-public interface FontPolicy {
-
- /**
- * Looks up and returns a set of fonts that will be used
- * by a Look&Feel to set the default fonts for its components.<p>
- *
- * This method is invoked during the L&F component initialization.
- * And the invoker hands over the UIDefaults object used to define
- * the component settings. Hence, the UIDefaults object may be used
- * to look up a font as initialized by a super Look&Feel.
- * For example the JGoodies Windows L&F could use the
- * defaults set by the super L&F, the Sun Windows L&F.
- *
- * @param lafName the name of the Look&Feel that requests the fonts
- * @param table the UIDefaults table that can be used
- * to look up fonts of a super L&F
- *
- * @return a set of fonts used as default for the component.
- */
- FontSet getFontSet(String lafName, UIDefaults table);
-
-}
diff --git a/src/core/com/jgoodies/looks/FontSet.java b/src/core/com/jgoodies/looks/FontSet.java
deleted file mode 100644
index 7b3a1cc..0000000
--- a/src/core/com/jgoodies/looks/FontSet.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import javax.swing.plaf.FontUIResource;
-
-/**
- * Returns the Fonts used by a Look&Feel or theme.
- * These Fonts must implement the UIResource marker interface.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @since 2.0
- */
-public interface FontSet {
-
- /**
- * Returns the font used for all dialog components.
- *
- * @return the font used for all dialog components.
- */
- FontUIResource getControlFont();
-
-
- /**
- * Returns the font used for the menu.
- *
- * @return the font used for the menu.
- */
- FontUIResource getMenuFont();
-
-
- /**
- * Returns the font used for the title label in TitledBorders.
- * This font is also used by JGoodies Forms titles,
- * and titled separators.
- *
- * @return the font used for TitledBorder titles.
- */
- FontUIResource getTitleFont();
-
-
- /**
- * Returns the font used for internal frame titles.
- *
- * @return the font used for internal frame titles.
- */
- FontUIResource getWindowTitleFont();
-
-
- /**
- * Returns the font used for tool tips.
- *
- * @return the tool tip font.
- */
- FontUIResource getSmallFont();
-
-
- /**
- * Returns the font used for message dialogs.
- *
- * @return the font used for message dialogs.
- */
- FontUIResource getMessageFont();
-
-}
diff --git a/src/core/com/jgoodies/looks/FontSets.java b/src/core/com/jgoodies/looks/FontSets.java
deleted file mode 100644
index caf1e9f..0000000
--- a/src/core/com/jgoodies/looks/FontSets.java
+++ /dev/null
@@ -1,321 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import java.awt.Font;
-
-import javax.swing.plaf.FontUIResource;
-
-
-/**
- * Provides predefined FontSet implementations.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.16 $
- *
- * @see FontSet
- * @see FontPolicy
- * @see FontPolicies
- *
- * @since 2.0
- */
-public final class FontSets {
-
- private static FontSet logicalFontSet;
-
-
- private FontSets() {
- // Override default constructor; prevents instantation.
- }
-
-
- // Default FontSets *******************************************************
-
- /**
- * Creates and returns a FontSet that is based only
- * on the given control font. The small font will be
- * derived from the control font; all other fonts
- * returned are the control font.
- *
- * @param controlFont the font used for all controls
- *
- * @return a FontSet based on the given fonts
- *
- * @throws NullPointerException if the control font is {@code null}
- */
- public static FontSet createDefaultFontSet(Font controlFont) {
- return createDefaultFontSet(controlFont, null);
- }
-
-
- /**
- * Creates and returns a FontSet that is based on the given control font
- * and menu font. The small font will be derived from the control font;
- * all other fonts return, except the menu font, are the control font.
- *
- * @param controlFont the font used for all controls
- * @param menuFont the font used for the menu bar and menu items
- *
- * @return a FontSet based on the given fonts
- *
- * @throws NullPointerException if the control font is {@code null}
- */
- public static FontSet createDefaultFontSet(Font controlFont, Font menuFont) {
- return createDefaultFontSet(controlFont, menuFont, null, null, null, null);
- }
-
-
- /**
- * Creates and returns a FontSet that is based on the given control font
- * and menu font. The small font will be derived from the control font;
- * all other fonts return, except the menu font, are the control font.
- *
- * @param controlFont the font used for all controls
- * @param menuFont the font used for the menu bar and menu items
- * @param titleFont used for TitledBorder, titles and titled separators
- *
- * @return a FontSet based on the given fonts
- *
- * @throws NullPointerException if the control font is {@code null}
- */
- public static FontSet createDefaultFontSet(Font controlFont, Font menuFont, Font titleFont) {
- return createDefaultFontSet(controlFont, menuFont, titleFont, null, null, null);
- }
-
-
- /**
- * Creates and returns a FontSet for the given fonts.
- * If a font is {@code null}, it uses the control font as
- * fallback. If the small font is {@code null} it will
- * be derived from the control font.
- *
- * @param controlFont used for all controls
- * @param menuFont used for the menu bar and menu items
- * @param titleFont used for TitledBorder, titles and titled separators
- * @param messageFont used for OptionPanes
- * @param smallFont used for tool tips and similar components
- * @param windowTitleFont used for internal frame window titles
- *
- * @return a FontSet based on the given fonts
- *
- * @throws NullPointerException if the control font is {@code null}
- */
- public static FontSet createDefaultFontSet(
- Font controlFont,
- Font menuFont,
- Font titleFont,
- Font messageFont,
- Font smallFont,
- Font windowTitleFont) {
- return new DefaultFontSet(controlFont, menuFont, titleFont, messageFont, smallFont, windowTitleFont);
- }
-
-
- // Logical FontSet ********************************************************
-
- /**
- * Lazily creates and returns the FontSet that returns
- * the logical fonts specified by the Java runtime environment.
- *
- * @return a FontSets that uses the logical fonts specified
- * by the Java environment
- */
- public static FontSet getLogicalFontSet() {
- if (logicalFontSet == null) {
- logicalFontSet = new LogicalFontSet();
- }
- return logicalFontSet;
- }
-
-
- // Helper Code ************************************************************
-
- private static final class DefaultFontSet implements FontSet {
-
- private final FontUIResource controlFont;
- private final FontUIResource menuFont;
- private final FontUIResource titleFont;
- private final FontUIResource messageFont;
- private final FontUIResource smallFont;
- private final FontUIResource windowTitleFont;
-
-
- // Instance Creation --------------------------------------------------
-
- /**
- * Constructs a DefaultFontSet for the given fonts.
- * If a font is {@code null}, it uses the control font as
- * fallback. If the small font is {@code null} it will
- * be derived from the control font.
- *
- * @param controlFont used for all controls
- * @param menuFont used for the menu bar and menu items
- * @param titleFont used for TitledBorder, titles and titled separators
- * @param messageFont used for OptionPanes
- * @param smallFont used for tool tips and similar components
- * @param windowTitleFont used for internal frame window titles
- *
- * @throws NullPointerException if the control font is {@code null}
- */
- public DefaultFontSet(
- Font controlFont,
- Font menuFont,
- Font titleFont,
- Font messageFont,
- Font smallFont,
- Font windowTitleFont) {
- this.controlFont = new FontUIResource(controlFont);
- this.menuFont = menuFont != null
- ? new FontUIResource(menuFont)
- : this.controlFont;
- this.titleFont = titleFont != null
- ? new FontUIResource(titleFont)
- : this.controlFont; //new FontUIResource(controlFont.deriveFont(Font.BOLD))
- this.messageFont = messageFont != null
- ? new FontUIResource(messageFont)
- : this.controlFont;
- this.smallFont = new FontUIResource(smallFont != null
- ? smallFont
- : controlFont.deriveFont(controlFont.getSize2D() - 2f));
- this.windowTitleFont = windowTitleFont != null
- ? new FontUIResource(windowTitleFont)
- : this.titleFont;
- }
-
-
- // FontSet API --------------------------------------------------------
-
- @Override
- public FontUIResource getControlFont() {
- return controlFont;
- }
-
- @Override
- public FontUIResource getMenuFont() {
- return menuFont;
- }
-
- @Override
- public FontUIResource getTitleFont() {
- return titleFont;
- }
-
- @Override
- public FontUIResource getWindowTitleFont() {
- return windowTitleFont;
- }
-
- @Override
- public FontUIResource getSmallFont() {
- return smallFont;
- }
-
- @Override
- public FontUIResource getMessageFont() {
- return messageFont;
- }
-
- }
-
-
- /**
- * Looks up and returns the logical fonts as specified
- * by the Java runtime environment.
- */
- private static final class LogicalFontSet implements FontSet {
-
- private FontUIResource controlFont;
- private FontUIResource titleFont;
- private FontUIResource systemFont;
- private FontUIResource smallFont;
-
-
- @Override
- public FontUIResource getControlFont() {
- if (controlFont == null) {
- controlFont = new FontUIResource(
- Font.getFont(
- "swing.plaf.metal.controlFont",
- new Font("Dialog", Font.PLAIN, 12)));
-
- }
- return controlFont;
- }
-
- @Override
- public FontUIResource getMenuFont() {
- return getControlFont();
- }
-
- @Override
- public FontUIResource getTitleFont() {
- if (titleFont == null) {
- titleFont =
- new FontUIResource(
- getControlFont().deriveFont(Font.BOLD));
- }
- return titleFont;
- }
-
- @Override
- public FontUIResource getSmallFont() {
- if (smallFont == null) {
- smallFont =
- new FontUIResource(
- Font.getFont(
- "swing.plaf.metal.smallFont",
- new Font("Dialog", Font.PLAIN, 10)));
- }
- return smallFont;
- }
-
- @Override
- public FontUIResource getMessageFont() {
- if (systemFont == null) {
- systemFont =
- new FontUIResource(
- Font.getFont(
- "swing.plaf.metal.systemFont",
- new Font("Dialog", Font.PLAIN, 12)));
- }
- return systemFont;
- }
-
- @Override
- public FontUIResource getWindowTitleFont() {
- return getTitleFont();
- }
-
-
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/Fonts.java b/src/core/com/jgoodies/looks/Fonts.java
deleted file mode 100644
index 8d8a58b..0000000
--- a/src/core/com/jgoodies/looks/Fonts.java
+++ /dev/null
@@ -1,409 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import java.awt.Font;
-import java.awt.Toolkit;
-import java.util.Locale;
-
-import com.jgoodies.common.base.SystemUtils;
-
-
-/**
- * Provides static access to popular Windows fonts.
- * The sizes of the font constants are specified in
- * <em>typographic points</em>, approximately 1/72 of an inch.<p>
- *
- * TODO: Consider changing the visibility of the package private methods
- * to public. As an alternative we may provide a FontPolicy that can
- * emulate the font choice on Windows XP/2000 and Windows Vista for
- * different software resolutions (96dpi/120dpi) and desktop font size settings
- * (Normal/Large/Extra Large).
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.22 $
- *
- * @see FontSet
- * @see FontSets
- * @see FontPolicy
- * @see FontPolicies
- *
- * @since 2.0
- */
-public final class Fonts {
-
- /**
- * The name of the default dialog font on western Windows XP.
- */
- public static final String TAHOMA_NAME = "Tahoma";
-
- /**
- * The name of the default dialog font on western Windows Vista.
- */
- public static final String SEGOE_UI_NAME = "Segoe UI";
-
-
- // Physical Fonts *********************************************************
-
- /**
- * This is the default font on western XP with 96dpi and normal fonts.
- * Ascent=11, descent=3, height=14, dbuX=6, dbuY=12, 14dluY=21px.
- */
- public static final Font TAHOMA_11PT = new Font(TAHOMA_NAME, Font.PLAIN, 11);
-
- /**
- * Ascent=13, descent=3, height=16, dbuX=8, dbuY=13, 14dluY=22.75px.
- */
- public static final Font TAHOMA_13PT = new Font(TAHOMA_NAME, Font.PLAIN, 13);
-
- /**
- * Ascent=14, descent=3, height=17, dbuX=8, dbuY=14, 14dluY=24.5px.
- */
- public static final Font TAHOMA_14PT = new Font(TAHOMA_NAME, Font.PLAIN, 14);
-
- /**
- * This is Segoe UI 9pt, the default font on western Vista with 96dpi.
- * Ascent=13, descent=4, height=17, dbuX=7, dbuY=13, 13dluY=21.125px.
- */
- public static final Font SEGOE_UI_12PT = new Font(SEGOE_UI_NAME, Font.PLAIN, 12);
-
- /**
- * Ascent=14, descent=4, height=18, dbuX=8, dbuY=14, 13dluY=22.75px.
- */
- public static final Font SEGOE_UI_13PT = new Font(SEGOE_UI_NAME, Font.PLAIN, 13);
-
- /**
- * Ascent=16, descent=5, height=21, dbuX=9, dbuY=16, 13dluY=26px.
- */
- public static final Font SEGOE_UI_15PT = new Font(SEGOE_UI_NAME, Font.PLAIN, 15);
-
-
- // Default Windows Fonts **************************************************
-
- /**
- * The default icon font on western Windows XP with 96dpi
- * and the dialog font desktop setting "Normal".
- */
- public static final Font WINDOWS_XP_96DPI_NORMAL = TAHOMA_11PT;
-
- /**
- * The default GUI font on western Windows XP with 96dpi
- * and the dialog font desktop setting "Normal".
- */
- public static final Font WINDOWS_XP_96DPI_DEFAULT_GUI = TAHOMA_11PT;
-
- /**
- * The default icon font on western Windows XP with 96dpi
- * and the dialog font desktop setting "Large".
- */
- public static final Font WINDOWS_XP_96DPI_LARGE = TAHOMA_13PT;
-
- /**
- * The default icon font on western Windows XP with 120dpi
- * and the dialog font desktop setting "Normal".
- */
- public static final Font WINDOWS_XP_120DPI_NORMAL = TAHOMA_14PT;
-
- /**
- * The default GUI font on western Windows XP with 120dpi
- * and the dialog font desktop setting "Normal".
- */
- public static final Font WINDOWS_XP_120DPI_DEFAULT_GUI = TAHOMA_13PT;
-
- /**
- * The default icon font on western Windows Vista with 96dpi
- * and the dialog font desktop setting "Normal".
- */
- public static final Font WINDOWS_VISTA_96DPI_NORMAL = SEGOE_UI_12PT;
-
- /**
- * The default icon font on western Windows Vista with 96dpi
- * and the dialog font desktop setting "Large".
- */
- public static final Font WINDOWS_VISTA_96DPI_LARGE = SEGOE_UI_15PT;
-
- /**
- * The default icon font on western Windows Vista with 101dpi
- * and the dialog font desktop setting "Normal".<P>
- *
- * TODO: Check if this shall be removed or not.
- */
- static final Font WINDOWS_VISTA_101DPI_NORMAL = SEGOE_UI_13PT;
-
- /**
- * The default icon font on western Windows Vista with 120dpi
- * and the dialog font desktop setting "Normal".
- */
- public static final Font WINDOWS_VISTA_120DPI_NORMAL = SEGOE_UI_15PT;
-
-
- // Desktop Property Font Keys *********************************************
-
- /**
- * The desktop property key used to lookup the DEFAULTGUI font.
- * This font scales with the software resolution only
- * but works in western and non-western Windows environments.
- *
- * @see #getWindowsControlFont()
- */
- static final String WINDOWS_DEFAULT_GUI_FONT_KEY = "win.defaultGUI.font";
-
- /**
- * The desktop property key used to lookup Windows' icon font.
- * This font scales with the software resolution and
- * the desktop font size setting (Normal/Large/Extra Large).
- * However, in some non-western Windows environments
- * this font cannot display the locale's glyphs.<p>
- *
- * Implementation Note: Windows uses the icon font to label icons
- * in the Windows Explorer and other places. It seems to me that
- * this works in non-western environments due to font chaining.
- *
- * @see #getWindowsControlFont()
- */
- static final String WINDOWS_ICON_FONT_KEY = "win.icon.font";
-
-
- // Instance Creation ******************************************************
-
- private Fonts() {
- // Override default constructor; prevents instantation.
- }
-
-
- // Font Lookup ************************************************************
-
- static Font getDefaultGUIFontWesternModernWindowsNormal() {
- return SystemUtils.IS_LOW_RESOLUTION
- ? WINDOWS_XP_96DPI_DEFAULT_GUI
- : WINDOWS_XP_120DPI_DEFAULT_GUI;
- }
-
- static Font getDefaultIconFontWesternModernWindowsNormal() {
- return SystemUtils.IS_LOW_RESOLUTION
- ? WINDOWS_XP_96DPI_NORMAL
- : WINDOWS_XP_120DPI_NORMAL;
- }
-
- static Font getDefaultIconFontWesternWindowsVistaNormal() {
- return SystemUtils.IS_LOW_RESOLUTION
- ? WINDOWS_VISTA_96DPI_NORMAL
- : WINDOWS_VISTA_120DPI_NORMAL;
- }
-
-
- /**
- * Returns the Windows control font used by the JGoodies Looks version 1.x.
- * It is intended for visual backward compatibility only.
- * The font returned is the default GUI font that scales with the resolution
- * (96dpi, 120dpi, etc) but not with the desktop font size settings
- * (normal, large, extra large).<p>
- *
- * On Windows Vista, the font may be completely wrong.
- *
- * @return the Windows default GUI font that scales with the resolution,
- * but not the desktop font size setting
- *
- * @throws UnsupportedOperationException on non-Windows platforms
- */
- static Font getLooks1xWindowsControlFont() {
- if (!SystemUtils.IS_OS_WINDOWS) {
- throw new UnsupportedOperationException();
- }
-
- return getDesktopFont(WINDOWS_DEFAULT_GUI_FONT_KEY);
- }
-
-
- /**
- * Looks up and returns the Windows control font. Returns the Windows icon
- * title font unless it is inappropriate for the Windows version,
- * Java renderer, or locale.<p>
- *
- * The icon title font scales with the resolution (96dpi, 101dpi, 120dpi, etc)
- * and the desktop font size settings (normal, large, extra large).
- * Older versions may return a poor font. Also, since Java 1.4 and Java 5
- * render the Windows Vista icon font Segoe UI poorly,
- * we return the default GUI font in these environments.<p>
- *
- * The last check is, if the icon font can display text in the
- * default locale. Therefore we test if the locale's localized display name
- * can be displayed by the icon font. For example, Tahoma can display
- * "English", "Deutsch", but not the display name for "Chinese" in Chinese.
- *
- * @return the Windows control font
- *
- * @throws UnsupportedOperationException on non-Windows platforms
- */
- public static Font getWindowsControlFont() {
- if (!SystemUtils.IS_OS_WINDOWS) {
- throw new UnsupportedOperationException();
- }
-
- Font defaultGUIFont = getDefaultGUIFont();
- // Return the default GUI font on older Windows versions.
- if (LookUtils.IS_OS_WINDOWS_95
- || SystemUtils.IS_OS_WINDOWS_98
- || LookUtils.IS_OS_WINDOWS_NT
- || SystemUtils.IS_OS_WINDOWS_ME) {
- return defaultGUIFont;
- }
-
- Font iconFont = getDesktopFont(WINDOWS_ICON_FONT_KEY);
- return Boolean.TRUE.equals(canDisplayLocalizedText(iconFont, Locale.getDefault()))
- ? iconFont
- : defaultGUIFont;
- }
-
-
- /**
- * Looks up and returns the Windows defaultGUI font.
- * Works around a bug with Java 1.4.2_17, 1.5.0_15, and 1.6.0
- * on Vista, where the win.defaultGUI.font desktop property
- * returns {@code null}. In this case a logical "Dialog" font
- * is used as fallback.
- *
- * @return the Windows defaultGUI font, or a dialog font as fallback.
- */
- private static Font getDefaultGUIFont() {
- Font font = getDesktopFont(WINDOWS_DEFAULT_GUI_FONT_KEY);
- if (font != null) {
- return font;
- }
- return new Font("Dialog", Font.PLAIN, 12);
- }
-
-
- /**
- * Checks and answers whether the given font can display text
- * that is localized for the specified locale.
- * Returns {@code null} if we can't test it.<p>
- *
- * First checks, if the locale's display language is available
- * in localized form, for example "Deutsch" for the German locale.
- * If so, we check if the given font can display the localized
- * display language.<p>
- *
- * Otherwise we check some known combinations of fonts and locales
- * and return the associated results. For all other combinations,
- * {@code null} is returned to indicate that we don't know
- * whether the font can display text in the given locale.
- *
- * @param font the font to be tested
- * @param locale the locale to be used
- * @return {@code Boolean.TRUE} if the font can display the locale's text,
- * {@code Boolean.FALSE} if not,
- * {@code null} if we don't know
- *
- * @since 2.0.4
- */
- public static Boolean canDisplayLocalizedText(Font font, Locale locale) {
- if (localeHasLocalizedDisplayLanguage(locale)) {
- return Boolean.valueOf(canDisplayLocalizedDisplayLanguage(font, locale));
- }
- String fontName = font.getName();
- String language = locale.getLanguage();
- if ("Tahoma".equals(fontName)) {
- if ("hi".equals(language)) {
- return Boolean.FALSE;
- } else if ("ja".equals(language)) {
- return Boolean.FALSE;
- } else if ("ko".equals(language)) {
- return Boolean.FALSE;
- } else if ("zh".equals(language)) {
- return Boolean.FALSE;
- }
- }
- if ("Microsoft Sans Serif".equals(fontName)) {
- if ("ja".equals(language)) {
- return Boolean.FALSE;
- } else if ("ko".equals(language)) {
- return Boolean.FALSE;
- } else if ("zh".equals(language)) {
- return Boolean.FALSE;
- }
- }
- return null;
- }
-
-
- /**
- * Checks and answers if the given font can display the locale's
- * localized display language, for example "English" for English,
- * "Deutsch" for German, etc.
- * The test invokes {@code Font#canDisplayUpTo} on the localized
- * display language. In a Chinese locale this test
- * will check if the font can display Chinese glyphs.
- *
- * @param font the font to be tested
- * @param locale the locale to be used
- * @return true if the font can display the locale's localized display language,
- * false otherwise
- */
- private static boolean canDisplayLocalizedDisplayLanguage(Font font, Locale locale) {
- String testString = locale.getDisplayLanguage(locale);
- int index = font.canDisplayUpTo(testString);
- return index == -1;
- }
-
-
- /**
- * Checks and answers whether the locale's display language
- * is available in a localized form, for example "Deutsch" for the
- * German locale.
- *
- * @param locale the Locale to test
- * @return true if the display language is localized, false if not
- */
- private static boolean localeHasLocalizedDisplayLanguage(Locale locale) {
- if (locale.getLanguage().equals(Locale.ENGLISH.getLanguage())) {
- return true;
- }
- String englishDisplayLanguage = locale.getDisplayLanguage(Locale.ENGLISH);
- String localizedDisplayLanguage = locale.getDisplayLanguage(locale);
- return !englishDisplayLanguage.equals(localizedDisplayLanguage);
- }
-
-
- /**
- * Looks up and returns a font using the default toolkit's
- * desktop properties.
- *
- * @param fontName the name of the font to return
- * @return the font
- */
- private static Font getDesktopFont(String fontName) {
- Toolkit toolkit = Toolkit.getDefaultToolkit();
- return (Font) toolkit.getDesktopProperty(fontName);
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/HeaderStyle.java b/src/core/com/jgoodies/looks/HeaderStyle.java
deleted file mode 100644
index cae9960..0000000
--- a/src/core/com/jgoodies/looks/HeaderStyle.java
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import javax.swing.JComponent;
-import javax.swing.JMenuBar;
-import javax.swing.JToolBar;
-
-/**
- * Describes the header styles for JMenuBar and JToolBar.
- * Header styles are look-independent and can be shadowed by a look-dependent
- * {@code BorderStyle}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see BorderStyle
- */
-public final class HeaderStyle {
-
- public static final HeaderStyle SINGLE = new HeaderStyle("Single");
- public static final HeaderStyle BOTH = new HeaderStyle("Both");
-
- private final String name;
-
-
- private HeaderStyle(String name) {
- this.name = name;
- }
-
-
- /**
- * Looks up the client property for the {@code HeaderStyle}
- * from the JToolBar.
- *
- * @param menuBar the menu bar to inspect
- * @return the menu bar's header style
- */
- public static HeaderStyle from(JMenuBar menuBar) {
- return from0(menuBar);
- }
-
-
- /**
- * Looks up the client property for the {@code HeaderStyle}
- * from the JToolBar.
- *
- * @param toolBar the tool bar to inspect
- * @return the tool bar's header style
- */
- public static HeaderStyle from(JToolBar toolBar) {
- return from0(toolBar);
- }
-
-
- /**
- * Looks up the client property for the {@code HeaderStyle}
- * from the specified JComponent.
- *
- * @param c the component to inspect
- * @return the header style for the given component
- */
- private static HeaderStyle from0(JComponent c) {
- Object value = c.getClientProperty(Options.HEADER_STYLE_KEY);
- if (value instanceof HeaderStyle) {
- return (HeaderStyle) value;
- }
-
- if (value instanceof String) {
- return HeaderStyle.valueOf((String) value);
- }
-
- return null;
- }
-
-
- /**
- * Looks up and answers the {@code HeaderStyle} with the specified name.
- *
- * @param name the name of the HeaderStyle object to lookup
- * @return the associated HeaderStyle
- */
- private static HeaderStyle valueOf(String name) {
- if (name.equalsIgnoreCase(SINGLE.name)) {
- return SINGLE;
- } else if (name.equalsIgnoreCase(BOTH.name)) {
- return BOTH;
- } else {
- throw new IllegalArgumentException("Invalid HeaderStyle name "
- + name);
- }
- }
-
-
- @Override
- public String toString() {
- return name;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/LookUtils.java b/src/core/com/jgoodies/looks/LookUtils.java
deleted file mode 100644
index cd4f778..0000000
--- a/src/core/com/jgoodies/looks/LookUtils.java
+++ /dev/null
@@ -1,276 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.util.Collections;
-import java.util.List;
-
-import javax.swing.LookAndFeel;
-import javax.swing.UIManager;
-import javax.swing.UnsupportedLookAndFeelException;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-import com.jgoodies.looks.plastic.PlasticTheme;
-
-/**
- * Provides convenience behavior used by the JGoodies Looks.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.18 $
- */
-public final class LookUtils extends SystemUtils {
-
- // Basics System Properties **********************************************
-
- /**
- * True if this is Windows 98/ME/2000/Server 2003/XP/VISTA/Server 2008.
- */
- public static final boolean IS_OS_WINDOWS_MODERN =
- startsWith(OS_NAME, "Windows") && !startsWith(OS_VERSION, "4.0");
-
- /**
- * True if this is Windows 95.
- *
- * @since 2.0
- */
- public static final boolean IS_OS_WINDOWS_95 =
- startsWith(OS_NAME, "Windows 9") && startsWith(OS_VERSION, "4.0");
-
- /**
- * True if this is Windows NT.
- *
- * @since 2.0
- */
- public static final boolean IS_OS_WINDOWS_NT =
- startsWith(OS_NAME, "Windows NT");
-
- private static boolean loggingEnabled = true;
-
-
- private LookUtils() {
- // Override default constructor; prevents instantiation.
- }
-
-
- // Accessing System Configuration *****************************************
-
- /**
- * Tries to look up the System property for the given key.
- * In untrusted environments this may throw a SecurityException.
- * In this case we catch the exception and answer {@code null}.
- *
- * @param key the name of the system property
- * @return the system property's String value, or {@code null} if there's
- * no such value, or a SecurityException has been caught
- */
- public static String getSystemProperty(String key) {
- try {
- return System.getProperty(key);
- } catch (SecurityException e) {
- log("Can't read the System property " + key + ".");
- return null;
- }
- }
-
- /**
- * Tries to look up the System property for the given key.
- * In untrusted environments this may throw a SecurityException.
- * In this case, we catch the exception and answer the default value.
- *
- * @param key the name of the system property
- * @param defaultValue the default value if no property exists.
- * @return the system property's String value, or the defaultValue
- * if there's no such value, or a SecurityException has been caught
- */
- public static String getSystemProperty(String key, String defaultValue) {
- try {
- return System.getProperty(key, defaultValue);
- } catch (SecurityException e) {
- log("Can't read the System property " + key + ".");
- return defaultValue;
- }
- }
-
- /**
- * Checks if a boolean system property has been set for the given key,
- * and returns the associated Boolean, or {@code null} if no value
- * has been set. The test for the property ignores case.
- * If a Boolean value has been set, a message is logged
- * with the given prefix.
- *
- * @param key the key used to lookup the system property value
- * @param logMessage a prefix used when a message is logged
- * @return {@code Boolean.TRUE} if the system property has been set to
- * "true" (case ignored), {@code Boolean.FALSE} if it has been set to
- * "false", {@code null} otherwise
- */
- public static Boolean getBooleanSystemProperty(String key, String logMessage) {
- String value = getSystemProperty(key, "");
- Boolean result;
- if (value.equalsIgnoreCase("false")) {
- result = Boolean.FALSE;
- } else if (value.equalsIgnoreCase("true")) {
- result = Boolean.TRUE;
- } else {
- result = null;
- }
- if (result != null) {
- LookUtils.log(
- logMessage
- + " have been "
- + (result.booleanValue() ? "en" : "dis")
- + "abled in the system properties.");
- }
- return result;
- }
-
-
- /**
- * Checks and answers whether we have a true color system.
- *
- * @param c the component used to determine the toolkit
- * @return true if the component's toolkit has a pixel size >= 24
- */
- public static boolean isTrueColor(Component c) {
- return c.getToolkit().getColorModel().getPixelSize() >= 24;
- }
-
-
- /**
- * Checks and answers whether this toolkit provides native drop shadows
- * for popups such as the Mac OS X. Currently this is used to
- * determine if the Looks' popup drop shadow feature is active or not
- * - even if it's enabled.
- *
- * @return true if the toolkit provides native drop shadows
- *
- * @see Options#isPopupDropShadowActive()
- */
- public static boolean getToolkitUsesNativeDropShadows() {
- return IS_OS_MAC;
- }
-
-
- /**
- * Computes and returns a Color that is slightly brighter
- * than the specified Color.
- *
- * @param color the color used as basis for the brightened color
- * @return a slightly brighter color
- */
- public static Color getSlightlyBrighter(Color color) {
- return getSlightlyBrighter(color, 1.1f);
- }
-
- /**
- * Computes and returns a Color that is slightly brighter
- * than the specified Color.
- *
- * @param color the color used as basis for the brightened color
- * @param factor the factor used to compute the brightness
- * @return a slightly brighter color
- */
- public static Color getSlightlyBrighter(Color color, float factor) {
- float[] hsbValues = new float[3];
- Color.RGBtoHSB(
- color.getRed(),
- color.getGreen(),
- color.getBlue(),
- hsbValues);
- float hue = hsbValues[0];
- float saturation = hsbValues[1];
- float brightness = hsbValues[2];
- float newBrightness = Math.min(brightness * factor, 1.0f);
- return Color.getHSBColor(hue, saturation, newBrightness);
- }
-
-
- // Accessing Look, Theme, and Font Settings *****************************
-
- public static void setLookAndTheme(LookAndFeel laf, Object theme)
- throws UnsupportedLookAndFeelException {
- if (laf instanceof PlasticLookAndFeel
- && theme != null
- && theme instanceof PlasticTheme) {
- PlasticLookAndFeel.setPlasticTheme((PlasticTheme) theme);
- }
- UIManager.setLookAndFeel(laf);
- }
-
- public static Object getDefaultTheme(LookAndFeel laf) {
- return laf instanceof PlasticLookAndFeel
- ? PlasticLookAndFeel.createMyDefaultTheme()
- : null;
- }
-
- public static List getInstalledThemes(LookAndFeel laf) {
- return laf instanceof PlasticLookAndFeel
- ? PlasticLookAndFeel.getInstalledThemes()
- : Collections.EMPTY_LIST;
- }
-
-
- // Minimal logging ******************************************************
-
- /**
- * Enables or disables the Looks logging.
- *
- * @param enabled true to enable logging, false to disable it
- */
- public static void setLoggingEnabled(boolean enabled) {
- loggingEnabled = enabled;
- }
-
- /**
- * Prints a new line to the console if logging is enabled.
- */
- public static void log() {
- if (loggingEnabled) {
- System.out.println();
- }
- }
-
- /**
- * Prints the given message to the console if logging is enabled.
- *
- * @param message the message to print
- */
- public static void log(String message) {
- if (loggingEnabled) {
- System.out.println("JGoodies Looks: " + message);
- }
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/MicroLayout.java b/src/core/com/jgoodies/looks/MicroLayout.java
deleted file mode 100644
index df4d9b8..0000000
--- a/src/core/com/jgoodies/looks/MicroLayout.java
+++ /dev/null
@@ -1,177 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import java.awt.Insets;
-
-import javax.swing.plaf.InsetsUIResource;
-
-/**
- * Describes the insets and margins used by a Look&Feel or theme.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- *
- * @since 2.1
- */
-public final class MicroLayout {
-
- private final InsetsUIResource textInsets;
- private final InsetsUIResource wrappedTextInsets;
- private final InsetsUIResource comboBoxEditorInsets;
- private final Insets buttonBorderInsets;
- private final InsetsUIResource buttonMargin;
- private final InsetsUIResource commitButtonMargin;
- private final int comboBorderSize;
- private final int comboPopupBorderSize;
- private final InsetsUIResource checkBoxMargin;
- private final InsetsUIResource menuItemMargin;
- private final InsetsUIResource menuMargin;
- private final InsetsUIResource popupMenuSeparatorMargin;
-
-
- // Instance Creation ******************************************************
-
- public MicroLayout(
- InsetsUIResource textInsets,
- InsetsUIResource wrappedTextInsets,
- InsetsUIResource comboBoxEditorInsets,
- int comboBorderSize,
- int comboPopupBorderSize,
- Insets buttonBorderInsets,
- InsetsUIResource buttonMargin,
- InsetsUIResource commitButtonMargin,
- InsetsUIResource checkBoxMargin,
- InsetsUIResource menuItemMargin,
- InsetsUIResource menuMargin,
- InsetsUIResource popupMenuSeparatorMargin) {
- this.textInsets = textInsets;
- this.wrappedTextInsets = wrappedTextInsets;
- this.comboBoxEditorInsets = comboBoxEditorInsets;
- this.buttonBorderInsets = buttonBorderInsets;
- this.buttonMargin = buttonMargin;
- this.commitButtonMargin = commitButtonMargin;
- this.comboBorderSize = comboBorderSize;
- this.comboPopupBorderSize = comboPopupBorderSize;
- this.checkBoxMargin = checkBoxMargin;
- this.menuItemMargin = menuItemMargin;
- this.menuMargin = menuMargin;
- this.popupMenuSeparatorMargin = popupMenuSeparatorMargin;
- }
-
-
- // Getters ****************************************************************
-
- /**
- * Returns the insets used for button borders.
- *
- * @return the insets used for button borders.
- */
- public Insets getButtonBorderInsets() {
- return buttonBorderInsets;
- }
-
-
- /**
- * Returns the margin used for standard buttons. These insets describe
- * buttons that are arranged with other components in a row of a form.
- * The standard button <em>height</em> will often be the same for
- * text fields, combo boxes, and other components that are arranged in
- * a row.<p>
- *
- * Toolbar buttons may have a different height, as well as
- * commit buttons that are placed in a special command bar area,
- * for example OK, Cancel, Apply.
- *
- * @return the margin for standard buttons.
- *
- * @see #getCommitButtonMargin()
- */
- public InsetsUIResource getButtonMargin() {
- return buttonMargin;
- }
-
- /**
- * Returns the margin used for commit buttons in command areas.
- * Such command areas are often at the bottom or side of a dialog or pane;
- * frequently used labels are OK, Cancel, Apply, Yes, No, Retry.
- * The <em>height</em> of a commit button may differ from the height
- * used for buttons that are arranged in a row with other components
- * in a form.
- *
- * @return the margin for commit buttons in command areas.
- *
- * @see #getButtonMargin()
- */
- public InsetsUIResource getCommitButtonMargin() {
- return commitButtonMargin;
- }
-
- public int getComboBorderSize() {
- return comboBorderSize;
- }
-
- public int getComboPopupBorderSize() {
- return comboPopupBorderSize;
- }
-
- public InsetsUIResource getComboBoxEditorInsets() {
- return comboBoxEditorInsets;
- }
-
- public InsetsUIResource getCheckBoxMargin() {
- return checkBoxMargin;
- }
-
-
- public InsetsUIResource getMenuItemMargin() {
- return menuItemMargin;
- }
-
- public InsetsUIResource getMenuMargin() {
- return menuMargin;
- }
-
- public InsetsUIResource getPopupMenuSeparatorMargin() {
- return popupMenuSeparatorMargin;
- }
-
-
- public InsetsUIResource getTextInsets() {
- return textInsets;
- }
-
-
- public InsetsUIResource getWrappedTextInsets() {
- return wrappedTextInsets;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/MicroLayoutPolicies.java b/src/core/com/jgoodies/looks/MicroLayoutPolicies.java
deleted file mode 100644
index 9bc592d..0000000
--- a/src/core/com/jgoodies/looks/MicroLayoutPolicies.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import javax.swing.UIDefaults;
-
-import com.jgoodies.common.base.SystemUtils;
-
-
-/**
- * Provides predefined MicroLayoutPolicy implementations.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- *
- * @see MicroLayout
- * @see MicroLayouts
- * @see MicroLayoutPolicy
- *
- * @since 2.1
- */
-public final class MicroLayoutPolicies {
-
-
- private MicroLayoutPolicies() {
- // Override default constructor; prevents instantation.
- }
-
-
- // Getting a MicroLayoutPolicy ********************************************
-
- /**
- * Returns the default MicroLayoutPolicy for the Plastic L&fs.
- * Uses component insets that are similar to the Windows L&f
- * micro layout, making it easier to
- *
- * @return a Windows-like micro layout policy for the Plastic L&fs
- */
- public static MicroLayoutPolicy getDefaultPlasticPolicy() {
- return new DefaultPlasticPolicy();
- }
-
-
- /**
- * Returns the default MicroLayoutPolicy for the Windows L&f.
- * It aims to describe component insets that follow the native guidelines.
- *
- * @return the default micro layout policy for the Windows platform.
- */
- public static MicroLayoutPolicy getDefaultWindowsPolicy() {
- return new DefaultWindowsPolicy();
- }
-
-
- // MicroLayoutPolicy Implementations **************************************
-
- /**
- * Implements the default font lookup for the Plastic L&f family
- * when running in a Windows environment.
- */
- private static final class DefaultPlasticPolicy implements MicroLayoutPolicy {
-
- @Override
- public MicroLayout getMicroLayout(String lafName, UIDefaults table) {
- boolean isClassic = !SystemUtils.IS_LAF_WINDOWS_XP_ENABLED;
- boolean is6OrLater = SystemUtils.IS_OS_WINDOWS_6_OR_LATER;
- boolean isLowRes = SystemUtils.IS_LOW_RESOLUTION;
- boolean isPlasticXP = lafName.equals("JGoodies Plastic XP");
- if (isPlasticXP) {
- if (is6OrLater) {
- return isClassic
- ? MicroLayouts.createPlasticXPVistaClassicMicroLayout()
- : MicroLayouts.createPlasticXPVistaMicroLayout();
- }
- return isLowRes
- ? MicroLayouts.createPlasticXPLowResMicroLayout()
- : MicroLayouts.createPlasticXPHiResMicroLayout();
- }
- if (is6OrLater) {
- return isClassic
- ? MicroLayouts.createPlasticVistaClassicMicroLayout()
- : MicroLayouts.createPlasticVistaMicroLayout();
- }
- return isLowRes
- ? MicroLayouts.createPlasticLowResMicroLayout()
- : MicroLayouts.createPlasticHiResMicroLayout();
- }
-
- }
-
-
- /**
- * Implements the default font lookup on the Windows platform.
- */
- private static final class DefaultWindowsPolicy implements MicroLayoutPolicy {
-
- @Override
- public MicroLayout getMicroLayout(String lafName, UIDefaults table) {
- boolean isClassic = !SystemUtils.IS_LAF_WINDOWS_XP_ENABLED;
- boolean isVista = SystemUtils.IS_OS_WINDOWS_6_OR_LATER;
- boolean isLowRes = SystemUtils.IS_LOW_RESOLUTION;
- if (isClassic) {
- return isLowRes
- ? MicroLayouts.createWindowsClassicLowResMicroLayout()
- : MicroLayouts.createWindowsClassicHiResMicroLayout();
- } else if (isVista) {
- return isLowRes
- ? MicroLayouts.createWindowsVistaLowResMicroLayout()
- : MicroLayouts.createWindowsVistaHiResMicroLayout();
- } else {
- return isLowRes
- ? MicroLayouts.createWindowsXPLowResMicroLayout()
- : MicroLayouts.createWindowsXPHiResMicroLayout();
- }
- }
-
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/MicroLayoutPolicy.java b/src/core/com/jgoodies/looks/MicroLayoutPolicy.java
deleted file mode 100644
index 047f5b3..0000000
--- a/src/core/com/jgoodies/looks/MicroLayoutPolicy.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import javax.swing.UIDefaults;
-
-
-/**
- * Looks up and returns a MicroLayout.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.6 $
- *
- * @see MicroLayout
- * @see MicroLayoutPolicies
- *
- * @since 2.1
- */
-public interface MicroLayoutPolicy {
-
- /**
- * Looks up and returns insets, margins, and gaps that will be used
- * by a Look&Feel to set the component insets, margins and gaps.<p>
- *
- * This method is invoked during the L&F component initialization.
- * And the invoker hands over the UIDefaults object used to define
- * the component settings. Hence, the UIDefaults object may be used
- * to look up values as initialized by a super Look&Feel.
- * For example the JGoodies Windows L&F could use the
- * defaults set by the super L&F, the Sun Windows L&F.
- *
- * @param lafName the name of the Look&Feel that requests the fonts
- * @param table the UIDefaults table that can be used
- * to look up fonts of a super L&F
- *
- * @return a micro layout used as default for the components.
- */
- MicroLayout getMicroLayout(String lafName, UIDefaults table);
-
-}
diff --git a/src/core/com/jgoodies/looks/MicroLayouts.java b/src/core/com/jgoodies/looks/MicroLayouts.java
deleted file mode 100644
index b8c0381..0000000
--- a/src/core/com/jgoodies/looks/MicroLayouts.java
+++ /dev/null
@@ -1,338 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import java.awt.Insets;
-
-import javax.swing.plaf.InsetsUIResource;
-
-
-
-/**
- * A factory that vends predefined MicroLayout instances.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.6 $
- *
- * @see MicroLayout
- * @see MicroLayoutPolicy
- * @see MicroLayoutPolicies
- *
- * @since 2.1
- */
-public final class MicroLayouts {
-
- private MicroLayouts() {
- // Override default constructor; prevents instantation.
- }
-
-
- // Plastic and Plastic3D MicroLayouts *************************************
-
- private static final InsetsUIResource PLASTIC_MENU_ITEM_MARGIN =
- new InsetsUIResource(3, 0, 3, 0);
-
- private static final InsetsUIResource PLASTIC_MENU_MARGIN =
- new InsetsUIResource(2, 4, 2, 4);
-
- private static final InsetsUIResource PLASTIC_CHECK_BOX_MARGIN =
- new InsetsUIResource(2, 0, 2, 1);
-
-
- public static MicroLayout createPlasticLowResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 1, 2, 1), // text insets
- new InsetsUIResource(2, 2, 2, 1), // wrapped text insets
- new InsetsUIResource(1, 1, 2, 1), // combo box editor insets
- -1, // combo border size
- 1 , // combo popup border size
- new Insets(2, 3, 3, 3), // button border insets
- getButtonMargin(1, 1), // button margin
- getButtonMargin(1, 1), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createPlasticHiResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 1, 2, 1), // text insets
- new InsetsUIResource(2, 2, 2, 1), // wrapped text insets
- new InsetsUIResource(1, 1, 2, 1), // combo box editor insets
- -1, // combo border size
- 1, // combo popup border size
- new Insets(1, 3, 1, 3), // button border insets
- getButtonMargin(2, 3), // button margin
- getButtonMargin(2, 3), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createPlasticVistaMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 1, 1, 1), // text insets
- new InsetsUIResource(1, 2, 1, 1), // wrapped text insets
- new InsetsUIResource(1, 1, 1, 1), // combo box editor insets
- -1, // combo border size
- 1, // combo popup border size
- new Insets(2, 3, 3, 3), // button border insets
- getButtonMargin(0, 1), // button margin
- getButtonMargin(0, 1), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createPlasticVistaClassicMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 1, 2, 1), // text insets
- new InsetsUIResource(2, 2, 2, 1), // wrapped text insets
- new InsetsUIResource(1, 1, 2, 1), // combo box editor insets
- -1, // combo border size
- 1, // combo popup border size
- new Insets(3, 3, 3, 3), // button border insets
- getButtonMargin(0, 1), // button margin
- getButtonMargin(0, 1), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- // PlasticXP MicroLayouts *************************************************
-
- public static MicroLayout createPlasticXPLowResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(2, 2, 3, 2), // text insets
- new InsetsUIResource(2, 2, 3, 2), // wrapped text insets
- new InsetsUIResource(2, 2, 3, 2), // combo box editor insets
- -1, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 3, 2), // button border insets
- getButtonMargin(0, 1), // button margin
- getButtonMargin(0, 1), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createPlasticXPHiResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(2, 2, 3, 2), // text insets
- new InsetsUIResource(2, 2, 3, 2), // wrapped text insets
- new InsetsUIResource(2, 2, 3, 2), // combo box editor insets
- -1, // combo border size
- 1, // combo popup border size
- new Insets(2, 2, 2, 2), // button border insets
- getButtonMargin(1, 2), // button margin
- getButtonMargin(1, 2), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createPlasticXPVistaMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 2, 2, 2), // text insets
- new InsetsUIResource(1, 2, 2, 2), // wrapped text insets
- new InsetsUIResource(1, 2, 2, 2), // combo box editor insets
- -1, // combo border size
- 1, // combo popup border size
- new Insets(2, 2, 3, 2), // button border insets
- getButtonMargin(0, 0), // button margin
- getButtonMargin(0, 0), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createPlasticXPVistaClassicMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(2, 2, 3, 2), // text insets
- new InsetsUIResource(2, 2, 3, 2), // wrapped text insets
- new InsetsUIResource(2, 2, 3, 2), // combo box editor insets
- -1, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 4, 2), // button border insets
- getButtonMargin(0, 0), // button margin
- getButtonMargin(0, 0), // commit button margin
- PLASTIC_CHECK_BOX_MARGIN, // check box margin
- PLASTIC_MENU_ITEM_MARGIN, // menu item margin
- PLASTIC_MENU_MARGIN, // menu margin
- null // popup menu separator margin
- );
- }
-
-
- // Windows MicroLayouts ***************************************************
-
- private static final InsetsUIResource WINDOWS_CHECK_BOX_MARGIN =
- new InsetsUIResource(2, 0, 2, 0);
-
-
- public static MicroLayout createWindowsClassicLowResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 2, 2, 2), // text insets
- new InsetsUIResource(1, 2, 2, 2), // wrapped text insets
- new InsetsUIResource(1, 2, 2, 2), // combo box editor insets
- 2, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 4, 2), // button border insets
- getButtonMargin(1, 1), // button margin
- getButtonMargin(1, 1), // commit button margin
- WINDOWS_CHECK_BOX_MARGIN, // check box margin
- new InsetsUIResource(3, 0, 3, 0), // menu item margin
- new InsetsUIResource(2, 3, 2, 3), // menu margin
- new InsetsUIResource(2, 0, 3, 0) // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createWindowsClassicHiResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 2, 2, 2), // text insets
- new InsetsUIResource(1, 2, 2, 2), // wrapped text insets
- new InsetsUIResource(1, 2, 2, 2), // combo box editor insets
- 2, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 4, 2), // button border insets
- getButtonMargin(1, 1), // button margin
- getButtonMargin(1, 1), // commit button margin
- WINDOWS_CHECK_BOX_MARGIN, // check box margin
- new InsetsUIResource(2, 0, 2, 0), // menu item margin
- new InsetsUIResource(2, 4, 2, 4), // menu margin
- new InsetsUIResource(3, 0, 4, 0) // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createWindowsXPLowResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(2, 2, 3, 2), // text insets
- new InsetsUIResource(2, 2, 3, 2), // wrapped text insets
- new InsetsUIResource(2, 2, 3, 2), // combo box editor insets
- 1, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 4, 2), // button border insets
- getButtonMargin(2, 3), // button margin
- getButtonMargin(2, 3), // commit button margin
- WINDOWS_CHECK_BOX_MARGIN, // check box margin
- new InsetsUIResource(3, 0, 3, 0), // menu item margin
- new InsetsUIResource(2, 3, 2, 4), // menu margin
- new InsetsUIResource(2, 3, 3, 3) // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createWindowsXPHiResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(2, 2, 3, 2), // text insets
- new InsetsUIResource(2, 2, 3, 2), // wrapped text insets
- new InsetsUIResource(2, 2, 3, 2), // combo box editor insets
- 1, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 4, 2), // button border insets
- getButtonMargin(2, 3), // button margin
- getButtonMargin(2, 3), // commit button margin
- WINDOWS_CHECK_BOX_MARGIN, // check box margin
- new InsetsUIResource(2, 0, 2, 0), // menu item margin
- new InsetsUIResource(2, 5, 2, 6), // menu margin
- new InsetsUIResource(3, 3, 4, 3) // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createWindowsVistaLowResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 2, 2, 2), // text insets
- new InsetsUIResource(1, 2, 2, 2), // wrapped text insets
- new InsetsUIResource(1, 2, 2, 2), // combo box editor insets
- 1, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 4, 2), // button border insets
- getButtonMargin(1, 2), // button margin
- getButtonMargin(1, 2), // commit button margin
- WINDOWS_CHECK_BOX_MARGIN, // check box margin
- new InsetsUIResource(3, 0, 3, 0), // menu item margin
- new InsetsUIResource(2, 3, 2, 4), // menu margin
- new InsetsUIResource(2, 3, 3, 3) // popup menu separator margin
- );
- }
-
-
- public static MicroLayout createWindowsVistaHiResMicroLayout() {
- return new MicroLayout(
- new InsetsUIResource(1, 2, 2, 2), // text insets
- new InsetsUIResource(1, 2, 2, 2), // wrapped text insets
- new InsetsUIResource(1, 2, 2, 2), // combo box editor insets
- 1, // combo border size
- 1, // combo popup border size
- new Insets(3, 2, 4, 2), // button border insets
- getButtonMargin(1, 2), // button margin
- getButtonMargin(1, 2), // commit button margin
- WINDOWS_CHECK_BOX_MARGIN, // check box margin
- new InsetsUIResource(2, 0, 2, 0), // menu item margin
- new InsetsUIResource(2, 5, 2, 6), // menu margin
- new InsetsUIResource(3, 3, 4, 3) // popup menu separator margin
- );
- }
-
-
- // Helper Code ************************************************************
-
- private static InsetsUIResource getButtonMargin(int top, int bottom) {
- int pad = Options.getUseNarrowButtons() ? 4 : 14;
- return new InsetsUIResource(top, pad, bottom, pad);
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/Options.java b/src/core/com/jgoodies/looks/Options.java
deleted file mode 100644
index 41f1599..0000000
--- a/src/core/com/jgoodies/looks/Options.java
+++ /dev/null
@@ -1,955 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks;
-
-import java.awt.Dimension;
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.swing.JTextField;
-import javax.swing.UIManager;
-import javax.swing.text.JTextComponent;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.common.ShadowPopup;
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-import com.jgoodies.looks.windows.WindowsLookAndFeel;
-
-/**
- * Provides access to optional features of the JGoodies L&Fs
- * via a key to the system properties, via a key for the {@code UIDefaults}
- * table, via a method, or all of them.<p>
- *
- * API users can use this class' constants or their values to configure
- * the JGoodies L&amP;f. Using the constants requires the Looks library
- * classes in the class path of the using application/applet, where using
- * the String values doesn't require having this class in the class path.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.25 $
- */
-public final class Options {
-
- // Look & Feel Names ******************************************************
-
- /**
- * The class name of the JGoodies Plastic L&f.
- */
- public static final String PLASTIC_NAME =
- "com.jgoodies.looks.plastic.PlasticLookAndFeel";
-
- /**
- * The class name of the JGoodies Plastic3D L&f.
- */
- public static final String PLASTIC3D_NAME =
- "com.jgoodies.looks.plastic.Plastic3DLookAndFeel";
-
- /**
- * The class name of the JGoodies PlasticXP L&f.
- */
- public static final String PLASTICXP_NAME =
- "com.jgoodies.looks.plastic.PlasticXPLookAndFeel";
-
- /**
- * The class name of the JGoodies Windows L&f.
- */
- public static final String JGOODIES_WINDOWS_NAME =
- "com.jgoodies.looks.windows.WindowsLookAndFeel";
-
- /**
- * The class name of the default JGoodies L&f, PlasticXP.
- */
- public static final String DEFAULT_LOOK_NAME =
- PLASTICXP_NAME;
-
- /**
- * Holds a Map that enables the look&feel replacement
- * mechanism to replace one look by another.
- * Maps the original class names to their replacement class names.
- *
- * @see #getReplacementClassNameFor(String)
- * @see #putLookAndFeelReplacement(String, String)
- * @see #removeLookAndFeelReplacement(String)
- */
- private static final Map<String, String> LAF_REPLACEMENTS;
- static {
- LAF_REPLACEMENTS = new HashMap<String, String>();
- initializeDefaultReplacements();
- }
-
-
- // Keys for Overriding Font Settings **************************************
-
- /**
- * A key for setting a custom FontPolicy for the Plastic L&fs.
- * Used for both the system properties and the UIDefaults table.
- *
- * @see PlasticLookAndFeel#getFontPolicy()
- * @see PlasticLookAndFeel#setFontPolicy(FontPolicy)
- */
- public static final String PLASTIC_FONT_POLICY_KEY =
- "Plastic.fontPolicy";
-
- /**
- * A key for setting the default control font in Plastic L&fs.
- * Used for both the system properties and the UIDefaults table.
- *
- * @see FontPolicies#customSettingsPolicy(FontPolicy)
- */
- public static final String PLASTIC_CONTROL_FONT_KEY =
- "Plastic.controlFont";
-
- /**
- * A key for setting the default menu font in Plastic L&fs.
- * Used for both the system properties and the UIDefaults table.
- *
- * @see FontPolicies#customSettingsPolicy(FontPolicy)
- */
- public static final String PLASTIC_MENU_FONT_KEY =
- "Plastic.menuFont";
-
- /**
- * A key for setting a custom FontPolicy for the Windows L&fs.
- * Used for both the system properties and the UIDefaults table.
- *
- * @see WindowsLookAndFeel#getFontPolicy()
- * @see WindowsLookAndFeel#setFontPolicy(FontPolicy)
- */
- public static final String WINDOWS_FONT_POLICY_KEY =
- "Windows.fontPolicy";
-
- /**
- * A key for setting the default control font in the Windows L&f.
- * Used for both the system properties and the UIDefaults table.
- *
- * @see FontPolicies#customSettingsPolicy(FontPolicy)
- */
- public static final String WINDOWS_CONTROL_FONT_KEY =
- "Windows.controlFont";
-
- /**
- * A key for setting the default menu font in the Windows L&f.
- * Used for both the system properties and the UIDefaults table.
- *
- * @see FontPolicies#customSettingsPolicy(FontPolicy)
- */
- public static final String WINDOWS_MENU_FONT_KEY =
- "Windows.menuFont";
-
- /**
- * A convenience constant for the standard Swing system property key
- * that configures the use of system fonts.
- *
- * @see #getUseSystemFonts()
- * @see #setUseSystemFonts(boolean)
- */
- public static final String USE_SYSTEM_FONTS_KEY =
- "swing.useSystemFontSettings";
-
- /**
- * A convenience constant for the standard Swing UIDefaults key
- * that configures the use of system fonts.
- *
- * @see #getUseSystemFonts()
- * @see #setUseSystemFonts(boolean)
- */
- public static final String USE_SYSTEM_FONTS_APP_KEY =
- "Application.useSystemFontSettings";
-
-
- // Keys for Micro Layout Policies *****************************************
-
- /**
- * A UIManager key for setting a custom MicroLayoutPolicy
- * for the Plastic L&fs.
- *
- * @see PlasticLookAndFeel#getMicroLayoutPolicy()
- * @see PlasticLookAndFeel#setMicroLayoutPolicy(MicroLayout)
- */
- public static final String PLASTIC_MICRO_LAYOUT_POLICY_KEY =
- "Plastic.MicroLayoutPolicy";
-
-
- /**
- * A UIManager key for setting a custom MicroLayoutPolicy
- * for the Windows L&f.
- *
- * @see WindowsLookAndFeel#getMicroLayoutPolicy()
- * @see WindowsLookAndFeel#setMicroLayoutPolicy(MicroLayout)
- */
- public static final String WINDOWS_MICRO_LAYOUT_POLICY_KEY =
- "Windows.MicroLayoutPolicy";
-
-
- // Optional Global User Properties ****************************************
-
- public static final String DEFAULT_ICON_SIZE_KEY =
- "jgoodies.defaultIconSize";
-
- public static final String USE_NARROW_BUTTONS_KEY =
- "jgoodies.useNarrowButtons";
-
- public static final String TAB_ICONS_ENABLED_KEY =
- "jgoodies.tabIconsEnabled";
-
- /**
- * A UIDefaults key for the popup drop shadow enablement.
- *
- * @see #isPopupDropShadowEnabled()
- * @see #setPopupDropShadowEnabled(boolean)
- */
- public static final String POPUP_DROP_SHADOW_ENABLED_KEY =
- "jgoodies.popupDropShadowEnabled";
-
-
- /**
- * A UIDefaults key for enabling/disabling the new high-resolution
- * gray filter globally. This setting can be overridden per component.
- *
- * @see #setHiResGrayFilterEnabled(boolean)
- * @see #HI_RES_DISABLED_ICON_CLIENT_KEY
- *
- * @since 2.1
- */
- public static final String HI_RES_GRAY_FILTER_ENABLED_KEY =
- "HiResGrayFilterEnabled";
-
-
- /**
- * A UIDefaults key for the global default whether text fields
- * shall select all text on focus gain. This can be overridden per field.
- *
- * @see #setSelectOnFocusGainEnabled(boolean)
- *
- * @since 2.2
- */
- public static final String SELECT_ON_FOCUS_GAIN_KEY =
- "JGoodies.selectAllOnFocusGain";
-
-
- // Optional Client Properties *********************************************
-
- /**
- * A JScrollPane client property key for a hint
- * that the scroll pane border should be etched.
- */
- public static final String IS_ETCHED_KEY = "jgoodies.isEtched";
-
- /**
- * A client property key for JMenuBar and JToolBar style hints.
- * Available styles are: {@code HeaderStyle.Single} and
- * {@code HeaderStyle.Both}.
- *
- * @see HeaderStyle
- * @see BorderStyle
- */
- public static final String HEADER_STYLE_KEY = "jgoodies.headerStyle";
-
- /**
- * A JMenu client property key for a hint
- * that the menu items in the menu have no icons.
- */
- public static final String NO_ICONS_KEY = "jgoodies.noIcons";
-
- /**
- * A JPopupMenu client property key for a hint that the border
- * shall have no extra margin. This is useful if the popup menu
- * contains only a single component, for example a scrollpane.
- */
- public static final String NO_MARGIN_KEY = "JPopupMenu.noMargin";
-
- /**
- * A JTree client property key for a tree line style hint.
- *
- * @see #TREE_LINE_STYLE_ANGLED_VALUE
- * @see #TREE_LINE_STYLE_NONE_VALUE
- */
- public static final String TREE_LINE_STYLE_KEY =
- "JTree.lineStyle";
-
- /**
- * A JTree client property value that indicates that lines shall be drawn.
- *
- * @see #TREE_LINE_STYLE_KEY
- */
- public static final String TREE_LINE_STYLE_ANGLED_VALUE =
- "Angled";
-
- /**
- * A JTree client property value that indicates that lines shall be hidden.
- *
- * @see #TREE_LINE_STYLE_KEY
- */
- public static final String TREE_LINE_STYLE_NONE_VALUE =
- "None";
-
- /**
- * A JTabbedPane client property key that indicates
- * that no content border shall be painted.
- * Supported by the JGoodies Windows L&f and the
- * JGoodies Plastic look&feel family.
- * This effect will be achieved also if the EMBEDDED property is true.
- */
- public static final String NO_CONTENT_BORDER_KEY =
- "jgoodies.noContentBorder";
-
- /**
- * A JTabbedPane client property key that indicates
- * that tabs are painted with a special embedded appearance.
- * Supported by the JGoodies Windows L&f and the
- * JGoodies Plastic look&feel family.
- * As a side effect of the embedded appearance,
- * supporting L&fs won't paint the content border.
- */
- public static final String EMBEDDED_TABS_KEY =
- "jgoodies.embeddedTabs";
-
- /**
- * A JComboBox client property key for the combo's
- * popup menu prototype display value. If this key is set,
- * the value will be used to compute the combo popup width.
- * This optional feature is supported by the JGoodies Windows L&f
- * as well as the JGoodies Plastic L&fs.
- */
- public static final String COMBO_POPUP_PROTOTYPE_DISPLAY_VALUE_KEY =
- "ComboBox.popupPrototypeDisplayValue";
-
-
- /**
- * A client property key for combo box renderer components.
- * The Boolean value indicates whether the component's border
- * can be temporarily removed when painting the current value or not.<p>
- *
- * This is useful for custom renderers used with Windows combo boxes
- * as described by {@code WindowsComboBoxUI#paintCurrentValue}}.
- *
- * @since 2.1
- */
- public static final String COMBO_RENDERER_IS_BORDER_REMOVABLE =
- "isBorderRemovable";
-
-
- /**
- * A client property key for components with a disabled icon
- * such as buttons, labels, and tabbed panes. Specifies whether
- * the new high resolution gray filter shall be used to compute
- * a disabled icon - if none is available.
- *
- * @see #isHiResGrayFilterEnabled()
- * @see #setHiResGrayFilterEnabled(boolean)
- * @see #HI_RES_GRAY_FILTER_ENABLED_KEY
- *
- * @since 2.1
- */
- public static final String HI_RES_DISABLED_ICON_CLIENT_KEY =
- "generateHiResDisabledIcon";
-
-
- /**
- * A JTextField client property key that specifies whether all text shall
- * be selected on focus gain. Overrides the global default.<p>
- *
- * This feature can be set using
- * {@link #setSelectOnFocusGainEnabled(JTextField, Boolean)}.
- * If you want to avoid to link application code to the JGoodies Looks
- * library, you can set the client property directly using:
- * <pre>
- * aTextField.putClientProperty("JGoodies.selectAllOnFocusGain", Boolean.TRUE);
- * </pre>
- *
- * @see #setSelectOnFocusGainEnabled(boolean)
- *
- * @since 2.2
- */
- public static final String SELECT_ON_FOCUS_GAIN_CLIENT_KEY =
- "JGoodies.selectAllOnFocusGain";
-
-
- /**
- * A JTextField client property key that specifies the direction
- * how text shall be selected on focus gain - if at all:
- * from start to end vs. end to start.
- *
- * If the value is set to Boolean.TRUE, the text is selected
- * from end to start, otherwise it is selected from start to end.<p>
- *
- * You can set the client property using:
- * <pre>
- * aTextField.putClientProperty("JGoodies.invertSelection", Boolean.TRUE);
- * </pre>
- *
- * @since 2.2
- */
- public static final String INVERT_SELECTION_CLIENT_KEY =
- "JGoodies.invertSelection";
-
-
- /**
- * A JTextField client property key that specifies whether the caret
- * shall be positioned at the start on focus lost.
- * If the value is set to Boolean.TRUE, the caret is set to position 0
- * on focus lost, otherwise the caret remains unchanged.<p>
- *
- * You can set the client property using:
- * <pre>
- * aTextField.putClientProperty("JGoodies.setCaretToStartOnFocusLost", Boolean.TRUE);
- * </pre>
- *
- * @since 2.2
- */
- public static final String SET_CARET_TO_START_ON_FOCUS_LOST_CLIENT_KEY =
- "JGoodies.setCaretToStartOnFocusLost";
-
-
- // System Settings ********************************************************
-
- /**
- * Holds the Boolean system property value for the use of system fonts,
- * or null, if it has not been set. If this property has been
- * set, we log a message about the choosen value.
- *
- * @see #getUseSystemFonts()
- */
- private static final Boolean USE_SYSTEM_FONTS_SYSTEM_VALUE =
- LookUtils.getBooleanSystemProperty(
- USE_SYSTEM_FONTS_KEY, "Use system fonts");
-
-
- /**
- * Holds the Boolean system property value for the use of narrow buttons
- * or null, if it has not been set. If this property has been
- * set, we log a message about the choosen value.
- *
- * @see #getUseNarrowButtons()
- */
- private static final Boolean USE_NARROW_BUTTONS_SYSTEM_VALUE =
- LookUtils.getBooleanSystemProperty(
- USE_NARROW_BUTTONS_KEY, "Use narrow buttons");
-
-
- /**
- * Holds the Boolean system property value for the tab icon enablement,
- * or null, if it has not been set. If this property has been
- * set, we log a message about the choosen value.
- *
- * @see #isTabIconsEnabled()
- */
- private static final Boolean TAB_ICONS_ENABLED_SYSTEM_VALUE =
- LookUtils.getBooleanSystemProperty(
- TAB_ICONS_ENABLED_KEY, "Icons in tabbed panes");
-
-
- /**
- * Holds the Boolean system property value for the popup drop shadow
- * enablement, or null, if it has not been set. If this property has been
- * set, we log a message about the choosen value.<p>
- *
- * This property just set the feature's enablement, not its actual
- * activation. For example, drop shadows are always inactive on
- * the Mac OS X, because this platform already provides shadows.
- * The activation is requested in {@code #isPopupDropShadowActive}.
- *
- * @see #isPopupDropShadowEnabled()
- * @see #isPopupDropShadowActive()
- */
- private static final Boolean POPUP_DROP_SHADOW_ENABLED_SYSTEM_VALUE =
- LookUtils.getBooleanSystemProperty(
- POPUP_DROP_SHADOW_ENABLED_KEY, "Popup drop shadows");
-
-
- // Private ****************************************************************
-
- private static final Dimension DEFAULT_ICON_SIZE =
- new Dimension(20, 20);
-
- private Options() {
- // Override default constructor; prevents instantiation.
- }
-
-
- // Accessing Options ******************************************************
-
- /**
- * Returns whether native system fonts shall be used, {@code true}
- * by default unless disabled in the system properties or UIManager.
- *
- * @return true unless disabled in the system properties or UIManager
- *
- * @see #setUseSystemFonts(boolean)
- * @see #USE_SYSTEM_FONTS_KEY
- * @see #USE_SYSTEM_FONTS_APP_KEY
- */
- public static boolean getUseSystemFonts() {
- return USE_SYSTEM_FONTS_SYSTEM_VALUE != null
- ? USE_SYSTEM_FONTS_SYSTEM_VALUE.booleanValue()
- : !Boolean.FALSE.equals(UIManager.get(USE_SYSTEM_FONTS_APP_KEY));
- }
-
- /**
- * Sets a value in the UIManager to indicate,
- * that a look&feel may use the native system fonts.
- *
- * @param useSystemFonts true to enable system fonts in the UIManager
- *
- * @see #getUseSystemFonts()
- * @see #USE_SYSTEM_FONTS_KEY
- * @see #USE_SYSTEM_FONTS_APP_KEY
- */
- public static void setUseSystemFonts(boolean useSystemFonts) {
- UIManager.put(USE_SYSTEM_FONTS_APP_KEY, Boolean.valueOf(useSystemFonts));
- }
-
- /**
- * Returns the default icon size that is used in menus, menu items and
- * toolbars. Menu items that have no icon set are aligned using the default
- * icon dimensions.
- *
- * @return the dimension of the default icon
- *
- * @see #setDefaultIconSize(Dimension)
- */
- public static Dimension getDefaultIconSize() {
- Dimension size = UIManager.getDimension(DEFAULT_ICON_SIZE_KEY);
- return size == null ? DEFAULT_ICON_SIZE : size;
- }
-
- /**
- * Sets the default icon size.
- *
- * @param defaultIconSize the default icon size to set
- *
- * @see #getDefaultIconSize()
- */
- public static void setDefaultIconSize(Dimension defaultIconSize) {
- UIManager.put(DEFAULT_ICON_SIZE_KEY, defaultIconSize);
- }
-
- /**
- * Checks and answers if we shall use narrow button margins of 4 pixels.
- * As of the Looks version 1.4 the default value is {@code true}
- * (narrow) for the JGoodies Windows L&F and the JGoodies Plastic
- * L&F family. The native Windows L&F uses narrow margins too.
- * The default can be disabled in the system properties or UIManager.<p>
- *
- * <strong>Note:</strong> Using narrow button margins can potentially cause
- * compatibility issues, if you don't take care that command buttons with
- * short labels (OK) get a reasonable minimum width. Therefore you can
- * get back to wide button margins using {@code #setUseNarrowButtons}.
- * Sun's L&F implementations use a wider button margin of 14 pixels.<p>
- *
- * Narrow button margins make it easier to give buttons in a button bar
- * the same width, even if some button labels are long. And narrow margins
- * are useful for embedded command buttons that just have an icon,
- * or an ellipsis (…). Many style guides recommend to use a minimum
- * button width in command button bars, for example 50 dialog units on
- * Windows. Such a minimum width makes it easier to click a button,
- * just because the button area has a reasonable minimum size.
- * To ensure a reasonable button minimum width, you may configure a
- * LayoutManager, use a special panel for command button bars, or
- * a factory that vends command button bars.<p>
- *
- * The JGoodies FormLayout can layout button bars that comply with both the
- * MS Windows Layout Guidelines and the Mac Aqua Human Interface Guidelines.
- * The JGoodies Forms contains a ButtonBarBuilder to build command button
- * bars, and a ButtonBarFactory that vends frequently used button bars.
- *
- * @return {@code true} (default) if all buttons shall use narrow
- * margins, {@code false} for wider margins
- *
- * @see #setUseNarrowButtons(boolean)
- * @see #USE_NARROW_BUTTONS_KEY
- */
- public static boolean getUseNarrowButtons() {
- return USE_NARROW_BUTTONS_SYSTEM_VALUE != null
- ? USE_NARROW_BUTTONS_SYSTEM_VALUE.booleanValue()
- : !Boolean.FALSE.equals(UIManager.get(USE_NARROW_BUTTONS_KEY));
- }
-
- /**
- * Globally sets the use narrow or standard button margins.<p>
- *
- * In previous versions of the JGoodies Looks this setting was supported
- * also for individual buttons - primarily to offer visual backward
- * compatibility with Sun L&Fs.
- *
- * @param b true to use narrow button margins globally
- *
- * @see #getUseNarrowButtons()
- * @see #USE_NARROW_BUTTONS_KEY
- */
- public static void setUseNarrowButtons(boolean b) {
- UIManager.put(USE_NARROW_BUTTONS_KEY, Boolean.valueOf(b));
- }
-
- /**
- * Checks and answers if we shall use icons in JTabbedPanes.
- * By default, tab icons are enabled. If the user has set a system property,
- * we log a message about the choosen style.
- *
- * @return true if icons in tabbed panes are enabled, false if disabled
- * @see #setTabIconsEnabled(boolean)
- */
- public static boolean isTabIconsEnabled() {
- return TAB_ICONS_ENABLED_SYSTEM_VALUE != null
- ? TAB_ICONS_ENABLED_SYSTEM_VALUE.booleanValue()
- : !Boolean.FALSE.equals(UIManager.get(TAB_ICONS_ENABLED_KEY));
- }
-
- /**
- * Enables or disables the use of icons in JTabbedPanes.
- *
- * @param b true to enable icons in tabbed panes, false to disable them
- *
- * @see #isTabIconsEnabled()
- */
- public static void setTabIconsEnabled(boolean b) {
- UIManager.put(TAB_ICONS_ENABLED_KEY, Boolean.valueOf(b));
- }
-
-
- /**
- * Checks and answers whether popup drop shadows are active.
- * This feature shall be inactive with toolkits that use
- * native drop shadows, such as Aqua on the Mac OS X.
- * It is also inactive if the ShadowPopup cannot snapshot
- * the desktop background (due to security and AWT exceptions).
- * Otherwise the feature's enablement state is returned.<p>
- *
- * Currently only the Mac OS X is detected as platform where
- * the toolkit uses native drop shadows.
- *
- * @return true if drop shadows are active, false if inactive
- *
- * @see #isPopupDropShadowEnabled()
- * @see #setPopupDropShadowEnabled(boolean)
- */
- public static boolean isPopupDropShadowActive() {
- return !LookUtils.getToolkitUsesNativeDropShadows()
- && ShadowPopup.canSnapshot()
- && isPopupDropShadowEnabled();
- }
-
- /**
- * Checks and answers whether the optional drop shadows for
- * PopupMenus are enabled or disabled.
- *
- * @return true if drop shadows are enabled, false if disabled
- *
- * @see #isPopupDropShadowActive()
- * @see #setPopupDropShadowEnabled(boolean)
- * @see #POPUP_DROP_SHADOW_ENABLED_KEY
- */
- public static boolean isPopupDropShadowEnabled() {
- if (POPUP_DROP_SHADOW_ENABLED_SYSTEM_VALUE != null) {
- return POPUP_DROP_SHADOW_ENABLED_SYSTEM_VALUE.booleanValue();
- }
-
- Object value = UIManager.get(POPUP_DROP_SHADOW_ENABLED_KEY);
- return value == null
- ? isPopupDropShadowEnabledDefault()
- : Boolean.TRUE.equals(value);
- }
-
- /**
- * Enables or disables drop shadows in PopupMenus.
- * Note that drop shadows are always inactive on platforms
- * that provide native drop shadows such as the Mac OS X.<p>
- *
- * It is recommended to enable this feature only on platforms that
- * accelerate translucency and snapshots with the hardware.
- *
- * @param b true to enable drop shadows, false to disable them
- *
- * @see #isPopupDropShadowActive()
- * @see #isPopupDropShadowEnabled()
- */
- public static void setPopupDropShadowEnabled(boolean b) {
- UIManager.put(POPUP_DROP_SHADOW_ENABLED_KEY, Boolean.valueOf(b));
- }
-
- /**
- * Checks and answers whether popup drop shadows are enabled
- * or disabled by default. True for modern Windows platforms:
- * Windows 98/ME/2000/XP.<p>
- *
- * TODO: Consider enabling popup drop shadows on Linux by default.<p>
- *
- * TODO: Consider moving the default to the individual L&F's
- * component defaults initialization. For example Plastic and Plastic3D
- * may disable this feature by default, while PlasticXP enables it
- * by default.
- *
- * @return false
- */
- private static boolean isPopupDropShadowEnabledDefault() {
- return LookUtils.IS_OS_WINDOWS_MODERN;
- }
-
-
- /**
- * Checks and answers whether the new high-resolution gray filter
- * is enabled or disabled. It is enabled by default.
- *
- * @return true if the high-resolution gray filter is enabled, false if disabled
- *
- * @see #setHiResGrayFilterEnabled(boolean)
- * @see #HI_RES_GRAY_FILTER_ENABLED_KEY
- * @see #HI_RES_DISABLED_ICON_CLIENT_KEY
- *
- * @since 2.1
- */
- public static boolean isHiResGrayFilterEnabled() {
- return !Boolean.FALSE.equals(UIManager.get(HI_RES_GRAY_FILTER_ENABLED_KEY));
- }
-
- /**
- * Enables or disables the new high-resolution gray filter globally.
- * This gray filter can be disabled for individual components using the
- * client property key {@code HI_RES_DISABLED_ICON_CLIENT_KEY}.
- *
- * @param b true to enable the high-resolution gray filter,
- * false to disable them
- *
- * @see #isHiResGrayFilterEnabled()
- *
- * @since 2.1
- */
- public static void setHiResGrayFilterEnabled(boolean b) {
- UIManager.put(HI_RES_GRAY_FILTER_ENABLED_KEY, Boolean.valueOf(b));
- }
-
-
- /**
- * Checks and answers whether the global default for text fields
- * is to select all text on focus gain. The global default can be
- * overridden per component. This feature is turned on by default.<p>
- *
- * For all full description and background
- * see {@link #setSelectOnFocusGainEnabled(boolean)}.
- *
- * @return true if the select all feature is enabled globally,
- * false if disabled
- *
- * @see #SELECT_ON_FOCUS_GAIN_KEY
- * @see #SELECT_ON_FOCUS_GAIN_CLIENT_KEY
- *
- * @since 2.2
- */
- public static boolean isSelectOnFocusGainEnabled() {
- return !Boolean.FALSE.equals(UIManager.get(SELECT_ON_FOCUS_GAIN_KEY));
- }
-
- /**
- * Enables or disables the select on focus gain feature globally.
- * This feature can be disabled for individual components using the
- * client property key {@code SELECT_ALL_ON_FOCUS_GAIN_CLIENT_KEY}.
- * It is enabled by default.<p>
- *
- * <b>Background:</b> If users are more likely going to reenter the entire
- * value in a text field, all text shall be selected on focus gain.
- * If users are more likely to edit a text, the caret shall be placed
- * at the end of the text.
- *
- * @param b true to enable the select all on focus gain,
- * false to disable this feature globally
- *
- * @see #isSelectOnFocusGainEnabled()
- *
- * @since 2.2
- */
- public static void setSelectOnFocusGainEnabled(boolean b) {
- UIManager.put(SELECT_ON_FOCUS_GAIN_KEY, Boolean.valueOf(b));
- }
-
-
- /**
- * Checks and answers whether the select all on focus gain feature
- * is active for the given field. Involves both the indiviual setting
- * and the global default.
- *
- * @param c the component to check
- * @return true if the feature is enabled for {@code c} or globally,
- * false if the feature is disabled for {@code c} or globally
- * disabled.
- *
- * @since 2.2
- */
- public static boolean isSelectOnFocusGainActive(JTextComponent c) {
- Boolean enabled = getSelectOnFocusGainEnabled(c);
- if (enabled != null) {
- return enabled.booleanValue();
- }
- return isSelectOnFocusGainEnabled();
- }
-
-
- /**
- * Returns component's individual setting for the select on focus gain
- * feature.
- *
- * @param c the component to check
- * @return Boolean.TRUE if enabled, Boolean.FALSE if disabled,
- * null if the global default is used
- *
- * @see #isSelectOnFocusGainActive(JTextComponent)
- *
- * @since 2.2
- */
- public static Boolean getSelectOnFocusGainEnabled(JTextComponent c) {
- return (Boolean) c.getClientProperty(SELECT_ON_FOCUS_GAIN_CLIENT_KEY);
- }
-
-
- /**
- * Overrides the global default for the select all feature for the given
- * text field.
- *
- * @param field the field to set this feature
- * @param b Boolean.TRUE to enable, Boolean.FALSE to disable,
- * null to use the global default
- *
- * @since 2.2
- */
- public static void setSelectOnFocusGainEnabled(JTextField field, Boolean b) {
- field.putClientProperty(SELECT_ON_FOCUS_GAIN_CLIENT_KEY, b);
- }
-
-
- // Look And Feel Replacements *********************************************
-
- /**
- * Puts a replacement name for a given {@code LookAndFeel}
- * class name in the list of all look and feel replacements.
- *
- * @param original the name of the look-and-feel to replace
- * @param replacement the name of the replacement look-and-feel
- * @see #removeLookAndFeelReplacement(String)
- * @see #getReplacementClassNameFor(String)
- */
- public static void putLookAndFeelReplacement(
- String original,
- String replacement) {
- LAF_REPLACEMENTS.put(original, replacement);
- }
-
- /**
- * Removes a replacement name for a given {@code LookAndFeel}
- * class name from the list of all look and feel replacements.
- *
- * @param original the name of the look-and-feel that has been replaced
- * @see #putLookAndFeelReplacement(String, String)
- * @see #getReplacementClassNameFor(String)
- */
- public static void removeLookAndFeelReplacement(String original) {
- LAF_REPLACEMENTS.remove(original);
- }
-
-
- /**
- * A replacement used to replace a given L&f with nothing,
- * that indicates that it should not be used. For example,
- * by default we mark the WindowsClass L&f this way,
- * to remove it from L&f lists that replace the Sun Windows L&f
- * with the JGoodies Windows L&f.
- *
- * @since 2.1.3
- */
- public static final String NO_REPLACEMENT = "none";
-
- /**
- * Initializes some default class name replacements, that replace
- * Sun's Java look and feel, and Sun's Windows look and feel by
- * the appropriate JGoodies replacements.
- *
- * @see #putLookAndFeelReplacement(String, String)
- * @see #removeLookAndFeelReplacement(String)
- * @see #getReplacementClassNameFor(String)
- */
- private static void initializeDefaultReplacements() {
- putLookAndFeelReplacement(
- "javax.swing.plaf.metal.MetalLookAndFeel",
- PLASTIC3D_NAME);
- putLookAndFeelReplacement(
- "com.sun.java.swing.plaf.windows.WindowsLookAndFeel",
- JGOODIES_WINDOWS_NAME);
- putLookAndFeelReplacement(
- "com.sun.java.swing.plaf.windows.WindowsClassicLookAndFeel",
- NO_REPLACEMENT);
- }
-
- /**
- * Returns the class name that can be used to replace the specified
- * {@code LookAndFeel} class name.
- *
- * @param className the name of the look-and-feel class
- * @return the name of the suggested replacement class
- *
- * @see #putLookAndFeelReplacement(String, String)
- * @see #removeLookAndFeelReplacement(String)
- */
- public static String getReplacementClassNameFor(String className) {
- String replacement = (String) LAF_REPLACEMENTS.get(className);
- if (replacement == null) {
- return className;
- } else if (replacement.equals(NO_REPLACEMENT)) {
- return null;
- } else {
- return replacement;
- }
- }
-
- /**
- * Returns the class name for a cross-platform {@code LookAndFeel}.
- *
- * @return the name of a cross platform look-and-feel class
- * @see #getSystemLookAndFeelClassName()
- */
- public static String getCrossPlatformLookAndFeelClassName() {
- return PLASTICXP_NAME;
- }
-
- /**
- * Returns the class name for a system specific {@code LookAndFeel}.
- *
- * @return the name of the system look-and-feel class
- * @see #getCrossPlatformLookAndFeelClassName()
- */
- public static String getSystemLookAndFeelClassName() {
- if (SystemUtils.IS_OS_WINDOWS) {
- return Options.JGOODIES_WINDOWS_NAME;
- } else if (SystemUtils.IS_OS_MAC) {
- return UIManager.getSystemLookAndFeelClassName();
- } else {
- return getCrossPlatformLookAndFeelClassName();
- }
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/common/ComboBoxEditorTextField.java b/src/core/com/jgoodies/looks/common/ComboBoxEditorTextField.java
deleted file mode 100644
index c8e201b..0000000
--- a/src/core/com/jgoodies/looks/common/ComboBoxEditorTextField.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import javax.swing.JTextField;
-import javax.swing.UIManager;
-
-/**
- * A text field designed to be used as combo box editor.
- * It doesn't set a text if the text equals the content;
- * this works around the Java issue #4530952.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.7 $
- */
-public final class ComboBoxEditorTextField extends JTextField {
-
- public ComboBoxEditorTextField(boolean isTableCellEditor) {
- super("", UIManager.getInt("ComboBox.editorColumns"));
- // Use special insets for tables, the text field defaults otherwise
- if (isTableCellEditor) {
- setMargin(UIManager.getInsets("ComboBox.tableEditorInsets"));
- }
- setBorder(UIManager.getBorder("ComboBox.editorBorder"));
- }
-
- // Workaround for 4530952
- @Override
- public void setText(String s) {
- if (getText().equals(s)) {
- return;
- }
- super.setText(s);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/ExtBasicCheckBoxMenuItemUI.java b/src/core/com/jgoodies/looks/common/ExtBasicCheckBoxMenuItemUI.java
deleted file mode 100644
index aa35cea..0000000
--- a/src/core/com/jgoodies/looks/common/ExtBasicCheckBoxMenuItemUI.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-
-
-/**
- * Renders aligned JCheckBoxMenuItems.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class ExtBasicCheckBoxMenuItemUI extends ExtBasicRadioButtonMenuItemUI {
-
- @Override
- protected String getPropertyPrefix() { return "CheckBoxMenuItem"; }
-
-
- public static ComponentUI createUI(JComponent b) {
- return new ExtBasicCheckBoxMenuItemUI();
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/common/ExtBasicMenuItemUI.java b/src/core/com/jgoodies/looks/common/ExtBasicMenuItemUI.java
deleted file mode 100644
index 9c0d24f..0000000
--- a/src/core/com/jgoodies/looks/common/ExtBasicMenuItemUI.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Color;
-import java.awt.Dimension;
-import java.awt.Font;
-import java.awt.Graphics;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.JMenuItem;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicMenuItemUI;
-
-/**
- * An implementation of {@code MenuItemUI} used by the
- * JGoodies Windows and Plastic looks.
- * Unlike it's superclass it aligns menu items, uses a slightly
- * smaller gap between text and icon, which you can override
- * in the UI defaults.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-
-public class ExtBasicMenuItemUI extends BasicMenuItemUI {
-
- private static final int MINIMUM_WIDTH = 80;
-
- private MenuItemRenderer renderer;
-
- public static ComponentUI createUI(JComponent b) {
- return new ExtBasicMenuItemUI();
- }
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- renderer = createRenderer(
- menuItem,
- iconBorderEnabled(),
- acceleratorFont,
- selectionForeground,
- disabledForeground,
- acceleratorForeground,
- acceleratorSelectionForeground);
- Integer gap =
- (Integer) UIManager.get(getPropertyPrefix() + ".textIconGap");
- defaultTextIconGap = gap != null ? gap.intValue() : 2;
- }
-
- // RadioButtonMenuItems and CheckBoxMenuItems will override
- protected boolean iconBorderEnabled() {
- return false;
- }
-
- @Override
- protected void uninstallDefaults() {
- super.uninstallDefaults();
- renderer = null;
- }
-
- @Override
- protected Dimension getPreferredMenuItemSize(
- JComponent c,
- Icon aCheckIcon,
- Icon anArrowIcon,
- int textIconGap) {
- //if (storedCheckIcon == null) replaceIcons();
- Dimension size =
- renderer.getPreferredMenuItemSize(
- c,
- aCheckIcon,
- anArrowIcon,
- textIconGap);
- int width = Math.max(MINIMUM_WIDTH, size.width);
- int height = size.height;
- return new Dimension(width, height);
- }
-
- @Override
- protected void paintMenuItem(
- Graphics g,
- JComponent c,
- Icon aCheckIcon,
- Icon anArrowIcon,
- Color background,
- Color foreground,
- int textIconGap) {
- renderer.paintMenuItem(
- g,
- c,
- aCheckIcon,
- anArrowIcon,
- background,
- foreground,
- textIconGap);
- }
-
- protected MenuItemRenderer createRenderer(
- JMenuItem menuItem,
- boolean iconBorderEnabled,
- Font acceleratorFont,
- Color selectionForeground,
- Color disabledForeground,
- Color acceleratorForeground,
- Color acceleratorSelectionForeground) {
- return new MenuItemRenderer(
- menuItem,
- iconBorderEnabled(),
- acceleratorFont,
- selectionForeground,
- disabledForeground,
- acceleratorForeground,
- acceleratorSelectionForeground);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/ExtBasicMenuUI.java b/src/core/com/jgoodies/looks/common/ExtBasicMenuUI.java
deleted file mode 100644
index 12d6f11..0000000
--- a/src/core/com/jgoodies/looks/common/ExtBasicMenuUI.java
+++ /dev/null
@@ -1,230 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Color;
-import java.awt.Dimension;
-import java.awt.Graphics;
-import java.awt.event.MouseAdapter;
-import java.awt.event.MouseEvent;
-import java.awt.event.MouseListener;
-
-import javax.swing.*;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicMenuUI;
-
-/**
- * An implementation of {@code MenuUI} used by the JGoodies Windows
- * and Plastic looks. Unlike it's superclass, it aligns submenu items.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.12 $
- */
-
-public class ExtBasicMenuUI extends BasicMenuUI {
-
- private static final String MENU_PROPERTY_PREFIX = "Menu";
- private static final String SUBMENU_PROPERTY_PREFIX = "MenuItem";
-
- // May be changed to SUBMENU_PROPERTY_PREFIX later
- private String propertyPrefix = MENU_PROPERTY_PREFIX;
-
- private MenuItemRenderer renderer;
- private MouseListener mouseListener;
-
-
- public static ComponentUI createUI(JComponent b) {
- return new ExtBasicMenuUI();
- }
-
-
- // Install and Uninstall ************************************************
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- if (arrowIcon == null || arrowIcon instanceof UIResource) {
- arrowIcon = UIManager.getIcon("Menu.arrowIcon");
- }
- renderer =
- new MenuItemRenderer(
- menuItem,
- false,
- acceleratorFont,
- selectionForeground,
- disabledForeground,
- acceleratorForeground,
- acceleratorSelectionForeground);
- Integer gap =
- (Integer) UIManager.get(getPropertyPrefix() + ".textIconGap");
- defaultTextIconGap = gap != null ? gap.intValue() : 2;
- LookAndFeel.installBorder(menuItem, getPropertyPrefix() + ".border");
- }
-
- @Override
- protected void uninstallDefaults() {
- super.uninstallDefaults();
- renderer = null;
- }
-
- @Override
- protected String getPropertyPrefix() {
- return propertyPrefix;
- }
-
- @Override
- protected Dimension getPreferredMenuItemSize(
- JComponent c,
- Icon aCheckIcon,
- Icon anArrowIcon,
- int textIconGap) {
-
- if (isSubMenu(menuItem)) {
- ensureSubMenuInstalled();
- return renderer.getPreferredMenuItemSize(
- c,
- aCheckIcon,
- anArrowIcon,
- textIconGap);
- }
- return super.getPreferredMenuItemSize(
- c,
- aCheckIcon,
- anArrowIcon,
- textIconGap);
- }
-
- @Override
- protected void paintMenuItem(
- Graphics g,
- JComponent c,
- Icon aCheckIcon,
- Icon anArrowIcon,
- Color background,
- Color foreground,
- int textIconGap) {
- if (isSubMenu(menuItem)) {
- renderer.paintMenuItem(
- g,
- c,
- aCheckIcon,
- anArrowIcon,
- background,
- foreground,
- textIconGap);
- } else {
- super.paintMenuItem(
- g,
- c,
- aCheckIcon,
- anArrowIcon,
- background,
- foreground,
- textIconGap);
- }
- }
-
- /**
- * Checks if we have already detected the correct menu type,
- * menu in menu bar vs. sub menu; reinstalls if necessary.
- */
- private void ensureSubMenuInstalled() {
- if (propertyPrefix.equals(SUBMENU_PROPERTY_PREFIX)) {
- return;
- }
-
- ButtonModel model = menuItem.getModel();
-
- //save values of armed and selected properties.
- //they will be resetted in #ununinstallDefaults().
- boolean oldArmed = model.isArmed();
- boolean oldSelected = model.isSelected();
-
- uninstallRolloverListener();
- uninstallDefaults();
- propertyPrefix = SUBMENU_PROPERTY_PREFIX;
- installDefaults();
-
- //restore values of armed and selected properties
- model.setArmed(oldArmed);
- model.setSelected(oldSelected);
- }
-
-
- // Rollover Listener ****************************************************
-
- @Override
- protected void installListeners() {
- super.installListeners();
- mouseListener = new RolloverHandler();
- menuItem.addMouseListener(mouseListener);
- }
-
- @Override
- protected void uninstallListeners() {
- super.uninstallListeners();
- uninstallRolloverListener();
- }
-
- private void uninstallRolloverListener() {
- if (mouseListener != null) {
- menuItem.removeMouseListener(mouseListener);
- mouseListener = null;
- }
- }
-
-
- // Helper Code **********************************************************
-
- private static boolean isSubMenu(JMenuItem aMenuItem) {
- return !((JMenu) aMenuItem).isTopLevelMenu();
- }
-
-
- private static final class RolloverHandler extends MouseAdapter {
-
- @Override
- public void mouseEntered(MouseEvent e) {
- AbstractButton b = (AbstractButton) e.getSource();
- b.getModel().setRollover(true);
- }
-
- @Override
- public void mouseExited(MouseEvent e) {
- AbstractButton b = (AbstractButton) e.getSource();
- b.getModel().setRollover(false);
- }
-
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/common/ExtBasicPopupMenuSeparatorUI.java b/src/core/com/jgoodies/looks/common/ExtBasicPopupMenuSeparatorUI.java
deleted file mode 100644
index 7bf2482..0000000
--- a/src/core/com/jgoodies/looks/common/ExtBasicPopupMenuSeparatorUI.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Dimension;
-import java.awt.Graphics;
-import java.awt.Insets;
-
-import javax.swing.JComponent;
-import javax.swing.JSeparator;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicPopupMenuSeparatorUI;
-
-/**
- * Renders the separator in popup and pull-down menus.
- * Unlike its superclass we use a setting for the insets and
- * it uses a shared UI delegate.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class ExtBasicPopupMenuSeparatorUI extends BasicPopupMenuSeparatorUI {
-
- private static final int SEPARATOR_HEIGHT = 2;
-
- private Insets insets;
-
- /** Shared UI object. */
- private static ComponentUI popupMenuSeparatorUI;
-
- public static ComponentUI createUI(JComponent b) {
- if (popupMenuSeparatorUI == null) {
- popupMenuSeparatorUI = new ExtBasicPopupMenuSeparatorUI();
- }
- return popupMenuSeparatorUI;
- }
-
-
- @Override
- protected void installDefaults(JSeparator s) {
- super.installDefaults(s);
- insets = UIManager.getInsets("PopupMenuSeparator.margin");
- }
-
-
- @Override
- public void paint(Graphics g, JComponent c) {
- Dimension s = c.getSize();
-
- int topInset = insets.top;
- int leftInset = insets.left;
- int rightInset = insets.right;
-
- // Paint background
- g.setColor(UIManager.getColor("MenuItem.background"));
- g.fillRect(0, 0, s.width, s.height);
-
- // Draw side
- /*
- g.setColor(UIManager.getColor("controlHighlight"));
- g.drawLine(0, 0, 0, s.height -1);
- g.drawLine(s.width-1, 0, s.width-1, s.height-1);
- */
-
- g.translate(0, topInset);
- g.setColor(c.getForeground());
- g.drawLine(leftInset, 0, s.width - rightInset, 0);
-
- g.setColor(c.getBackground());
- g.drawLine(leftInset, 1, s.width - rightInset, 1);
- g.translate(0, -topInset);
- }
-
-
- @Override
- public Dimension getPreferredSize(JComponent c) {
- return new Dimension(0, insets.top + SEPARATOR_HEIGHT + insets.bottom);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/ExtBasicRadioButtonMenuItemUI.java b/src/core/com/jgoodies/looks/common/ExtBasicRadioButtonMenuItemUI.java
deleted file mode 100644
index de9067f..0000000
--- a/src/core/com/jgoodies/looks/common/ExtBasicRadioButtonMenuItemUI.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Point;
-import java.awt.event.MouseEvent;
-
-import javax.swing.JComponent;
-import javax.swing.JMenuItem;
-import javax.swing.MenuElement;
-import javax.swing.MenuSelectionManager;
-import javax.swing.plaf.ComponentUI;
-
-
-/**
- * Renders aligned {@code JRadioButtonMenuItem}s.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public class ExtBasicRadioButtonMenuItemUI extends ExtBasicMenuItemUI {
-
- @Override
- protected String getPropertyPrefix() { return "RadioButtonMenuItem"; }
-
-
- public static ComponentUI createUI(JComponent b) {
- return new ExtBasicRadioButtonMenuItemUI();
- }
-
-
- // RadioButtonMenuItems and CheckBoxMenuItems will override
- @Override
- protected boolean iconBorderEnabled() { return true; }
-
-
- public void processMouseEvent(JMenuItem item, MouseEvent e,
- MenuElement[] path, MenuSelectionManager manager) {
- Point p = e.getPoint();
- if (p.x >= 0 && p.x < item.getWidth() &&
- p.y >= 0 && p.y < item.getHeight()) {
- if (e.getID() == MouseEvent.MOUSE_RELEASED) {
- manager.clearSelectedPath();
- item.doClick(0);
- item.setArmed(false);
- } else {
- manager.setSelectedPath(path);
- }
- } else if (item.getModel().isArmed()) {
- MenuElement[] newPath = new MenuElement[path.length - 1];
- int i, c;
- for (i = 0, c = path.length - 1; i < c; i++) {
- newPath[i] = path[i];
- }
- manager.setSelectedPath(newPath);
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/ExtBasicSpinnerLayout.java b/src/core/com/jgoodies/looks/common/ExtBasicSpinnerLayout.java
deleted file mode 100644
index a668c3e..0000000
--- a/src/core/com/jgoodies/looks/common/ExtBasicSpinnerLayout.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.*;
-
-import javax.swing.UIManager;
-
-
-/**
- * A simple layout manager for the editor and the next/previous buttons.
- * See the BasicSpinnerUI javadoc for more information about exactly how
- * the components are arranged.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.7 $
- */
-public final class ExtBasicSpinnerLayout implements LayoutManager {
-
- /**
- * Used by the default LayoutManager class - SpinnerLayout for
- * missing (null) editor/nextButton/previousButton children.
- */
- private static final Dimension ZERO_SIZE = new Dimension(0, 0);
-
-
- private Component nextButton = null;
- private Component previousButton = null;
- private Component editor = null;
-
-
- @Override
- public void addLayoutComponent(String name, Component c) {
- if ("Next".equals(name)) {
- nextButton = c;
- } else if ("Previous".equals(name)) {
- previousButton = c;
- } else if ("Editor".equals(name)) {
- editor = c;
- }
- }
-
-
- @Override
- public void removeLayoutComponent(Component c) {
- if (c == nextButton) {
- c = null;
- } else if (c == previousButton) {
- previousButton = null;
- } else if (c == editor) {
- editor = null;
- }
- }
-
-
- private static Dimension preferredSize(Component c) {
- return c == null ? ZERO_SIZE : c.getPreferredSize();
- }
-
-
- @Override
- public Dimension preferredLayoutSize(Container parent) {
- Dimension nextD = preferredSize(nextButton);
- Dimension previousD = preferredSize(previousButton);
- Dimension editorD = preferredSize(editor);
-
- Dimension size = new Dimension(editorD.width, editorD.height);
- size.width += Math.max(nextD.width, previousD.width);
- Insets insets = parent.getInsets();
- size.width += insets.left + insets.right;
- size.height += insets.top + insets.bottom;
- return size;
- }
-
-
- @Override
- public Dimension minimumLayoutSize(Container parent) {
- return preferredLayoutSize(parent);
- }
-
-
- private static void setBounds(Component c, int x, int y, int width, int height) {
- if (c != null) {
- c.setBounds(x, y, width, height);
- }
- }
-
-
- @Override
- public void layoutContainer(Container parent) {
- int width = parent.getWidth();
- int height = parent.getHeight();
-
- Insets insets = parent.getInsets();
- Dimension nextD = preferredSize(nextButton);
- Dimension previousD = preferredSize(previousButton);
- int buttonsWidth = Math.max(nextD.width, previousD.width);
- int editorHeight = height - (insets.top + insets.bottom);
-
- // The arrowButtonInsets value is used instead of the JSpinner's
- // insets if not null. Defining this to be (0, 0, 0, 0) causes the
- // buttons to be aligned with the outer edge of the spinner's
- // border, and leaving it as "null" places the buttons completely
- // inside the spinner's border.
- Insets buttonInsets = UIManager
- .getInsets("Spinner.arrowButtonInsets");
- if (buttonInsets == null) {
- buttonInsets = insets;
- }
-
- /*
- * Deal with the spinner's componentOrientation property.
- */
- int editorX, editorWidth, buttonsX;
- if (parent.getComponentOrientation().isLeftToRight()) {
- editorX = insets.left;
- editorWidth = width - insets.left - buttonsWidth
- - buttonInsets.right;
- buttonsX = width - buttonsWidth - buttonInsets.right;
- } else {
- buttonsX = buttonInsets.left;
- editorX = buttonsX + buttonsWidth;
- editorWidth = width - buttonInsets.left - buttonsWidth
- - insets.right;
- }
-
- int nextY = buttonInsets.top;
- int nextHeight = height / 2 + height % 2 - nextY;
- int previousY = buttonInsets.top + nextHeight;
- int previousHeight = height - previousY - buttonInsets.bottom;
-
- setBounds(editor, editorX, insets.top, editorWidth, editorHeight);
- setBounds(nextButton, buttonsX, nextY, buttonsWidth, nextHeight);
- setBounds(previousButton, buttonsX, previousY, buttonsWidth,
- previousHeight);
- }
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/ExtButtonAreaLayout.java b/src/core/com/jgoodies/looks/common/ExtButtonAreaLayout.java
deleted file mode 100644
index 5160b5a..0000000
--- a/src/core/com/jgoodies/looks/common/ExtButtonAreaLayout.java
+++ /dev/null
@@ -1,222 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Component;
-import java.awt.Container;
-import java.awt.Dimension;
-import java.awt.Insets;
-
-import javax.swing.plaf.basic.BasicOptionPaneUI;
-
-import com.jgoodies.common.base.SystemUtils;
-
-/**
- * Unlike its superclass, this layout uses a minimum button width
- * that complies with Mac and Windows UI style guides.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.13 $
- */
-
-public final class ExtButtonAreaLayout
- extends BasicOptionPaneUI.ButtonAreaLayout {
-
- /**
- * Constructs an {@code ExtButtonAreaLayout}.
- *
- * @param syncAllWidths true indicates that all buttons get the same size
- * @param padding the padding between buttons
- */
- public ExtButtonAreaLayout(boolean syncAllWidths, int padding) {
- super(syncAllWidths, padding);
- }
-
- @Override
- public void layoutContainer(Container container) {
- Component[] children = container.getComponents();
-
- if (children != null && children.length > 0) {
- int numChildren = children.length;
- Dimension[] sizes = new Dimension[numChildren];
- int counter;
- int yLocation = container.getInsets().top;
-
- if (syncAllWidths) {
- int maxWidth = getMinimumButtonWidth();
-
- for (counter = 0; counter < numChildren; counter++) {
- sizes[counter] = children[counter].getPreferredSize();
- maxWidth = Math.max(maxWidth, sizes[counter].width);
- }
-
- int xLocation;
- int xOffset;
-
- if (getCentersChildren()) {
- xLocation =
- (container.getSize().width
- - (maxWidth * numChildren
- + (numChildren - 1) * padding))
- / 2;
- xOffset = padding + maxWidth;
- } else {
- if (numChildren > 1) {
- xLocation = 0;
- xOffset =
- (container.getSize().width
- - maxWidth * numChildren)
- / (numChildren - 1)
- + maxWidth;
- } else {
- xLocation = (container.getSize().width - maxWidth) / 2;
- xOffset = 0;
- }
- }
- boolean ltr = container.getComponentOrientation()
- .isLeftToRight();
- for (counter = 0; counter < numChildren; counter++) {
- int index = ltr
- ? counter
- : numChildren - counter - 1;
- children[index].setBounds(
- xLocation,
- yLocation,
- maxWidth,
- sizes[index].height);
- xLocation += xOffset;
- }
- } else {
- int totalWidth = 0;
-
- for (counter = 0; counter < numChildren; counter++) {
- sizes[counter] = children[counter].getPreferredSize();
- totalWidth += sizes[counter].width;
- }
- totalWidth += (numChildren - 1) * padding;
-
- boolean cc = getCentersChildren();
- int xOffset;
- int xLocation;
-
- if (cc) {
- xLocation = (container.getSize().width - totalWidth) / 2;
- xOffset = padding;
- } else {
- if (numChildren > 1) {
- xOffset =
- (container.getSize().width - totalWidth)
- / (numChildren - 1);
- xLocation = 0;
- } else {
- xLocation =
- (container.getSize().width - totalWidth) / 2;
- xOffset = 0;
- }
- }
-
- boolean ltr = container.getComponentOrientation()
- .isLeftToRight();
- for (counter = 0; counter < numChildren; counter++) {
- int index = ltr
- ? counter
- : numChildren - counter - 1;
- children[index].setBounds(
- xLocation,
- yLocation,
- sizes[index].width,
- sizes[index].height);
- xLocation += xOffset + sizes[index].width;
- }
- }
- }
- }
-
- @Override
- public Dimension minimumLayoutSize(Container c) {
- if (c != null) {
- Component[] children = c.getComponents();
-
- if (children != null && children.length > 0) {
- Dimension aSize;
- int numChildren = children.length;
- int height = 0;
- Insets cInsets = c.getInsets();
- int extraHeight = cInsets.top + cInsets.bottom;
-
- if (syncAllWidths) {
- int maxWidth = getMinimumButtonWidth();
-
- for (int counter = 0; counter < numChildren; counter++) {
- aSize = children[counter].getPreferredSize();
- height = Math.max(height, aSize.height);
- maxWidth = Math.max(maxWidth, aSize.width);
- }
- return new Dimension(
- maxWidth * numChildren + (numChildren - 1) * padding,
- extraHeight + height);
- }
- int totalWidth = 0;
-
- for (int counter = 0; counter < numChildren; counter++) {
- aSize = children[counter].getPreferredSize();
- height = Math.max(height, aSize.height);
- totalWidth += aSize.width;
- }
- totalWidth += (numChildren - 1) * padding;
- return new Dimension(totalWidth, extraHeight + height);
- }
- }
- return new Dimension(0, 0);
- }
-
- /**
- * Computes and answers the minimum button width.
- * The MS UX guide recommends a minimum width of 50 Dialog units (DLU).<p>
- *
- * This current implementation assumes an 8pt Tahoma and honors resolutions
- * of 96dpi and 120dpi. This leads to a good approximation of the 50dlu
- * for the vast majority of today's target systems. And it sure is
- * an improvement over the superclass' value of 0.<p>
- *
- * A better implementation would use a conversion from dlu to pixel
- * for the given buttons (that may have different font render contexts
- * if located in different graphics environments in a multi-screen context).
- * The JGoodies Forms provides such a converter and offers a better button
- * layout by means of the {@code ButtonBarBuilder2} class.
- *
- * @return the minimum button width
- */
- private static int getMinimumButtonWidth() {
- return SystemUtils.IS_LOW_RESOLUTION ? 75 : 100;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/MenuItemRenderer.java b/src/core/com/jgoodies/looks/common/MenuItemRenderer.java
deleted file mode 100644
index d169f9a..0000000
--- a/src/core/com/jgoodies/looks/common/MenuItemRenderer.java
+++ /dev/null
@@ -1,685 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.*;
-import java.awt.event.KeyEvent;
-
-import javax.swing.*;
-import javax.swing.plaf.basic.BasicHTML;
-import javax.swing.text.View;
-
-import com.jgoodies.common.internal.RenderingUtils;
-import com.jgoodies.looks.Options;
-
-/**
- * Renders and lays out menu items.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.14 $
- */
-
-public class MenuItemRenderer {
-
- /*
- * Implementation note: The protected visibility prevents
- * the String value from being encrypted by the obfuscator.
- * An encrypted String key would break the client property lookup
- * in the #paint method below.
- */
- protected static final String HTML_KEY = BasicHTML.propertyKey;
-
- /* Client Property keys for text and accelerator text widths */
- static final String MAX_TEXT_WIDTH = "maxTextWidth";
- static final String MAX_ACC_WIDTH = "maxAccWidth";
-
- private static final Icon NO_ICON = new NullIcon();
-
-
- static Rectangle zeroRect = new Rectangle(0, 0, 0, 0);
- static Rectangle iconRect = new Rectangle();
- static Rectangle textRect = new Rectangle();
- static Rectangle acceleratorRect= new Rectangle();
- static Rectangle checkIconRect = new Rectangle();
- static Rectangle arrowIconRect = new Rectangle();
- static Rectangle viewRect = new Rectangle(Short.MAX_VALUE, Short.MAX_VALUE);
- static Rectangle r = new Rectangle();
-
-
- private final JMenuItem menuItem;
- private final boolean iconBorderEnabled; // when selected or pressed.
- private final Font acceleratorFont;
- private final Color selectionForeground;
- private final Color disabledForeground;
- private final Color acceleratorForeground;
- private final Color acceleratorSelectionForeground;
-
- private final String acceleratorDelimiter;
- private final Icon fillerIcon;
-
-
-
- /**
- * Constructs a MenuItemRenderer for the specified menu item and settings.
- */
- public MenuItemRenderer(JMenuItem menuItem, boolean iconBorderEnabled,
- Font acceleratorFont,
- Color selectionForeground,
- Color disabledForeground,
- Color acceleratorForeground,
- Color acceleratorSelectionForeground) {
- this.menuItem = menuItem;
- this.iconBorderEnabled = iconBorderEnabled;
- this.acceleratorFont = acceleratorFont;
- this.selectionForeground = selectionForeground;
- this.disabledForeground = disabledForeground;
- this.acceleratorForeground = acceleratorForeground;
- this.acceleratorSelectionForeground = acceleratorSelectionForeground;
- this.acceleratorDelimiter = UIManager.getString("MenuItem.acceleratorDelimiter");
- this.fillerIcon = new MinimumSizedIcon();
- }
-
-
- /**
- * Looks up and answers the appropriate menu item icon.
- */
- private static Icon getIcon(JMenuItem aMenuItem, Icon defaultIcon) {
- Icon icon = aMenuItem.getIcon();
- if (icon == null) {
- return defaultIcon;
- }
-
- ButtonModel model = aMenuItem.getModel();
- if (!model.isEnabled()) {
- return model.isSelected()
- ? aMenuItem.getDisabledSelectedIcon()
- : aMenuItem.getDisabledIcon();
- } else if (model.isPressed() && model.isArmed()) {
- Icon pressedIcon = aMenuItem.getPressedIcon();
- return pressedIcon != null ? pressedIcon : icon;
- } else if (model.isSelected()) {
- Icon selectedIcon = aMenuItem.getSelectedIcon();
- return selectedIcon != null ? selectedIcon : icon;
- } else {
- return icon;
- }
- }
-
-
- /**
- * Checks and answers if the menu item has a custom icon.
- */
- private boolean hasCustomIcon() {
- return getIcon(menuItem, null) != null;
- }
-
-
- /**
- * Answers the wrapped icon.
- */
- private Icon getWrappedIcon(Icon icon) {
- if (hideIcons()) {
- return NO_ICON;
- }
- if (icon == null) {
- return fillerIcon;
- }
- return iconBorderEnabled && hasCustomIcon()
- ? new MinimumSizedCheckIcon(icon, menuItem)
- : new MinimumSizedIcon(icon);
- }
-
-
- private static void resetRects() {
- iconRect.setBounds(zeroRect);
- textRect.setBounds(zeroRect);
- acceleratorRect.setBounds(zeroRect);
- checkIconRect.setBounds(zeroRect);
- arrowIconRect.setBounds(zeroRect);
- viewRect.setBounds(0, 0, Short.MAX_VALUE, Short.MAX_VALUE);
- r.setBounds(zeroRect);
- }
-
-
- public Dimension getPreferredMenuItemSize(JComponent c,
- Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) {
-
- JMenuItem b = (JMenuItem) c;
- String text = b.getText();
- KeyStroke accelerator = b.getAccelerator();
- String acceleratorText = "";
-
- if (accelerator != null) {
- int modifiers = accelerator.getModifiers();
- if (modifiers > 0) {
- acceleratorText = KeyEvent.getKeyModifiersText(modifiers);
- acceleratorText += acceleratorDelimiter;
- }
- int keyCode = accelerator.getKeyCode();
- if (keyCode != 0) {
- acceleratorText += KeyEvent.getKeyText(keyCode);
- } else {
- acceleratorText += accelerator.getKeyChar();
- }
- }
-
- Font font = b.getFont();
- FontMetrics fm = b.getFontMetrics(font);
- FontMetrics fmAccel = b.getFontMetrics(acceleratorFont);
-
- resetRects();
-
- Icon wrappedIcon = getWrappedIcon(getIcon(menuItem, checkIcon));
- Icon wrappedArrowIcon = new MinimumSizedIcon(arrowIcon);
- Icon icon = wrappedIcon.getIconHeight() > fillerIcon.getIconHeight()
- ? wrappedIcon
- : null;
-
- layoutMenuItem(fm, text, fmAccel, acceleratorText,
- //icon, checkIcon,
- icon, wrappedIcon,
- wrappedArrowIcon, //arrowIcon,
- b.getVerticalAlignment(), b.getHorizontalAlignment(),
- b.getVerticalTextPosition(), b.getHorizontalTextPosition(),
- viewRect, iconRect, textRect, acceleratorRect, checkIconRect, arrowIconRect,
- text == null ? 0 : defaultTextIconGap,
- defaultTextIconGap);
- // find the union of the icon and text rects
- r.setBounds(textRect);
- r = SwingUtilities.computeUnion(iconRect.x, iconRect.y, iconRect.width, iconRect.height, r);
- // r = iconRect.union(textRect);
-
- // To make the accelerator texts appear in a column, find the widest MenuItem text
- // and the widest accelerator text.
-
- //Get the parent, which stores the information.
- Container parent = menuItem.getParent();
-
- //Check the parent, and see that it is not a top-level menu.
- if (parent != null
- && parent instanceof JComponent
- && !(menuItem instanceof JMenu && ((JMenu) menuItem).isTopLevelMenu())) {
- JComponent p = (JComponent) parent;
-
- //Get widest text so far from parent, if no one exists null is returned.
- Integer maxTextWidth = (Integer) p.getClientProperty(MAX_TEXT_WIDTH);
- Integer maxAccWidth = (Integer) p.getClientProperty(MAX_ACC_WIDTH);
-
- int maxTextValue = maxTextWidth != null ? maxTextWidth.intValue() : 0;
- int maxAccValue = maxAccWidth != null ? maxAccWidth.intValue() : 0;
-
- //Compare the text widths, and adjust the r.width to the widest.
- if (r.width < maxTextValue) {
- r.width = maxTextValue;
- } else {
- p.putClientProperty(MAX_TEXT_WIDTH, new Integer(r.width));
- }
-
- //Compare the accelarator widths.
- if (acceleratorRect.width > maxAccValue) {
- maxAccValue = acceleratorRect.width;
- p.putClientProperty(MAX_ACC_WIDTH, new Integer(acceleratorRect.width));
- }
-
- //Add on the widest accelerator
- r.width += maxAccValue;
- r.width += 10;
- }
-
- if (useCheckAndArrow()) {
- // Add in the checkIcon
- r.width += checkIconRect.width;
- r.width += defaultTextIconGap;
-
- // Add in the arrowIcon
- r.width += defaultTextIconGap;
- r.width += arrowIconRect.width;
- }
-
- r.width += 2 * defaultTextIconGap;
-
- Insets insets = b.getInsets();
- if (insets != null) {
- r.width += insets.left + insets.right;
- r.height += insets.top + insets.bottom;
- }
-
- // if the width is even, bump it up one. This is critical
- // for the focus dash line to draw properly
- /* JGoodies: Can't believe the above
- * if(r.width%2 == 0) {
- r.width++;
- }*/
-
- // if the height is even, bump it up one. This is critical
- // for the text to center properly
- // JGoodies: An even height is critical to center icons properly
- if (r.height % 2 == 1) {
- r.height++;
- }
- return r.getSize();
- }
-
-
- public void paintMenuItem(Graphics g, JComponent c,
- Icon checkIcon, Icon arrowIcon,
- Color background, Color foreground, int defaultTextIconGap) {
- JMenuItem b = (JMenuItem) c;
- ButtonModel model = b.getModel();
-
- // Dimension size = b.getSize();
- int menuWidth = b.getWidth();
- int menuHeight = b.getHeight();
- Insets i = c.getInsets();
-
- resetRects();
-
- viewRect.setBounds(0, 0, menuWidth, menuHeight);
-
- viewRect.x += i.left;
- viewRect.y += i.top;
- viewRect.width -= i.right + viewRect.x;
- viewRect.height -= i.bottom + viewRect.y;
-
- Font holdf = g.getFont();
- Font f = c.getFont();
- g.setFont(f);
- FontMetrics fm = g.getFontMetrics(f);
- FontMetrics fmAccel = g.getFontMetrics(acceleratorFont);
-
- // get Accelerator text
- KeyStroke accelerator = b.getAccelerator();
- String acceleratorText = "";
- if (accelerator != null) {
- int modifiers = accelerator.getModifiers();
- if (modifiers > 0) {
- acceleratorText = KeyEvent.getKeyModifiersText(modifiers);
- acceleratorText += acceleratorDelimiter;
- }
-
- int keyCode = accelerator.getKeyCode();
- if (keyCode != 0) {
- acceleratorText += KeyEvent.getKeyText(keyCode);
- } else {
- acceleratorText += accelerator.getKeyChar();
- }
- }
-
- Icon wrappedIcon = getWrappedIcon(getIcon(menuItem, checkIcon));
- Icon wrappedArrowIcon = new MinimumSizedIcon(arrowIcon);
-
- // layout the text and icon
- String text = layoutMenuItem(fm, b.getText(), fmAccel, acceleratorText,
- // b.getIcon(), checkIcon,
- null, wrappedIcon,
- wrappedArrowIcon, //arrowIcon,
- b.getVerticalAlignment(), b.getHorizontalAlignment(),
- b.getVerticalTextPosition(), b.getHorizontalTextPosition(),
- viewRect, iconRect, textRect, acceleratorRect, checkIconRect, arrowIconRect,
- b.getText() == null ? 0 : defaultTextIconGap,
- defaultTextIconGap);
-
- // Paint background
- paintBackground(g, b, background);
-
- // Paint icon
- Color holdc = g.getColor();
- if (model.isArmed() || c instanceof JMenu && model.isSelected()) {
- g.setColor(foreground);
- }
- wrappedIcon.paintIcon(c, g, checkIconRect.x, checkIconRect.y);
- g.setColor(holdc);
-
-
- // Draw the Text
- if (text != null) {
- View v = (View) c.getClientProperty(HTML_KEY);
- if (v != null) {
- v.paint(g, textRect);
- } else {
- paintText(g, b, textRect, text);
- }
- }
-
- // Draw the Accelerator Text
- if (!acceleratorText.equals("")) {
-
- //Get the maxAccWidth from the parent to calculate the offset.
- int accOffset = 0;
- Container parent = menuItem.getParent();
- if (parent != null && parent instanceof JComponent) {
- JComponent p = (JComponent) parent;
- Integer maxValueInt = (Integer) p.getClientProperty(MAX_ACC_WIDTH);
- int maxValue = maxValueInt != null ? maxValueInt.intValue() : acceleratorRect.width;
-
- //Calculate the offset, with which the accelerator texts will be drawn with.
- accOffset = isLeftToRight(menuItem)
- ? maxValue - acceleratorRect.width
- : acceleratorRect.width - maxValue;
- }
-
- g.setFont(acceleratorFont);
- if (!model.isEnabled()) {
- // *** paint the acceleratorText disabled
- if (!disabledTextHasShadow()) {
- g.setColor(disabledForeground);
- RenderingUtils.drawStringUnderlineCharAt(c, g, acceleratorText, -1,
- acceleratorRect.x - accOffset,
- acceleratorRect.y + fmAccel.getAscent());
- } else {
- g.setColor(b.getBackground().brighter());
- RenderingUtils.drawStringUnderlineCharAt(c, g, acceleratorText, -1,
- acceleratorRect.x - accOffset,
- acceleratorRect.y + fmAccel.getAscent());
- g.setColor(b.getBackground().darker());
- RenderingUtils.drawStringUnderlineCharAt(c, g, acceleratorText, -1,
- acceleratorRect.x - accOffset - 1,
- acceleratorRect.y + fmAccel.getAscent() - 1);
- }
- } else {
- // *** paint the acceleratorText normally
- if (model.isArmed() || c instanceof JMenu && model.isSelected()) {
- g.setColor(acceleratorSelectionForeground);
- } else {
- g.setColor(acceleratorForeground);
- }
- RenderingUtils.drawStringUnderlineCharAt(c, g, acceleratorText, -1,
- acceleratorRect.x - accOffset,
- acceleratorRect.y + fmAccel.getAscent());
- }
- }
-
- // Paint the Arrow
- if (arrowIcon != null) {
- if (model.isArmed() || c instanceof JMenu && model.isSelected()) {
- g.setColor(foreground);
- }
- if (useCheckAndArrow()) {
- wrappedArrowIcon.paintIcon(c, g, arrowIconRect.x, arrowIconRect.y);
- }
- }
- g.setColor(holdc);
- g.setFont(holdf);
- }
-
- /**
- * Compute and return the location of the icons origin, the
- * location of origin of the text baseline, and a possibly clipped
- * version of the compound labels string. Locations are computed
- * relative to the viewRect rectangle.
- */
- private String layoutMenuItem(FontMetrics fm, String text,
- FontMetrics fmAccel, String acceleratorText,
- Icon icon, Icon checkIcon, Icon arrowIcon,
- int verticalAlignment, int horizontalAlignment,
- int verticalTextPosition, int horizontalTextPosition,
- Rectangle viewRectangle,
- Rectangle iconRectangle,
- Rectangle textRectangle,
- Rectangle acceleratorRectangle,
- Rectangle checkIconRectangle,
- Rectangle arrowIconRectangle,
- int textIconGap,
- int menuItemGap) {
-
- SwingUtilities.layoutCompoundLabel(menuItem, fm, text, icon,
- verticalAlignment, horizontalAlignment,
- verticalTextPosition, horizontalTextPosition,
- viewRectangle, iconRectangle, textRectangle, textIconGap);
-
- /* Initialize the acceleratorText bounds rectangle textRect. If a null
- * or and empty String was specified we substitute "" here
- * and use 0,0,0,0 for acceleratorTextRect.
- */
- if (acceleratorText == null || acceleratorText.equals("")) {
- acceleratorRectangle.width = acceleratorRectangle.height = 0;
- acceleratorText = "";
- } else {
- acceleratorRectangle.width = SwingUtilities.computeStringWidth(fmAccel, acceleratorText);
- acceleratorRectangle.height = fmAccel.getHeight();
- }
-
- boolean useCheckAndArrow = useCheckAndArrow();
-
- // Initialize the checkIcon bounds rectangle's width & height.
-
- if (useCheckAndArrow) {
- if (checkIcon != null) {
- checkIconRectangle.width = checkIcon.getIconWidth();
- checkIconRectangle.height = checkIcon.getIconHeight();
- } else {
- checkIconRectangle.width = checkIconRectangle.height = 0;
- }
-
- // Initialize the arrowIcon bounds rectangle width & height.
-
- if (arrowIcon != null) {
- arrowIconRectangle.width = arrowIcon.getIconWidth();
- arrowIconRectangle.height = arrowIcon.getIconHeight();
- } else {
- arrowIconRectangle.width = arrowIconRectangle.height = 0;
- }
- }
-
- Rectangle labelRect = iconRectangle.union(textRectangle);
- if (isLeftToRight(menuItem)) {
- textRectangle.x += menuItemGap;
- iconRectangle.x += menuItemGap;
-
- // Position the Accelerator text rect
- acceleratorRectangle.x = viewRectangle.x
- + viewRectangle.width
- - arrowIconRectangle.width
- - menuItemGap
- - acceleratorRectangle.width;
-
- // Position the Check and Arrow Icons
- if (useCheckAndArrow) {
- checkIconRectangle.x = viewRectangle.x; // + menuItemGap; JGoodies: No leading gap
- textRectangle.x += menuItemGap + checkIconRectangle.width;
- iconRectangle.x += menuItemGap + checkIconRectangle.width;
- arrowIconRectangle.x = viewRectangle.x + viewRectangle.width - menuItemGap - arrowIconRectangle.width;
- }
- } else {
- textRectangle.x -= menuItemGap;
- iconRectangle.x -= menuItemGap;
-
- // Position the Accelerator text rect
- acceleratorRectangle.x = viewRectangle.x + arrowIconRectangle.width + menuItemGap;
-
- // Position the Check and Arrow Icons
- if (useCheckAndArrow) {
- // JGoodies: No trailing gap
- checkIconRectangle.x = viewRectangle.x + viewRectangle.width - checkIconRectangle.width;
- textRectangle.x -= menuItemGap + checkIconRectangle.width;
- iconRectangle.x -= menuItemGap + checkIconRectangle.width;
- arrowIconRectangle.x = viewRectangle.x + menuItemGap;
- }
- }
-
- // Align the accelerator text and the check and arrow icons vertically
- // with the center of the label rect.
- acceleratorRectangle.y = labelRect.y + labelRect.height / 2 - acceleratorRectangle.height / 2;
- if (useCheckAndArrow) {
- arrowIconRectangle.y = labelRect.y + labelRect.height / 2 - arrowIconRectangle.height / 2;
- checkIconRectangle.y = labelRect.y + labelRect.height / 2 - checkIconRectangle.height / 2;
- }
-
- /*
- System.out.println("Layout: text="+menuItem.getText()+"\n\tv="
- +viewRect+"\n\tc="+checkIconRect+"\n\ti="
- +iconRect+"\n\tt="+textRect+"\n\tacc="
- +acceleratorRect+"\n\ta="+arrowIconRect+"\n");
- */
-
- return text;
- }
-
- /*
- * Returns false if the component is a JMenu and it is a top
- * level menu (on the menubar).
- */
- private boolean useCheckAndArrow() {
- boolean isTopLevelMenu = menuItem instanceof JMenu &&
- ((JMenu) menuItem).isTopLevelMenu();
- return !isTopLevelMenu;
- }
-
-
- private static boolean isLeftToRight(Component c) {
- return c.getComponentOrientation().isLeftToRight();
- }
-
-
- // Copies from 1.4.1 ****************************************************
-
-
- /**
- * Draws the background of the menu item.
- * Copied from 1.4.1 BasicMenuItem to make it visible to the
- * MenuItemLayouter
- *
- * @param g the paint graphics
- * @param aMenuItem menu item to be painted
- * @param bgColor selection background color
- * @since 1.4
- */
- private static void paintBackground(Graphics g, JMenuItem aMenuItem, Color bgColor) {
- ButtonModel model = aMenuItem.getModel();
-
- if (aMenuItem.isOpaque()) {
- int menuWidth = aMenuItem.getWidth();
- int menuHeight = aMenuItem.getHeight();
- Color c = model.isArmed() ||
- aMenuItem instanceof JMenu && model.isSelected()
- ? bgColor
- : aMenuItem.getBackground();
- Color oldColor = g.getColor();
- g.setColor(c);
- g.fillRect(0, 0, menuWidth, menuHeight);
- g.setColor(oldColor);
- }
- }
-
-
- /**
- * Renders the text of the current menu item.
- * <p>
- * @param g graphics context
- * @param aMenuItem menu item to render
- * @param textRectangle bounding rectangle for rendering the text
- * @param text string to render
- * @since 1.4
- */
- private void paintText(Graphics g, JMenuItem aMenuItem, Rectangle textRectangle, String text) {
- ButtonModel model = aMenuItem.getModel();
- FontMetrics fm = g.getFontMetrics();
- int mnemIndex = aMenuItem.getDisplayedMnemonicIndex();
- if (isMnemonicHidden()) {
- mnemIndex = -1;
- }
-
- if (!model.isEnabled()) {
- if (!disabledTextHasShadow()) {
- // *** paint the text disabled
- g.setColor(UIManager.getColor("MenuItem.disabledForeground"));
- RenderingUtils.drawStringUnderlineCharAt(aMenuItem, g, text, mnemIndex,
- textRectangle.x,
- textRectangle.y + fm.getAscent());
- } else {
- // *** paint the text disabled with a shadow
- g.setColor(aMenuItem.getBackground().brighter());
- RenderingUtils.drawStringUnderlineCharAt(aMenuItem, g, text, mnemIndex,
- textRectangle.x,
- textRectangle.y + fm.getAscent());
- g.setColor(aMenuItem.getBackground().darker());
- RenderingUtils.drawStringUnderlineCharAt(aMenuItem, g, text, mnemIndex,
- textRectangle.x - 1,
- textRectangle.y + fm.getAscent() - 1);
- }
- } else {
- // *** paint the text normally
- if (model.isArmed()|| aMenuItem instanceof JMenu && model.isSelected()) {
- g.setColor(selectionForeground); // Uses protected field.
- }
- RenderingUtils.drawStringUnderlineCharAt(aMenuItem, g, text, mnemIndex,
- textRectangle.x,
- textRectangle.y + fm.getAscent());
- }
- }
-
-
- protected boolean isMnemonicHidden() {
- return false;
- }
-
- protected boolean disabledTextHasShadow() {
- return false;
- }
-
-
- /**
- * Checks and answers if the parent menu indicates that we should use no icons.
- */
- private boolean hideIcons() {
- Component parent = menuItem.getParent();
- if (!(parent instanceof JPopupMenu)) {
- return false;
- }
- JPopupMenu popupMenu = (JPopupMenu) parent;
- Object value = popupMenu.getClientProperty(Options.NO_ICONS_KEY);
- if (value == null) {
- Component invoker = popupMenu.getInvoker();
- if (invoker != null && invoker instanceof JMenu) {
- value = ((JMenu) invoker).getClientProperty(Options.NO_ICONS_KEY);
- }
- }
- return Boolean.TRUE.equals(value);
- }
-
-
- /**
- * Used as a placeholder if icons are disabled.
- */
- private static class NullIcon implements Icon {
- @Override
- public int getIconWidth() { return 0; }
- @Override
- public int getIconHeight() { return 0; }
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- // The NullIcon doesn't paint anything.
- }
- }
-
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/MenuSelectionProcessor.java b/src/core/com/jgoodies/looks/common/MenuSelectionProcessor.java
deleted file mode 100644
index 5650a94..0000000
--- a/src/core/com/jgoodies/looks/common/MenuSelectionProcessor.java
+++ /dev/null
@@ -1,129 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.KeyEventPostProcessor;
-import java.awt.Window;
-import java.awt.event.KeyEvent;
-
-import javax.swing.*;
-import javax.swing.plaf.basic.ComboPopup;
-
-import com.sun.java.swing.plaf.windows.WindowsRootPaneUI;
-
-/**
- * Handles the Alt key to select the first menu in the menu bar - if any.
- * Useful to let non-Windows L&fs like Plastic feel more like Windows.
- *
- * @see WindowsRootPaneUI
- */
-public final class MenuSelectionProcessor implements KeyEventPostProcessor {
-
- private boolean altKeyPressed = false;
- private boolean menuCanceledOnPress = false;
-
- @Override
- public boolean postProcessKeyEvent(KeyEvent ev) {
- if (ev.isConsumed()) {
- return false;
- }
- if (ev.getKeyCode() == KeyEvent.VK_ALT) {
- if (ev.getID() == KeyEvent.KEY_PRESSED) {
- if (!altKeyPressed) {
- altPressed(ev);
- }
- altKeyPressed = true;
- return true;
- } else if (ev.getID() == KeyEvent.KEY_RELEASED) {
- if (altKeyPressed) {
- altReleased(ev);
- }
- altKeyPressed = false;
- }
- } else {
- altKeyPressed = false;
- }
- return false;
- }
-
-
- private void altPressed(KeyEvent ev) {
- MenuSelectionManager msm =
- MenuSelectionManager.defaultManager();
- MenuElement[] path = msm.getSelectedPath();
- if (path.length > 0 && ! (path[0] instanceof ComboPopup)) {
- msm.clearSelectedPath();
- menuCanceledOnPress = true;
- ev.consume();
- } else if (path.length > 0) { // we are in a combo box
- menuCanceledOnPress = false;
- ev.consume();
- } else {
- menuCanceledOnPress = false;
- JMenuBar mbar = getMenuBar(ev);
- JMenu menu = mbar != null ? mbar.getMenu(0) : null;
- if (menu != null) {
- ev.consume();
- }
- }
- }
-
-
- private void altReleased(KeyEvent ev) {
- if (menuCanceledOnPress) {
- return;
- }
- MenuSelectionManager msm = MenuSelectionManager.defaultManager();
- if (msm.getSelectedPath().length == 0) {
- // If no menu is active, we try activating the menu bar.
- JMenuBar mbar = getMenuBar(ev);
- JMenu menu = mbar != null ? mbar.getMenu(0) : null;
- if (menu != null) {
- MenuElement[] path = new MenuElement[2];
- path[0] = mbar;
- path[1] = menu;
- msm.setSelectedPath(path);
- }
- }
- }
-
-
- private static JMenuBar getMenuBar(KeyEvent ev) {
- JRootPane root = SwingUtilities.getRootPane(ev.getComponent());
- Window winAncestor = root == null ? null : SwingUtilities.getWindowAncestor(root);
- JMenuBar mbar = root != null ? root.getJMenuBar() : null;
- if(mbar == null && winAncestor instanceof JFrame) {
- mbar = ((JFrame)winAncestor).getJMenuBar();
- }
- return mbar;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/common/MinimumSizedCheckIcon.java b/src/core/com/jgoodies/looks/common/MinimumSizedCheckIcon.java
deleted file mode 100644
index af7f8ca..0000000
--- a/src/core/com/jgoodies/looks/common/MinimumSizedCheckIcon.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Graphics;
-
-import javax.swing.ButtonModel;
-import javax.swing.Icon;
-import javax.swing.JMenuItem;
-import javax.swing.UIManager;
-
-/**
- * An implementation of the {@code Icon} interface that has a minimum size
- * and active border. The minimum size is read from the {@code UIManager}
- * {@code defaultIconSize} key.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see MinimumSizedIcon
- */
-
-public final class MinimumSizedCheckIcon extends MinimumSizedIcon {
-
- private final JMenuItem menuItem;
-
- public MinimumSizedCheckIcon(Icon icon, JMenuItem menuItem) {
- super(icon);
- this.menuItem = menuItem;
- }
-
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- paintState(g, x, y);
- super.paintIcon(c, g, x, y);
- }
-
- private void paintState(Graphics g, int x, int y) {
- ButtonModel model = menuItem.getModel();
- //if (!model.isEnabled()) return;
-
- int w = getIconWidth();
- int h = getIconHeight();
-
- g.translate(x, y);
- if (model.isSelected() || model.isArmed() /* && model.isPressed()*/) {
- Color background = model.isArmed()
- ? UIManager.getColor("MenuItem.background")
- : UIManager.getColor("ScrollBar.track");
- Color upColor = UIManager.getColor("controlLtHighlight");
- Color downColor = UIManager.getColor("controlDkShadow");
-
- // Background
- g.setColor(background);
- g.fillRect(0, 0, w, h);
- // Top and left border
- g.setColor(model.isSelected() ? downColor : upColor);
- g.drawLine(0, 0, w-2, 0);
- g.drawLine(0, 0, 0, h-2);
- // Bottom and right border
- g.setColor(model.isSelected() ? upColor: downColor);
- g.drawLine(0, h-1, w-1, h-1);
- g.drawLine(w-1, 0, w-1, h-1);
- }
- g.translate(-x, -y);
- g.setColor(UIManager.getColor("textText"));
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/MinimumSizedIcon.java b/src/core/com/jgoodies/looks/common/MinimumSizedIcon.java
deleted file mode 100644
index ede34a2..0000000
--- a/src/core/com/jgoodies/looks/common/MinimumSizedIcon.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Component;
-import java.awt.Dimension;
-import java.awt.Graphics;
-
-import javax.swing.Icon;
-
-import com.jgoodies.looks.Options;
-
-/**
- * An {@code Icon} with a minimum size that is read from the
- * {@code UIManager} {@code defaultIconSize} key.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-
-public class MinimumSizedIcon implements Icon {
-
- private final Icon icon;
- private final int width;
- private final int height;
- private final int xOffset;
- private final int yOffset;
-
-
- public MinimumSizedIcon() {
- this(null);
- }
-
- public MinimumSizedIcon(Icon icon) {
- Dimension minimumSize = Options.getDefaultIconSize();
- this.icon = icon;
- int iconWidth = icon == null ? 0 : icon.getIconWidth();
- int iconHeight = icon == null ? 0 : icon.getIconHeight();
- width = Math.max(iconWidth, Math.max(20, minimumSize.width));
- height = Math.max(iconHeight, Math.max(20, minimumSize.height));
- xOffset = Math.max(0, (width - iconWidth) / 2);
- yOffset = Math.max(0, (height - iconHeight) / 2);
- }
-
-
- @Override
- public int getIconHeight() { return height; }
- @Override
- public int getIconWidth() { return width; }
-
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- if (icon != null) {
- icon.paintIcon(c, g, x + xOffset, y + yOffset);
- }
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/PopupMenuLayout.java b/src/core/com/jgoodies/looks/common/PopupMenuLayout.java
deleted file mode 100644
index d26ccce..0000000
--- a/src/core/com/jgoodies/looks/common/PopupMenuLayout.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Container;
-
-import javax.swing.BoxLayout;
-import javax.swing.JPopupMenu;
-import javax.swing.plaf.UIResource;
-
-
-/**
- * The JGoodies implementation of a layout manager for Popup menus.
- * In comparison to the JDK's implementation it flushes the values of the client
- * properties {@code maxTextWidth} and {@code maxAccWidth} in
- * the method {@link #invalidateLayout(Container)} and not in the method
- * {@link #preferredLayoutSize(Container)}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class PopupMenuLayout extends BoxLayout implements UIResource {
-
-
- /**
- * Creates a layout manager that will lay out components along
- * the given axis.
- *
- * @param target the container that needs to be laid out
- * @param axis the axis to lay out components along
- */
- public PopupMenuLayout(Container target, int axis) {
- super(target, axis);
- }
-
-
- /**
- * Indicates that a child has changed its layout related information,
- * and thus any cached calculations should be flushed.
- * <p>
- * In case the target is an instance of JPopupMenu it flushes the values of
- * the client properties {@code maxTextWidth} and {@code maxAccWidth}.
- *
- * @param target the affected container
- */
- @Override
- public synchronized void invalidateLayout(Container target) {
- if (target instanceof JPopupMenu) {
- JPopupMenu menu = (JPopupMenu) target;
- menu.putClientProperty(MenuItemRenderer.MAX_TEXT_WIDTH, null);
- menu.putClientProperty(MenuItemRenderer.MAX_ACC_WIDTH, null);
- }
- super.invalidateLayout(target);
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/common/RGBGrayFilter.java b/src/core/com/jgoodies/looks/common/RGBGrayFilter.java
deleted file mode 100644
index 8344f9a..0000000
--- a/src/core/com/jgoodies/looks/common/RGBGrayFilter.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Image;
-import java.awt.image.*;
-
-import javax.swing.GrayFilter;
-import javax.swing.Icon;
-import javax.swing.ImageIcon;
-import javax.swing.JComponent;
-
-import com.jgoodies.looks.Options;
-
-/**
- * An image filter that turns an icon into a grayscale icon. Used by
- * the JGoodies Windows and Plastic L&Fs to create a disabled icon.<p>
- *
- * The high-resolution gray filter can be disabled globally using
- * {@link Options#setHiResGrayFilterEnabled(boolean)}; it is enabled by default.
- * The global setting can be overridden per component by setting
- * the client property key {@link Options#HI_RES_DISABLED_ICON_CLIENT_KEY}
- * to {@code Boolean.FALSE}.<p>
- *
- * Thanks to Andrej Golovnin for suggesting a simpler filter formula.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.13 $
- */
-public final class RGBGrayFilter extends RGBImageFilter {
-
- /**
- * Overrides default constructor; prevents instantiation.
- */
- private RGBGrayFilter() {
- canFilterIndexColorModel = true;
- }
-
-
- /**
- * Returns an icon with a disabled appearance. This method is used
- * to generate a disabled icon when one has not been specified.
- *
- * @param component the component that will display the icon, may be null.
- * @param icon the icon to generate disabled icon from.
- * @return disabled icon, or null if a suitable icon can not be generated.
- */
- public static Icon getDisabledIcon(JComponent component, Icon icon) {
- if ( (icon == null)
- || (component == null)
- || (icon.getIconWidth() == 0)
- || (icon.getIconHeight() == 0)) {
- return null;
- }
- Image img;
- if (icon instanceof ImageIcon) {
- img = ((ImageIcon) icon).getImage();
- } else {
- img = new BufferedImage(
- icon.getIconWidth(),
- icon.getIconHeight(),
- BufferedImage.TYPE_INT_ARGB);
- icon.paintIcon(component, img.getGraphics(), 0, 0);
- }
- if ( !Options.isHiResGrayFilterEnabled()
- || (Boolean.FALSE.equals(component.getClientProperty(Options.HI_RES_DISABLED_ICON_CLIENT_KEY)))) {
- return new ImageIcon(GrayFilter.createDisabledImage(img));
- }
-
- ImageProducer producer =
- new FilteredImageSource(img.getSource(), new RGBGrayFilter());
-
- return new ImageIcon(component.createImage(producer));
- }
-
-
- /**
- * Converts a single input pixel in the default RGB ColorModel to a single
- * gray pixel.
- *
- * @param x the horizontal pixel coordinate
- * @param y the vertical pixel coordinate
- * @param rgb the integer pixel representation in the default RGB color model
- * @return a gray pixel in the default RGB color model.
- *
- * @see ColorModel#getRGBdefault
- * @see #filterRGBPixels
- */
- @Override
- public int filterRGB(int x, int y, int rgb) {
- // Find the average of red, green, and blue.
- float avg = (((rgb >> 16) & 0xff) / 255f +
- ((rgb >> 8) & 0xff) / 255f +
- (rgb & 0xff) / 255f) / 3;
- // Pull out the alpha channel.
- float alpha = (((rgb >> 24) & 0xff) / 255f);
-
- // Calculate the average.
- // Sun's formula: Math.min(1.0f, (1f - avg) / (100.0f / 35.0f) + avg);
- // The following formula uses less operations and hence is faster.
- avg = Math.min(1.0f, 0.35f + 0.65f * avg);
- // Convert back into RGB.
- return (int) (alpha * 255f) << 24 |
- (int) (avg * 255f) << 16 |
- (int) (avg * 255f) << 8 |
- (int) (avg * 255f);
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/common/ShadowPopup.java b/src/core/com/jgoodies/looks/common/ShadowPopup.java
deleted file mode 100644
index 1b84ecc..0000000
--- a/src/core/com/jgoodies/looks/common/ShadowPopup.java
+++ /dev/null
@@ -1,423 +0,0 @@
-/*
- * Copyright (c) 2007-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.AWTException;
-import java.awt.Component;
-import java.awt.Container;
-import java.awt.Dimension;
-import java.awt.Graphics;
-import java.awt.Panel;
-import java.awt.Point;
-import java.awt.Rectangle;
-import java.awt.Robot;
-import java.awt.Window;
-import java.awt.image.BufferedImage;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.swing.JApplet;
-import javax.swing.JComboBox;
-import javax.swing.JComponent;
-import javax.swing.JInternalFrame;
-import javax.swing.JRootPane;
-import javax.swing.JWindow;
-import javax.swing.Popup;
-import javax.swing.SwingUtilities;
-import javax.swing.border.Border;
-
-/**
- * Does all the magic for getting popups with drop shadows.
- * It adds the drop shadow border to the Popup,
- * in {@code #show} it snapshots the screen background as needed,
- * and in {@code #hide} it cleans up all changes made before.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.12 $
- *
- * @see com.jgoodies.looks.common.ShadowPopupBorder
- * @see com.jgoodies.looks.common.ShadowPopupFactory
- */
-public final class ShadowPopup extends Popup {
-
- /**
- * Max number of items to store in the cache.
- */
- private static final int MAX_CACHE_SIZE = 5;
-
- /**
- * The cache to use for ShadowPopups.
- */
- private static List<ShadowPopup> cache;
-
- /**
- * The singleton instance used to draw all borders.
- */
- private static final Border SHADOW_BORDER = ShadowPopupBorder.getInstance();
-
- /**
- * The size of the drop shadow.
- */
- private static final int SHADOW_SIZE = 5;
-
- /**
- * Indicates whether we can make snapshots from screen or not.
- */
- private static boolean canSnapshot = true;
-
- /**
- * The component mouse coordinates are relative to, may be null.
- */
- private Component owner;
-
- /**
- * The contents of the popup.
- */
- private Component contents;
-
- /**
- * The desired x and y location of the popup.
- */
- private int x, y;
-
- /**
- * The real popup. The #show() and #hide() methods will delegate
- * all calls to these popup.
- */
- private Popup popup;
-
- /**
- * The border of the contents' parent replaced by SHADOW_BORDER.
- */
- private Border oldBorder;
-
- /**
- * The old value of the opaque property of the contents' parent.
- */
- private boolean oldOpaque;
-
- /**
- * The heavy weight container of the popup contents, may be null.
- */
- private Container heavyWeightContainer;
-
- /**
- * Returns a previously used {@code ShadowPopup}, or a new one
- * if none of the popups have been recycled.
- */
- static Popup getInstance(Component owner, Component contents, int x,
- int y, Popup delegate) {
- ShadowPopup result;
- synchronized (ShadowPopup.class) {
- if (cache == null) {
- cache = new ArrayList<ShadowPopup>(MAX_CACHE_SIZE);
- }
- if (cache.size() > 0) {
- result = (ShadowPopup) cache.remove(0);
- } else {
- result = new ShadowPopup();
- }
- }
- result.reset(owner, contents, x, y, delegate);
- return result;
- }
-
- /**
- * Recycles the ShadowPopup.
- */
- private static void recycle(ShadowPopup popup) {
- synchronized (ShadowPopup.class) {
- if (cache.size() < MAX_CACHE_SIZE) {
- cache.add(popup);
- }
- }
- }
-
- public static boolean canSnapshot() {
- return canSnapshot;
- }
-
- /**
- * Hides and disposes of the {@code Popup}. Once a {@code Popup}
- * has been disposed you should no longer invoke methods on it. A
- * {@code dispose}d {@code Popup} may be reclaimed and later used
- * based on the {@code PopupFactory}. As such, if you invoke methods
- * on a {@code disposed} {@code Popup}, indeterminate
- * behavior will result.<p>
- *
- * In addition to the superclass behavior, we reset the stored
- * horizontal and vertical drop shadows - if any.
- */
- @Override
- public void hide() {
- if (contents == null) {
- return;
- }
-
- JComponent parent = (JComponent) contents.getParent();
- popup.hide();
- if ((parent != null) && parent.getBorder() == SHADOW_BORDER) {
- parent.setBorder(oldBorder);
- parent.setOpaque(oldOpaque);
- oldBorder = null;
- if (heavyWeightContainer != null) {
- parent.putClientProperty(ShadowPopupFactory.PROP_HORIZONTAL_BACKGROUND, null);
- parent.putClientProperty(ShadowPopupFactory.PROP_VERTICAL_BACKGROUND, null);
- heavyWeightContainer = null;
- }
- }
- owner = null;
- contents = null;
- popup = null;
- recycle(this);
- }
-
- /**
- * Makes the {@code Popup} visible. If the popup has a
- * heavy-weight container, we try to snapshot the background.
- * If the {@code Popup} is currently visible, it remains visible.
- */
- @Override
- public void show() {
- if (heavyWeightContainer != null) {
- snapshot();
- }
- popup.show();
- }
-
- /**
- * Reinitializes this ShadowPopup using the given parameters.
- *
- * @param owner component mouse coordinates are relative to, may be null
- * @param contents the contents of the popup
- * @param x the desired x location of the popup
- * @param y the desired y location of the popup
- * @param popup the popup to wrap
- */
- private void reset(Component owner, Component contents, int x, int y,
- Popup popup) {
- this.owner = owner;
- this.contents = contents;
- this.popup = popup;
- this.x = x;
- this.y = y;
- if (owner instanceof JComboBox) {
- return;
- }
- // Do not install the shadow border when the contents
- // has a preferred size less than or equal to 0.
- // We can't use the size, because it is(0, 0) for new popups.
- Dimension contentsPrefSize = contents.getPreferredSize();
- if ((contentsPrefSize.width <= 0) || (contentsPrefSize.height <= 0)) {
- return;
- }
- for(Container p = contents.getParent(); p != null; p = p.getParent()) {
- if ((p instanceof JWindow) || (p instanceof Panel)) {
- // Workaround for the gray rect problem.
- p.setBackground(contents.getBackground());
- heavyWeightContainer = p;
- break;
- }
- }
- JComponent parent = (JComponent) contents.getParent();
- oldOpaque = parent.isOpaque();
- oldBorder = parent.getBorder();
- parent.setOpaque(false);
- parent.setBorder(SHADOW_BORDER);
- // Pack it because we have changed the border.
- if (heavyWeightContainer != null) {
- heavyWeightContainer.setSize(
- heavyWeightContainer.getPreferredSize());
- } else {
- parent.setSize(parent.getPreferredSize());
- }
- }
-
- /**
- * The 'scratch pad' objects used to calculate dirty regions of
- * the screen snapshots.
- *
- * @see #snapshot()
- */
- private static final Point POINT = new Point();
- private static final Rectangle RECT = new Rectangle();
-
- /**
- * Snapshots the background. The snapshots are stored as client
- * properties of the contents' parent. The next time the border is drawn,
- * this background will be used.<p>
- *
- * Uses a robot on the default screen device to capture the screen
- * region under the drop shadow. Does <em>not</em> use the window's
- * device, because that may be an outdated device (due to popup reuse)
- * and the robot's origin seems to be adjusted with the default screen
- * device.
- *
- * @see #show()
- * @see com.jgoodies.looks.common.ShadowPopupBorder
- * @see Robot#createScreenCapture(Rectangle)
- */
- private void snapshot() {
- try {
- Dimension size = heavyWeightContainer.getPreferredSize();
- int width = size.width;
- int height = size.height;
-
- // Avoid unnecessary and illegal screen captures
- // for degenerated popups.
- if ((width <= 0) || (height <= SHADOW_SIZE)) {
- return;
- }
-
- Robot robot = new Robot(); // uses the default screen device
-
- RECT.setBounds(x, y + height - SHADOW_SIZE, width, SHADOW_SIZE);
- BufferedImage hShadowBg = robot.createScreenCapture(RECT);
-
- RECT.setBounds(x + width - SHADOW_SIZE, y, SHADOW_SIZE,
- height - SHADOW_SIZE);
- BufferedImage vShadowBg = robot.createScreenCapture(RECT);
-
- JComponent parent = (JComponent) contents.getParent();
- parent.putClientProperty(ShadowPopupFactory.PROP_HORIZONTAL_BACKGROUND, hShadowBg);
- parent.putClientProperty(ShadowPopupFactory.PROP_VERTICAL_BACKGROUND, vShadowBg);
-
- Container layeredPane = getLayeredPane();
- if (layeredPane == null) {
- // This could happen if owner is null.
- return;
- }
-
- int layeredPaneWidth = layeredPane.getWidth();
- int layeredPaneHeight = layeredPane.getHeight();
-
- POINT.x = x;
- POINT.y = y;
- SwingUtilities.convertPointFromScreen(POINT, layeredPane);
-
- // If needed paint dirty region of the horizontal snapshot.
- RECT.x = POINT.x;
- RECT.y = POINT.y + height - SHADOW_SIZE;
- RECT.width = width;
- RECT.height = SHADOW_SIZE;
-
- if ((RECT.x + RECT.width) > layeredPaneWidth) {
- RECT.width = layeredPaneWidth - RECT.x;
- }
- if ((RECT.y + RECT.height) > layeredPaneHeight) {
- RECT.height = layeredPaneHeight - RECT.y;
- }
- if (!RECT.isEmpty()) {
- Graphics g = hShadowBg.createGraphics();
- g.translate(-RECT.x, -RECT.y);
- g.setClip(RECT);
- if (layeredPane instanceof JComponent) {
- JComponent c = (JComponent) layeredPane;
- boolean doubleBuffered = c.isDoubleBuffered();
- c.setDoubleBuffered(false);
- c.paintAll(g);
- c.setDoubleBuffered(doubleBuffered);
- } else {
- layeredPane.paintAll(g);
- }
- g.dispose();
- }
-
- // If needed paint dirty region of the vertical snapshot.
- RECT.x = POINT.x + width - SHADOW_SIZE;
- RECT.y = POINT.y;
- RECT.width = SHADOW_SIZE;
- RECT.height = height - SHADOW_SIZE;
-
- if ((RECT.x + RECT.width) > layeredPaneWidth) {
- RECT.width = layeredPaneWidth - RECT.x;
- }
- if ((RECT.y + RECT.height) > layeredPaneHeight) {
- RECT.height = layeredPaneHeight - RECT.y;
- }
- if (!RECT.isEmpty()) {
- Graphics g = vShadowBg.createGraphics();
- g.translate(-RECT.x, -RECT.y);
- g.setClip(RECT);
- if (layeredPane instanceof JComponent) {
- JComponent c = (JComponent) layeredPane;
- boolean doubleBuffered = c.isDoubleBuffered();
- c.setDoubleBuffered(false);
- c.paintAll(g);
- c.setDoubleBuffered(doubleBuffered);
- } else {
- layeredPane.paintAll(g);
- }
- g.dispose();
- }
- } catch (AWTException e) {
- canSnapshot = false;
- } catch (SecurityException e) {
- canSnapshot = false;
- }
- }
-
- /**
- * @return the top level layered pane which contains the owner.
- */
- private Container getLayeredPane() {
- // The code below is copied from PopupFactory#LightWeightPopup#show()
- Container parent = null;
- if (owner != null) {
- parent = owner instanceof Container
- ? (Container) owner
- : owner.getParent();
- }
- // Try to find a JLayeredPane and Window to add
- for (Container p = parent; p != null; p = p.getParent()) {
- if (p instanceof JRootPane) {
- if (p.getParent() instanceof JInternalFrame) {
- continue;
- }
- parent = ((JRootPane) p).getLayeredPane();
- // Continue, so that if there is a higher JRootPane, we'll
- // pick it up.
- } else if (p instanceof Window) {
- if (parent == null) {
- parent = p;
- }
- break;
- } else if (p instanceof JApplet) {
- // Painting code stops at Applets, we don't want
- // to add to a Component above an Applet otherwise
- // you'll never see it painted.
- break;
- }
- }
- return parent;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/common/ShadowPopupBorder.java b/src/core/com/jgoodies/looks/common/ShadowPopupBorder.java
deleted file mode 100644
index e4649e3..0000000
--- a/src/core/com/jgoodies/looks/common/ShadowPopupBorder.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.awt.Image;
-import java.awt.Insets;
-
-import javax.swing.ImageIcon;
-import javax.swing.JComponent;
-import javax.swing.border.AbstractBorder;
-
-/**
- * A border with a drop shadow intended to be used as the outer border
- * of popups. Can paint the screen background if used with heavy-weight
- * popup windows.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see ShadowPopup
- * @see ShadowPopupFactory
- */
-final class ShadowPopupBorder extends AbstractBorder {
-
- /**
- * The drop shadow needs 5 pixels at the bottom and the right hand side.
- */
- private static final int SHADOW_SIZE = 5;
-
- /**
- * The singleton instance used to draw all borders.
- */
- private static ShadowPopupBorder instance = new ShadowPopupBorder();
-
- /**
- * The drop shadow is created from a PNG image with 8 bit alpha channel.
- */
- private static Image shadow
- = new ImageIcon(ShadowPopupBorder.class.getResource("shadow.png")).getImage();
-
-
- // Instance Creation *****************************************************
-
- /**
- * Returns the singleton instance used to draw all borders.
- */
- public static ShadowPopupBorder getInstance() {
- return instance;
- }
-
-
- /**
- * Paints the border for the specified component with the specified
- * position and size.
- */
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) {
- // fake drop shadow effect in case of heavy weight popups
- JComponent popup = (JComponent) c;
- Image hShadowBg = (Image) popup.getClientProperty(ShadowPopupFactory.PROP_HORIZONTAL_BACKGROUND);
- if (hShadowBg != null) {
- g.drawImage(hShadowBg, x, y + height - 5, c);
- }
- Image vShadowBg = (Image) popup.getClientProperty(ShadowPopupFactory.PROP_VERTICAL_BACKGROUND);
- if (vShadowBg != null) {
- g.drawImage(vShadowBg, x + width - 5, y, c);
- }
-
- // draw drop shadow
- g.drawImage(shadow, x + 5, y + height - 5, x + 10, y + height, 0, 6, 5, 11, null, c);
- g.drawImage(shadow, x + 10, y + height - 5, x + width - 5, y + height, 5, 6, 6, 11, null, c);
- g.drawImage(shadow, x + width - 5, y + 5, x + width, y + 10, 6, 0, 11, 5, null, c);
- g.drawImage(shadow, x + width - 5, y + 10, x + width, y + height - 5, 6, 5, 11, 6, null, c);
- g.drawImage(shadow, x + width - 5, y + height - 5, x + width, y + height, 6, 6, 11, 11, null, c);
- }
-
-
- /**
- * Returns the insets of the border.
- */
- @Override
- public Insets getBorderInsets(Component c) {
- return new Insets(0, 0, SHADOW_SIZE, SHADOW_SIZE);
- }
-
-
- /**
- * Reinitializes the insets parameter with this Border's current Insets.
- * @param c the component for which this border insets value applies
- * @param insets the object to be reinitialized
- * @return the {@code insets} object
- */
- @Override
- public Insets getBorderInsets(Component c, Insets insets) {
- insets.left = insets.top = 0;
- insets.right = insets.bottom = SHADOW_SIZE;
- return insets;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/common/ShadowPopupFactory.java b/src/core/com/jgoodies/looks/common/ShadowPopupFactory.java
deleted file mode 100644
index 699d9c4..0000000
--- a/src/core/com/jgoodies/looks/common/ShadowPopupFactory.java
+++ /dev/null
@@ -1,183 +0,0 @@
-/*
- * Copyright (c) 2005-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.common;
-
-import java.awt.Component;
-
-import javax.swing.LookAndFeel;
-import javax.swing.Popup;
-import javax.swing.PopupFactory;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.Options;
-
-
-/**
- * The JGoodies Looks implementation of {@code PopupFactory}.
- * Adds a drop shadow border to all popups except ComboBox popups.
- * It is installed by the JGoodies Plastic L&F, as well as by
- * the JGoodies Windows L&F during the Look&Feel initialization,
- * see {@link com.jgoodies.looks.plastic.PlasticLookAndFeel#initialize} and
- * {@link com.jgoodies.looks.windows.WindowsLookAndFeel#initialize}.<p>
- *
- * This factory shall not be used on platforms that provide native drop shadows,
- * such as the Mac OS X. Therefore the invocation of the {@link #install()}
- * method will have no effect on such platforms.<p>
- *
- * <strong>Note:</strong> To be used in a sandbox environment, this PopupFactory
- * requires two AWT permissions: {@code createRobot} and
- * {@code readDisplayPixels}. The reason for it is, that in the case of
- * the heavy weight popups this PopupFactory uses a Robot to snapshot
- * the screen background to simulate the drop shadow effect.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- *
- * @see java.awt.AWTPermission
- * @see java.awt.Robot
- * @see javax.swing.Popup
- * @see LookAndFeel#initialize
- * @see LookAndFeel#uninitialize
- */
-public final class ShadowPopupFactory extends PopupFactory {
-
- /**
- * In the case of heavy weight popups, snapshots of the screen background
- * will be stored as client properties of the popup contents' parent.
- * These snapshots will be used by the popup border to simulate the drop
- * shadow effect. The two following constants define the names of
- * these client properties.
- *
- * @see com.jgoodies.looks.common.ShadowPopupBorder
- */
- static final String PROP_HORIZONTAL_BACKGROUND = "jgoodies.hShadowBg";
- static final String PROP_VERTICAL_BACKGROUND = "jgoodies.vShadowBg";
-
- /**
- * The PopupFactory used before this PopupFactory has been installed
- * in {@code #install}. Used to restored the original state
- * in {@code #uninstall}.
- */
- private final PopupFactory storedFactory;
-
-
- // Instance Creation ******************************************************
-
- private ShadowPopupFactory(PopupFactory storedFactory) {
- this.storedFactory = storedFactory;
- }
-
-
- // API ********************************************************************
-
- /**
- * Installs the ShadowPopupFactory as the shared popup factory
- * on non-Mac platforms. Also stores the previously set factory,
- * so that it can be restored in {@code #uninstall}.<p>
- *
- * In some Mac Java environments the popup factory throws
- * a NullPointerException when we call {@code #getPopup}.<p>
- *
- * TODO: The Mac case shows that we may have problems replacing
- * non PopupFactory instances. Therefore we should consider
- * replacing only instances of PopupFactory.
- *
- * @see #uninstall()
- */
- public static void install() {
- if (SystemUtils.IS_OS_MAC) {
- return;
- }
-
- PopupFactory factory = PopupFactory.getSharedInstance();
- if (factory instanceof ShadowPopupFactory) {
- return;
- }
-
- PopupFactory.setSharedInstance(new ShadowPopupFactory(factory));
- }
-
- /**
- * Uninstalls the ShadowPopupFactory and restores the original
- * popup factory as the new shared popup factory.
- *
- * @see #install()
- */
- public static void uninstall() {
- PopupFactory factory = PopupFactory.getSharedInstance();
- if (!(factory instanceof ShadowPopupFactory)) {
- return;
- }
-
- PopupFactory stored = ((ShadowPopupFactory) factory).storedFactory;
- PopupFactory.setSharedInstance(stored);
- }
-
-
- /**
- * Creates a {@code Popup} for the Component {@code owner}
- * containing the Component {@code contents}. In addition to
- * the superclass behavior, we try to return a Popup that has a drop shadow,
- * if popup drop shadows are active - as returned by
- * {@code Options#isPopupDropShadowActive}.<p>
- *
- * {@code owner} is used to determine which {@code Window} the new
- * {@code Popup} will parent the {@code Component} the
- * {@code Popup} creates to. A null {@code owner} implies there
- * is no valid parent. {@code x} and
- * {@code y} specify the preferred initial location to place
- * the {@code Popup} at. Based on screen size, or other paramaters,
- * the {@code Popup} may not display at {@code x} and
- * {@code y}.<p>
- *
- * We invoke the super {@code #getPopup}, not the one in the
- * stored factory, because the popup type is set in this instance,
- * not in the stored one.
- *
- * @param owner Component mouse coordinates are relative to, may be null
- * @param contents Contents of the Popup
- * @param x Initial x screen coordinate
- * @param y Initial y screen coordinate
- * @return Popup containing Contents
- * @throws IllegalArgumentException if contents is null
- *
- * @see Options#isPopupDropShadowActive()
- */
- @Override
- public Popup getPopup(Component owner, Component contents, int x, int y)
- throws IllegalArgumentException {
- Popup popup = super.getPopup(owner, contents, x, y);
- return Options.isPopupDropShadowActive()
- ? ShadowPopup.getInstance(owner, contents, x, y, popup)
- : popup;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/common/package.html b/src/core/com/jgoodies/looks/common/package.html
deleted file mode 100644
index 8d341c4..0000000
--- a/src/core/com/jgoodies/looks/common/package.html
+++ /dev/null
@@ -1,65 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
- Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- o Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- o Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
- o Neither the name of JGoodies Karsten Lentzsch nor the names of
- its contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
- OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
- JavaDoc uses all text between the "body" tags.
- The first sentence is used as short description.
--->
-</head>
-<body bgcolor="white">
-
-Contains classes shared by all JGoodies Looks implementations.
-
-<!--
-<h2>Package Specification</h2>
-
-##### FILL IN ANY SPECS NEEDED BY JAVA COMPATIBILITY KIT #####
-<ul>
- <li><a href="">##### REFER TO ANY FRAMEMAKER SPECIFICATION HERE #####</a>
-</ul>
--->
-
-<h2>Related Documentation</h2>
-
-For more information see:
-<ul>
- <li><a href="http://www.jgoodies.com/articles/" >
- http://www.jgoodies.com/articles/</a>
-</ul>
-<!-- Put @see and @since tags down here. -->
-
- at see com.jgoodies.looks
- at see com.jgoodies.looks.plastic
- at see com.jgoodies.looks.plastic.theme
- at see com.jgoodies.looks.windows
-
-</body>
-</html>
diff --git a/src/core/com/jgoodies/looks/common/shadow.png b/src/core/com/jgoodies/looks/common/shadow.png
deleted file mode 100644
index 2bf27f2..0000000
Binary files a/src/core/com/jgoodies/looks/common/shadow.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/package.html b/src/core/com/jgoodies/looks/package.html
deleted file mode 100644
index bb8674a..0000000
--- a/src/core/com/jgoodies/looks/package.html
+++ /dev/null
@@ -1,65 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
- Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- o Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- o Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
- o Neither the name of JGoodies Karsten Lentzsch nor the names of
- its contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
- OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
- JavaDoc uses all text between the "body" tags.
- The first sentence is used as short description.
--->
-</head>
-<body bgcolor="white">
-
-Contains classes to configure the JGoodies L&Fs.
-
-<!--
-<h2>Package Specification</h2>
-
-##### FILL IN ANY SPECS NEEDED BY JAVA COMPATIBILITY KIT #####
-<ul>
- <li><a href="">##### REFER TO ANY FRAMEMAKER SPECIFICATION HERE #####</a>
-</ul>
--->
-
-<h2>Related Documentation</h2>
-
-For more information see:
-<ul>
- <li><a href="http://www.jgoodies.com/articles/" >
- http://www.jgoodies.com/articles/</a>
-</ul>
-<!-- Put @see and @since tags down here. -->
-
- at see com.jgoodies.looks.common
- at see com.jgoodies.looks.plastic
- at see com.jgoodies.looks.plastic.theme
- at see com.jgoodies.looks.windows
-
-</body>
-</html>
diff --git a/src/core/com/jgoodies/looks/plastic/ActiveBasicButtonListener.java b/src/core/com/jgoodies/looks/plastic/ActiveBasicButtonListener.java
deleted file mode 100644
index 6fc8f93..0000000
--- a/src/core/com/jgoodies/looks/plastic/ActiveBasicButtonListener.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.event.MouseEvent;
-
-import javax.swing.AbstractButton;
-import javax.swing.plaf.basic.BasicButtonListener;
-
-/**
- * Unlike its superclass this class sets the armed state when the mouse
- * is over the button, where the 1.4 superclass sets the armed state only
- * if the button is pressed.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-
-final class ActiveBasicButtonListener extends BasicButtonListener {
-
- private boolean mouseOver;
-
- ActiveBasicButtonListener(AbstractButton b) {
- super(b);
- mouseOver = false;
- }
-
- @Override
- public void mouseEntered(MouseEvent e){
- super.mouseEntered(e);
- AbstractButton button = (AbstractButton) e.getSource();
- button.getModel().setArmed(mouseOver = true);
- }
-
- @Override
- public void mouseExited(MouseEvent e){
- super.mouseExited(e);
- AbstractButton button = (AbstractButton) e.getSource();
- button.getModel().setArmed(mouseOver = false);
- }
-
- @Override
- public void mouseReleased(MouseEvent e){
- super.mouseReleased(e);
- AbstractButton button = (AbstractButton) e.getSource();
- button.getModel().setArmed(mouseOver);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/Plastic3DLookAndFeel.java b/src/core/com/jgoodies/looks/plastic/Plastic3DLookAndFeel.java
deleted file mode 100644
index 26c0a84..0000000
--- a/src/core/com/jgoodies/looks/plastic/Plastic3DLookAndFeel.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.UIDefaults;
-
-/**
- * Intializes class and component defaults for the JGoodies Plastic3D
- * look&feel.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public class Plastic3DLookAndFeel extends PlasticLookAndFeel {
-
- /**
- * Constructs the JGoodies Plastic3D look&feel.
- */
- public Plastic3DLookAndFeel() {
- }
-
- @Override
- public String getID() {
- return "JGoodies Plastic 3D";
- }
-
- @Override
- public String getName() {
- return "JGoodies Plastic 3D";
- }
-
- @Override
- public String getDescription() {
- return "The JGoodies Plastic 3D Look and Feel"
- + " - \u00a9 2001-2012 JGoodies Karsten Lentzsch";
- }
-
- @Override
- protected boolean is3DEnabled() {
- return true;
- }
-
- /**
- * Initializes the Plastic3D component defaults.
- *
- * @param table the UIDefaults table to work with
- */
- @Override
- protected void initComponentDefaults(UIDefaults table) {
- super.initComponentDefaults(table);
-
- Object menuBarBorder = PlasticBorders.getThinRaisedBorder();
- Object toolBarBorder = PlasticBorders.getThinRaisedBorder();
-
- Object[] defaults = {
- "MenuBar.border", menuBarBorder,
- "ToolBar.border", toolBarBorder,
- };
- table.putDefaults(defaults);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticArrowButton.java b/src/core/com/jgoodies/looks/plastic/PlasticArrowButton.java
deleted file mode 100644
index f5c1bbf..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticArrowButton.java
+++ /dev/null
@@ -1,355 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Graphics;
-import java.awt.Rectangle;
-
-import javax.swing.ButtonModel;
-import javax.swing.UIManager;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-import javax.swing.plaf.metal.MetalScrollButton;
-
-/**
- * Renders the arrow buttons in scroll bars and spinners.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-class PlasticArrowButton extends MetalScrollButton {
-
- private final Color shadowColor;
- private final Color highlightColor;
-
- protected boolean isFreeStanding;
-
-
- public PlasticArrowButton(int direction, int width, boolean freeStanding) {
- super(direction, width, freeStanding);
- shadowColor = UIManager.getColor("ScrollBar.darkShadow");
- highlightColor = UIManager.getColor("ScrollBar.highlight");
- isFreeStanding = freeStanding;
- }
-
-
- @Override
- public void setFreeStanding(boolean freeStanding) {
- super.setFreeStanding(freeStanding);
- isFreeStanding = freeStanding;
- }
-
-
- @Override
- public void paint(Graphics g) {
- boolean leftToRight = PlasticUtils.isLeftToRight(this);
- boolean isEnabled = getParent().isEnabled();
- boolean isPressed = getModel().isPressed();
-
- Color arrowColor = isEnabled
- ? MetalLookAndFeel.getControlInfo()
- : MetalLookAndFeel.getControlDisabled();
- int width = getWidth();
- int height = getHeight();
- int w = width;
- int h = height;
- int arrowHeight = calculateArrowHeight(height, width);
- int arrowOffset = calculateArrowOffset();
- boolean paintNorthBottom = isPaintingNorthBottom();
-
- g.setColor(isPressed ? MetalLookAndFeel.getControlShadow() : getBackground());
- g.fillRect(0, 0, width, height);
-
- if (getDirection() == NORTH) {
- paintNorth(g, leftToRight, isEnabled, arrowColor, isPressed,
- width, height, w, h, arrowHeight, arrowOffset, paintNorthBottom);
- } else if (getDirection() == SOUTH) {
- paintSouth(g, leftToRight, isEnabled, arrowColor, isPressed,
- width, height, w, h, arrowHeight, arrowOffset);
- } else if (getDirection() == EAST) {
- paintEast(g, isEnabled, arrowColor, isPressed,
- width, height, w, h, arrowHeight);
- } else if (getDirection() == WEST) {
- paintWest(g, isEnabled, arrowColor, isPressed,
- width, height, w, h, arrowHeight);
- }
- if (PlasticUtils.is3D("ScrollBar.")) {
- paint3D(g);
- }
- }
-
- /**
- * Computes and returns the arrow height based on the specified
- * buttons height and width.
- *
- * @param height the height of the button to be used for calculation.
- * @param width the width of the button to be used for calculation.
- * @return the height of the arrow
- */
- protected int calculateArrowHeight(int height, int width) {
- return (height + 1) / 4;
- }
-
- protected int calculateArrowOffset() {
- return 0;
- }
-
- protected boolean isPaintingNorthBottom() {
- return false;
- }
-
-
- private void paintWest(Graphics g, boolean isEnabled, Color arrowColor,
- boolean isPressed, int width, int height, int w, int h, int arrowHeight) {
-
- if (!isFreeStanding) {
- height += 2;
- width += 1;
- g.translate(-1, 0);
- }
-
- // Draw the arrow
- g.setColor(arrowColor);
-
- int startX = (((w + 1) - arrowHeight) / 2);
- int startY = (h / 2);
-
- for (int line = 0; line < arrowHeight; line++) {
- g.drawLine(
- startX + line,
- startY - line,
- startX + line,
- startY + line + 1);
- }
-
- if (isEnabled) {
- g.setColor(highlightColor);
-
- if (!isPressed) {
- g.drawLine(1, 1, width - 1, 1);
- g.drawLine(1, 1, 1, height - 3);
- }
- g.drawLine(1, height - 1, width - 1, height - 1);
-
- g.setColor(shadowColor);
- g.drawLine(0, 0, width - 1, 0);
- g.drawLine(0, 0, 0, height - 2);
- g.drawLine(1, height - 2, width - 1, height - 2);
- } else {
- PlasticUtils.drawDisabledBorder(g, 0, 0, width + 1, height);
- }
-
- if (!isFreeStanding) {
- height -= 2;
- width -= 1;
- g.translate(1, 0);
- }
- }
-
-
- private void paintEast(Graphics g, boolean isEnabled, Color arrowColor,
- boolean isPressed, int width, int height, int w, int h, int arrowHeight) {
- if (!isFreeStanding) {
- height += 2;
- width += 1;
- }
-
- // Draw the arrow
- g.setColor(arrowColor);
-
- int startX = (((w + 1) - arrowHeight) / 2) + arrowHeight - 1;
- int startY = (h / 2);
- for (int line = 0; line < arrowHeight; line++) {
- g.drawLine(
- startX - line,
- startY - line,
- startX - line,
- startY + line + 1);
- }
-
- if (isEnabled) {
- g.setColor(highlightColor);
- if (!isPressed) {
- g.drawLine(0, 1, width - 3, 1);
- g.drawLine(0, 1, 0, height - 3);
- }
- g.drawLine(width - 1, 1, width - 1, height - 1);
- g.drawLine(0, height - 1, width - 1, height - 1);
-
- g.setColor(shadowColor);
- g.drawLine(0, 0, width - 2, 0);
- g.drawLine(width - 2, 1, width - 2, height - 2);
- g.drawLine(0, height - 2, width - 2, height - 2);
- } else {
- PlasticUtils.drawDisabledBorder(g, -1, 0, width + 1, height);
- }
- if (!isFreeStanding) {
- height -= 2;
- width -= 1;
- }
- }
-
-
- protected void paintSouth(Graphics g, boolean leftToRight, boolean isEnabled,
- Color arrowColor, boolean isPressed,
- int width, int height, int w, int h, int arrowHeight, int arrowOffset) {
-
- if (!isFreeStanding) {
- height += 1;
- if (!leftToRight) {
- width += 1;
- g.translate(-1, 0);
- } else {
- width += 2;
- }
- }
-
- // Draw the arrow
- g.setColor(arrowColor);
-
- int startY = (((h + 0) - arrowHeight) / 2) + arrowHeight - 1; // KL was h + 1
- int startX = w / 2;
-
- // System.out.println( "startX2 :" + startX + " startY2 :"+startY);
-
- for (int line = 0; line < arrowHeight; line++) {
- g.fillRect(startX - line - arrowOffset, startY - line, 2 * (line + 1), 1);
- }
-
- if (isEnabled) {
- g.setColor(highlightColor);
- if (!isPressed) {
- g.drawLine(1, 0, width - 3, 0);
- g.drawLine(1, 0, 1, height - 3);
- }
- g.drawLine(0, height - 1, width - 1, height - 1);
- g.drawLine(width - 1, 0, width - 1, height - 1);
-
- g.setColor(shadowColor);
- g.drawLine(0, 0, 0, height - 2);
- g.drawLine(width - 2, 0, width - 2, height - 2);
- g.drawLine(1, height - 2, width - 2, height - 2);
- } else {
- PlasticUtils.drawDisabledBorder(g, 0, -1, width, height + 1);
- }
-
- if (!isFreeStanding) {
- height -= 1;
- if (!leftToRight) {
- width -= 1;
- g.translate(1, 0);
- } else {
- width -= 2;
- }
- }
- }
-
-
- protected void paintNorth(Graphics g, boolean leftToRight, boolean isEnabled,
- Color arrowColor, boolean isPressed,
- int width, int height, int w, int h, int arrowHeight, int arrowOffset,
- boolean paintBottom) {
- if (!isFreeStanding) {
- height += 1;
- g.translate(0, -1);
- if (!leftToRight) {
- width += 1;
- g.translate(-1, 0);
- } else {
- width += 2;
- }
- }
-
- // Draw the arrow
- g.setColor(arrowColor);
- int startY = ((h + 1) - arrowHeight) / 2; // KL was (h + 1)
- int startX = w / 2;
- // System.out.println( "startX :" + startX + " startY :"+startY);
- for (int line = 0; line < arrowHeight; line++) {
- g.fillRect(startX - line - arrowOffset, startY + line, 2*(line + 1), 1);
- }
-
- if (isEnabled) {
- g.setColor(highlightColor);
-
- if (!isPressed) {
- g.drawLine(1, 1, width - 3, 1);
- g.drawLine(1, 1, 1, height - 1);
- }
-
- g.drawLine(width - 1, 1, width - 1, height - 1);
-
- g.setColor(shadowColor);
- g.drawLine(0, 0, width - 2, 0);
- g.drawLine(0, 0, 0, height - 1);
- g.drawLine(width - 2, 1, width - 2, height - 1);
- if (paintBottom) {
- g.fillRect(0, height - 1, width - 1, 1);
- }
- } else {
- PlasticUtils.drawDisabledBorder(g, 0, 0, width, height + 1);
- if (paintBottom) {
- g.setColor(MetalLookAndFeel.getControlShadow());
- g.fillRect(0, height - 1, width - 1, 1);
- }
- }
- if (!isFreeStanding) {
- height -= 1;
- g.translate(0, 1);
- if (!leftToRight) {
- width -= 1;
- g.translate(1, 0);
- } else {
- width -= 2;
- }
- }
- }
-
-
- private void paint3D(Graphics g) {
- ButtonModel buttonModel = getModel();
- if (buttonModel.isArmed() && buttonModel.isPressed() || buttonModel.isSelected()) {
- return;
- }
-
- int width = getWidth();
- int height = getHeight();
- if (getDirection() == EAST) {
- width -= 2;
- } else if (getDirection() == SOUTH) {
- height -= 2;
- }
-
- Rectangle r = new Rectangle(1, 1, width, height);
- boolean isHorizontal = (getDirection() == EAST || getDirection() == WEST);
- PlasticUtils.addLight3DEffekt(g, r, isHorizontal);
- }
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticBorders.java b/src/core/com/jgoodies/looks/plastic/PlasticBorders.java
deleted file mode 100644
index 641d57f..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticBorders.java
+++ /dev/null
@@ -1,847 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.awt.Insets;
-
-import javax.swing.*;
-import javax.swing.border.AbstractBorder;
-import javax.swing.border.Border;
-import javax.swing.border.CompoundBorder;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.BorderUIResource;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicBorders;
-import javax.swing.plaf.metal.MetalBorders;
-import javax.swing.text.JTextComponent;
-
-
-/**
- * This class consists of a set of {@code Border}s used
- * by the JGoodies Plastic Look and Feel UI delegates.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.15 $
- */
-
-final class PlasticBorders {
-
- private PlasticBorders() {
- // Overrides default constructor; prevents instantiation.
- }
-
-
- // Accessing and Creating Borders ***************************************
-
- private static Border comboBoxEditorBorder;
- private static Border comboBoxArrowButtonBorder;
- private static Border etchedBorder;
- private static Border flush3DBorder;
- private static Border menuBarHeaderBorder;
- private static Border menuBorder;
- private static Border menuItemBorder;
- private static Border popupMenuBorder;
- private static Border noMarginPopupMenuBorder;
- private static Border rolloverButtonBorder;
- private static Border scrollPaneBorder;
- private static Border separatorBorder;
- private static Border textFieldBorder;
- private static Border thinLoweredBorder;
- private static Border thinRaisedBorder;
- private static Border toolBarHeaderBorder;
-
-
- /**
- * Returns a border instance for a {@code JButton}.
- *
- * @return the lazily created button border
- */
- static Border getButtonBorder(Insets buttonMargin) {
- return new BorderUIResource.CompoundBorderUIResource(
- new ButtonBorder(buttonMargin),
- new BasicBorders.MarginBorder());
- }
-
- /**
- * Returns a border for a {@code JComboBox}'s button.
- *
- * @return the lazily created combo box arrow button border
- */
- static Border getComboBoxArrowButtonBorder() {
- if (comboBoxArrowButtonBorder == null) {
- comboBoxArrowButtonBorder = new CompoundBorder( // No UIResource
- new ComboBoxArrowButtonBorder(),
- new BasicBorders.MarginBorder());
- }
- return comboBoxArrowButtonBorder;
- }
-
- /**
- * Returns a border for a {@code JComboBox}'s editor.
- *
- * @return the lazily created combo box editor border
- */
- static Border getComboBoxEditorBorder() {
- if (comboBoxEditorBorder == null) {
- comboBoxEditorBorder = new CompoundBorder( // No UIResource
- new ComboBoxEditorBorder(),
- new BasicBorders.MarginBorder());
- }
- return comboBoxEditorBorder;
- }
-
- /**
- * Returns an etched border instance for {@code JMenuBar} or
- * {@code JToolBar}.
- *
- * @return the lazily created etched border
- */
- static Border getEtchedBorder() {
- if (etchedBorder == null) {
- etchedBorder = new BorderUIResource.CompoundBorderUIResource(
- new EtchedBorder(),
- new BasicBorders.MarginBorder());
- }
- return etchedBorder;
- }
-
- /**
- * Returns a flushed 3D border.
- *
- * @return the lazily created flushed 3D border
- */
- static Border getFlush3DBorder() {
- if (flush3DBorder == null) {
- flush3DBorder = new Flush3DBorder();
- }
- return flush3DBorder;
- }
-
- /**
- * Returns a border for a {@code JInternalFrame}.
- *
- * @return an internal frame border
- */
- static Border getInternalFrameBorder() {
- return new InternalFrameBorder();
- }
-
- /**
- * Returns a special border for a {@code JMenuBar} that
- * is used in a header just above a {@code JToolBar}.
- *
- * @return the lazily created menu bar header border
- */
- static Border getMenuBarHeaderBorder() {
- if (menuBarHeaderBorder == null) {
- menuBarHeaderBorder = new BorderUIResource.CompoundBorderUIResource(
- new MenuBarHeaderBorder(),
- new BasicBorders.MarginBorder());
- }
- return menuBarHeaderBorder;
- }
-
- /**
- * Returns a border instance for a {@code JMenu}.
- *
- * @return the lazily created menu border
- */
- static Border getMenuBorder() {
- if (menuBorder == null) {
- menuBorder = new BorderUIResource.CompoundBorderUIResource(
- new MenuBorder(),
- new BasicBorders.MarginBorder());
- }
- return menuBorder;
- }
-
- /**
- * Returns a border instance for a {@code JMenuItem}.
- *
- * @return the lazily created menu item border
- */
- static Border getMenuItemBorder() {
- if (menuItemBorder == null) {
- menuItemBorder =
- new BorderUIResource(new BasicBorders.MarginBorder());
- }
- return menuItemBorder;
- }
-
- /**
- * Returns a border instance for a {@code JPopupMenu}.
- *
- * @return the lazily created popup menu border
- */
- static Border getPopupMenuBorder() {
- if (popupMenuBorder == null) {
- popupMenuBorder = new PopupMenuBorder();
- }
- return popupMenuBorder;
- }
-
- /**
- * Returns a border instance for a {@code JPopupMenu} that
- * has no (extra) margin.
- *
- * @return the lazily created no-margin popup menu border
- */
- static Border getNoMarginPopupMenuBorder() {
- if (noMarginPopupMenuBorder == null) {
- noMarginPopupMenuBorder = new NoMarginPopupMenuBorder();
- }
- return noMarginPopupMenuBorder;
- }
-
- /**
- * Returns a border for a {@code JInternalFrame}'s palette.
- *
- * @return a border for an internal frame in palette mode
- */
- static Border getPaletteBorder() {
- return new PaletteBorder();
- }
-
- /**
- * Returns a rollover border for buttons in a {@code JToolBar}.
- *
- * @return the lazily created rollover button border
- */
- static Border getRolloverButtonBorder() {
- if (rolloverButtonBorder == null) {
- rolloverButtonBorder = new CompoundBorder( // No UIResource
- new RolloverButtonBorder(),
- new RolloverMarginBorder());
- }
- return rolloverButtonBorder;
- }
-
- /**
- * Returns a separator border instance for {@code JScrollPane}.
- *
- * @return the lazily created scroll pane border
- */
- static Border getScrollPaneBorder() {
- if (scrollPaneBorder == null) {
- scrollPaneBorder = new ScrollPaneBorder();
- }
- return scrollPaneBorder;
- }
-
- /**
- * Returns a separator border instance for {@code JMenuBar} or
- * {@code JToolBar}.
- *
- * @return the lazily created separator border
- */
- static Border getSeparatorBorder() {
- if (separatorBorder == null) {
- separatorBorder = new BorderUIResource.CompoundBorderUIResource(
- new SeparatorBorder(),
- new BasicBorders.MarginBorder());
- }
- return separatorBorder;
- }
-
- /**
- * Returns a border instance for a JTextField.
- *
- * @return the lazily created text field border
- */
- static Border getTextFieldBorder() {
- if (textFieldBorder == null) {
- textFieldBorder = new BorderUIResource.CompoundBorderUIResource(
- new TextFieldBorder(),
- new BasicBorders.MarginBorder());
- }
- return textFieldBorder;
- }
-
- /**
- * Returns a thin lowered border.
- *
- * @return the lazily created thin lowered border
- */
- static Border getThinLoweredBorder() {
- if (thinLoweredBorder == null) {
- thinLoweredBorder = new ThinLoweredBorder();
- }
- return thinLoweredBorder;
- }
-
- /**
- * Returns a thin raised border.
- *
- * @return the lazily created thin raised border
- */
- static Border getThinRaisedBorder() {
- if (thinRaisedBorder == null) {
- thinRaisedBorder = new ThinRaisedBorder();
- }
- return thinRaisedBorder;
- }
-
- /**
- * Returns a border instance for a JToggleButton.
- *
- * @return the lazily created toggle button border
- */
- static Border getToggleButtonBorder(Insets buttonMargin) {
- return new BorderUIResource.CompoundBorderUIResource(
- new ToggleButtonBorder(buttonMargin),
- new BasicBorders.MarginBorder());
- }
-
- /**
- * Returns a special border for a {@code JToolBar} that
- * is used in a header just below a {@code JMenuBar}.
- *
- * @return the lazily created toolbar header border
- */
- static Border getToolBarHeaderBorder() {
- if (toolBarHeaderBorder == null) {
- toolBarHeaderBorder = new BorderUIResource.CompoundBorderUIResource(
- new ToolBarHeaderBorder(),
- new BasicBorders.MarginBorder());
- }
- return toolBarHeaderBorder;
- }
-
- private static class Flush3DBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(2, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- if (c.isEnabled()) {
- PlasticUtils.drawFlush3DBorder(g, x, y, w, h);
- } else {
- PlasticUtils.drawDisabledBorder(g, x, y, w, h);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
-
- @Override
- public Insets getBorderInsets(Component c, Insets newInsets) {
- newInsets.top = INSETS.top;
- newInsets.left = INSETS.left;
- newInsets.bottom = INSETS.bottom;
- newInsets.right = INSETS.right;
- return newInsets;
- }
- }
-
-
- private static class ButtonBorder extends AbstractBorder implements UIResource {
-
- protected final Insets insets;
-
- protected ButtonBorder(Insets insets) {
- this.insets = insets;
- }
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton button = (AbstractButton) c;
- ButtonModel model = button.getModel();
-
- if (model.isEnabled()) {
- boolean isPressed = model.isPressed() && model.isArmed();
- boolean isDefault = button instanceof JButton
- && ((JButton) button).isDefaultButton();
-
- if (isPressed && isDefault) {
- PlasticUtils.drawDefaultButtonPressedBorder(g, x, y, w, h);
- } else if (isPressed) {
- PlasticUtils.drawPressed3DBorder(g, x, y, w, h);
- } else if (isDefault) {
- PlasticUtils.drawDefaultButtonBorder(g, x, y, w, h, false);
- } else {
- PlasticUtils.drawButtonBorder(g, x, y, w, h, false);
- }
- } else { // disabled state
- PlasticUtils.drawDisabledBorder(g, x, y, w - 1, h - 1);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return insets; }
-
- @Override
- public Insets getBorderInsets(Component c, Insets newInsets) {
- newInsets.top = insets.top;
- newInsets.left = insets.left;
- newInsets.bottom = insets.bottom;
- newInsets.right = insets.right;
- return newInsets;
- }
- }
-
-
- private static final class ComboBoxArrowButtonBorder extends AbstractBorder implements UIResource {
-
- protected static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton button = (AbstractButton) c;
- ButtonModel model = button.getModel();
-
- if (model.isEnabled()) {
- boolean isPressed = model.isPressed() && model.isArmed();
-
- if (isPressed) {
- PlasticUtils.drawPressed3DBorder(g, x, y, w, h);
- } else {
- PlasticUtils.drawButtonBorder(g, x, y, w, h, false);
- }
- } else {
- PlasticUtils.drawDisabledBorder(g, x, y, w - 1, h - 1);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static final class ComboBoxEditorBorder extends AbstractBorder {
-
- private static final Insets INSETS = new Insets(2, 2, 2, 0);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- if (c.isEnabled()) {
- PlasticUtils.drawFlush3DBorder(g, x, y, w + 2, h);
- } else {
- PlasticUtils.drawDisabledBorder(g, x, y, w + 2, h-1);
- g.setColor(UIManager.getColor("control"));
- g.drawLine(x, y + h-1, x + w, y + h-1);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for {@code JInternalFrame}s.
- */
- private static final class InternalFrameBorder extends AbstractBorder implements UIResource {
-
- private static final Insets NORMAL_INSETS = new Insets(1, 1, 1, 1);
- private static final Insets MAXIMIZED_INSETS = new Insets(1, 1, 0, 0);
-
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- JInternalFrame frame = (JInternalFrame) c;
- if (frame.isMaximum()) {
- paintMaximizedBorder(g, x, y, w, h);
- } else {
- PlasticUtils.drawThinFlush3DBorder(g, x, y, w, h);
- }
- }
-
- private static void paintMaximizedBorder(Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlHighlight());
- g.drawLine(0, 0, w - 2, 0);
- g.drawLine(0, 0, 0, h - 2);
- g.translate(-x, -y);
- }
-
- @Override
- public Insets getBorderInsets(Component c) {
- return ((JInternalFrame) c).isMaximum() ? MAXIMIZED_INSETS : NORMAL_INSETS;
- }
- }
-
-
- /**
- * A border used for the palette of {@code JInternalFrame}s.
- */
- private static final class PaletteBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h ) {
- g.translate(x,y);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawRect(0, 0, w-1, h-1);
- g.translate(-x,-y);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border that looks like a separator line; used for menu bars
- * and tool bars.
- */
- private static final class SeparatorBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(0, 0, 2, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor( UIManager.getColor("Separator.foreground"));
- g.drawLine( 0, h - 2, w - 1, h - 2 );
-
- g.setColor( UIManager.getColor("Separator.background"));
- g.drawLine( 0, h - 1, w - 1, h - 1 );
- g.translate(-x, -y);
- }
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static final class ThinRaisedBorder extends AbstractBorder implements UIResource {
- private static final Insets INSETS = new Insets(2, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- PlasticUtils.drawThinFlush3DBorder(g, x, y, w, h);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static final class ThinLoweredBorder extends AbstractBorder implements UIResource {
- private static final Insets INSETS = new Insets(2, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- PlasticUtils.drawThinPressed3DBorder(g, x, y, w, h);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for menu bars and tool bars in
- * {@code HeaderStyle.SINGLE}. The bar is wrapped by an inner thin
- * raised border, which in turn is wrapped by an outer thin lowered
- * border.
- */
- private static final class EtchedBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(2, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- PlasticUtils.drawThinPressed3DBorder(g, x, y, w, h);
- PlasticUtils.drawThinFlush3DBorder (g, x + 1, y + 1, w - 2, h - 2);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for menu bars in {@code HeaderStyle.BOTH}.
- * The menu bar and tool bar are wrapped by a thin raised border,
- * both together are wrapped by a thin lowered border.
- */
- private static final class MenuBarHeaderBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(2, 2, 1, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- PlasticUtils.drawThinPressed3DBorder(g, x, y, w, h + 1);
- PlasticUtils.drawThinFlush3DBorder (g, x + 1, y + 1, w - 2, h - 1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for tool bars in {@code HeaderStyle.BOTH}.
- * The menu bar and tool bar are wrapped by a thin raised border,
- * both together are wrapped by a thin lowered border.
- */
- private static final class ToolBarHeaderBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(1, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- PlasticUtils.drawThinPressed3DBorder(g, x, y - 1, w, h + 1);
- PlasticUtils.drawThinFlush3DBorder (g, x + 1, y, w - 2, h - 1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static final class MenuBorder extends AbstractBorder implements UIResource {
- private static final Insets INSETS = new Insets( 2, 2, 2, 2 );
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- JMenuItem b = (JMenuItem) c;
- ButtonModel model = b.getModel();
-
- if (model.isArmed() || model.isSelected()) {
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawLine(0, 0, w - 2, 0 );
- g.drawLine(0, 0, 0, h - 1 );
- //g.drawLine(w - 2, 2, w - 2, h - 1 );
-
- g.setColor(PlasticLookAndFeel.getPrimaryControlHighlight());
- g.drawLine(w - 1, 0, w - 1, h - 1 );
- } else if (model.isRollover()) {
- g.translate(x, y);
- PlasticUtils.drawFlush3DBorder(g, x, y, w, h);
- g.translate(-x, -y);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
-
- @Override
- public Insets getBorderInsets(Component c, Insets newInsets) {
- newInsets.top = INSETS.top;
- newInsets.left = INSETS.left;
- newInsets.bottom = INSETS.bottom;
- newInsets.right = INSETS.right;
- return newInsets;
- }
- }
-
-
- private static final class PopupMenuBorder extends AbstractBorder implements UIResource {
- private static final Insets INSETS = new Insets(3, 3, 3, 3);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawRect(0, 0, w-1, h-1);
- g.setColor(PlasticLookAndFeel.getMenuItemBackground());
- g.drawRect(1, 1, w-3, h-3);
- g.drawRect(2, 2, w-5, h-5);
- g.translate(-x, -y);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static final class NoMarginPopupMenuBorder extends AbstractBorder implements UIResource {
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawRect(0, 0, w-1, h-1);
- g.translate(-x, -y);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static class RolloverButtonBorder extends ButtonBorder {
-
- private RolloverButtonBorder() {
- super(new Insets(3, 3, 3, 3));
- }
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- if (!model.isEnabled()) {
- return;
- }
-
- if (!(c instanceof JToggleButton)) {
- if ( model.isRollover() && !( model.isPressed() && !model.isArmed() ) ) {
- super.paintBorder( c, g, x, y, w, h );
- }
- return;
- }
-
- //if ( model.isRollover() && !( model.isPressed() && !model.isArmed() ) ) {
- //super.paintBorder( c, g, x, y, w, h );
- //}
-
- if (model.isRollover()) {
- if (model.isPressed() && model.isArmed()) {
- PlasticUtils.drawPressed3DBorder(g, x, y, w, h);
- } else {
- PlasticUtils.drawFlush3DBorder(g, x, y, w, h);
- }
- } else if (model.isSelected()) {
- PlasticUtils.drawDark3DBorder(g, x, y, w, h);
- }
- }
- }
-
-
- /**
- * A border which is like a Margin border but it will only honor the margin
- * if the margin has been explicitly set by the developer.
- */
- static final class RolloverMarginBorder extends EmptyBorder {
-
- RolloverMarginBorder() {
- super(1, 1, 1, 1);
- }
-
-
- @Override
- public Insets getBorderInsets(Component c) {
- return getBorderInsets(c, new Insets(0, 0, 0, 0));
- }
-
-
- @Override
- public Insets getBorderInsets(Component c, Insets insets) {
- Insets margin = null;
-
- if (c instanceof AbstractButton) {
- margin = ((AbstractButton) c).getMargin();
- }
- if (margin == null || margin instanceof UIResource) {
- // default margin so replace
- insets.left = left;
- insets.top = top;
- insets.right = right;
- insets.bottom = bottom;
- } else {
- // Margin which has been explicitly set by the user.
- insets.left = margin.left;
- insets.top = margin.top;
- insets.right = margin.right;
- insets.bottom = margin.bottom;
- }
- return insets;
- }
- }
-
- /**
- * Unlike Metal we don't paint the (misplaced) control color edges.
- * Being a subclass of MetalBorders.ScrollPaneBorders ensures that
- * the ScrollPaneUI will update the ScrollbarsFreeStanding property.
- */
- private static final class ScrollPaneBorder extends MetalBorders.ScrollPaneBorder {
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
-
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawRect(0, 0, w - 2, h - 2);
- g.setColor(PlasticLookAndFeel.getControlHighlight());
- g.drawLine(w - 1, 0, w - 1, h - 1);
- g.drawLine(0, h - 1, w - 1, h - 1);
-
- g.translate(-x, -y);
- }
- }
-
-
- private static final class TextFieldBorder extends Flush3DBorder {
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
-
- if (!(c instanceof JTextComponent)) {
- // special case for non-text components (bug ID 4144840)
- if (c.isEnabled()) {
- PlasticUtils.drawFlush3DBorder(g, x, y, w, h);
- } else {
- PlasticUtils.drawDisabledBorder(g, x, y, w, h);
- }
- return;
- }
-
- if (c.isEnabled() && ((JTextComponent) c).isEditable()) {
- PlasticUtils.drawFlush3DBorder(g, x, y, w, h);
- } else {
- PlasticUtils.drawDisabledBorder(g, x, y, w, h);
- }
- }
- }
-
-
- private static final class ToggleButtonBorder extends ButtonBorder {
-
- private ToggleButtonBorder(Insets insets) {
- super(insets);
- }
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- if (!c.isEnabled()) {
- PlasticUtils.drawDisabledBorder(g, x, y, w - 1, h - 1);
- } else {
- AbstractButton button = (AbstractButton) c;
- ButtonModel model = button.getModel();
- if (model.isPressed() && model.isArmed()) {
- PlasticUtils.drawPressed3DBorder(g, x, y, w, h);
- } else if (model.isSelected()) {
- PlasticUtils.drawDark3DBorder(g, x, y, w, h);
- } else {
- PlasticUtils.drawFlush3DBorder(g, x, y, w, h);
- }
- }
- }
-
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticBumps.java b/src/core/com/jgoodies/looks/plastic/PlasticBumps.java
deleted file mode 100644
index ac9705d..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticBumps.java
+++ /dev/null
@@ -1,252 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Dimension;
-import java.awt.Graphics;
-import java.awt.Graphics2D;
-import java.awt.GraphicsConfiguration;
-import java.awt.Image;
-import java.awt.image.BufferedImage;
-import java.awt.image.DataBuffer;
-import java.awt.image.IndexColorModel;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.swing.Icon;
-
-/**
- * Creates, adjusts and paints the bumps used in the JGoodies Plastic L&Fs.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-final class PlasticBumps implements Icon {
-
- private static final List<BumpBuffer> BUFFERS = new ArrayList<BumpBuffer>();
-
- private int xBumps;
- private int yBumps;
-
- private Color topColor;
- private Color shadowColor;
- private Color backColor;
-
- private BumpBuffer buffer;
-
-
- // Instance Creation *****************************************************
-
- PlasticBumps(int width, int height,
- Color newTopColor, Color newShadowColor, Color newBackColor) {
- setBumpArea(width, height);
- setBumpColors(newTopColor, newShadowColor, newBackColor);
- }
-
-
- // Package API ************************************************************
-
- void setBumpArea(int width, int height) {
- xBumps = width / 2;
- yBumps = height / 2;
- }
-
-
- void setBumpColors(Color newTopColor, Color newShadowColor, Color newBackColor) {
- topColor = newTopColor;
- shadowColor = newShadowColor;
- backColor = newBackColor;
- }
-
-
- // Icon Implementation ****************************************************
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- GraphicsConfiguration gc = g instanceof Graphics2D
- ? (GraphicsConfiguration) ((Graphics2D) g).getDeviceConfiguration()
- : null;
-
- buffer = getBuffer(gc, topColor, shadowColor, backColor);
-
- int bufferWidth = BumpBuffer.getImageSize().width;
- int bufferHeight = BumpBuffer.getImageSize().height;
- int iconWidth = getIconWidth();
- int iconHeight = getIconHeight();
- int x2 = x + iconWidth;
- int y2 = y + iconHeight;
- int savex = x;
-
- while (y < y2) {
- int h = Math.min(y2 - y, bufferHeight);
- for (x = savex; x < x2; x += bufferWidth) {
- int w = Math.min(x2 - x, bufferWidth);
- g.drawImage(buffer.getImage(), x, y, x + w, y + h, 0, 0, w, h, null);
- }
- y += bufferHeight;
- }
- }
-
- @Override
- public int getIconWidth() { return xBumps * 2; }
- @Override
- public int getIconHeight() { return yBumps * 2; }
-
-
- // Helper Code ************************************************************
-
- private BumpBuffer getBuffer(GraphicsConfiguration gc,
- Color aTopColor, Color aShadowColor, Color aBackColor) {
- if (buffer != null
- && buffer.hasSameConfiguration(gc, aTopColor, aShadowColor, aBackColor)) {
- return buffer;
- }
- BumpBuffer result = null;
- for (Iterator iterator = BUFFERS.iterator(); iterator.hasNext();) {
- BumpBuffer aBuffer = (BumpBuffer) iterator.next();
- if (aBuffer.hasSameConfiguration(gc, aTopColor, aShadowColor, aBackColor)) {
- result = aBuffer;
- break;
- }
- }
- if (result == null) {
- result = new BumpBuffer(gc, topColor, shadowColor, backColor);
- BUFFERS.add(result);
- }
- return result;
- }
-
-
- // Helper Class ***********************************************************
-
- private static final class BumpBuffer {
-
- private static final int IMAGE_SIZE = 64;
- private static Dimension imageSize = new Dimension(IMAGE_SIZE, IMAGE_SIZE);
-
- transient Image image;
- private final Color topColor;
- private final Color shadowColor;
- private final Color backColor;
- private final GraphicsConfiguration gc;
-
- BumpBuffer(
- GraphicsConfiguration gc,
- Color aTopColor,
- Color aShadowColor,
- Color aBackColor) {
- this.gc = gc;
- topColor = aTopColor;
- shadowColor = aShadowColor;
- backColor = aBackColor;
- createImage();
- fillBumpBuffer();
- }
-
-
- boolean hasSameConfiguration(
- GraphicsConfiguration aGC,
- Color aTopColor,
- Color aShadowColor,
- Color aBackColor) {
- if (gc != null) {
- if (!gc.equals(aGC)) {
- return false;
- }
- } else if (aGC != null) {
- return false;
- }
- return topColor.equals(aTopColor)
- && shadowColor.equals(aShadowColor)
- && backColor.equals(aBackColor);
- }
-
-
- /**
- * Returns the Image containing the bumps appropriate for the passed in
- * {@code GraphicsConfiguration}.
- */
- Image getImage() { return image; }
-
-
- static Dimension getImageSize() { return imageSize; }
-
-
- /**
- * Paints the bumps into the current image.
- */
- private void fillBumpBuffer() {
- Graphics g = image.getGraphics();
-
- g.setColor(backColor);
- g.fillRect(0, 0, IMAGE_SIZE, IMAGE_SIZE);
-
- g.setColor(topColor);
- for (int x = 0; x < IMAGE_SIZE; x += 4) {
- for (int y = 0; y < IMAGE_SIZE; y += 4) {
- g.drawLine(x, y, x, y);
- g.drawLine(x + 2, y + 2, x + 2, y + 2);
- }
- }
-
- g.setColor(shadowColor);
- for (int x = 0; x < IMAGE_SIZE; x += 4) {
- for (int y = 0; y < IMAGE_SIZE; y += 4) {
- g.drawLine(x + 1, y + 1, x + 1, y + 1);
- g.drawLine(x + 3, y + 3, x + 3, y + 3);
- }
- }
- g.dispose();
- }
-
-
- /**
- * Creates the image appropriate for the passed in
- * {@code GraphicsConfiguration}, which may be null.
- */
- private void createImage() {
- if (gc != null) {
- image = gc.createCompatibleImage(IMAGE_SIZE, IMAGE_SIZE);
- } else {
- int[] cmap = { backColor.getRGB(), topColor.getRGB(), shadowColor.getRGB()};
- IndexColorModel icm =
- new IndexColorModel(8, 3, cmap, 0, false, -1, DataBuffer.TYPE_BYTE);
- image = new BufferedImage(IMAGE_SIZE, IMAGE_SIZE, BufferedImage.TYPE_BYTE_INDEXED, icm);
- }
- }
- }
-
-
-}
-
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticButtonUI.java b/src/core/com/jgoodies/looks/plastic/PlasticButtonUI.java
deleted file mode 100644
index cd7a126..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticButtonUI.java
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Container;
-import java.awt.Graphics;
-import java.awt.Rectangle;
-
-import javax.swing.*;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalButtonUI;
-
-/**
- * The JGoodies Plastic L&F implementation of {@code ButtonUI}.
- * It differs from the superclass {@code MetalButtonUI} in that
- * it can add a pseudo 3D effect and that the border can paint the focus.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public class PlasticButtonUI extends MetalButtonUI {
-
- private static final PlasticButtonUI INSTANCE = new PlasticButtonUI();
-
- private boolean borderPaintsFocus;
-
- public static ComponentUI createUI(JComponent b) {
- return INSTANCE;
- }
-
- /**
- * Installs defaults.
- */
- @Override
- public void installDefaults(AbstractButton b) {
- super.installDefaults(b);
- borderPaintsFocus =
- Boolean.TRUE.equals(UIManager.get("Button.borderPaintsFocus"));
- }
-
-
- // Painting ***************************************************************
-
- @Override
- public void update(Graphics g, JComponent c) {
- if (c.isOpaque()) {
- AbstractButton b = (AbstractButton) c;
- if (isToolBarButton(b)) {
- c.setOpaque(false);
- } else if (b.isContentAreaFilled()) {
- g.setColor(c.getBackground());
- g.fillRect(0, 0, c.getWidth(), c.getHeight());
-
- if (is3D(b)) {
- Rectangle r =
- new Rectangle(
- 1,
- 1,
- c.getWidth() - 2,
- c.getHeight() - 1);
- PlasticUtils.add3DEffekt(g, r);
- }
- }
- }
- paint(g, c);
- }
-
- /**
- * Paints the focus with close to the button's border.
- */
- @Override
- protected void paintFocus(
- Graphics g,
- AbstractButton b,
- Rectangle viewRect,
- Rectangle textRect,
- Rectangle iconRect) {
-
- if (borderPaintsFocus) {
- return;
- }
-
- boolean isDefault =
- b instanceof JButton && ((JButton) b).isDefaultButton();
- int topLeftInset = isDefault ? 3 : 2;
- int width = b.getWidth() - 1 - topLeftInset * 2;
- int height = b.getHeight() - 1 - topLeftInset * 2;
-
- g.setColor(getFocusColor());
- g.drawRect(topLeftInset, topLeftInset, width - 1, height - 1);
- }
-
- // Private Helper Code **************************************************************
-
- /**
- * Checks and answers if this is button is in a tool bar.
- *
- * @param b the button to check
- * @return true if in tool bar, false otherwise
- */
- protected boolean isToolBarButton(AbstractButton b) {
- Container parent = b.getParent();
- return parent != null
- && (parent instanceof JToolBar
- || parent.getParent() instanceof JToolBar);
- }
-
- /**
- * Checks and answers if this button shall use a pseudo 3D effect.
- *
- * @param b the button to check
- * @return true indicates a 3D effect, false flat
- */
- protected boolean is3D(AbstractButton b) {
- if (PlasticUtils.force3D(b)) {
- return true;
- }
- if (PlasticUtils.forceFlat(b)) {
- return false;
- }
- ButtonModel model = b.getModel();
- return PlasticUtils.is3D("Button.")
- && b.isBorderPainted()
- && model.isEnabled()
- && !(model.isPressed() && model.isArmed());
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticComboBoxButton.java b/src/core/com/jgoodies/looks/plastic/PlasticComboBoxButton.java
deleted file mode 100644
index 9803222..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticComboBoxButton.java
+++ /dev/null
@@ -1,296 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.awt.Insets;
-
-import javax.swing.*;
-import javax.swing.border.Border;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.basic.BasicComboBoxRenderer;
-
-/**
- * The default button for combo boxes in the JGoodies Plastic Look&Feel.
- * <p>
- * It differs from {@code MetalComboBoxButton} in that the border
- * is quite the same as for text fields: a compound border with an inner
- * {@code MarginBorder}.
- * <p>
- * Also, we try to switch the {@code ListCellRenderer} to transparent,
- * which works for most {@code JComponent} renderes including the
- * {@code BasicComboBoxRenderer}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.13 $
- */
-final class PlasticComboBoxButton extends JButton {
-
- private static final Insets EMPTY_INSETS = new Insets(0, 0, 0, 0);
- private static final Border EMPTY_BORDER = new EmptyBorder(EMPTY_INSETS);
- private static final int LEFT_MARGIN = 2;
- private static final int RIGHT_MARGIN = 2;
-
- private final JList listBox;
- private final CellRendererPane rendererPane;
-
- private JComboBox comboBox;
- private Icon comboIcon;
- private boolean iconOnly = false;
- private final boolean borderPaintsFocus;
-
- /**
- * Constructs a {@code PlasticComboBoxButton}.
- */
- PlasticComboBoxButton(
- JComboBox comboBox,
- Icon comboIcon,
- boolean iconOnly,
- CellRendererPane rendererPane,
- JList listBox) {
- super("");
- setModel(new DefaultButtonModel() {
- @Override
- public void setArmed(boolean armed) {
- super.setArmed(isPressed() || armed);
- }
- });
- this.comboBox = comboBox;
- this.comboIcon = comboIcon;
- this.iconOnly = iconOnly;
- this.rendererPane = rendererPane;
- this.listBox = listBox;
- setEnabled(comboBox.isEnabled());
- setFocusable(false);
- setRequestFocusEnabled(comboBox.isEnabled());
- setBorder(UIManager.getBorder("ComboBox.arrowButtonBorder"));
- setMargin(new Insets(0, LEFT_MARGIN, 0, RIGHT_MARGIN));
- borderPaintsFocus = UIManager.getBoolean("ComboBox.borderPaintsFocus");
- }
-
- public JComboBox getComboBox() {
- return comboBox;
- }
-
- public void setComboBox(JComboBox cb) {
- comboBox = cb;
- }
-
- public Icon getComboIcon() {
- return comboIcon;
- }
-
- public void setComboIcon(Icon i) {
- comboIcon = i;
- }
-
- public boolean isIconOnly() {
- return iconOnly;
- }
-
- public void setIconOnly(boolean b) {
- iconOnly = b;
- }
-
- @Override
- public void setEnabled(boolean enabled) {
- super.setEnabled(enabled);
- // Set the background and foreground to the combobox colors.
- if (enabled) {
- setBackground(comboBox.getBackground());
- setForeground(comboBox.getForeground());
- } else {
- setBackground(UIManager.getColor("ComboBox.disabledBackground"));
- setForeground(UIManager.getColor("ComboBox.disabledForeground"));
- }
- }
-
- /**
- * The combo's arrow button should be excluded from the focus traversal.
- * Since Java 6 the arrow button is configured as being focusable
- * in {@code BasicComboBoxUI#configureArrowButton}.
- * Therefore it doesn't help to call {@code setFocusable(false)}
- * in the constructor; instead we override this method.
- */
- @Override
- public boolean isFocusTraversable() {
- return false;
- }
-
-
- /**
- * Paints the component; honors the 3D settings and
- * tries to switch the renderer component to transparent.
- */
- @Override
- public void paintComponent(Graphics g) {
- super.paintComponent(g);
- boolean leftToRight = PlasticUtils.isLeftToRight(comboBox);
- Insets insets = getInsets();
- int width = getWidth() - (insets.left + insets.right);
- int height = getHeight() - (insets.top + insets.bottom);
- if (height <= 0 || width <= 0) {
- return;
- }
- int left = insets.left;
- int top = insets.top;
- int right = left + (width - 1);
-
- int iconWidth = 0;
- int iconLeft = (leftToRight) ? right : left;
-
- // Paint the icon
- if (comboIcon != null) {
- iconWidth = comboIcon.getIconWidth();
- int iconHeight = comboIcon.getIconHeight();
- int iconTop;
-
- if (iconOnly) {
- iconLeft = (getWidth() - iconWidth) / 2;
- iconTop = (getHeight() - iconHeight) / 2;
- } else {
- iconLeft = leftToRight
- ? left + (width - 1) - iconWidth
- : left;
- iconTop = (getHeight() - iconHeight) / 2;
- }
- comboIcon.paintIcon(this, g, iconLeft, iconTop);
- }
-
- // Let the renderer paint
- if (!iconOnly && comboBox != null) {
- ListCellRenderer renderer = comboBox.getRenderer();
- boolean renderPressed = getModel().isPressed();
- Component c = renderer.getListCellRendererComponent(
- listBox, comboBox.getSelectedItem(), -1, renderPressed, false);
-
- int x = leftToRight ? left : left + iconWidth;
- int y = top;
- int w = getWidth() - left - PlasticComboBoxUI.getEditableButtonWidth();
- int h = height;
-
- Border oldBorder = null;
- if ((c instanceof JComponent) && !isTableCellEditor()) {
- JComponent component = (JComponent) c;
- if (c instanceof BasicComboBoxRenderer.UIResource) {
- oldBorder = component.getBorder();
- component.setBorder(EMPTY_BORDER);
- }
- Insets rendererInsets = component.getInsets();
- Insets editorInsets = UIManager.getInsets("ComboBox.editorInsets");
- int offsetTop = Math.max(0, editorInsets.top - rendererInsets.top);
- int offsetBottom = Math.max(0, editorInsets.bottom - rendererInsets.bottom);
- y += offsetTop;
- h -= offsetTop + offsetBottom;
- }
- c.setFont(rendererPane.getFont());
- configureColors(c);
-
-
- // Fix for 4238829: should lay out the JPanel.
- boolean shouldValidate = c instanceof JPanel;
-
- if (!is3D() || !(c instanceof JComponent) || !c.isOpaque()) {
- rendererPane.paintComponent(g, c, this, x, y, w, h, shouldValidate);
- } else {
- // In case, we are in 3D mode _and_ have a non-transparent
- // JComponent renderer, store the opaque state, set it
- // to transparent, paint, then restore.
- JComponent component = (JComponent) c;
- boolean oldOpaque = component.isOpaque();
- component.setOpaque(false);
- rendererPane.paintComponent(g, c, this, x, y, w, h, shouldValidate);
- component.setOpaque(oldOpaque);
- }
- if (oldBorder != null) {
- ((JComponent) c).setBorder(oldBorder);
- }
- }
-
- if (comboIcon != null) {
- // Paint the focus
- boolean hasFocus = comboBox.hasFocus();
- if (!borderPaintsFocus && hasFocus) {
- g.setColor(PlasticLookAndFeel.getFocusColor());
- g.drawRect(2, 2, getWidth() - 6, getHeight() - 6);
- }
- }
-
- }
-
- private void configureColors(Component c) {
- if (model.isArmed() && model.isPressed()) {
- if (isOpaque()) {
- c.setBackground(UIManager.getColor("Button.select"));
- }
- c.setForeground(comboBox.getForeground());
- } else if (!comboBox.isEnabled()) {
- if (isOpaque()) {
- c.setBackground(UIManager.getColor("ComboBox.disabledBackground"));
- }
- c.setForeground(UIManager.getColor("ComboBox.disabledForeground"));
- } else {
- c.setForeground(comboBox.getForeground());
- c.setBackground(comboBox.getBackground());
- }
- }
-
-
- // Helper Code ************************************************************
-
- /**
- * Checks and answers if we should paint a pseudo 3D effect.
- */
- private boolean is3D() {
- if (PlasticUtils.force3D(comboBox)) {
- return true;
- }
- if (PlasticUtils.forceFlat(comboBox)) {
- return false;
- }
- return PlasticUtils.is3D("ComboBox.");
- }
-
-
- /**
- * Checks and answers if this UI's combo has a client property
- * that indicates that the combo is used as a table cell editor.
- *
- * @return {@code true} if the table cell editor client property
- * is set to {@code Boolean.TRUE}, {@code false} otherwise
- */
- private boolean isTableCellEditor() {
- return Boolean.TRUE.equals(comboBox.getClientProperty(PlasticComboBoxUI.CELL_EDITOR_KEY));
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticComboBoxEditor.java b/src/core/com/jgoodies/looks/plastic/PlasticComboBoxEditor.java
deleted file mode 100644
index d34ee40..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticComboBoxEditor.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.plaf.basic.BasicComboBoxEditor;
-
-import com.jgoodies.looks.common.ComboBoxEditorTextField;
-
-/**
- * The default editor for editable combo boxes in the
- * JGoodies Plastic Look&Feel. <p>
- *
- * It differs from {@link javax.swing.plaf.metal.MetalComboBoxEditor} in that
- * the border is quite the same as for text fields:
- * a compound border with an inner {@code MarginBorder}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-class PlasticComboBoxEditor extends BasicComboBoxEditor {
-
- PlasticComboBoxEditor(boolean isTableCellEditor) {
- editor = new ComboBoxEditorTextField(isTableCellEditor);
- }
-
- @Override
- public void setItem(Object item) {
- super.setItem(item);
- editor.selectAll();
- }
-
-
- /**
- * A subclass of BasicComboBoxEditor that implements UIResource.
- * BasicComboBoxEditor and PlasticComboBoxEditor don't implement UIResource
- * directly so that applications can safely override the cellRenderer
- * property with BasicListCellRenderer subclasses.
- */
- static final class UIResource extends PlasticComboBoxEditor implements
- javax.swing.plaf.UIResource {
- // Just an implementation of UIResource
-
- UIResource(boolean isTableCellEditor) {
- super(isTableCellEditor);
- }
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticComboBoxUI.java b/src/core/com/jgoodies/looks/plastic/PlasticComboBoxUI.java
deleted file mode 100644
index e184bc5..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticComboBoxUI.java
+++ /dev/null
@@ -1,556 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Container;
-import java.awt.Dimension;
-import java.awt.Graphics;
-import java.awt.Insets;
-import java.awt.LayoutManager;
-import java.awt.Rectangle;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.ComboBoxEditor;
-import javax.swing.JButton;
-import javax.swing.JComboBox;
-import javax.swing.JComponent;
-import javax.swing.JScrollBar;
-import javax.swing.JTextField;
-import javax.swing.JToolBar;
-import javax.swing.ListCellRenderer;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.TextUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicComboBoxRenderer;
-import javax.swing.plaf.basic.BasicComboBoxUI;
-import javax.swing.plaf.basic.BasicComboPopup;
-import javax.swing.plaf.basic.ComboPopup;
-import javax.swing.plaf.metal.MetalComboBoxUI;
-import javax.swing.plaf.metal.MetalScrollBarUI;
-import javax.swing.plaf.metal.MetalTextFieldUI;
-
-import com.jgoodies.looks.Options;
-
-
-/**
- * The JGoodies Plastic Look and Feel implementation of {@code ComboBoxUI}.
- * Has the same height as text fields - unless you change the renderer.<p>
- *
- * Also, this class offers to use the combo's popup prototype display value
- * to compute the popup menu width. This is an optional feature of
- * the JGoodies Plastic L&fs implemented via a client property key.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.19 $
- *
- * @see Options#COMBO_POPUP_PROTOTYPE_DISPLAY_VALUE_KEY
- */
-public class PlasticComboBoxUI extends MetalComboBoxUI {
-
- static final String CELL_EDITOR_KEY = "JComboBox.isTableCellEditor";
-
- /**
- * Used to determine the minimum height of a text field,
- * which in turn is used to answer the combobox's minimum height.
- */
- private static final JTextField PHANTOM = new JTextField("Phantom");
-
- /**
- * Different Plastic L&fs may need different phantom UIs.
- * Therefore we store the LookAndFeel class and update the
- * phantom UI whenever the Look&Feel changes.
- */
- private static Class phantomLafClass;
-
-
- private boolean tableCellEditor;
- private PropertyChangeListener propertyChangeListener;
-
-
- // ************************************************************************
-
- public static ComponentUI createUI(JComponent b) {
- ensurePhantomHasPlasticUI();
- return new PlasticComboBoxUI();
- }
-
-
- /**
- * Ensures that the phantom text field has a Plastic text field UI.
- */
- private static void ensurePhantomHasPlasticUI() {
- TextUI ui = PHANTOM.getUI();
- Class lafClass = UIManager.getLookAndFeel().getClass();
- if ( (phantomLafClass != lafClass)
- || !(ui instanceof MetalTextFieldUI)) {
- phantomLafClass = lafClass;
- PHANTOM.updateUI();
- }
- }
-
-
- // ************************************************************************
-
- @Override
- public void installUI( JComponent c ) {
- super.installUI(c);
- tableCellEditor = isTableCellEditor();
- }
-
- @Override
- protected void installListeners() {
- super.installListeners();
- propertyChangeListener = new TableCellEditorPropertyChangeHandler();
- comboBox.addPropertyChangeListener(CELL_EDITOR_KEY, propertyChangeListener);
- }
-
- @Override
- protected void uninstallListeners() {
- super.uninstallListeners();
- comboBox.removePropertyChangeListener(CELL_EDITOR_KEY, propertyChangeListener);
- propertyChangeListener = null;
- }
-
-
- // Overridden Superclass Configuration ************************************
-
- /**
- * Creates and answers the arrow button that is to be used in the combo box.<p>
- *
- * Overridden to use a button that can have a pseudo 3D effect.
- */
- @Override
- protected JButton createArrowButton() {
- return new PlasticComboBoxButton(
- comboBox,
- PlasticIconFactory.getComboBoxButtonIcon(),
- comboBox.isEditable(),
- currentValuePane,
- listBox);
- }
-
- /**
- * Creates the editor that is to be used in editable combo boxes.
- * This method only gets called if a custom editor has not already
- * been installed in the JComboBox.
- */
- @Override
- protected ComboBoxEditor createEditor() {
- return new PlasticComboBoxEditor.UIResource(tableCellEditor);
- }
-
-
- /**
- * Creates a layout manager for managing the components which
- * make up the combo box.<p>
- *
- * Overriden to use a layout that has a fixed width arrow button.
- *
- * @return an instance of a layout manager
- */
- @Override
- protected LayoutManager createLayoutManager() {
- return new PlasticComboBoxLayoutManager();
- }
-
-
- @Override
- protected ComboPopup createPopup() {
- return new PlasticComboPopup(comboBox);
- }
-
-
- /**
- * Creates the default renderer that will be used in a non-editiable combo
- * box. A default renderer will used only if a renderer has not been
- * explicitly set with {@code setRenderer}.<p>
- *
- * This method differs from the superclass implementation
- * in that it uses an empty border with wider left and right margins
- * of 2 pixels instead of 1.
- *
- * @return a {@code ListCellRender} used for the combo box
- * @see javax.swing.JComboBox#setRenderer
- */
- @Override
- protected ListCellRenderer createRenderer() {
- if (tableCellEditor) {
- return super.createRenderer();
- }
- BasicComboBoxRenderer renderer = new BasicComboBoxRenderer.UIResource();
- renderer.setBorder(UIManager.getBorder("ComboBox.rendererBorder"));
- return renderer;
- }
-
-
- /**
- * The minumum size is the size of the display area plus insets plus the button.
- */
- @Override
- public Dimension getMinimumSize(JComponent c) {
- if (!isMinimumSizeDirty) {
- return new Dimension(cachedMinimumSize);
- }
- Dimension size = getDisplaySize();
- Insets insets = getInsets();
- size.height += insets.top + insets.bottom;
- if (comboBox.isEditable()) {
- Insets editorBorderInsets = UIManager.getInsets("ComboBox.editorBorderInsets");
- size.width += editorBorderInsets.left + editorBorderInsets.right;
- //size.height += editorBorderInsets.top + editorBorderInsets.bottom;
- // The combo editor benefits from extra space for the caret.
- // To make editable and non-editable equally wide,
- // we always add 1 pixel.
- size.width += 1;
- } else if (arrowButton != null) {
- Insets arrowButtonInsets = arrowButton.getInsets();
- size.width += arrowButtonInsets.left;
- }
- int buttonWidth = getEditableButtonWidth();
- size.width += insets.left + insets.right + buttonWidth;
-
- // Honor corrections made in #paintCurrentValue
- ListCellRenderer renderer = comboBox.getRenderer();
- if (renderer instanceof JComponent) {
- JComponent component = (JComponent) renderer;
- Insets rendererInsets = component.getInsets();
- Insets editorInsets = UIManager.getInsets("ComboBox.editorInsets");
- int offsetLeft = Math.max(0, editorInsets.left - rendererInsets.left);
- int offsetRight = Math.max(0, editorInsets.right - rendererInsets.right);
- // int offsetTop = Math.max(0, editorInsets.top - rendererInsets.top);
- // int offsetBottom = Math.max(0, editorInsets.bottom - rendererInsets.bottom);
- size.width += offsetLeft + offsetRight;
- //size.height += offsetTop + offsetBottom;
- }
-
- // The height is oriented on the JTextField height
- Dimension textFieldSize = PHANTOM.getMinimumSize();
- size.height = Math.max(textFieldSize.height, size.height);
-
- cachedMinimumSize.setSize(size.width, size.height);
- isMinimumSizeDirty = false;
-
- return new Dimension(size);
- }
-
-
- /**
- * Delegates to #getMinimumSize(Component).
- * Overridden to return the same result in JDK 1.5 as in JDK 1.4.
- */
- @Override
- public Dimension getPreferredSize(JComponent c) {
- return getMinimumSize(c);
- }
-
-
- /**
- * Returns the area that is reserved for drawing the currently selected item.
- */
- @Override
- protected Rectangle rectangleForCurrentValue() {
- int width = comboBox.getWidth();
- int height = comboBox.getHeight();
- Insets insets = getInsets();
- int buttonWidth = getEditableButtonWidth();
- if (arrowButton != null) {
- buttonWidth = arrowButton.getWidth();
- }
- if (comboBox.getComponentOrientation().isLeftToRight()) {
- return new Rectangle(
- insets.left,
- insets.top,
- width - (insets.left + insets.right + buttonWidth),
- height - (insets.top + insets.bottom));
- }
- return new Rectangle(
- insets.left + buttonWidth,
- insets.top ,
- width - (insets.left + insets.right + buttonWidth),
- height - (insets.top + insets.bottom));
- }
-
-
- // Painting ***************************************************************
-
- @Override
- public void update(Graphics g, JComponent c) {
- if (c.isOpaque()) {
- g.setColor(c.getBackground());
- g.fillRect(0, 0, c.getWidth(), c.getHeight());
- if (isToolBarComboBox(c)) {
- c.setOpaque(false);
- } }
- paint(g, c);
- }
-
-
- /**
- * Checks and answers if this combo is in a tool bar.
- *
- * @param c the component to check
- * @return true if in tool bar, false otherwise
- */
- protected boolean isToolBarComboBox(JComponent c) {
- Container parent = c.getParent();
- return parent != null
- && (parent instanceof JToolBar
- || parent.getParent() instanceof JToolBar);
- }
-
-
- // Helper Code ************************************************************
-
- /**
- * Computes and returns the width of the arrow button in editable state.
- * The perceived width shall be equal to the width of a scroll bar.
- * Therefore we subtract a pixel that is perceived as part of the
- * arrow button but that is painted by the editor's border.
- *
- * @return the width of the arrow button in editable state
- */
- static int getEditableButtonWidth() {
- return UIManager.getInt("ScrollBar.width") - 1;
- }
-
-
- /**
- * Checks and answers if this UI's combo has a client property
- * that indicates that the combo is used as a table cell editor.
- *
- * @return {@code true} if the table cell editor client property
- * is set to {@code Boolean.TRUE}, {@code false} otherwise
- */
- private boolean isTableCellEditor() {
- return Boolean.TRUE.equals(comboBox.getClientProperty(CELL_EDITOR_KEY));
- }
-
-
- // Helper Classes *********************************************************
-
- /**
- * This layout manager handles the 'standard' layout of combo boxes.
- * It puts the arrow button to the right and the editor to the left.
- * If there is no editor it still keeps the arrow button to the right.
- *
- * Overriden to use a fixed arrow button width.
- */
- private final class PlasticComboBoxLayoutManager
- extends MetalComboBoxUI.MetalComboBoxLayoutManager {
-
- @Override
- public void layoutContainer(Container parent) {
- JComboBox cb = (JComboBox) parent;
-
- // Use superclass behavior if the combobox is not editable.
- if (!cb.isEditable()) {
- super.layoutContainer(parent);
- return;
- }
-
- int width = cb.getWidth();
- int height = cb.getHeight();
-
- Insets insets = getInsets();
- int buttonWidth = getEditableButtonWidth();
- int buttonHeight = height - (insets.top + insets.bottom);
-
- if (arrowButton != null) {
- if (cb.getComponentOrientation().isLeftToRight()) {
- arrowButton.setBounds(
- width - (insets.right + buttonWidth),
- insets.top,
- buttonWidth,
- buttonHeight);
- } else {
- arrowButton.setBounds(
- insets.left,
- insets.top,
- buttonWidth,
- buttonHeight);
- }
- }
- if (editor != null) {
- editor.setBounds(rectangleForCurrentValue());
- }
- }
- }
-
- // Required if we have a combobox button that does not extend MetalComboBoxButton
- @Override
- public PropertyChangeListener createPropertyChangeListener() {
- return new PlasticPropertyChangeListener();
- }
-
- /**
- * Overriden to use PlasticComboBoxButton instead of a MetalComboBoxButton.
- * Required if we have a combobox button that does not extend MetalComboBoxButton
- */
- private final class PlasticPropertyChangeListener
- extends BasicComboBoxUI.PropertyChangeHandler {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- super.propertyChange(e);
- String propertyName = e.getPropertyName();
-
- if (propertyName.equals("editable")) {
- PlasticComboBoxButton button =
- (PlasticComboBoxButton) arrowButton;
- button.setIconOnly(comboBox.isEditable());
- comboBox.repaint();
- } else if (propertyName.equals("background")) {
- Color color = (Color) e.getNewValue();
- arrowButton.setBackground(color);
- listBox.setBackground(color);
-
- } else if (propertyName.equals("foreground")) {
- Color color = (Color) e.getNewValue();
- arrowButton.setForeground(color);
- listBox.setForeground(color);
- }
- }
- }
-
- /**
- * Differs from the BasicComboPopup in that it uses the standard
- * popmenu border and honors an optional popup prototype display value.
- */
- private static final class PlasticComboPopup extends BasicComboPopup {
-
- private PlasticComboPopup(JComboBox combo) {
- super(combo);
- }
-
- /**
- * Configures the list created by #createList().
- */
- @Override
- protected void configureList() {
- super.configureList();
- list.setForeground(UIManager.getColor("MenuItem.foreground"));
- list.setBackground(UIManager.getColor("MenuItem.background"));
- }
-
- /**
- * Configures the JScrollPane created by #createScroller().
- */
- @Override
- protected void configureScroller() {
- super.configureScroller();
- scroller.getVerticalScrollBar().putClientProperty(
- MetalScrollBarUI.FREE_STANDING_PROP,
- Boolean.FALSE);
- }
-
- /**
- * Calculates the placement and size of the popup portion
- * of the combo box based on the combo box location and
- * the enclosing screen bounds. If no transformations are required,
- * then the returned rectangle will have the same values
- * as the parameters.<p>
- *
- * In addition to the superclass behavior, this class offers
- * to use the combo's popup prototype display value to compute
- * the popup menu width. This is an optional feature of the
- * JGoodies Plastic L&fs implemented via a client property key.<p>
- *
- * If a prototype is set, the popup width is the maximum of the
- * combobox width and the prototype based popup width.
- * For the latter the renderer is used to render the prototype.
- * The prototype based popup width is the prototype's width
- * plus the scrollbar width - if any. The scrollbar test checks
- * if there are more items than the combo's maximum row count.
- *
- * @param px starting x location
- * @param py starting y location
- * @param pw starting width
- * @param ph starting height
- * @return a rectangle which represents the placement and size of the popup
- *
- * @see Options#COMBO_POPUP_PROTOTYPE_DISPLAY_VALUE_KEY
- * @see JComboBox#getMaximumRowCount()
- */
- @Override
- protected Rectangle computePopupBounds(int px, int py, int pw, int ph) {
- Rectangle defaultBounds = super.computePopupBounds(px, py, pw, ph);
- Object popupPrototypeDisplayValue = comboBox.getClientProperty(
- Options.COMBO_POPUP_PROTOTYPE_DISPLAY_VALUE_KEY);
- if (popupPrototypeDisplayValue == null) {
- return defaultBounds;
- }
-
- ListCellRenderer renderer = list.getCellRenderer();
- Component c = renderer.getListCellRendererComponent(
- list, popupPrototypeDisplayValue, -1, true, true);
- pw = c.getPreferredSize().width;
- boolean hasVerticalScrollBar =
- comboBox.getItemCount() > comboBox.getMaximumRowCount();
- if (hasVerticalScrollBar) {
- // Add the scrollbar width.
- JScrollBar verticalBar = scroller.getVerticalScrollBar();
- pw += verticalBar.getPreferredSize().width;
- }
- Rectangle prototypeBasedBounds = super.computePopupBounds(px, py, pw, ph);
- return prototypeBasedBounds.width > defaultBounds.width
- ? prototypeBasedBounds
- : defaultBounds;
- }
-
- }
-
-
- // Handling Combo Changes *************************************************
-
- /**
- * Listens to changes in the table cell editor client property
- * and updates the default editor - if any - to use the correct
- * insets for this case.
- */
- private final class TableCellEditorPropertyChangeHandler implements PropertyChangeListener {
- @Override
- public void propertyChange(PropertyChangeEvent evt) {
- tableCellEditor = isTableCellEditor();
- if (comboBox.getRenderer() == null || comboBox.getRenderer() instanceof UIResource) {
- comboBox.setRenderer(createRenderer());
- }
- if (comboBox.getEditor() == null || comboBox.getEditor() instanceof UIResource) {
- comboBox.setEditor(createEditor());
- }
- }
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticFieldCaret.java b/src/core/com/jgoodies/looks/plastic/PlasticFieldCaret.java
deleted file mode 100644
index 83c7c15..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticFieldCaret.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.EventQueue;
-import java.awt.event.FocusEvent;
-import java.awt.event.MouseEvent;
-
-import javax.swing.JFormattedTextField;
-import javax.swing.SwingUtilities;
-import javax.swing.plaf.UIResource;
-import javax.swing.text.DefaultCaret;
-import javax.swing.text.JTextComponent;
-
-import com.jgoodies.looks.Options;
-
-/**
- * PlasticFieldCaret is visible in non-editable fields,
- * and the text is selected after a keyboard focus gained event.
- * For the latter see also issue #4337647 in Sun's bug database.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.13 $
- */
-final class PlasticFieldCaret extends DefaultCaret implements UIResource {
-
- PlasticFieldCaret() {
- super();
- }
-
-
- private boolean isKeyboardFocusEvent = true;
-
-
- @Override
- public void focusGained(FocusEvent e) {
- final JTextComponent c = getComponent();
- if (c == null) {
- return;
- }
- if (c.isEnabled()) {
- setVisible(true);
- setSelectionVisible(true);
- }
- if ( !c.isEnabled()
- || !isKeyboardFocusEvent
- || !Options.isSelectOnFocusGainActive(c)) {
- return;
- }
- if (c instanceof JFormattedTextField) {
- EventQueue.invokeLater(new Runnable() {
- @Override
- public void run() {
- selectAll();
- }
- });
- } else {
- selectAll();
- }
-}
-
-
- private void selectAll() {
- final JTextComponent c = getComponent();
- if (c == null) {
- return;
- }
- boolean backward = Boolean.TRUE.equals(c.getClientProperty(Options.INVERT_SELECTION_CLIENT_KEY));
- if (backward) {
- setDot(c.getDocument().getLength());
- moveDot(0);
- } else {
- setDot(0);
- moveDot(c.getDocument().getLength());
- }
- }
-
-
- @Override
- public void focusLost(FocusEvent e) {
- super.focusLost(e);
- if (!e.isTemporary()) {
- isKeyboardFocusEvent = true;
- if ( getComponent() != null
- && Boolean.TRUE.equals(getComponent().getClientProperty(Options.SET_CARET_TO_START_ON_FOCUS_LOST_CLIENT_KEY))) {
- setDot(0);
- }
- }
- }
-
-
- @Override
- public void mousePressed(MouseEvent e) {
- if (SwingUtilities.isLeftMouseButton(e) || e.isPopupTrigger()) {
- isKeyboardFocusEvent = false;
- }
- super.mousePressed(e);
-
- }
-
-
- @Override
- public void mouseReleased(MouseEvent e) {
- super.mouseReleased(e);
- if (e.isPopupTrigger()) {
- isKeyboardFocusEvent = false;
- if ( getComponent() != null
- && getComponent().isEnabled()
- && getComponent().isRequestFocusEnabled()) {
- getComponent().requestFocus();
- }
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticFileChooserUI.java b/src/core/com/jgoodies/looks/plastic/PlasticFileChooserUI.java
deleted file mode 100644
index b976d46..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticFileChooserUI.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.io.File;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.JFileChooser;
-import javax.swing.UIManager;
-import javax.swing.filechooser.FileSystemView;
-import javax.swing.filechooser.FileView;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalFileChooserUI;
-
-
-/**
- * The JGoodies Plastic L&F implementation of {@code FileChooserUI}.
- * Uses {@link FileSystemView#getSystemIcon(File)} to look up icons for files.<p>
- *
- * Thanks to Andrej Golovnin for his feedback and suggestions.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.7 $
- *
- * @see FileSystemView#getSystemIcon(File)
- */
-public final class PlasticFileChooserUI extends MetalFileChooserUI {
-
- private final BasicFileView fileView = new SystemIconFileView();
-
-
- public static ComponentUI createUI(JComponent c) {
- return new PlasticFileChooserUI((JFileChooser) c);
- }
-
-
- public PlasticFileChooserUI(JFileChooser fileChooser) {
- super(fileChooser);
- }
-
-
- @Override
- public void clearIconCache() {
- fileView.clearIconCache();
- }
-
-
- @Override
- public FileView getFileView(JFileChooser fc) {
- return fileView;
- }
-
-
- /**
- * Unlike its superclass, this class can look up and cache
- * the system icon from the file chooser's file system view.
- */
- private final class SystemIconFileView extends BasicFileView {
-
- @Override
- public Icon getIcon(File f) {
- Icon icon = getCachedIcon(f);
- if (icon != null) {
- return icon;
- }
- if (f != null && UIManager.getBoolean("FileChooser.useSystemIcons")) {
- icon = getFileChooser().getFileSystemView().getSystemIcon(f);
- }
- if (icon == null) {
- return super.getIcon(f);
- }
- cacheIcon(f, icon);
- return icon;
- }
-
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticFormattedTextFieldUI.java b/src/core/com/jgoodies/looks/plastic/PlasticFormattedTextFieldUI.java
deleted file mode 100644
index d543879..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticFormattedTextFieldUI.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicFormattedTextFieldUI;
-import javax.swing.text.Caret;
-
-
-/**
- * The JGoodies Plastic L&F implementation of {@code TextFieldUI}.
- * In addition to its superclass MetalTextFieldUI, it can use a caret
- * that selects all text when the field gains focus via the keyboard.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class PlasticFormattedTextFieldUI extends BasicFormattedTextFieldUI {
-
- /**
- * Creates a UI for a JFormattedTextField.
- *
- * @param c the formatted text field
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new PlasticFormattedTextFieldUI();
- }
-
-
- /**
- * Creates the caret for a field.
- *
- * @return the caret
- */
- @Override
- protected Caret createCaret() {
- return new PlasticFieldCaret();
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticIconFactory.java b/src/core/com/jgoodies/looks/plastic/PlasticIconFactory.java
deleted file mode 100644
index 964efa3..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticIconFactory.java
+++ /dev/null
@@ -1,363 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Graphics;
-import java.io.Serializable;
-
-import javax.swing.*;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-
-/**
- * Factory class that vends {@code Icon}s for the
- * JGoodies Plastic look and feel.
- * These icons are used extensively in Plastic via the defaults mechanism.
- * While other look and feels often use GIFs for icons, creating icons
- * in code facilitates switching to other themes.
- * <p>
- * Each method in this class returns either an {@code Icon} or {@code null},
- * where {@code null} implies that there is no default icon.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-
-final class PlasticIconFactory {
-
-
- private PlasticIconFactory() {
- // Overrides default constructor; prevents instantiation.
- }
-
-
- // Helper method utilized by the CheckBoxIcon and the CheckBoxMenuItemIcon.
- private static void drawCheck(Graphics g, int x, int y) {
- g.translate(x, y);
- g.drawLine(3, 5, 3, 5);
- g.fillRect(3, 6, 2, 2);
- g.drawLine(4, 8, 9, 3);
- g.drawLine(5, 8, 9, 4);
- g.drawLine(5, 9, 9, 5);
- g.translate(-x, -y);
- }
-
-
- private static class CheckBoxIcon implements Icon, UIResource, Serializable {
-
- private static final int SIZE = 13;
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- JCheckBox cb = (JCheckBox) c;
- ButtonModel model = cb.getModel();
-
- if (model.isEnabled()) {
- if (cb.isBorderPaintedFlat()) {
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawRect(x, y, SIZE - 2, SIZE - 2);
- // inside box
- g.setColor(PlasticLookAndFeel.getControlHighlight());
- g.fillRect(x+1, y+1, SIZE-3, SIZE-3);
- } else if (model.isPressed() && model.isArmed()) {
- g.setColor(MetalLookAndFeel.getControlShadow());
- g.fillRect(x, y, SIZE - 1, SIZE - 1);
- PlasticUtils.drawPressed3DBorder(g, x, y, SIZE, SIZE);
- } else {
- PlasticUtils.drawFlush3DBorder(g, x, y, SIZE, SIZE);
- }
- g.setColor(MetalLookAndFeel.getControlInfo());
- } else {
- g.setColor(MetalLookAndFeel.getControlShadow());
- g.drawRect(x, y, SIZE - 2, SIZE - 2);
- }
-
- if (model.isSelected()) {
- drawCheck(g, x, y);
- }
- }
-
- }
-
-
- private static class CheckBoxMenuItemIcon implements Icon, UIResource, Serializable {
-
- private static final int SIZE = 13;
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- JMenuItem b = (JMenuItem) c;
- if (b.isSelected()) {
- drawCheck(g, x, y + 1);
- }
- }
- }
-
-
- private static class RadioButtonMenuItemIcon implements Icon, UIResource, Serializable {
-
- private static final int SIZE = 13;
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- JMenuItem b = (JMenuItem) c;
- if (b.isSelected()) {
- drawDot(g, x, y);
- }
- }
-
- private static void drawDot(Graphics g, int x, int y) {
- g.translate(x, y);
- g.drawLine(5, 4, 8, 4);
- g.fillRect(4, 5, 6, 4);
- g.drawLine(5, 9, 8, 9);
- g.translate(-x, -y);
- }
- }
-
-
- private static class MenuArrowIcon implements Icon, UIResource, Serializable {
-
- private static final int WIDTH = 4;
- private static final int HEIGHT = 8;
-
- @Override
- public void paintIcon( Component c, Graphics g, int x, int y ) {
- JMenuItem b = (JMenuItem) c;
-
- g.translate( x, y );
- if (PlasticUtils.isLeftToRight(b) ) {
- g.drawLine( 0, 0, 0, 7 );
- g.drawLine( 1, 1, 1, 6 );
- g.drawLine( 2, 2, 2, 5 );
- g.drawLine( 3, 3, 3, 4 );
- } else {
- g.drawLine( 4, 0, 4, 7 );
- g.drawLine( 3, 1, 3, 6 );
- g.drawLine( 2, 2, 2, 5 );
- g.drawLine( 1, 3, 1, 4 );
- }
- g.translate( -x, -y );
- }
-
- @Override
- public int getIconWidth() { return WIDTH; }
- @Override
- public int getIconHeight() { return HEIGHT; }
-
- }
-
-
- /**
- * Paints a minus sign button icon used in trees.
- * Uses a white background, gray border, and black foreground.
- */
- private static class ExpandedTreeIcon implements Icon, Serializable {
-
- protected static final int SIZE = 9;
- protected static final int HALF_SIZE = 4;
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- g.setColor(Color.WHITE);
- g.fillRect(x, y, SIZE - 1, SIZE - 1);
- g.setColor(Color.GRAY);
- g.drawRect(x, y, SIZE - 1, SIZE - 1);
- g.setColor(Color.BLACK);
- g.drawLine(x + 2, y + HALF_SIZE, x + SIZE - 3, y + HALF_SIZE);
- }
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
- }
-
-
- /**
- * The plus sign button icon used in trees.
- */
- private static class CollapsedTreeIcon extends ExpandedTreeIcon {
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- super.paintIcon(c, g, x, y);
- g.drawLine(x + HALF_SIZE, y + 2, x + HALF_SIZE, y + SIZE - 3);
- }
- }
-
-
- /**
- * The arrow button used in comboboxes.
- */
- private static class ComboBoxButtonIcon implements Icon, Serializable {
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- JComponent component = (JComponent) c;
- int iconWidth = getIconWidth();
-
- g.translate(x, y);
-
- g.setColor( component.isEnabled()
- ? MetalLookAndFeel.getControlInfo()
- : MetalLookAndFeel.getControlShadow() );
- g.drawLine( 0, 0, iconWidth - 1, 0 );
- g.drawLine( 1, 1, 1 + iconWidth - 3, 1 );
- g.drawLine( 2, 2, 2 + iconWidth - 5, 2 );
- g.drawLine( 3, 3, 3 + iconWidth - 7, 3 );
-
-/*
- int startY = (((h + 1) - arrowHeight) / 2) + arrowHeight - 1;
- int startX = (w / 2);
-
- // System.out.println( "startX2 :" + startX + " startY2 :"+startY);
-
- for (int line = 0; line < arrowHeight; line++) {
- g.drawLine(
- startX - line,
- startY - line,
- startX + line + 1,
- startY - line);
- }*/
- g.translate( -x, -y );
- }
-
- @Override
- public int getIconWidth() { return 8; }
- @Override
- public int getIconHeight() { return 4; }
- }
-
-
- // Cached Access to Icons ***********************************************************
-
- private static Icon checkBoxIcon;
- private static Icon checkBoxMenuItemIcon;
- private static Icon radioButtonMenuItemIcon;
- private static Icon menuArrowIcon;
- private static Icon expandedTreeIcon;
- private static Icon collapsedTreeIcon;
- private static Icon comboBoxButtonIcon;
-
-
- /**
- * Answers an {@code Icon} used for {@code JCheckBox}es.
- */
- static Icon getCheckBoxIcon() {
- if (checkBoxIcon == null) {
- checkBoxIcon = new CheckBoxIcon();
- }
- return checkBoxIcon;
- }
-
-
- /**
- * Answers an {@code Icon} used for {@code JCheckButtonMenuItem}s.
- */
- static Icon getCheckBoxMenuItemIcon() {
- if (checkBoxMenuItemIcon == null) {
- checkBoxMenuItemIcon = new CheckBoxMenuItemIcon();
- }
- return checkBoxMenuItemIcon;
- }
-
-
- /**
- * Answers an {@code Icon} used for {@code JRadioButtonMenuItem}s.
- */
- static Icon getRadioButtonMenuItemIcon() {
- if (radioButtonMenuItemIcon == null) {
- radioButtonMenuItemIcon = new RadioButtonMenuItemIcon();
- }
- return radioButtonMenuItemIcon;
- }
-
-
- /**
- * Answers an {@code Icon} used for arrows in {@code JMenu}s.
- */
- static Icon getMenuArrowIcon() {
- if (menuArrowIcon == null) {
- menuArrowIcon = new MenuArrowIcon();
- }
- return menuArrowIcon;
- }
-
-
- /**
- * Answers an {@code Icon} used in {@code JTree}s.
- */
- static Icon getExpandedTreeIcon() {
- if (expandedTreeIcon == null) {
- expandedTreeIcon = new ExpandedTreeIcon();
- }
- return expandedTreeIcon;
- }
-
- /**
- * Answers an {@code Icon} used in {@code JTree}s.
- */
- static Icon getCollapsedTreeIcon() {
- if (collapsedTreeIcon == null) {
- collapsedTreeIcon = new CollapsedTreeIcon();
- }
- return collapsedTreeIcon;
- }
-
- /**
- * Answers an {@code Icon} used in {@code JComboBox}es.
- */
- static Icon getComboBoxButtonIcon() {
- if (comboBoxButtonIcon == null) {
- comboBoxButtonIcon = new ComboBoxButtonIcon();
- }
- return comboBoxButtonIcon;
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticInternalFrameTitlePane.java b/src/core/com/jgoodies/looks/plastic/PlasticInternalFrameTitlePane.java
deleted file mode 100644
index 994f4ea..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticInternalFrameTitlePane.java
+++ /dev/null
@@ -1,313 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.*;
-
-import javax.swing.Icon;
-import javax.swing.JInternalFrame;
-import javax.swing.SwingUtilities;
-import javax.swing.plaf.metal.MetalInternalFrameTitlePane;
-
-/**
- * Paints the internal frame title. Uses JGoodies Plastic colors.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class PlasticInternalFrameTitlePane
- extends MetalInternalFrameTitlePane {
-
- private PlasticBumps paletteBumps;
-
- private final PlasticBumps activeBumps =
- new PlasticBumps(
- 0,
- 0,
- PlasticLookAndFeel.getPrimaryControlHighlight(),
- PlasticLookAndFeel.getPrimaryControlDarkShadow(),
- PlasticLookAndFeel.getPrimaryControl());
-
- private final PlasticBumps inactiveBumps =
- new PlasticBumps(
- 0,
- 0,
- PlasticLookAndFeel.getControlHighlight(),
- PlasticLookAndFeel.getControlDarkShadow(),
- PlasticLookAndFeel.getControl());
-
- public PlasticInternalFrameTitlePane(JInternalFrame frame) {
- super(frame);
- }
-
- @Override
- public void paintPalette(Graphics g) {
- boolean leftToRight = PlasticUtils.isLeftToRight(frame);
-
- int width = getWidth();
- int height = getHeight();
-
- if (paletteBumps == null) {
- paletteBumps =
- new PlasticBumps(
- 0,
- 0,
- PlasticLookAndFeel.getPrimaryControlHighlight(),
- PlasticLookAndFeel.getPrimaryControlInfo(),
- PlasticLookAndFeel.getPrimaryControlShadow());
- }
-
- Color background = PlasticLookAndFeel.getPrimaryControlShadow();
- Color darkShadow = PlasticLookAndFeel.getControlDarkShadow();
-
- g.setColor(background);
- g.fillRect(0, 0, width, height);
-
- g.setColor(darkShadow);
- g.drawLine(0, height - 1, width, height - 1);
-
- int buttonsWidth = getButtonsWidth();
- int xOffset = leftToRight ? 4 : buttonsWidth + 4;
- int bumpLength = width - buttonsWidth - 2 * 4;
- int bumpHeight = getHeight() - 4;
- paletteBumps.setBumpArea(bumpLength, bumpHeight);
- paletteBumps.paintIcon(this, g, xOffset, 2);
- }
-
- @Override
- public void paintComponent(Graphics g) {
- if (isPalette) {
- paintPalette(g);
- return;
- }
-
- boolean leftToRight = PlasticUtils.isLeftToRight(frame);
- boolean isSelected = frame.isSelected();
-
- int width = getWidth();
- int height = getHeight();
-
- Color background = null;
- Color foreground = null;
- Color shadow = null;
-
- PlasticBumps bumps;
-
- if (isSelected) {
- background = PlasticLookAndFeel.getWindowTitleBackground();
- foreground = PlasticLookAndFeel.getWindowTitleForeground();
- bumps = activeBumps;
- } else {
- background = PlasticLookAndFeel.getWindowTitleInactiveBackground();
- foreground = PlasticLookAndFeel.getWindowTitleInactiveForeground();
- bumps = inactiveBumps;
- }
- // JGoodies: darkShadow is always controlDarkShadow
- shadow = PlasticLookAndFeel.getControlDarkShadow();
-
- /*
-
- if (isSelected) {
- if (selectedBackgroundKey != null) {
- background = UIManager.getColor(selectedBackgroundKey);
- }
- if (background == null) {
- background = PlasticLookAndFeel.getWindowTitleBackground();
- }
- if (selectedForegroundKey != null) {
- foreground = UIManager.getColor(selectedForegroundKey);
- }
- if (selectedShadowKey != null) {
- shadow = UIManager.getColor(selectedShadowKey);
- }
- if (shadow == null) {
- shadow = PlasticLookAndFeel.getPrimaryControlDarkShadow();
- }
- if (foreground == null) {
- foreground = PlasticLookAndFeel.getWindowTitleForeground();
- }
- activeBumps.setBumpColors(activeBumpsHighlight, activeBumpsShadow,
- background);
- bumps = activeBumps;
- } else {
- background = PlasticLookAndFeel.getWindowTitleInactiveBackground();
- foreground = PlasticLookAndFeel.getWindowTitleInactiveForeground();
- shadow = PlasticLookAndFeel.getControlDarkShadow();
- bumps = inactiveBumps;
- }
- */
- g.setColor(background);
- g.fillRect(0, 0, width, height);
-
- g.setColor(shadow);
- g.drawLine(0, height - 1, width, height - 1);
- g.drawLine(0, 0, 0, 0);
- g.drawLine(width - 1, 0, width - 1, 0);
-
- int titleLength = 0;
- int xOffset = leftToRight ? 5 : width - 5;
- String frameTitle = frame.getTitle();
-
- Icon icon = frame.getFrameIcon();
- if (icon != null) {
- if (!leftToRight) {
- xOffset -= icon.getIconWidth();
- }
- int iconY = ((height / 2) - (icon.getIconHeight() / 2));
- icon.paintIcon(frame, g, xOffset, iconY);
- xOffset += leftToRight ? icon.getIconWidth() + 5 : -5;
- }
-
- if (frameTitle != null) {
- Font f = getFont();
- g.setFont(f);
- FontMetrics fm = g.getFontMetrics();
- //int fHeight = fm.getHeight();
-
- g.setColor(foreground);
-
- int yOffset = ((height - fm.getHeight()) / 2) + fm.getAscent();
-
- Rectangle rect = new Rectangle(0, 0, 0, 0);
- if (frame.isIconifiable()) {
- rect = iconButton.getBounds();
- } else if (frame.isMaximizable()) {
- rect = maxButton.getBounds();
- } else if (frame.isClosable()) {
- rect = closeButton.getBounds();
- }
- int titleW;
-
- if (leftToRight) {
- if (rect.x == 0) {
- rect.x = frame.getWidth() - frame.getInsets().right - 2;
- }
- titleW = rect.x - xOffset - 4;
- frameTitle = getTitle(frameTitle, fm, titleW);
- } else {
- titleW = xOffset - rect.x - rect.width - 4;
- frameTitle = getTitle(frameTitle, fm, titleW);
- xOffset -= SwingUtilities.computeStringWidth(fm, frameTitle);
- }
-
- titleLength = SwingUtilities.computeStringWidth(fm, frameTitle);
- g.drawString(frameTitle, xOffset, yOffset);
- xOffset += leftToRight ? titleLength + 5 : -5;
- }
-
- int bumpXOffset;
- int bumpLength;
- int buttonsWidth = getButtonsWidth();
- if (leftToRight) {
- bumpLength = width - buttonsWidth - xOffset - 5;
- bumpXOffset = xOffset;
- } else {
- bumpLength = xOffset - buttonsWidth - 5;
- bumpXOffset = buttonsWidth + 5;
- }
- int bumpYOffset = 3;
- int bumpHeight = getHeight() - (2 * bumpYOffset);
- bumps.setBumpArea(bumpLength, bumpHeight);
- bumps.paintIcon(this, g, bumpXOffset, bumpYOffset);
- }
-
- @Override
- protected String getTitle(
- String text,
- FontMetrics fm,
- int availTextWidth) {
- if ((text == null) || (text.equals(""))) {
- return "";
- }
- int textWidth = SwingUtilities.computeStringWidth(fm, text);
- String clipString = "\u2026";
- if (textWidth > availTextWidth) {
- int totalWidth = SwingUtilities.computeStringWidth(fm, clipString);
- int nChars;
- for (nChars = 0; nChars < text.length(); nChars++) {
- totalWidth += fm.charWidth(text.charAt(nChars));
- if (totalWidth > availTextWidth) {
- break;
- }
- }
- text = text.substring(0, nChars) + clipString;
- }
- return text;
- }
-
- private int getButtonsWidth() {
- boolean leftToRight = PlasticUtils.isLeftToRight(frame);
-
- int w = getWidth();
- int x = leftToRight ? w : 0;
- int spacing;
-
- // assumes all buttons have the same dimensions
- // these dimensions include the borders
- int buttonWidth = closeButton.getIcon().getIconWidth();
-
- if (frame.isClosable()) {
- if (isPalette) {
- spacing = 3;
- x += leftToRight ? -spacing - (buttonWidth + 2) : spacing;
- if (!leftToRight) {
- x += (buttonWidth + 2);
- }
- } else {
- spacing = 4;
- x += leftToRight ? -spacing - buttonWidth : spacing;
- if (!leftToRight) {
- x += buttonWidth;
- }
- }
- }
-
- if (frame.isMaximizable() && !isPalette) {
- spacing = frame.isClosable() ? 10 : 4;
- x += leftToRight ? -spacing - buttonWidth : spacing;
- if (!leftToRight) {
- x += buttonWidth;
- }
- }
-
- if (frame.isIconifiable() && !isPalette) {
- spacing =
- frame.isMaximizable() ? 2 : (frame.isClosable() ? 10 : 4);
- x += leftToRight ? -spacing - buttonWidth : spacing;
- if (!leftToRight) {
- x += buttonWidth;
- }
- }
-
- return leftToRight ? w - x : x;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticInternalFrameUI.java b/src/core/com/jgoodies/looks/plastic/PlasticInternalFrameUI.java
deleted file mode 100644
index e2bd777..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticInternalFrameUI.java
+++ /dev/null
@@ -1,224 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Container;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.JComponent;
-import javax.swing.JInternalFrame;
-import javax.swing.LookAndFeel;
-import javax.swing.UIManager;
-import javax.swing.border.Border;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicInternalFrameUI;
-
-
-/**
- * The JGoodies Plastic Look and Feel implementation of {@code InternalFrameUI}.<p>
- *
- * Uses a {@code PlasticInternalFrameTitlePane}
- * that in turn uses {@code PlasticTheme} colors.<p>
- *
- * Although this class is not intended for subclassing, there's no final marker.
- * If you extend this class, carefully obey all explicit and implicit
- * constraints made in this class and its superclasses.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public class PlasticInternalFrameUI extends BasicInternalFrameUI {
-
-
- private static final String FRAME_TYPE = "JInternalFrame.frameType";
- public static final String IS_PALETTE = "JInternalFrame.isPalette";
- private static final String PALETTE_FRAME = "palette";
- private static final String OPTION_DIALOG = "optionDialog";
- private static final Border EMPTY_BORDER = new EmptyBorder(0, 0, 0, 0);
-
-
- private PlasticInternalFrameTitlePane titlePane;
- private PropertyChangeListener paletteListener;
- private PropertyChangeListener contentPaneListener;
-
-
- public PlasticInternalFrameUI(JInternalFrame b) {
- super(b);
- }
-
-
- public static ComponentUI createUI(JComponent c) {
- return new PlasticInternalFrameUI((JInternalFrame) c);
- }
-
-
- @Override
- public void installUI(JComponent c) {
- frame = (JInternalFrame) c;
-
- paletteListener = new PaletteListener (this);
- contentPaneListener = new ContentPaneListener();
- c.addPropertyChangeListener(paletteListener);
- c.addPropertyChangeListener(contentPaneListener);
-
- super.installUI(c);
-
- Object paletteProp = c.getClientProperty(IS_PALETTE);
- if (paletteProp != null) {
- setPalette(((Boolean) paletteProp).booleanValue());
- }
-
- Container content = frame.getContentPane();
- stripContentBorder(content);
- }
-
-
- @Override
- public void uninstallUI(JComponent c) {
- frame = (JInternalFrame) c;
-
- c.removePropertyChangeListener(paletteListener);
- c.removePropertyChangeListener(contentPaneListener);
-
- Container cont = ((JInternalFrame) c).getContentPane();
- if (cont instanceof JComponent) {
- JComponent content = (JComponent) cont;
- if (content.getBorder() == EMPTY_BORDER) {
- content.setBorder(null);
- }
- }
- super.uninstallUI(c);
- }
-
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
-
- /* Enable the content pane to inherit background color
- * from its parent by setting its background color to null.
- * Fixes bug#4268949, which has been fixed in 1.4, too. */
- JComponent contentPane = (JComponent) frame.getContentPane();
- if (contentPane != null) {
- Color bg = contentPane.getBackground();
- if (bg instanceof UIResource) {
- contentPane.setBackground(null);
- }
- }
- frame.setBackground(UIManager.getLookAndFeelDefaults().getColor("control"));
- }
-
-
- @Override
- protected void installKeyboardActions() {
- }
-
- @Override
- protected void uninstallKeyboardActions() {
- }
-
-
- private static void stripContentBorder(Object c) {
- if (c instanceof JComponent) {
- JComponent contentComp = (JComponent) c;
- Border contentBorder = contentComp.getBorder();
- if (contentBorder == null || contentBorder instanceof UIResource) {
- contentComp.setBorder(EMPTY_BORDER);
- }
- }
- }
-
-
- @Override
- protected JComponent createNorthPane(JInternalFrame w) {
- titlePane = new PlasticInternalFrameTitlePane(w);
- return titlePane;
- }
-
-
- public void setPalette(boolean isPalette) {
- String key = isPalette ? "InternalFrame.paletteBorder" : "InternalFrame.border";
- LookAndFeel.installBorder(frame, key);
- titlePane.setPalette(isPalette);
- }
-
-
- private void setFrameType(String frameType) {
- String key;
- boolean hasPalette = frameType.equals(PALETTE_FRAME);
- if (frameType.equals(OPTION_DIALOG)) {
- key = "InternalFrame.optionDialogBorder";
- } else if (hasPalette) {
- key = "InternalFrame.paletteBorder";
- } else {
- key = "InternalFrame.border";
- }
- LookAndFeel.installBorder(frame, key);
- titlePane.setPalette(hasPalette);
- }
-
-
- private static final class PaletteListener implements PropertyChangeListener {
-
- private final PlasticInternalFrameUI ui;
-
- private PaletteListener(PlasticInternalFrameUI ui) { this.ui = ui; }
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String name = e.getPropertyName();
- Object value = e.getNewValue();
- if (name.equals(FRAME_TYPE)) {
- if (value instanceof String) {
- ui.setFrameType((String) value);
- }
- } else if (name.equals(IS_PALETTE)) {
- ui.setPalette(Boolean.TRUE.equals(value));
- }
- }
- }
-
- private static final class ContentPaneListener implements PropertyChangeListener {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String name = e.getPropertyName();
- if (name.equals(JInternalFrame.CONTENT_PANE_PROPERTY)) {
- PlasticInternalFrameUI.stripContentBorder(e.getNewValue());
- }
- }
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticLookAndFeel.java b/src/core/com/jgoodies/looks/plastic/PlasticLookAndFeel.java
deleted file mode 100644
index 19f99a1..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticLookAndFeel.java
+++ /dev/null
@@ -1,1029 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Insets;
-import java.awt.Toolkit;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.UIDefaults;
-import javax.swing.UIManager;
-import javax.swing.border.Border;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.BorderUIResource;
-import javax.swing.plaf.ColorUIResource;
-import javax.swing.plaf.FontUIResource;
-import javax.swing.plaf.IconUIResource;
-import javax.swing.plaf.InsetsUIResource;
-import javax.swing.plaf.basic.BasicBorders;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-import javax.swing.plaf.metal.MetalTheme;
-
-import com.jgoodies.common.base.Preconditions;
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.FontPolicies;
-import com.jgoodies.looks.FontPolicy;
-import com.jgoodies.looks.LookUtils;
-import com.jgoodies.looks.MicroLayout;
-import com.jgoodies.looks.MicroLayoutPolicies;
-import com.jgoodies.looks.MicroLayoutPolicy;
-import com.jgoodies.looks.Options;
-import com.jgoodies.looks.common.MinimumSizedIcon;
-import com.jgoodies.looks.common.RGBGrayFilter;
-import com.jgoodies.looks.common.ShadowPopupFactory;
-import com.jgoodies.looks.plastic.theme.SkyBluer;
-
-/**
- * The base class for the JGoodies Plastic look&feel family.
- * Initializes class and component defaults for the Plastic L&f
- * and provides keys and optional features for the Plastic family.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.46 $
- */
-public class PlasticLookAndFeel extends MetalLookAndFeel {
-
- // System and Client Property Keys ****************************************
-
- /**
- * Client property key to set a border style - shadows the header style.
- */
- public static final String BORDER_STYLE_KEY = "Plastic.borderStyle";
-
- /**
- * Client property key to disable the pseudo 3D effect.
- */
- public static final String IS_3D_KEY = "Plastic.is3D";
-
- /**
- * A System property key to set the default theme.
- */
- public static final String DEFAULT_THEME_KEY =
- "Plastic.defaultTheme";
-
- /**
- * A System property key that indicates that the high contrast
- * focus colors shall be choosen - if applicable.
- * If not set, some focus colors look good but have low contrast.
- * Basically, the low contrast scheme uses the Plastic colors
- * before 1.0.7, and the high contrast scheme is 1.0.7 - 1.0.9.
- */
- public static final String HIGH_CONTRAST_FOCUS_ENABLED_KEY =
- "Plastic.highContrastFocus";
-
- /**
- * A System property key for the rendering style of the Plastic
- * TabbedPane. Valid values are: <tt>default</tt> for the
- * Plastic 1.0 tabs, and <tt>metal</tt> for the Metal L&F tabs.
- */
- protected static final String TAB_STYLE_KEY =
- "Plastic.tabStyle";
-
- /**
- * A System property value that indicates that Plastic shall render
- * tabs in the Plastic 1.0 style. This is the default.
- */
- public static final String TAB_STYLE_DEFAULT_VALUE =
- "default";
-
- /**
- * A System property value that indicates that Plastic shall
- * render tabs in the Metal L&F style.
- */
- public static final String TAB_STYLE_METAL_VALUE =
- "metal";
-
-
-
- // State *****************************************************************
-
- /**
- * Holds whether Plastic uses Metal or Plastic tabbed panes.
- */
- private static boolean useMetalTabs =
- LookUtils.getSystemProperty(TAB_STYLE_KEY, "").
- equalsIgnoreCase(TAB_STYLE_METAL_VALUE);
-
- /**
- * Holds whether we are using the high contrast focus colors.
- */
- private static boolean useHighContrastFocusColors =
- LookUtils.getSystemProperty(HIGH_CONTRAST_FOCUS_ENABLED_KEY) != null;
-
- /**
- * The List of installed Plastic themes.
- */
- private static List<PlasticTheme> installedThemes;
-
- /** The look-global state for the 3D enablement. */
- private static boolean is3DEnabled = false;
-
-
- private static boolean selectTextOnKeyboardFocusGained =
- LookUtils.IS_OS_WINDOWS;
-
-
- // Instance Creation ******************************************************
-
- /**
- * Constructs the PlasticLookAndFeel, creates the default theme
- * and sets it as current Plastic theme.
- */
- public PlasticLookAndFeel() {
- getPlasticTheme();
- }
-
-
- // L&f Description ********************************************************
-
- @Override
- public String getID() {
- return "JGoodies Plastic";
- }
-
- @Override
- public String getName() {
- return "JGoodies Plastic";
- }
-
- @Override
- public String getDescription() {
- return "The JGoodies Plastic Look and Feel"
- + " - \u00a9 2001-2012 JGoodies Karsten Lentzsch";
- }
-
-
- // Optional Settings ******************************************************
-
- /**
- * Looks up and retrieves the FontPolicy used
- * by the JGoodies Plastic Look&Feel family.
- * If a FontPolicy has been set, it'll be returned.
- * Otherwise, this method checks if a FontPolicy or FontSet is defined
- * in the system properties or UIDefaults. If so, it is returned.
- * If no FontPolicy has been set for this look, in the system
- * properties or UIDefaults, the default Plastic font policy
- * will be returned.
- *
- * @return the FontPolicy set for this Look&feel - if any,
- * the FontPolicy specified in the system properties or UIDefaults
- * - if any, or the default Plastic font policy.
- *
- * @see #setFontPolicy
- * @see Options#PLASTIC_FONT_POLICY_KEY
- * @see FontPolicies
- * @see FontPolicies#customSettingsPolicy(FontPolicy)
- * @see FontPolicies#getDefaultPlasticPolicy()
- */
- public static FontPolicy getFontPolicy() {
- FontPolicy policy =
- (FontPolicy) UIManager.get(Options.PLASTIC_FONT_POLICY_KEY);
- if (policy != null) {
- return policy;
- }
-
- FontPolicy defaultPolicy = FontPolicies.getDefaultPlasticPolicy();
- return FontPolicies.customSettingsPolicy(defaultPolicy);
- }
-
-
- /**
- * Sets the FontPolicy to be used with the JGoodies Plastic L&F
- * family. If the specified policy is {@code null}, the default will
- * be reset.
- *
- * @param fontPolicy the FontPolicy to be used with
- * the JGoodies Plastic L&F family, or {@code null} to reset
- * to the default
- *
- * @see #getFontPolicy()
- * @see Options#PLASTIC_FONT_POLICY_KEY
- */
- public static void setFontPolicy(FontPolicy fontPolicy) {
- UIManager.put(Options.PLASTIC_FONT_POLICY_KEY, fontPolicy);
- }
-
-
- /**
- * Looks up and retrieves the MicroLayoutPolicy used by
- * the JGoodies Plastic Look&Fs.
- * If a MicroLayoutPolicy has been set for this look, it'll be returned.
- * Otherwise, the default Plastic micro layout policy will be returned.
- *
- * @return the MicroLayoutPolicy set for this Look&feel - if any,
- * or the default Plastic MicroLayoutPolicy.
- *
- * @see #setMicroLayoutPolicy
- * @see Options#PLASTIC_MICRO_LAYOUT_POLICY_KEY
- * @see MicroLayoutPolicies
- */
- public static MicroLayoutPolicy getMicroLayoutPolicy() {
- MicroLayoutPolicy policy =
- (MicroLayoutPolicy) UIManager.get(Options.PLASTIC_MICRO_LAYOUT_POLICY_KEY);
- return policy != null
- ? policy
- : MicroLayoutPolicies.getDefaultPlasticPolicy();
- }
-
-
- /**
- * Sets the MicroLayoutPolicy to be used with the JGoodies Plastic L&Fs.
- * If the specified policy is {@code null}, the default will be reset.
- *
- * @param microLayoutPolicy the MicroLayoutPolicy to be used with
- * the JGoodies Plastic L&Fs, or {@code null} to reset
- * to the default
- *
- * @see #getMicroLayoutPolicy()
- * @see Options#PLASTIC_MICRO_LAYOUT_POLICY_KEY
- */
- public static void setMicroLayoutPolicy(MicroLayout microLayoutPolicy) {
- UIManager.put(Options.PLASTIC_MICRO_LAYOUT_POLICY_KEY, microLayoutPolicy);
- }
-
-
- protected boolean is3DEnabled() {
- return is3DEnabled;
- }
-
- public static void set3DEnabled(boolean b) {
- is3DEnabled = b;
- }
-
- public static String getTabStyle() {
- return useMetalTabs ? TAB_STYLE_METAL_VALUE : TAB_STYLE_DEFAULT_VALUE;
- }
-
- public static void setTabStyle(String tabStyle) {
- useMetalTabs = tabStyle.equalsIgnoreCase(TAB_STYLE_METAL_VALUE);
- }
-
- public static boolean getHighContrastFocusColorsEnabled() {
- return useHighContrastFocusColors;
- }
-
- public static void setHighContrastFocusColorsEnabled(boolean b) {
- useHighContrastFocusColors = b;
- }
-
- public static boolean isSelectTextOnKeyboardFocusGained() {
- return selectTextOnKeyboardFocusGained;
- }
-
-
- /**
- * Sets whether text field text shall be selected when it gains focus
- * via the keyboard. This is enabled on Windows by default and
- * disabled on all other platforms.
- *
- * @param b <code>true</code> to enabled, <code>false</code> to disable
- */
- public static void setSelectTextOnKeyboardFocusGained(boolean b) {
- selectTextOnKeyboardFocusGained = b;
- }
-
-
- // Overriding Superclass Behavior ***************************************
-
- /**
- * Invoked during {@code UIManager#setLookAndFeel}. In addition
- * to the superclass behavior, we install the ShadowPopupFactory.
- *
- * @see #uninitialize
- */
- @Override
- public void initialize() {
- super.initialize();
- ShadowPopupFactory.install();
- }
-
-
- /**
- * Invoked during {@code UIManager#setLookAndFeel}. In addition
- * to the superclass behavior, we uninstall the ShadowPopupFactory.
- *
- * @see #initialize
- */
- @Override
- public void uninitialize() {
- super.uninitialize();
- ShadowPopupFactory.uninstall();
- }
-
-
- /**
- * Returns an icon with a disabled appearance. This method is used
- * to generate a disabled icon when one has not been specified.<p>
- *
- * This method will be used only on JDK 5.0 and later.
- *
- * @param component the component that will display the icon, may be null.
- * @param icon the icon to generate disabled icon from.
- * @return disabled icon, or null if a suitable icon can not be generated.
- */
- @Override
- public Icon getDisabledIcon(JComponent component, Icon icon) {
- Icon disabledIcon = RGBGrayFilter.getDisabledIcon(component, icon);
- return disabledIcon != null
- ? new IconUIResource(disabledIcon)
- : null;
- }
-
-
- /**
- * Initializes the class defaults, that is, overrides some UI delegates
- * with JGoodies Plastic implementations.
- *
- * @param table the UIDefaults table to work with
- * @see javax.swing.plaf.basic.BasicLookAndFeel#getDefaults()
- */
- @Override
- protected void initClassDefaults(UIDefaults table) {
- super.initClassDefaults(table);
-
- final String plasticPrefix = "com.jgoodies.looks.plastic.Plastic";
- final String commonPrefix = "com.jgoodies.looks.common.ExtBasic";
-
- // Overwrite some of the uiDefaults.
- Object[] uiDefaults = {
- // 3D effect; optional narrow margins
- "ButtonUI", plasticPrefix + "ButtonUI",
- "ToggleButtonUI", plasticPrefix + "ToggleButtonUI",
-
- // 3D effect
- "ComboBoxUI", plasticPrefix + "ComboBoxUI",
- "ScrollBarUI", plasticPrefix + "ScrollBarUI",
- "SpinnerUI", plasticPrefix + "SpinnerUI",
-
- // Special borders defined by border style or header style, see LookUtils
- "MenuBarUI", plasticPrefix + "MenuBarUI",
- "ToolBarUI", plasticPrefix + "ToolBarUI",
-
- // Aligns menu icons
- "MenuUI", plasticPrefix + "MenuUI",
- "MenuItemUI", commonPrefix + "MenuItemUI",
- "CheckBoxMenuItemUI", commonPrefix + "CheckBoxMenuItemUI",
- "RadioButtonMenuItemUI", commonPrefix + "RadioButtonMenuItemUI",
-
- // Provides an option for a no margin border
- "PopupMenuUI", plasticPrefix + "PopupMenuUI",
-
- // Has padding above and below the separator lines
- "PopupMenuSeparatorUI", commonPrefix + "PopupMenuSeparatorUI",
-
- // Honors the screen resolution and uses a minimum button width
- "OptionPaneUI", plasticPrefix + "OptionPaneUI",
-
- // Can installs an optional etched border
- "ScrollPaneUI", plasticPrefix + "ScrollPaneUI",
-
- // Uses a modified split divider
- "SplitPaneUI", plasticPrefix + "SplitPaneUI",
-
- // Selects all text after focus gain via keyboard.
- "PasswordFieldUI", plasticPrefix + "PasswordFieldUI",
-
- // Updates the disabled and inactive background
- "TextAreaUI", plasticPrefix + "TextAreaUI",
-
- // Modified icons and lines
- "TreeUI", plasticPrefix + "TreeUI",
-
- // Just to use Plastic colors
- "InternalFrameUI", plasticPrefix + "InternalFrameUI",
-
- // Share the UI delegate instances
- "SeparatorUI", plasticPrefix + "SeparatorUI",
- "ToolBarSeparatorUI", plasticPrefix + "ToolBarSeparatorUI",
-
- // Optionally looks up the system icons
- "FileChooserUI", plasticPrefix + "FileChooserUI"
-
- };
- if (!useMetalTabs) {
- // Modified tabs and ability use a version with reduced borders.
- uiDefaults = append(uiDefaults,
- "TabbedPaneUI", plasticPrefix + "TabbedPaneUI");
- }
- if (isSelectTextOnKeyboardFocusGained()) {
- // Selects all text after focus gain via keyboard.
- uiDefaults = append(uiDefaults,
- "TextFieldUI", plasticPrefix + "TextFieldUI");
- uiDefaults = append(uiDefaults,
- "FormattedTextFieldUI", plasticPrefix + "FormattedTextFieldUI");
- }
- table.putDefaults(uiDefaults);
- }
-
-
- @Override
- protected void initComponentDefaults(UIDefaults table) {
- super.initComponentDefaults(table);
-
- MicroLayout microLayout = getMicroLayoutPolicy().getMicroLayout(getName(), table);
- Insets buttonBorderInsets = microLayout.getButtonBorderInsets();
-
- Object marginBorder = new BasicBorders.MarginBorder();
-
- Object buttonBorder = PlasticBorders.getButtonBorder(buttonBorderInsets);
- Object comboBoxButtonBorder = PlasticBorders.getComboBoxArrowButtonBorder();
- Border comboBoxEditorBorder = PlasticBorders.getComboBoxEditorBorder();
- Object menuItemBorder = PlasticBorders.getMenuItemBorder();
- Object textFieldBorder = PlasticBorders.getTextFieldBorder();
- Object toggleButtonBorder = PlasticBorders.getToggleButtonBorder(buttonBorderInsets);
-
- Object scrollPaneBorder = PlasticBorders.getScrollPaneBorder();
- Object tableHeaderBorder = new BorderUIResource(
- (Border) table.get("TableHeader.cellBorder"));
-
- Object menuBarEmptyBorder = marginBorder;
- Object menuBarSeparatorBorder = PlasticBorders.getSeparatorBorder();
- Object menuBarEtchedBorder = PlasticBorders.getEtchedBorder();
- Object menuBarHeaderBorder = PlasticBorders.getMenuBarHeaderBorder();
-
- Object toolBarEmptyBorder = marginBorder;
- Object toolBarSeparatorBorder = PlasticBorders.getSeparatorBorder();
- Object toolBarEtchedBorder = PlasticBorders.getEtchedBorder();
- Object toolBarHeaderBorder = PlasticBorders.getToolBarHeaderBorder();
-
- Object internalFrameBorder = getInternalFrameBorder();
- Object paletteBorder = getPaletteBorder();
-
- Color controlColor = table.getColor("control");
-
- Object checkBoxIcon = PlasticIconFactory.getCheckBoxIcon();
- Object checkBoxMargin = microLayout.getCheckBoxMargin();
-
- Object buttonMargin = microLayout.getButtonMargin();
- Object textInsets = microLayout.getTextInsets();
- Object wrappedTextInsets = microLayout.getWrappedTextInsets();
- Insets comboEditorInsets = microLayout.getComboBoxEditorInsets();
-
- Insets comboEditorBorderInsets = comboBoxEditorBorder.getBorderInsets(null);
- int comboBorderSize = comboEditorBorderInsets.left;
- int comboPopupBorderSize = microLayout.getComboPopupBorderSize();
- int comboRendererGap = comboEditorInsets.left + comboBorderSize - comboPopupBorderSize;
- Object comboRendererBorder = new EmptyBorder(1, comboRendererGap, 1, comboRendererGap);
- Object comboTableEditorInsets = new Insets(0, 0, 0, 0);
-
- Object menuItemMargin = microLayout.getMenuItemMargin();
- Object menuMargin = microLayout.getMenuMargin();
-
- Icon menuItemCheckIcon = new MinimumSizedIcon();
- Icon checkBoxMenuItemIcon = PlasticIconFactory.getCheckBoxMenuItemIcon();
- Icon radioButtonMenuItemIcon = PlasticIconFactory.getRadioButtonMenuItemIcon();
-
- Color menuItemForeground = table.getColor("MenuItem.foreground");
-
- Color inactiveTextBackground = table.getColor("TextField.inactiveBackground");
-
- // Should be active.
- int treeFontSize = table.getFont("Tree.font").getSize();
- Integer rowHeight = new Integer(treeFontSize + 6);
- Object treeExpandedIcon = PlasticIconFactory.getExpandedTreeIcon();
- Object treeCollapsedIcon = PlasticIconFactory.getCollapsedTreeIcon();
- ColorUIResource gray = new ColorUIResource(Color.GRAY);
-
- Boolean is3D = Boolean.valueOf(is3DEnabled());
-
- Character passwordEchoChar = new Character(SystemUtils.IS_OS_WINDOWS ? '\u25CF' : '\u2022');
-
- String iconPrefix = "icons/" + (SystemUtils.IS_LOW_RESOLUTION ? "32x32/" : "48x48/");
- Object errorIcon = makeIcon(getClass(), iconPrefix + "dialog-error.png");
- Object informationIcon = makeIcon(getClass(), iconPrefix + "dialog-information.png");
- Object helpIcon = makeIcon(getClass(), iconPrefix + "dialog-help.png");
- Object warningIcon = makeIcon(getClass(), iconPrefix + "dialog-warning.png");
-
-
- Object[] defaults = {
- "Button.border", buttonBorder,
- "Button.margin", buttonMargin,
-
- "CheckBox.margin", checkBoxMargin,
-
- // Use a modified check
- "CheckBox.icon", checkBoxIcon,
-
- "CheckBoxMenuItem.border", menuItemBorder,
- "CheckBoxMenuItem.margin", menuItemMargin, // 1.4.1 Bug
- "CheckBoxMenuItem.checkIcon", checkBoxMenuItemIcon,
- "CheckBoxMenuItem.background", getMenuItemBackground(),// Added by JGoodies
- "CheckBoxMenuItem.selectionForeground", getMenuItemSelectedForeground(),
- "CheckBoxMenuItem.selectionBackground", getMenuItemSelectedBackground(),
- "CheckBoxMenuItem.acceleratorForeground", menuItemForeground,
- "CheckBoxMenuItem.acceleratorSelectionForeground",getMenuItemSelectedForeground(),
- "CheckBoxMenuItem.acceleratorSelectionBackground",getMenuItemSelectedBackground(),
-
- // ComboBox uses menu item selection colors
- "ComboBox.selectionForeground", getMenuSelectedForeground(),
- "ComboBox.selectionBackground", getMenuSelectedBackground(),
- "ComboBox.arrowButtonBorder", comboBoxButtonBorder,
- "ComboBox.editorBorder", comboBoxEditorBorder,
- "ComboBox.editorColumns", new Integer(5),
- "ComboBox.editorBorderInsets", comboEditorBorderInsets, // Added by JGoodies
- "ComboBox.editorInsets", textInsets, // Added by JGoodies
- "ComboBox.tableEditorInsets", comboTableEditorInsets,
- "ComboBox.rendererBorder", comboRendererBorder, // Added by JGoodies
-
- "EditorPane.margin", wrappedTextInsets,
-
- "InternalFrame.border", internalFrameBorder,
- "InternalFrame.paletteBorder", paletteBorder,
-
- "List.font", getControlTextFont(),
- "Menu.border", PlasticBorders.getMenuBorder(),
- "Menu.margin", menuMargin,
- "Menu.arrowIcon", PlasticIconFactory.getMenuArrowIcon(),
-
- "MenuBar.emptyBorder", menuBarEmptyBorder, // Added by JGoodies
- "MenuBar.separatorBorder", menuBarSeparatorBorder, // Added by JGoodies
- "MenuBar.etchedBorder", menuBarEtchedBorder, // Added by JGoodies
- "MenuBar.headerBorder", menuBarHeaderBorder, // Added by JGoodies
-
- "MenuItem.border", menuItemBorder,
- "MenuItem.checkIcon", menuItemCheckIcon, // Aligns menu items
- "MenuItem.margin", menuItemMargin, // 1.4.1 Bug
- "MenuItem.background", getMenuItemBackground(),// Added by JGoodies
- "MenuItem.selectionForeground", getMenuItemSelectedForeground(),// Added by JGoodies
- "MenuItem.selectionBackground", getMenuItemSelectedBackground(),// Added by JGoodies
- "MenuItem.acceleratorForeground", menuItemForeground,
- "MenuItem.acceleratorSelectionForeground", getMenuItemSelectedForeground(),
- "MenuItem.acceleratorSelectionBackground", getMenuItemSelectedBackground(),
-
- "OptionPane.errorIcon", errorIcon,
- "OptionPane.informationIcon", informationIcon,
- "OptionPane.questionIcon", helpIcon ,
- "OptionPane.warningIcon", warningIcon,
-
- //"DesktopIcon.icon", makeIcon(superclass, "icons/DesktopIcon.gif"),
- "FileView.computerIcon", makeIcon(getClass(), "icons/Computer.gif"),
- "FileView.directoryIcon", makeIcon(getClass(), "icons/TreeClosed.gif"),
- "FileView.fileIcon", makeIcon(getClass(), "icons/File.gif"),
- "FileView.floppyDriveIcon", makeIcon(getClass(), "icons/FloppyDrive.gif"),
- "FileView.hardDriveIcon", makeIcon(getClass(), "icons/HardDrive.gif"),
- "FileChooser.homeFolderIcon", makeIcon(getClass(), "icons/HomeFolder.gif"),
- "FileChooser.newFolderIcon", makeIcon(getClass(), "icons/NewFolder.gif"),
- "FileChooser.upFolderIcon", makeIcon(getClass(), "icons/UpFolder.gif"),
- "Tree.closedIcon", makeIcon(getClass(), "icons/TreeClosed.gif"),
- "Tree.openIcon", makeIcon(getClass(), "icons/TreeOpen.gif"),
- "Tree.leafIcon", makeIcon(getClass(), "icons/TreeLeaf.gif"),
-
- "FormattedTextField.border", textFieldBorder,
- "FormattedTextField.margin", textInsets,
-
- "PasswordField.border", textFieldBorder,
- "PasswordField.margin", textInsets,
- "PasswordField.echoChar", passwordEchoChar,
-
-
- "PopupMenu.border", PlasticBorders.getPopupMenuBorder(),
- "PopupMenu.noMarginBorder", PlasticBorders.getNoMarginPopupMenuBorder(),
- "PopupMenuSeparator.margin", new InsetsUIResource(3, 4, 3, 4),
-
- "RadioButton.margin", checkBoxMargin,
- "RadioButtonMenuItem.border", menuItemBorder,
- "RadioButtonMenuItem.checkIcon", radioButtonMenuItemIcon,
- "RadioButtonMenuItem.margin", menuItemMargin, // 1.4.1 Bug
- "RadioButtonMenuItem.background", getMenuItemBackground(),// Added by JGoodies
- "RadioButtonMenuItem.selectionForeground", getMenuItemSelectedForeground(),
- "RadioButtonMenuItem.selectionBackground", getMenuItemSelectedBackground(),
- "RadioButtonMenuItem.acceleratorForeground", menuItemForeground,
- "RadioButtonMenuItem.acceleratorSelectionForeground", getMenuItemSelectedForeground(),
- "RadioButtonMenuItem.acceleratorSelectionBackground", getMenuItemSelectedBackground(),
- "Separator.foreground", getControlDarkShadow(),
- "ScrollPane.border", scrollPaneBorder,
- "ScrollPane.etchedBorder", scrollPaneBorder,
-// "ScrollPane.background", table.get("window"),
-
- "SimpleInternalFrame.activeTitleForeground", getSimpleInternalFrameForeground(),
- "SimpleInternalFrame.activeTitleBackground", getSimpleInternalFrameBackground(),
-
- "Spinner.border", PlasticBorders.getFlush3DBorder(),
- "Spinner.defaultEditorInsets", textInsets,
-
- "SplitPane.dividerSize", new Integer(7),
- "TabbedPane.focus", getFocusColor(),
- "TabbedPane.tabInsets", new InsetsUIResource(1, 9, 1, 8),
- "Table.foreground", table.get("textText"),
- "Table.gridColor", controlColor, //new ColorUIResource(new Color(216, 216, 216)),
- "Table.scrollPaneBorder", scrollPaneBorder,
- "TableHeader.cellBorder", tableHeaderBorder,
- "TextArea.inactiveBackground", inactiveTextBackground,
- "TextArea.margin", wrappedTextInsets,
- "TextField.border", textFieldBorder,
- "TextField.margin", textInsets,
- "TitledBorder.font", getTitleTextFont(),
- "TitledBorder.titleColor", getTitleTextColor(),
- "ToggleButton.border", toggleButtonBorder,
- "ToggleButton.margin", buttonMargin,
-
- "ToolBar.emptyBorder", toolBarEmptyBorder, // Added by JGoodies
- "ToolBar.separatorBorder", toolBarSeparatorBorder, // Added by JGoodies
- "ToolBar.etchedBorder", toolBarEtchedBorder, // Added by JGoodies
- "ToolBar.headerBorder", toolBarHeaderBorder, // Added by JGoodies
-
- "ToolTip.hideAccelerator", Boolean.TRUE,
-
- "Tree.expandedIcon", treeExpandedIcon,
- "Tree.collapsedIcon", treeCollapsedIcon,
- "Tree.line", gray,
- "Tree.hash", gray,
- "Tree.rowHeight", rowHeight,
-
- "Button.is3DEnabled", is3D,
- "ComboBox.is3DEnabled", is3D,
- "MenuBar.is3DEnabled", is3D,
- "ToolBar.is3DEnabled", is3D,
- "ScrollBar.is3DEnabled", is3D,
- "ToggleButton.is3DEnabled", is3D,
-
- // 1.4.1 uses a 2 pixel non-standard border, that leads to bad
- // alignment in the typical case that the border is not painted
- "CheckBox.border", marginBorder,
- "RadioButton.border", marginBorder,
-
- // Fix of the issue #21
- "ProgressBar.selectionForeground", getSystemTextColor(),
- "ProgressBar.selectionBackground", getSystemTextColor()
- };
- table.putDefaults(defaults);
-
- // Set paths to sounds for auditory feedback
- String soundPathPrefix = "/javax/swing/plaf/metal/";
- Object[] auditoryCues = (Object[]) table.get("AuditoryCues.allAuditoryCues");
- if (auditoryCues != null) {
- Object[] audioDefaults = new String[auditoryCues.length * 2];
- for (int i = 0; i < auditoryCues.length; i++) {
- Object auditoryCue = auditoryCues[i];
- audioDefaults[2*i] = auditoryCue;
- audioDefaults[2*i + 1] = soundPathPrefix + table.getString(auditoryCue);
- }
- table.putDefaults(audioDefaults);
- }
- }
-
-
- /**
- * Unlike my superclass I register a unified shadow color.
- * This color is used by my ThinBevelBorder class.
- *
- * @param table the UIDefaults table to work with
- */
- @Override
- protected void initSystemColorDefaults(UIDefaults table) {
- super.initSystemColorDefaults(table);
- table.put("unifiedControlShadow", table.getColor("controlDkShadow"));
- table.put("primaryControlHighlight", getPrimaryControlHighlight());
- }
-
-
- // Color Theme Behavior *************************************************************
-
- private static final String THEME_CLASSNAME_PREFIX = "com.jgoodies.looks.plastic.theme.";
-
- /**
- * Creates and returns the default color theme. Honors the current platform
- * and platform flavor - if available.
- *
- * @return the default color theme for the current environment
- */
- public static PlasticTheme createMyDefaultTheme() {
- String defaultName;
- if (SystemUtils.IS_LAF_WINDOWS_XP_ENABLED) {
- defaultName = getDefaultXPTheme();
- } else if (LookUtils.IS_OS_WINDOWS_MODERN) {
- defaultName = "DesertBluer";
- } else {
- defaultName = "SkyBlue";
- }
- // Don't use the default now, so we can detect that the users tried to set one.
- String userName = LookUtils.getSystemProperty(DEFAULT_THEME_KEY, "");
- boolean overridden = userName.length() > 0;
- String themeName = overridden ? userName : defaultName;
- PlasticTheme theme = createTheme(themeName);
- PlasticTheme result = theme != null ? theme : new SkyBluer();
-
- // In case the user tried to set a theme, log a message.
- if (overridden) {
- String className = result.getClass().getName().substring(
- THEME_CLASSNAME_PREFIX.length());
- if (className.equals(userName)) {
- LookUtils.log("I have successfully installed the '" + result.getName() + "' theme.");
- } else {
- LookUtils.log("I could not install the Plastic theme '" + userName + "'.");
- LookUtils.log("I have installed the '" + result.getName() + "' theme, instead.");
- }
- }
- return result;
- }
-
-
- private static String getDefaultXPTheme() {
- String fallbackName = "ExperienceBlue";
- Toolkit toolkit = Toolkit.getDefaultToolkit();
- String xpstyleDll = (String) toolkit.getDesktopProperty("win.xpstyle.dllName");
- if (xpstyleDll == null) {
- return fallbackName;
- }
- boolean isStyleLuna = xpstyleDll.endsWith("luna.msstyles");
- boolean isStyleRoyale = xpstyleDll.endsWith("Royale.msstyles");
- boolean isStyleAero = xpstyleDll.endsWith("Aero.msstyles");
- if (isStyleRoyale) {
- return "ExperienceRoyale";
- }
- if (isStyleLuna) {
- String xpstyleColorName = (String) toolkit.getDesktopProperty("win.xpstyle.colorName");
- if (xpstyleColorName == null) {
- return fallbackName;
- }
- if (xpstyleColorName.equalsIgnoreCase("HomeStead")) {
- return "ExperienceGreen";
- } else if (xpstyleColorName.equalsIgnoreCase("Metallic")) {
- return "Silver";
- } else {
- return fallbackName;
- }
- }
- if (isStyleAero) {
- return "LightGray";
- }
- return fallbackName;
- }
-
-
- /**
- * Lazily initializes and returns the {@code List} of installed
- * color themes.
- *
- * @return a list of installed color/font themes
- */
- public static List getInstalledThemes() {
- if (null == installedThemes) {
- installDefaultThemes();
- }
-
- Collections.sort(installedThemes, new Comparator() {
- @Override
- public int compare(Object o1, Object o2) {
- MetalTheme theme1 = (MetalTheme) o1;
- MetalTheme theme2 = (MetalTheme) o2;
- return theme1.getName().compareTo(theme2.getName());
- }
- });
-
- return installedThemes;
- }
-
-
- /**
- * Install the default color themes.
- */
- protected static void installDefaultThemes() {
- installedThemes = new ArrayList<PlasticTheme>();
- String[] themeNames = {
- "BrownSugar",
- "DarkStar",
- "DesertBlue",
- "DesertBluer",
- "DesertGreen",
- "DesertRed",
- "DesertYellow",
- "ExperienceBlue",
- "ExperienceGreen",
- "ExperienceRoyale",
- "LightGray",
- "Silver",
- "SkyBlue",
- "SkyBluer",
- "SkyGreen",
- "SkyKrupp",
- "SkyPink",
- "SkyRed",
- "SkyYellow"};
- for (int i = themeNames.length - 1; i >= 0; i--) {
- installTheme(createTheme(themeNames[i]));
- }
- }
-
-
- /**
- * Creates and returns a color theme from the specified theme name.
- *
- * @param themeName the unqualified name of the theme to create
- * @return the associated color theme or {@code null} in case of
- * a problem
- */
- protected static PlasticTheme createTheme(String themeName) {
- String className = THEME_CLASSNAME_PREFIX + themeName;
- try {
- Class cl = Class.forName(className);
- return (PlasticTheme) cl.newInstance();
- } catch (ClassNotFoundException e) {
- // Ignore the exception here and log below.
- } catch (IllegalAccessException e) {
- // Ignore the exception here and log below.
- } catch (InstantiationException e) {
- // Ignore the exception here and log below.
- }
- LookUtils.log("Can't create theme " + className);
- return null;
- }
-
-
- /**
- * Installs a color theme.
- *
- * @param theme the theme to install
- */
- public static void installTheme(PlasticTheme theme) {
- if (null == installedThemes) {
- installDefaultThemes();
- }
- installedThemes.add(theme);
- }
-
-
- /**
- * Lazily initializes and returns the PlasticTheme.
- *
- * @return the current PlasticTheme
- */
- public static PlasticTheme getPlasticTheme() {
- MetalTheme theme = getCurrentTheme();
- if (theme instanceof PlasticTheme) {
- return (PlasticTheme) theme;
- }
- PlasticTheme initialTheme = createMyDefaultTheme();
- setPlasticTheme(initialTheme);
- return initialTheme;
- }
-
-
- /**
- * Sets the theme for colors and fonts used by the Plastic L&F.<p>
- *
- * After setting the theme, you need to re-install the Look&Feel,
- * as well as update the UI's of any previously created components
- * - just as if you'd change the Look&Feel.
- *
- * @param theme the PlasticTheme to be set
- *
- * @throws NullPointerException if the theme is null.
- *
- * @see #getPlasticTheme()
- */
- public static void setPlasticTheme(PlasticTheme theme) {
- Preconditions.checkNotNull(theme, "The theme must not be null.");
- setCurrentTheme(theme);
- }
-
-
- // Accessed by ProxyLazyValues ******************************************
-
- public static BorderUIResource getInternalFrameBorder() {
- return new BorderUIResource(PlasticBorders.getInternalFrameBorder());
- }
-
- public static BorderUIResource getPaletteBorder() {
- return new BorderUIResource(PlasticBorders.getPaletteBorder());
- }
-
-
-
- // Accessing Theme Colors and Fonts *************************************
-
-
- public static ColorUIResource getPrimaryControlDarkShadow() {
- return getPlasticTheme().getPrimaryControlDarkShadow();
- }
-
- public static ColorUIResource getPrimaryControlHighlight() {
- return getPlasticTheme().getPrimaryControlHighlight();
- }
-
- public static ColorUIResource getPrimaryControlInfo() {
- return getPlasticTheme().getPrimaryControlInfo();
- }
-
- public static ColorUIResource getPrimaryControlShadow() {
- return getPlasticTheme().getPrimaryControlShadow();
- }
-
- public static ColorUIResource getPrimaryControl() {
- return getPlasticTheme().getPrimaryControl();
- }
-
- public static ColorUIResource getControlHighlight() {
- return getPlasticTheme().getControlHighlight();
- }
-
- public static ColorUIResource getControlDarkShadow() {
- return getPlasticTheme().getControlDarkShadow();
- }
-
- public static ColorUIResource getControl() {
- return getPlasticTheme().getControl();
- }
-
- public static ColorUIResource getFocusColor() {
- return getPlasticTheme().getFocusColor();
- }
-
- public static ColorUIResource getMenuItemBackground() {
- return getPlasticTheme().getMenuItemBackground();
- }
-
- public static ColorUIResource getMenuItemSelectedBackground() {
- return getPlasticTheme().getMenuItemSelectedBackground();
- }
-
- public static ColorUIResource getMenuItemSelectedForeground() {
- return getPlasticTheme().getMenuItemSelectedForeground();
- }
-
- public static ColorUIResource getWindowTitleBackground() {
- return getPlasticTheme().getWindowTitleBackground();
- }
-
- public static ColorUIResource getWindowTitleForeground() {
- return getPlasticTheme().getWindowTitleForeground();
- }
-
- public static ColorUIResource getWindowTitleInactiveBackground() {
- return getPlasticTheme().getWindowTitleInactiveBackground();
- }
-
- public static ColorUIResource getWindowTitleInactiveForeground() {
- return getPlasticTheme().getWindowTitleInactiveForeground();
- }
-
- public static ColorUIResource getSimpleInternalFrameForeground() {
- return getPlasticTheme().getSimpleInternalFrameForeground();
- }
-
- public static ColorUIResource getSimpleInternalFrameBackground() {
- return getPlasticTheme().getSimpleInternalFrameBackground();
- }
-
- public static ColorUIResource getTitleTextColor() {
- return getPlasticTheme().getTitleTextColor();
- }
-
- public static FontUIResource getTitleTextFont() {
- return getPlasticTheme().getTitleTextFont();
- }
-
-
- // Helper Code ************************************************************
-
- /**
- * Appends the key and value to the given source array and returns
- * a copy that has the two new elements at its end.
- *
- * @return an array with the key and value appended
- */
- private static Object[] append(Object[] source, String key, Object value) {
- int length = source.length;
- Object[] destination = new Object[length + 2];
- System.arraycopy(source, 0, destination, 0, length);
- destination[length] = key;
- destination[length + 1] = value;
- return destination;
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticMenuBarUI.java b/src/core/com/jgoodies/looks/plastic/PlasticMenuBarUI.java
deleted file mode 100644
index f1381a5..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticMenuBarUI.java
+++ /dev/null
@@ -1,173 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Graphics;
-import java.awt.Rectangle;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.JComponent;
-import javax.swing.LookAndFeel;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicMenuBarUI;
-
-import com.jgoodies.looks.BorderStyle;
-import com.jgoodies.looks.HeaderStyle;
-import com.jgoodies.looks.Options;
-
-
-/**
- * The JGoodies Plastic look and feel implemenation of {@code MenuBarUI}.
- * Can handle optional {@code Border} types as specified by the
- * {@code BorderStyle} or {@code HeaderStyle} client properties.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class PlasticMenuBarUI extends BasicMenuBarUI {
-
-
- private PropertyChangeListener listener;
-
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticMenuBarUI();
- }
-
-
- // Handling Special Borders *********************************************
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- installSpecialBorder();
- }
-
-
- @Override
- protected void installListeners() {
- super.installListeners();
- listener = createBorderStyleListener();
- menuBar.addPropertyChangeListener(listener);
- }
-
-
- @Override
- protected void uninstallListeners() {
- menuBar.removePropertyChangeListener(listener);
- super.uninstallListeners();
- }
-
-
- private PropertyChangeListener createBorderStyleListener() {
- return new PropertyChangeListener() {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String prop = e.getPropertyName();
- if (prop.equals(Options.HEADER_STYLE_KEY) ||
- prop.equals(PlasticLookAndFeel.BORDER_STYLE_KEY)) {
- PlasticMenuBarUI.this.installSpecialBorder();
- }
- }
-
- };
- }
-
-
- /**
- * Installs a special border, if either a look-dependent {@code BorderStyle}
- * or a look-independent {@code HeaderStyle} has been specified.
- * A look specific {@code BorderStyle} shadows a {@code HeaderStyle}.<p>
- *
- * We recommend to specify a {@code HeaderStyle}.
- */
- public void installSpecialBorder() {
- String suffix;
- BorderStyle borderStyle = BorderStyle.from(menuBar,
- PlasticLookAndFeel.BORDER_STYLE_KEY);
- if (borderStyle == BorderStyle.EMPTY) {
- suffix = "emptyBorder";
- } else if (borderStyle == BorderStyle.ETCHED) {
- suffix = "etchedBorder";
- } else if (borderStyle == BorderStyle.SEPARATOR) {
- suffix = "separatorBorder";
- } else {
- HeaderStyle headerStyle = HeaderStyle.from(menuBar);
- if (headerStyle == HeaderStyle.BOTH) {
- suffix = "headerBorder";
- } else if (headerStyle == HeaderStyle.SINGLE && is3D()) {
- suffix = "etchedBorder";
- } else {
- return;
- }
- }
-
- LookAndFeel.installBorder(menuBar, "MenuBar." + suffix);
- }
-
-
- // 3D Effect ************************************************************************
-
- @Override
- public void update(Graphics g, JComponent c) {
- if (c.isOpaque()) {
- g.setColor(c.getBackground());
- g.fillRect(0, 0, c.getWidth(), c.getHeight());
- if (is3D()) {
- Rectangle bounds =
- new Rectangle(0, 0, c.getWidth(), c.getHeight());
- PlasticUtils.addLight3DEffekt(g, bounds, true);
- }
- }
-
- paint(g, c);
- }
-
-
- /**
- * Checks and answers if we should add a pseudo 3D effect.
- */
- private boolean is3D() {
- if (PlasticUtils.force3D(menuBar)) {
- return true;
- }
- if (PlasticUtils.forceFlat(menuBar)) {
- return false;
- }
- return PlasticUtils.is3D("MenuBar.") &&
- (HeaderStyle.from(menuBar) != null) &&
- (BorderStyle.from(menuBar, PlasticLookAndFeel.BORDER_STYLE_KEY)
- != BorderStyle.EMPTY);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticMenuUI.java b/src/core/com/jgoodies/looks/plastic/PlasticMenuUI.java
deleted file mode 100644
index 95fa144..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticMenuUI.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Graphics;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.JMenu;
-import javax.swing.JMenuItem;
-import javax.swing.plaf.ComponentUI;
-
-import com.jgoodies.looks.common.ExtBasicMenuUI;
-
-/**
- * The JGoodies Plastic look&feel implementation of {@code MenuUI}.
- * It differs from the superclass in that it uses an overhauled menu
- * rendering an aligmnent system. Furthermore, you can set a client property
- * <tt>Options.NO_ICONS_KEY</tt> to indicate that this menu has no icons.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.14 $
- *
- * @see com.jgoodies.looks.Options
- */
-public final class PlasticMenuUI extends ExtBasicMenuUI {
-
-
- private boolean oldOpaque;
-
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticMenuUI();
- }
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- oldOpaque = menuItem.isOpaque();
- }
-
-
-
- /**
- * Makes the item transparent, if it is not a sub menu and the model is not selected.
- */
- @Override
- protected void paintMenuItem(Graphics g, JComponent c, Icon aCheckIcon,
- Icon anArrowIcon, Color background, Color foreground, int textIconGap) {
- JMenuItem b = (JMenuItem) c;
-
- if (((JMenu) menuItem).isTopLevelMenu()) {
- b.setOpaque(false);
- if (b.getModel().isSelected()) {
- int menuWidth = menuItem.getWidth();
- int menuHeight = menuItem.getHeight();
- Color oldColor = g.getColor();
- g.setColor(background);
- g.fillRect(0, 0, menuWidth, menuHeight);
- g.setColor(oldColor);
- }
- }
- super.paintMenuItem(g, c, aCheckIcon, anArrowIcon, background, foreground, textIconGap);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticOptionPaneUI.java b/src/core/com/jgoodies/looks/plastic/PlasticOptionPaneUI.java
deleted file mode 100644
index ffbbfb8..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticOptionPaneUI.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Container;
-
-import javax.swing.JComponent;
-import javax.swing.JPanel;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicOptionPaneUI;
-
-import com.jgoodies.looks.common.ExtButtonAreaLayout;
-
-/**
- * The JGoodies Plastic Look&Feel implementation of
- * {@code OptionPaneUI}. Honors the screen resolution and
- * uses a minimum button with that complies better with the Mac and Windows
- * UI style guides.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class PlasticOptionPaneUI extends BasicOptionPaneUI {
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticOptionPaneUI();
- }
-
- /**
- * Creates and returns a Container containin the buttons. The buttons
- * are created by calling {@code getButtons}.
- */
- @Override
- protected Container createButtonArea() {
- JPanel bottom = new JPanel(new ExtButtonAreaLayout(true, 6));
- bottom.setBorder(UIManager.getBorder("OptionPane.buttonAreaBorder"));
- addButtonComponents(bottom, getButtons(), getInitialValueIndex());
- return bottom;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticPasswordFieldUI.java b/src/core/com/jgoodies/looks/plastic/PlasticPasswordFieldUI.java
deleted file mode 100644
index 3863a26..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticPasswordFieldUI.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-
-import javax.swing.JComponent;
-import javax.swing.JPasswordField;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicPasswordFieldUI;
-import javax.swing.text.Caret;
-
-
-/**
- * The JGoodies PlasticXP Look&Feel implementation of a password field UI
- * delegate. It differs from its superclass in that it utilizes a custom caret.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public final class PlasticPasswordFieldUI extends BasicPasswordFieldUI {
-
- /**
- * Creates a UI for a {@link JPasswordField}.
- *
- * @param c the password field component
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new PlasticPasswordFieldUI();
- }
-
-
- /**
- * Creates the caret for a field.
- *
- * @return the caret
- */
- @Override
- protected Caret createCaret() {
- return PlasticLookAndFeel.isSelectTextOnKeyboardFocusGained()
- ? new PlasticFieldCaret()
- : super.createCaret();
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticPopupMenuUI.java b/src/core/com/jgoodies/looks/plastic/PlasticPopupMenuUI.java
deleted file mode 100644
index 8de7584..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticPopupMenuUI.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.BoxLayout;
-import javax.swing.JComponent;
-import javax.swing.LookAndFeel;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicPopupMenuUI;
-
-import com.jgoodies.looks.Options;
-import com.jgoodies.looks.common.PopupMenuLayout;
-
-/**
- * The JGoodies Plastic look&feel implementation of {@code PopMenuUI}.
- * It differs from the superclass in that it provides an option to get a
- * narrow border. You can set a client property
- * {@link Options#NO_MARGIN_KEY} to indicate that this popup menu
- * has a border without margin. That is useful in the special case
- * where the popup contains only a single component, for example
- * a JScrollPane.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- *
- * @see com.jgoodies.looks.Options#NO_MARGIN_KEY
- */
-public final class PlasticPopupMenuUI extends BasicPopupMenuUI {
-
- private PropertyChangeListener borderListener;
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticPopupMenuUI();
- }
-
-
- @Override
- public void installDefaults() {
- super.installDefaults();
- installBorder();
- if ( (popupMenu.getLayout() == null)
- || (popupMenu.getLayout() instanceof UIResource)) {
- popupMenu.setLayout(new PopupMenuLayout(popupMenu, BoxLayout.Y_AXIS));
- }
- }
-
- @Override
- protected void installListeners() {
- super.installListeners();
- borderListener = new BorderStyleChangeHandler();
- popupMenu.addPropertyChangeListener(Options.NO_MARGIN_KEY, borderListener);
- }
-
- @Override
- protected void uninstallListeners() {
- popupMenu.removePropertyChangeListener(Options.NO_MARGIN_KEY, borderListener);
- super.uninstallListeners();
- }
-
- // Narrow Border **********************************************************
-
- private final class BorderStyleChangeHandler implements PropertyChangeListener {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- installBorder();
- }
-
- }
-
- /**
- * Installs a border without margin, iff the client property
- * {@code Options.NO_MARGIN_KEY} is set to {@code Boolean.TRUE}.
- */
- private void installBorder() {
- boolean useNarrowBorder = Boolean.TRUE.equals(
- popupMenu.getClientProperty(Options.NO_MARGIN_KEY));
- String suffix = useNarrowBorder ? "noMarginBorder" : "border";
- LookAndFeel.installBorder(popupMenu, "PopupMenu." + suffix);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticScrollBarUI.java b/src/core/com/jgoodies/looks/plastic/PlasticScrollBarUI.java
deleted file mode 100644
index 67a17ef..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticScrollBarUI.java
+++ /dev/null
@@ -1,289 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Adjustable;
-import java.awt.Color;
-import java.awt.Graphics;
-import java.awt.Rectangle;
-
-import javax.swing.JButton;
-import javax.swing.JComponent;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalScrollBarUI;
-
-
-/**
- * The JGoodies Plastic L&F implementation of {@code ScrollBarUI}.
- * Can add a pseudo 3D effect and honors the Plastic Option
- * <tt>ScrollBar.maxBumpsWidth</tt> to limit the with of the scroll bar bumps.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-
-public final class PlasticScrollBarUI extends MetalScrollBarUI {
-
- private static final String PROPERTY_PREFIX = "ScrollBar.";
- public static final String MAX_BUMPS_WIDTH_KEY = PROPERTY_PREFIX + "maxBumpsWidth";
-
- private Color shadowColor;
- private Color highlightColor;
- private Color darkShadowColor;
- private Color thumbColor;
- private Color thumbShadow;
- private Color thumbHighlightColor;
-
- private PlasticBumps bumps;
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticScrollBarUI();
- }
-
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- bumps = new PlasticBumps(10, 10, thumbHighlightColor, thumbShadow, thumbColor);
- }
-
-
- @Override
- protected JButton createDecreaseButton(int orientation) {
- decreaseButton = new PlasticArrowButton(orientation, scrollBarWidth, isFreeStanding);
- return decreaseButton;
- }
-
-
- @Override
- protected JButton createIncreaseButton(int orientation) {
- increaseButton = new PlasticArrowButton(orientation, scrollBarWidth, isFreeStanding);
- return increaseButton;
- }
-
-
- @Override
- protected void configureScrollBarColors() {
- super.configureScrollBarColors();
- shadowColor = UIManager.getColor(PROPERTY_PREFIX + "shadow");
- highlightColor = UIManager.getColor(PROPERTY_PREFIX + "highlight");
- darkShadowColor = UIManager.getColor(PROPERTY_PREFIX + "darkShadow");
- thumbColor = UIManager.getColor(PROPERTY_PREFIX + "thumb");
- thumbShadow = UIManager.getColor(PROPERTY_PREFIX + "thumbShadow");
- thumbHighlightColor = UIManager.getColor(PROPERTY_PREFIX + "thumbHighlight");
- }
-
-
- @Override
- protected void paintTrack(Graphics g, JComponent c, Rectangle trackBounds) {
- g.translate(trackBounds.x, trackBounds.y);
-
- boolean leftToRight = PlasticUtils.isLeftToRight(c);
-
- if (scrollbar.getOrientation() == Adjustable.VERTICAL) {
- if (!isFreeStanding) {
- if (!leftToRight) {
- trackBounds.width += 1;
- g.translate(-1, 0);
- } else {
- trackBounds.width += 2;
- }
- }
-
- if (c.isEnabled()) {
- g.setColor(darkShadowColor);
- g.drawLine(0, 0, 0, trackBounds.height - 1);
- g.drawLine(trackBounds.width - 2, 0, trackBounds.width - 2, trackBounds.height - 1);
- g.drawLine(1, trackBounds.height - 1, trackBounds.width - 1, trackBounds.height - 1);
- g.drawLine(1, 0, trackBounds.width - 2, 0);
-
- g.setColor(shadowColor);
- // g.setColor( Color.red);
- g.drawLine(1, 1, 1, trackBounds.height - 2);
- g.drawLine(1, 1, trackBounds.width - 3, 1);
- if (scrollbar.getValue() != scrollbar.getMaximum()) { // thumb shadow
- int y = thumbRect.y + thumbRect.height - trackBounds.y;
- g.drawLine(1, y, trackBounds.width - 1, y);
- }
- g.setColor(highlightColor);
- g.drawLine(trackBounds.width - 1, 0, trackBounds.width - 1, trackBounds.height - 1);
- } else {
- PlasticUtils.drawDisabledBorder(g, 0, 0, trackBounds.width, trackBounds.height);
- }
-
- if (!isFreeStanding) {
- if (!leftToRight) {
- trackBounds.width -= 1;
- g.translate(1, 0);
- } else {
- trackBounds.width -= 2;
- }
- }
- } else { // HORIZONTAL
- if (!isFreeStanding) {
- trackBounds.height += 2;
- }
-
- if (c.isEnabled()) {
- g.setColor(darkShadowColor);
- g.drawLine(0, 0, trackBounds.width - 1, 0); // top
- g.drawLine(0, 1, 0, trackBounds.height - 2); // left
- g.drawLine(0, trackBounds.height - 2, trackBounds.width - 1, trackBounds.height - 2);
- // bottom
- g.drawLine(trackBounds.width - 1, 1, trackBounds.width - 1, trackBounds.height - 1);
-
- // right
- g.setColor(shadowColor);
- // g.setColor( Color.red);
- g.drawLine(1, 1, trackBounds.width - 2, 1); // top
- g.drawLine(1, 1, 1, trackBounds.height - 3); // left
- g.drawLine(0, trackBounds.height - 1, trackBounds.width - 1, trackBounds.height - 1);
- // bottom
- if (scrollbar.getValue() != scrollbar.getMaximum()) { // thumb shadow
- int x = thumbRect.x + thumbRect.width - trackBounds.x;
- g.drawLine(x, 1, x, trackBounds.height - 1);
- }
- } else {
- PlasticUtils.drawDisabledBorder(g, 0, 0, trackBounds.width, trackBounds.height);
- }
-
- if (!isFreeStanding) {
- trackBounds.height -= 2;
- }
- }
- g.translate(-trackBounds.x, -trackBounds.y);
- }
-
-
- @Override
- protected void paintThumb(Graphics g, JComponent c, Rectangle thumbBounds) {
- if (!c.isEnabled()) {
- return;
- }
-
- boolean leftToRight = PlasticUtils.isLeftToRight(c);
-
- g.translate(thumbBounds.x, thumbBounds.y);
-
- if (scrollbar.getOrientation() == Adjustable.VERTICAL) {
- if (!isFreeStanding) {
- if (!leftToRight) {
- thumbBounds.width += 1;
- g.translate(-1, 0);
- } else {
- thumbBounds.width += 2;
- }
-
- }
-
- g.setColor(thumbColor);
- g.fillRect(0, 0, thumbBounds.width - 2, thumbBounds.height - 1);
-
- g.setColor(thumbShadow);
- g.drawRect(0, 0, thumbBounds.width - 2, thumbBounds.height - 1);
-
- g.setColor(thumbHighlightColor);
- g.drawLine(1, 1, thumbBounds.width - 3, 1);
- g.drawLine(1, 1, 1, thumbBounds.height - 2);
-
- paintBumps(g, c, 3, 4, thumbBounds.width - 6, thumbBounds.height - 7);
-
- if (!isFreeStanding) {
- if (!leftToRight) {
- thumbBounds.width -= 1;
- g.translate(1, 0);
- } else {
- thumbBounds.width -= 2;
- }
- }
- } else { // HORIZONTAL
- if (!isFreeStanding) {
- thumbBounds.height += 2;
- }
-
- g.setColor(thumbColor);
- g.fillRect(0, 0, thumbBounds.width - 1, thumbBounds.height - 2);
-
- g.setColor(thumbShadow);
- g.drawRect(0, 0, thumbBounds.width - 1, thumbBounds.height - 2);
-
- g.setColor(thumbHighlightColor);
- g.drawLine(1, 1, thumbBounds.width - 2, 1);
- g.drawLine(1, 1, 1, thumbBounds.height - 3);
-
- paintBumps(g, c, 4, 3, thumbBounds.width - 7, thumbBounds.height - 6);
-
- if (!isFreeStanding) {
- thumbBounds.height -= 2;
- }
- }
- g.translate(-thumbBounds.x, -thumbBounds.y);
-
- if (PlasticUtils.is3D(PROPERTY_PREFIX)) {
- paintThumb3D(g, thumbBounds);
- }
-
- }
-
-
- private void paintBumps(Graphics g, JComponent c, int x, int y, int width, int height) {
- if (!useNarrowBumps()) {
- bumps.setBumpArea(width, height);
- bumps.paintIcon(c, g, x, y);
- } else {
- int maxWidth = UIManager.getInt(MAX_BUMPS_WIDTH_KEY);
- int myWidth = Math.min(maxWidth, width);
- int myHeight = Math.min(maxWidth, height);
- int myX = x + (width - myWidth) / 2;
- int myY = y + (height - myHeight) / 2;
- bumps.setBumpArea(myWidth, myHeight);
- bumps.paintIcon(c, g, myX, myY);
- }
- }
-
-
- private void paintThumb3D(Graphics g, Rectangle thumbBounds) {
- boolean isHorizontal = scrollbar.getOrientation() == Adjustable.HORIZONTAL;
- int width = thumbBounds.width - (isHorizontal ? 3 : 1);
- int height = thumbBounds.height - (isHorizontal ? 1 : 3);
- Rectangle r = new Rectangle(thumbBounds.x + 2, thumbBounds.y + 2, width, height);
- PlasticUtils.addLight3DEffekt(g, r, isHorizontal);
- }
-
-
- // Accessing Special Client Properties ************************************
-
- private static boolean useNarrowBumps() {
- Object value = UIManager.get(MAX_BUMPS_WIDTH_KEY);
- return value != null && value instanceof Integer;
- }
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticScrollPaneUI.java b/src/core/com/jgoodies/looks/plastic/PlasticScrollPaneUI.java
deleted file mode 100644
index 210a3cd..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticScrollPaneUI.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.JComponent;
-import javax.swing.JScrollPane;
-import javax.swing.LookAndFeel;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalScrollPaneUI;
-
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Plastic L&Fl implementation of {@code ScrollPaneUI}.
- * Installs an etched border if the client property
- * {@code Options.IS_ETCHED_KEY} is set.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see com.jgoodies.looks.Options#IS_ETCHED_KEY
- */
-public final class PlasticScrollPaneUI extends MetalScrollPaneUI {
-
- /**
- * Holds the listener that handles changes in the etched border property.
- */
- private PropertyChangeListener borderStyleChangeHandler;
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticScrollPaneUI();
- }
-
- @Override
- protected void installDefaults(JScrollPane scrollPane) {
- super.installDefaults(scrollPane);
- installEtchedBorder(scrollPane);
- }
-
-
- // Managing the Etched Property *******************************************
-
- @Override
- public void installListeners(JScrollPane scrollPane) {
- super.installListeners(scrollPane);
- borderStyleChangeHandler = new BorderStyleChangeHandler();
- scrollPane.addPropertyChangeListener(Options.IS_ETCHED_KEY, borderStyleChangeHandler);
- }
-
- @Override
- protected void uninstallListeners(JComponent c) {
- ((JScrollPane) c).removePropertyChangeListener(Options.IS_ETCHED_KEY,
- borderStyleChangeHandler);
- super.uninstallListeners(c);
- }
-
- private static void installEtchedBorder(JScrollPane scrollPane) {
- Object value = scrollPane.getClientProperty(Options.IS_ETCHED_KEY);
- boolean hasEtchedBorder = Boolean.TRUE.equals(value);
- LookAndFeel.installBorder(scrollPane,
- hasEtchedBorder
- ? "ScrollPane.etchedBorder"
- : "ScrollPane.border");
- }
-
- private class BorderStyleChangeHandler implements PropertyChangeListener {
-
- @Override
- public void propertyChange(PropertyChangeEvent evt) {
- JScrollPane scrollPane = (JScrollPane) evt.getSource();
- installEtchedBorder(scrollPane);
- }
-
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticSeparatorUI.java b/src/core/com/jgoodies/looks/plastic/PlasticSeparatorUI.java
deleted file mode 100644
index d9501bd..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticSeparatorUI.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalSeparatorUI;
-
-
-/**
- * The JGoodies Plastic L&F implementation of {@code SeparatorUI}.
- * It differs from its superclass in that it uses a shared UI delegate.<p>
- *
- * Thanks to Andrej Golovnin for his feedback and suggestions.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class PlasticSeparatorUI extends MetalSeparatorUI {
-
- /** Shared UI object. */
- private static ComponentUI separatorUI;
-
- public static ComponentUI createUI(JComponent c) {
- if (separatorUI == null) {
- separatorUI = new PlasticSeparatorUI();
- }
- return separatorUI;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticSpinnerUI.java b/src/core/com/jgoodies/looks/plastic/PlasticSpinnerUI.java
deleted file mode 100644
index f13c779..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticSpinnerUI.java
+++ /dev/null
@@ -1,183 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Component;
-import java.awt.Insets;
-import java.awt.LayoutManager;
-
-import javax.swing.*;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicSpinnerUI;
-
-import com.jgoodies.looks.common.ExtBasicSpinnerLayout;
-
-
-/**
- * The JGoodies Plastic Look&Feel implementation of {@code SpinnerUI}.
- * Configures the default editor to adjust font baselines and component
- * bounds. Also, changes the border of the buttons and the size of the arrows.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.13 $
- */
-public class PlasticSpinnerUI extends BasicSpinnerUI {
-
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticSpinnerUI();
- }
-
-
- protected Component createArrowButton(int direction) {
- return new SpinnerArrowButton(direction);
- }
-
-
- /**
- * Create a {@code LayoutManager} that manages the {@code editor},
- * {@code nextButton}, and {@code previousButton} children
- * of the JSpinner. These three children must be added with a constraint
- * that identifies their role: "Editor", "Next", and "Previous". The
- * default layout manager can handle the absence of any of these children.
- *
- * @return a LayoutManager for the editor, next button, and previous
- * button.
- * @see #createNextButton
- * @see #createPreviousButton
- * @see #createEditor
- */
- @Override
- protected LayoutManager createLayout() {
- return new ExtBasicSpinnerLayout();
- }
-
-
- /**
- * This method is called by installUI to get the editor component
- * of the {@code JSpinner}. By default it just returns
- * {@code JSpinner.getEditor()}. Subclasses can override
- * {@code createEditor} to return a component that contains
- * the spinner's editor or null, if they're going to handle adding
- * the editor to the {@code JSpinner} in an
- * {@code installUI} override.
- * <p>
- * Typically this method would be overridden to wrap the editor
- * with a container with a custom border, since one can't assume
- * that the editors border can be set directly.
- * <p>
- * The {@code replaceEditor} method is called when the spinners
- * editor is changed with {@code JSpinner.setEditor}. If you've
- * overriden this method, then you'll probably want to override
- * {@code replaceEditor} as well.
- *
- * @return the JSpinners editor JComponent, spinner.getEditor() by default
- * @see #installUI
- * @see #replaceEditor
- * @see JSpinner#getEditor
- */
- @Override
- protected JComponent createEditor() {
- JComponent editor = spinner.getEditor();
- configureEditorBorder(editor);
- return editor;
- }
-
- /**
- * Called by the {@code PropertyChangeListener} when the
- * {@code JSpinner} editor property changes. It's the responsibility
- * of this method to remove the old editor and add the new one. By
- * default this operation is just:
- * <pre>
- * spinner.remove(oldEditor);
- * spinner.add(newEditor, "Editor");
- * </pre>
- * The implementation of {@code replaceEditor} should be coordinated
- * with the {@code createEditor} method.
- *
- * @see #createEditor
- * @see #createPropertyChangeListener
- */
- @Override
- protected void replaceEditor(JComponent oldEditor, JComponent newEditor) {
- spinner.remove(oldEditor);
- configureEditorBorder(newEditor);
- spinner.add(newEditor, "Editor");
- }
-
-
- /**
- * Sets an empty border with the default text insets.
- */
- private static void configureEditorBorder(JComponent editor) {
- if (editor instanceof JSpinner.DefaultEditor) {
- JSpinner.DefaultEditor defaultEditor = (JSpinner.DefaultEditor) editor;
- JTextField editorField = defaultEditor.getTextField();
- Insets insets = UIManager.getInsets("Spinner.defaultEditorInsets");
- editorField.setBorder(new EmptyBorder(insets));
- } else if ( editor instanceof JPanel
- && editor.getBorder() == null
- && editor.getComponentCount() > 0) {
- JComponent editorField = (JComponent) editor.getComponent(0);
- Insets insets = UIManager.getInsets("Spinner.defaultEditorInsets");
- editorField.setBorder(new EmptyBorder(insets));
- }
- }
-
- /**
- * It differs from its superclass in that it uses the same formula as JDK
- * to calculate the arrow height.
- */
- private static final class SpinnerArrowButton extends PlasticArrowButton {
- private SpinnerArrowButton(int direction) {
- super(direction, UIManager.getInt("ScrollBar.width"), true);
- }
-
- @Override
- protected int calculateArrowHeight(int height, int width) {
- int arrowHeight = Math.min((height - 4) / 3, (width - 4) / 3);
- return Math.max(arrowHeight, 3);
- }
-
- @Override
- protected int calculateArrowOffset() {
- return 1;
- }
-
- @Override
- protected boolean isPaintingNorthBottom() {
- return true;
- }
-
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticSplitPaneDivider.java b/src/core/com/jgoodies/looks/plastic/PlasticSplitPaneDivider.java
deleted file mode 100644
index 77895df..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticSplitPaneDivider.java
+++ /dev/null
@@ -1,147 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Graphics;
-
-import javax.swing.JButton;
-import javax.swing.plaf.basic.BasicSplitPaneDivider;
-import javax.swing.plaf.basic.BasicSplitPaneUI;
-
-
-/**
- * Paints a single drag symbol instead of many bumps.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see PlasticSplitPaneUI
- */
-final class PlasticSplitPaneDivider extends BasicSplitPaneDivider {
-
-
- PlasticSplitPaneDivider(BasicSplitPaneUI ui) {
- super(ui);
- }
-
- @Override
- protected JButton createLeftOneTouchButton() {
- JButton btn = super.createLeftOneTouchButton();
- btn.setOpaque(false);
- return btn;
- }
-
- @Override
- protected JButton createRightOneTouchButton() {
- JButton btn = super.createRightOneTouchButton();
- btn.setOpaque(false);
- return btn;
- }
-
- @Override
- public void paint(Graphics g) {
- if (splitPane.isOpaque()) {
- Color bgColor = getBackground();
- if (bgColor != null) {
- g.setColor(bgColor);
- g.fillRect(0, 0, getWidth(), getHeight());
- }
- }
-
- /*
- Object value = splitPane.getClientProperty("add3D");
- if (value != null && value.equals(Boolean.TRUE)) {
- Rectangle r = new Rectangle(0, 0, size.width, size.height);
- FreebopUtils.addLight3DEffekt(g, r, true, false);
- }
- */
-
- //paintDragRectangle(g);
- super.paint(g);
- }
-
- /*
- private void paintDragRectangle(Graphics g) {
- Dimension size = getSize();
- int xCenter = size.width / 2;
- int yCenter = size.height / 2;
- int x = xCenter - 2;
- int y = yCenter - 2;
- int w = 4;
- int h = 4;
-
- Color down = UIManager.getColor("controlDkShadow");
- Color up = UIManager.getColor("controlHighlight");
-
- g.translate(x, y);
-
- g.setColor(down);
- g.drawLine(0, 1, 0, h - 1); // left
- g.drawLine(0, 0, w - 1, 0); // top
-
- g.setColor(up);
- g.drawLine(w - 1, 1, w - 1, h - 1);
- g.drawLine(1, h - 1, w - 1, h - 1);
-
- g.translate(-x, -y);
-
- super.paint(g);
- }
-
-
- private void paintDragLines(Graphics g) {
- Dimension size = getSize();
- Color bgColor = getBackground();
-
- if (bgColor != null) {
- g.setColor(bgColor);
- g.fillRect(0, 0, size.width, size.height);
- }
-
- int xCenter = size.width / 2;
- int yCenter = size.height / 2;
- int y0 = yCenter - 10;
- int y1 = yCenter + 10;
-
- Color dark = UIManager.getColor("controlDkShadow");
- int bars = 3;
-
- g.setColor(dark);
- for (int i = 0; i < bars; i++) {
- int x = 2 * i + xCenter - bars;
- g.drawLine(x, y0, x, y1);
- }
-
- super.paint(g);
- }
- */
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticSplitPaneUI.java b/src/core/com/jgoodies/looks/plastic/PlasticSplitPaneUI.java
deleted file mode 100644
index d979f60..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticSplitPaneUI.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicSplitPaneDivider;
-import javax.swing.plaf.basic.BasicSplitPaneUI;
-
-
-/**
- * The JGoodies Plastic L&F implementation of {@code SplitPaneUI}.
- * Uses a special divider that paints modified one-touch buttons.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see com.jgoodies.looks.plastic.PlasticSplitPaneDivider
- */
-public final class PlasticSplitPaneUI extends BasicSplitPaneUI {
-
-
- public static ComponentUI createUI(JComponent x) {
- return new PlasticSplitPaneUI();
- }
-
-
- /**
- * Creates and returns the modified default divider.
- */
- @Override
- public BasicSplitPaneDivider createDefaultDivider() {
- return new PlasticSplitPaneDivider(this);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticTabbedPaneUI.java b/src/core/com/jgoodies/looks/plastic/PlasticTabbedPaneUI.java
deleted file mode 100644
index 8c2c8c7..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticTabbedPaneUI.java
+++ /dev/null
@@ -1,3189 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.*;
-import java.awt.event.ActionEvent;
-import java.awt.event.ActionListener;
-import java.awt.event.MouseEvent;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.*;
-import javax.swing.event.ChangeEvent;
-import javax.swing.event.ChangeListener;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicTabbedPaneUI;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-import javax.swing.plaf.metal.MetalTabbedPaneUI;
-import javax.swing.text.View;
-
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Plastic Look&Feel implementation of
- * {@code TabbedPaneUI}. It differs from its superclass
- * {@code MetalTabbedPaneUI} in that it paints new tab shapes,
- * provides two options, and supports ClearLook.
- * <p>
- * You can enable or disable icons in tabs globally via
- * com.jgoodies.looks.Options.setTabIconsEnabled(boolean).
- * <p>
- * To disable the content border set
- * <pre>
- * JTabbedPane tabbedPane = new JTabbedPane();
- * tabbedPane.putClientProperty(Option.NO_CONTENT_BORDER_KEY, Boolean.TRUE);
- * </pre>
- * To paint embedded tabs use
- * <pre>
- * JTabbedPane tabbedPane = new JTabbedPane();
- * tabbedPane.putClientProperty(Option.EMBEDDED_TABS_KEY, Boolean.TRUE);
- * </pre>
- * <p>
- * There's a special mode that helps you detect content borders in
- * heavily wrapped component hierarchies - such as the NetBeans IDE.
- * In this marked mode the content border is painted as a Magenta line.
- * You can enable this mode by setting the System property
- * <tt>markContentBorders</tt> to <tt>true</tt>; in a command line:
- * <pre>
- * java -DmarkContentBorders=true
- * </pre><p>
- *
- * Thanks to Andrej Golovnin for his feedback and suggestions.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.15 $
- *
- * @see Options
- */
-public final class PlasticTabbedPaneUI extends MetalTabbedPaneUI {
-
-
- // State ******************************************************************
-
- /**
- * Describes if tabs are painted with or without icons.
- */
- private static boolean isTabIconsEnabled = Options.isTabIconsEnabled();
-
- /**
- * Describes if we paint no content border or not; is false by default.
- * You can disable the content border by setting the client property
- * Options.NO_CONTENT_BORDER_KEY to Boolean.TRUE;
- */
- private Boolean noContentBorder;
-
- /**
- * Describes if we paint tabs in an embedded style that is with
- * less decoration; this is false by default.
- * You can enable the embedded tabs style by setting the client property
- * Options.EMBEDDED_TABS_KEY to Boolean.TRUE.
- */
- private Boolean embeddedTabs;
-
- /**
- * Holds the renderer that is used to render the tabs.
- */
- private AbstractRenderer renderer;
-
-
- /** For use when tabLayoutPolicy == SCROLL_TAB_LAYOUT. */
- private ScrollableTabSupport tabScroller;
-
- /**
- * Creates the {@code PlasticTabbedPaneUI}.
- *
- * @see javax.swing.plaf.ComponentUI#createUI(JComponent)
- */
- public static ComponentUI createUI(JComponent tabPane) {
- return new PlasticTabbedPaneUI();
- }
-
- /**
- * Installs the UI.
- *
- * @see javax.swing.plaf.ComponentUI#installUI(JComponent)
- */
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- embeddedTabs = (Boolean) c.getClientProperty(Options.EMBEDDED_TABS_KEY);
- noContentBorder = (Boolean) c.getClientProperty(Options.NO_CONTENT_BORDER_KEY);
- renderer = createRenderer(tabPane);
- }
-
- /**
- * Uninstalls the UI.
- * @see javax.swing.plaf.ComponentUI#uninstallUI(JComponent)
- */
- @Override
- public void uninstallUI(JComponent c) {
- renderer = null;
- super.uninstallUI(c);
- }
-
- /**
- * Creates and installs any required subcomponents for the JTabbedPane.
- * Invoked by installUI.
- * @see javax.swing.plaf.basic.BasicTabbedPaneUI#installComponents()
- */
- @Override
- protected void installComponents() {
- if (scrollableTabLayoutEnabled()) {
- if (tabScroller == null) {
- tabScroller = new ScrollableTabSupport(tabPane.getTabPlacement());
- tabPane.add(tabScroller.viewport);
- }
- }
- }
-
- /**
- * Removes any installed subcomponents from the JTabbedPane.
- * Invoked by uninstallUI.
- * @see javax.swing.plaf.basic.BasicTabbedPaneUI#uninstallComponents()
- */
- @Override
- protected void uninstallComponents() {
- if (scrollableTabLayoutEnabled()) {
- tabPane.remove(tabScroller.viewport);
- tabPane.remove(tabScroller.scrollForwardButton);
- tabPane.remove(tabScroller.scrollBackwardButton);
- tabScroller = null;
- }
- }
-
-
- @Override
- protected void installKeyboardActions() {
- super.installKeyboardActions();
- // if the layout policy is the SCROLL_TAB_LAYOUT, then replace
- // the forward and backward actions, installed in the action map
- // in the supper class, by our own.
- if (scrollableTabLayoutEnabled()) {
- Action forwardAction = new ScrollTabsForwardAction();
- Action backwardAction = new ScrollTabsBackwardAction();
- ActionMap am = SwingUtilities.getUIActionMap(tabPane);
- am.put("scrollTabsForwardAction", forwardAction);
- am.put("scrollTabsBackwardAction", backwardAction);
- tabScroller.scrollForwardButton.setAction(forwardAction);
- tabScroller.scrollBackwardButton.setAction(backwardAction);
- }
- }
-
- /**
- * Checks and answers if content border will be painted.
- * This is controlled by the component's client property
- * Options.NO_CONTENT_BORDER or Options.EMBEDDED.
- */
- private boolean hasNoContentBorder() {
- return Boolean.TRUE.equals(noContentBorder);
- }
-
- /**
- * Checks and answers if tabs are painted with minimal decoration.
- */
- private boolean hasEmbeddedTabs() {
- return Boolean.TRUE.equals(embeddedTabs);
- }
-
- /**
- * Creates the renderer used to lay out and paint the tabs.
- * @param tabbedPane the UIs component
- * @return AbstractRenderer the renderer that will be used to paint
- */
- private AbstractRenderer createRenderer(JTabbedPane tabbedPane) {
- return hasEmbeddedTabs()
- ? AbstractRenderer.createEmbeddedRenderer(tabbedPane)
- : AbstractRenderer.createRenderer(tabPane);
- }
-
- /**
- * Creates and answer a handler that listens to property changes.
- * Unlike the superclass BasicTabbedPane, the PlasticTabbedPaneUI
- * uses an extended Handler.
- */
- @Override
- protected PropertyChangeListener createPropertyChangeListener() {
- return new MyPropertyChangeHandler();
- }
-
- @Override
- protected ChangeListener createChangeListener() {
- return new TabSelectionHandler();
- }
-
- /*
- * Private helper method for the next three methods.
- */
- private void doLayout() {
- tabPane.revalidate();
- tabPane.repaint();
- }
-
- /**
- * Updates the renderer and layout. This message is sent by
- * my PropertyChangeHandler whenever the tab placement changes.
- */
- private void tabPlacementChanged() {
- renderer = createRenderer(tabPane);
- if (scrollableTabLayoutEnabled()) {
- tabScroller.createButtons();
- }
- doLayout();
- }
-
- /**
- * Updates the embedded tabs property. This message is sent by
- * my PropertyChangeHandler whenever the embedded tabs property changes.
- */
- private void embeddedTabsPropertyChanged(Boolean newValue) {
- embeddedTabs = newValue;
- renderer = createRenderer(tabPane);
- doLayout();
- }
-
- /**
- * Updates the no content border property. This message is sent
- * by my PropertyChangeHandler whenever the noContentBorder
- * property changes.
- */
- private void noContentBorderPropertyChanged(Boolean newValue) {
- noContentBorder = newValue;
- tabPane.repaint();
- }
-
- @Override
- public void paint(Graphics g, JComponent c) {
- int selectedIndex = tabPane.getSelectedIndex();
- int tabPlacement = tabPane.getTabPlacement();
-
- ensureCurrentLayout();
-
- // Paint tab area
- // If scrollable tabs are enabled, the tab area will be
- // painted by the scrollable tab panel instead.
- //
- if (!scrollableTabLayoutEnabled()) { // WRAP_TAB_LAYOUT
- paintTabArea(g, tabPlacement, selectedIndex);
- }
-
- // Paint content border
- paintContentBorder(g, tabPlacement, selectedIndex);
- }
-
- @Override
- protected void paintTab(Graphics g, int tabPlacement, Rectangle[] rects,
- int tabIndex, Rectangle iconRect, Rectangle textRect) {
- Rectangle tabRect = rects[tabIndex];
- int selectedIndex = tabPane.getSelectedIndex();
- boolean isSelected = selectedIndex == tabIndex;
- Graphics2D g2 = null;
- Polygon cropShape = null;
- Shape save = null;
- int cropx = 0;
- int cropy = 0;
-
- if (scrollableTabLayoutEnabled()) {
- if (g instanceof Graphics2D) {
- g2 = (Graphics2D) g;
-
- // Render visual for cropped tab edge...
- Rectangle viewRect = tabScroller.viewport.getViewRect();
- int cropline;
- switch (tabPlacement) {
- case LEFT:
- case RIGHT:
- cropline = viewRect.y + viewRect.height;
- if (tabRect.y < cropline
- && tabRect.y + tabRect.height > cropline) {
- cropShape = createCroppedTabClip(tabPlacement, tabRect,
- cropline);
- cropx = tabRect.x;
- cropy = cropline - 1;
- }
- break;
- case TOP:
- case BOTTOM:
- default:
- cropline = viewRect.x + viewRect.width;
- if (tabRect.x < cropline
- && tabRect.x + tabRect.width > cropline) {
- cropShape = createCroppedTabClip(tabPlacement, tabRect,
- cropline);
- cropx = cropline - 1;
- cropy = tabRect.y;
- }
- }
- if (cropShape != null) {
- save = g.getClip();
- g2.clip(cropShape);
- }
- }
- }
-
- paintTabBackground(g, tabPlacement, tabIndex, tabRect.x, tabRect.y,
- tabRect.width, tabRect.height, isSelected);
-
- paintTabBorder(g, tabPlacement, tabIndex, tabRect.x, tabRect.y,
- tabRect.width, tabRect.height, isSelected);
-
- String title = tabPane.getTitleAt(tabIndex);
- Font font = tabPane.getFont();
- FontMetrics metrics = g.getFontMetrics(font);
- Icon icon = getIconForTab(tabIndex);
-
- layoutLabel(tabPlacement, metrics, tabIndex, title, icon, tabRect,
- iconRect, textRect, isSelected);
-
- paintText(g, tabPlacement, font, metrics, tabIndex, title, textRect,
- isSelected);
-
- paintIcon(g, tabPlacement, tabIndex, icon, iconRect, isSelected);
-
- paintFocusIndicator(g, tabPlacement, rects, tabIndex, iconRect,
- textRect, isSelected);
-
- if (cropShape != null) {
- paintCroppedTabEdge(g, tabPlacement, tabIndex, isSelected, cropx,
- cropy);
- g.setClip(save);
- }
- }
-
- /*
- * This method will create and return a polygon shape for the given tab
- * rectangle which has been cropped at the specified cropline with a torn
- * edge visual. e.g. A "File" tab which has cropped been cropped just after
- * the "i":
- * -------------
- * | ..... |
- * | . |
- * | ... . |
- * | . . |
- * | . . |
- * | . . |
- * --------------
- *
- * The x, y arrays below define the pattern used to create a "torn" edge
- * segment which is repeated to fill the edge of the tab. For tabs placed on
- * TOP and BOTTOM, this righthand torn edge is created by line segments
- * which are defined by coordinates obtained by subtracting xCropLen[i] from
- * (tab.x + tab.width) and adding yCroplen[i] to (tab.y). For tabs placed on
- * LEFT or RIGHT, the bottom torn edge is created by subtracting xCropLen[i]
- * from (tab.y + tab.height) and adding yCropLen[i] to (tab.x).
- */
- private final int[] xCropLen = { 1, 1, 0, 0, 1, 1, 2, 2 };
-
- private final int[] yCropLen = { 0, 3, 3, 6, 6, 9, 9, 12 };
-
- private static final int CROP_SEGMENT = 12;
-
- private Polygon createCroppedTabClip(int tabPlacement, Rectangle tabRect,
- int cropline) {
- int rlen = 0;
- int start = 0;
- int end = 0;
- int ostart = 0;
-
- switch (tabPlacement) {
- case LEFT:
- case RIGHT:
- rlen = tabRect.width;
- start = tabRect.x;
- end = tabRect.x + tabRect.width;
- ostart = tabRect.y;
- break;
- case TOP:
- case BOTTOM:
- default:
- rlen = tabRect.height;
- start = tabRect.y;
- end = tabRect.y + tabRect.height;
- ostart = tabRect.x;
- }
- int rcnt = rlen / CROP_SEGMENT;
- if (rlen % CROP_SEGMENT > 0) {
- rcnt++;
- }
- int npts = 2 + rcnt * 8;
- int[] xp = new int[npts];
- int[] yp = new int[npts];
- int pcnt = 0;
-
- xp[pcnt] = ostart;
- yp[pcnt++] = end;
- xp[pcnt] = ostart;
- yp[pcnt++] = start;
- for (int i = 0; i < rcnt; i++) {
- for (int j = 0; j < xCropLen.length; j++) {
- xp[pcnt] = cropline - xCropLen[j];
- yp[pcnt] = start + i * CROP_SEGMENT + yCropLen[j];
- if (yp[pcnt] >= end) {
- yp[pcnt] = end;
- pcnt++;
- break;
- }
- pcnt++;
- }
- }
- if (tabPlacement == SwingConstants.TOP
- || tabPlacement == SwingConstants.BOTTOM) {
- return new Polygon(xp, yp, pcnt);
-
- }
- //LEFT or RIGHT
- return new Polygon(yp, xp, pcnt);
- }
-
- /* If tabLayoutPolicy == SCROLL_TAB_LAYOUT, this method will paint an edge
- * indicating the tab is cropped in the viewport display
- */
- private void paintCroppedTabEdge(Graphics g, int tabPlacement,
- int tabIndex, boolean isSelected, int x, int y) {
- switch (tabPlacement) {
- case LEFT:
- case RIGHT:
- int xx = x;
- g.setColor(shadow);
- while (xx <= x + rects[tabIndex].width) {
- for (int i = 0; i < xCropLen.length; i += 2) {
- g.drawLine(xx + yCropLen[i], y - xCropLen[i], xx
- + yCropLen[i + 1] - 1, y - xCropLen[i + 1]);
- }
- xx += CROP_SEGMENT;
- }
- break;
- case TOP:
- case BOTTOM:
- default:
- int yy = y;
- g.setColor(shadow);
- while (yy <= y + rects[tabIndex].height) {
- for (int i = 0; i < xCropLen.length; i += 2) {
- g.drawLine(x - xCropLen[i], yy + yCropLen[i], x
- - xCropLen[i + 1], yy + yCropLen[i + 1] - 1);
- }
- yy += CROP_SEGMENT;
- }
- }
- }
-
- private void ensureCurrentLayout() {
- if (!tabPane.isValid()) {
- tabPane.validate();
- }
- /* If tabPane doesn't have a peer yet, the validate() call will
- * silently fail. We handle that by forcing a layout if tabPane
- * is still invalid. See bug 4237677.
- */
- if (!tabPane.isValid()) {
- TabbedPaneLayout layout = (TabbedPaneLayout) tabPane.getLayout();
- layout.calculateLayoutInfo();
- }
- }
-
- /**
- * Returns the tab index which intersects the specified point
- * in the JTabbedPane's coordinate space.
- */
- @Override
- public int tabForCoordinate(JTabbedPane pane, int x, int y) {
- ensureCurrentLayout();
- Point p = new Point(x, y);
-
- if (scrollableTabLayoutEnabled()) {
- translatePointToTabPanel(x, y, p);
- Rectangle viewRect = tabScroller.viewport.getViewRect();
- if (!viewRect.contains(p)) {
- return -1;
- }
- }
- int tabCount = tabPane.getTabCount();
- for (int i = 0; i < tabCount; i++) {
- if (rects[i].contains(p.x, p.y)) {
- return i;
- }
- }
- return -1;
- }
-
- @Override
- protected Rectangle getTabBounds(int tabIndex, Rectangle dest) {
- dest.width = rects[tabIndex].width;
- dest.height = rects[tabIndex].height;
- if (scrollableTabLayoutEnabled()) { // SCROLL_TAB_LAYOUT
- // Need to translate coordinates based on viewport location &
- // view position
- Point vpp = tabScroller.viewport.getLocation();
- Point viewp = tabScroller.viewport.getViewPosition();
- dest.x = rects[tabIndex].x + vpp.x - viewp.x;
- dest.y = rects[tabIndex].y + vpp.y - viewp.y;
- } else { // WRAP_TAB_LAYOUT
- dest.x = rects[tabIndex].x;
- dest.y = rects[tabIndex].y;
- }
- return dest;
- }
-
- /**
- * Returns the index of the tab closest to the passed in location, note
- * that the returned tab may not contain the location x,y.
- */
- private int getClosestTab(int x, int y) {
- int min = 0;
- int tabCount = Math.min(rects.length, tabPane.getTabCount());
- int max = tabCount;
- int tabPlacement = tabPane.getTabPlacement();
- boolean useX = tabPlacement == TOP || tabPlacement == BOTTOM;
- int want = useX ? x : y;
-
- while (min != max) {
- int current = (max + min) / 2;
- int minLoc;
- int maxLoc;
-
- if (useX) {
- minLoc = rects[current].x;
- maxLoc = minLoc + rects[current].width;
- } else {
- minLoc = rects[current].y;
- maxLoc = minLoc + rects[current].height;
- }
- if (want < minLoc) {
- max = current;
- if (min == max) {
- return Math.max(0, current - 1);
- }
- } else if (want >= maxLoc) {
- min = current;
- if (max - min <= 1) {
- return Math.max(current + 1, tabCount - 1);
- }
- } else {
- return current;
- }
- }
- return min;
- }
-
- /**
- * Returns a point which is translated from the specified point in the
- * JTabbedPane's coordinate space to the coordinate space of the
- * ScrollableTabPanel. This is used for SCROLL_TAB_LAYOUT ONLY.
- */
- private Point translatePointToTabPanel(int srcx, int srcy, Point dest) {
- Point vpp = tabScroller.viewport.getLocation();
- Point viewp = tabScroller.viewport.getViewPosition();
- dest.x = srcx - vpp.x + viewp.x;
- dest.y = srcy - vpp.y + viewp.y;
- return dest;
- }
-
- @Override
- protected void paintTabArea(Graphics g, int tabPlacement, int selectedIndex) {
- int tabCount = tabPane.getTabCount();
-
- Rectangle iconRect = new Rectangle(),
- textRect = new Rectangle();
- Rectangle clipRect = g.getClipBounds();
-
- // Paint tabRuns of tabs from back to front
- for (int i = runCount - 1; i >= 0; i--) {
- int start = tabRuns[i];
- int next = tabRuns[i == runCount - 1 ? 0 : i + 1];
- int end = next != 0 ? next - 1 : tabCount - 1;
- for (int j = end; j >= start; j--) {
- if (j != selectedIndex && rects[j].intersects(clipRect)) {
- paintTab(g, tabPlacement, rects, j, iconRect, textRect);
- }
- }
- }
-
- // Paint selected tab if its in the front run
- // since it may overlap other tabs
- if (selectedIndex >= 0 && rects[selectedIndex].intersects(clipRect)) {
- paintTab(g, tabPlacement, rects, selectedIndex, iconRect, textRect);
- }
- }
-
- /*
- * Copied here from super(super)class to avoid labels being centered on
- * vertical tab runs if they consist of icon and text
- */
- @Override
- protected void layoutLabel(
- int tabPlacement,
- FontMetrics metrics,
- int tabIndex,
- String title,
- Icon icon,
- Rectangle tabRect,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- textRect.x = textRect.y = iconRect.x = iconRect.y = 0;
- //fix of issue #4
- View v = getTextViewForTab(tabIndex);
- if (v != null) {
- tabPane.putClientProperty("html", v);
- }
-
- Rectangle calcRectangle = new Rectangle(tabRect);
- if (isSelected) {
- Insets calcInsets = getSelectedTabPadInsets(tabPlacement);
- calcRectangle.x += calcInsets.left;
- calcRectangle.y += calcInsets.top;
- calcRectangle.width -= calcInsets.left + calcInsets.right;
- calcRectangle.height -= calcInsets.bottom + calcInsets.top;
- }
- int xNudge = getTabLabelShiftX(tabPlacement, tabIndex, isSelected);
- int yNudge = getTabLabelShiftY(tabPlacement, tabIndex, isSelected);
- if ((tabPlacement == RIGHT || tabPlacement == LEFT) && icon != null && title != null && !title.equals("")) {
- SwingUtilities.layoutCompoundLabel(
- tabPane,
- metrics,
- title,
- icon,
- SwingConstants.CENTER,
- SwingConstants.LEFT,
- SwingConstants.CENTER,
- SwingConstants.TRAILING,
- calcRectangle,
- iconRect,
- textRect,
- textIconGap);
- xNudge += 4;
- } else {
- SwingUtilities.layoutCompoundLabel(
- tabPane,
- metrics,
- title,
- icon,
- SwingConstants.CENTER,
- SwingConstants.CENTER,
- SwingConstants.CENTER,
- SwingConstants.TRAILING,
- calcRectangle,
- iconRect,
- textRect,
- textIconGap);
- iconRect.y += calcRectangle.height % 2;
- }
-
- //fix of issue #4
- tabPane.putClientProperty("html", null);
-
- iconRect.x += xNudge;
- iconRect.y += yNudge;
- textRect.x += xNudge;
- textRect.y += yNudge;
- }
-
- /**
- * Answers the icon for the tab with the specified index.
- * In case, we have globally switched of the use tab icons,
- * we answer {@code null} if and only if we have a title.
- */
- @Override
- protected Icon getIconForTab(int tabIndex) {
- String title = tabPane.getTitleAt(tabIndex);
- boolean hasTitle = title != null && title.length() > 0;
- return !isTabIconsEnabled && hasTitle
- ? null
- : super.getIconForTab(tabIndex);
- }
-
- /**
- * Creates the layout manager used to set the tab's bounds.
- */
- @Override
- protected LayoutManager createLayoutManager() {
- if (tabPane.getTabLayoutPolicy() == JTabbedPane.SCROLL_TAB_LAYOUT) {
- return new TabbedPaneScrollLayout();
- }
- /* WRAP_TAB_LAYOUT */
- return new TabbedPaneLayout();
- }
-
- /* In an attempt to preserve backward compatibility for programs
- * which have extended BasicTabbedPaneUI to do their own layout, the
- * UI uses the installed layoutManager (and not tabLayoutPolicy) to
- * determine if scrollTabLayout is enabled.
- */
- private boolean scrollableTabLayoutEnabled() {
- return tabPane.getLayout() instanceof TabbedPaneScrollLayout;
- }
-
- protected boolean isTabInFirstRun(int tabIndex) {
- return getRunForTab(tabPane.getTabCount(), tabIndex) == 0;
- }
-
- @Override
- protected void paintContentBorder(Graphics g, int tabPlacement, int selectedIndex) {
- int width = tabPane.getWidth();
- int height = tabPane.getHeight();
- Insets insets = tabPane.getInsets();
-
- int x = insets.left;
- int y = insets.top;
- int w = width - insets.right - insets.left;
- int h = height - insets.top - insets.bottom;
-
- switch (tabPlacement) {
- case LEFT :
- x += calculateTabAreaWidth(tabPlacement, runCount, maxTabWidth);
- w -= x - insets.left;
- break;
- case RIGHT :
- w -= calculateTabAreaWidth(tabPlacement, runCount, maxTabWidth);
- break;
- case BOTTOM :
- h -= calculateTabAreaHeight(tabPlacement, runCount, maxTabHeight);
- break;
- case TOP :
- default :
- y += calculateTabAreaHeight(tabPlacement, runCount, maxTabHeight);
- h -= y - insets.top;
- }
- // Fill region behind content area
- g.setColor(selectColor == null
- ? tabPane.getBackground()
- : selectColor);
- g.fillRect(x, y, w, h);
-
- Rectangle selRect;
- selRect = selectedIndex < 0 ? null : getTabBounds(selectedIndex, calcRect);
- boolean drawBroken = selectedIndex >= 0 && isTabInFirstRun(selectedIndex);
- boolean isContentBorderPainted = !hasNoContentBorder();
- // It sounds a bit odd to call paintContentBorder with
- // a parameter isContentBorderPainted set to false.
- // But in this case the part of the border touching the tab
- // area will still be painted so best let the renderer decide.
- renderer.paintContentBorderTopEdge (g, x, y, w, h, drawBroken, selRect, isContentBorderPainted);
- renderer.paintContentBorderLeftEdge (g, x, y, w, h, drawBroken, selRect, isContentBorderPainted);
- renderer.paintContentBorderBottomEdge(g, x, y, w, h, drawBroken, selRect, isContentBorderPainted);
- renderer.paintContentBorderRightEdge (g, x, y, w, h, drawBroken, selRect, isContentBorderPainted);
- }
-
- //
- // Here comes a number of methods that are just delegated to the
- // appropriate renderer
- //
- /**
- * Returns the insets (i.e. the width) of the content Border.
- */
- @Override
- protected Insets getContentBorderInsets(int tabPlacement) {
- return renderer.getContentBorderInsets(super.getContentBorderInsets(tabPlacement));
- }
-
- /**
- * Returns the amount by which the Tab Area is inset.
- */
- @Override
- protected Insets getTabAreaInsets(int tabPlacement) {
- return renderer.getTabAreaInsets(super.getTabAreaInsets(tabPlacement));
- }
-
- /**
- * Returns the amount by which the label should be shifted horizontally.
- */
- @Override
- protected int getTabLabelShiftX(int tabPlacement, int tabIndex, boolean isSelected) {
- return renderer.getTabLabelShiftX(tabIndex, isSelected);
- }
-
- /**
- * Returns the amount by which the label should be shifted vertically.
- */
- @Override
- protected int getTabLabelShiftY(int tabPlacement, int tabIndex, boolean isSelected) {
- return renderer.getTabLabelShiftY(tabIndex, isSelected);
- }
-
- /**
- * Returns the amount (in pixels) by which two runs should overlap.
- */
- @Override
- protected int getTabRunOverlay(int tabPlacement) {
- return renderer.getTabRunOverlay(tabRunOverlay);
- }
-
- /**
- * This boolean controls wheather the given run should be padded to
- * use up as much space as the others (with more tabs in them).
- */
- @Override
- protected boolean shouldPadTabRun(int tabPlacement, int run) {
- return renderer.shouldPadTabRun(run, super.shouldPadTabRun(tabPlacement, run));
- }
-
- /**
- * Returns the amount by which the run number {@code run}
- * should be indented. Add six pixels for every run to make
- * diagonal lines align.
- */
- @Override
- protected int getTabRunIndent(int tabPlacement, int run) {
- return renderer.getTabRunIndent(run);
- }
-
- /**
- * Returns the insets for this tab.
- */
- @Override
- protected Insets getTabInsets(int tabPlacement, int tabIndex) {
- return renderer.getTabInsets(tabIndex, tabInsets);
- }
-
- /**
- * Returns the insets for selected tab.
- */
- @Override
- protected Insets getSelectedTabPadInsets(int tabPlacement) {
- return renderer.getSelectedTabPadInsets();
- }
-
- /**
- * Draws the rectancle around the Tab label which indicates keyboard focus.
- */
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- int tabPlacement,
- Rectangle[] rectangles,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- renderer.paintFocusIndicator(g, rectangles, tabIndex, iconRect, textRect, isSelected);
- }
-
- /**
- * Fills the background of the given tab to make sure overlap of
- * tabs is handled correctly.
- * Note: that tab backgrounds seem to be painted somewhere else, too.
- */
- @Override
- protected void paintTabBackground(Graphics g, int tabPlacement, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
- renderer.paintTabBackground(g, tabIndex, x, y, w, h, isSelected);
- }
-
- /**
- * Paints the border for one tab. Gets the bounds of the tab as parameters.
- * Note that the result is not clipped so you can paint outside that
- * rectangle. Tabs painted later on have a chance to overwrite though.
- */
- @Override
- protected void paintTabBorder(Graphics g, int tabPlacement, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
- renderer.paintTabBorder(g, tabIndex, x, y, w, h, isSelected);
- }
-
- /**
- * Answers wheather tab runs should be rotated. If true, the layout mechanism
- * will move the run containing the selected tab so that it touches
- * the content pane.
- */
- @Override
- protected boolean shouldRotateTabRuns(int tabPlacement) {
- return false;
- }
-
- private final class TabSelectionHandler implements ChangeListener {
-
- private final Rectangle rect = new Rectangle();
-
- @Override
- public void stateChanged(ChangeEvent e) {
- JTabbedPane tabPane = (JTabbedPane) e.getSource();
- tabPane.revalidate();
- tabPane.repaint();
-
- if (tabPane.getTabLayoutPolicy() == JTabbedPane.SCROLL_TAB_LAYOUT) {
- int index = tabPane.getSelectedIndex();
- if (index < rects.length && index != -1) {
- rect.setBounds(rects[index]);
- Point viewPosition = tabScroller.viewport.getViewPosition();
- if (rect.x < viewPosition.x) {
- rect.x -= renderer.getTabsOverlay();
- } else {
- rect.x += renderer.getTabsOverlay();
- }
- tabScroller.tabPanel.scrollRectToVisible(rect);
- }
- }
- }
- }
-
- /**
- * Catches and handles property change events. In addition to the super
- * class behavior we listen to changes of the ancestor, tab placement,
- * and JGoodies options for content border, and embedded tabs.
- */
- private final class MyPropertyChangeHandler
- extends BasicTabbedPaneUI.PropertyChangeHandler {
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String pName = e.getPropertyName();
-
- if (null == pName) {
- return;
- }
-
- super.propertyChange(e);
-
- if (pName.equals("tabPlacement")) {
- tabPlacementChanged();
- return;
- }
- if (pName.equals(Options.EMBEDDED_TABS_KEY)) {
- embeddedTabsPropertyChanged((Boolean) e.getNewValue());
- return;
- }
- if (pName.equals(Options.NO_CONTENT_BORDER_KEY)) {
- noContentBorderPropertyChanged((Boolean) e.getNewValue());
- return;
- }
- }
- }
-
- /**
- * Does all the layout work. The result is stored in the container
- * class's instance variables. Mainly the rects[] vector.
- */
- private class TabbedPaneLayout extends BasicTabbedPaneUI.TabbedPaneLayout {
-
- @Override
- protected void calculateTabRects(int tabPlacement, int tabCount) {
- FontMetrics metrics = getFontMetrics();
- Dimension size = tabPane.getSize();
- Insets insets = tabPane.getInsets();
- Insets theTabAreaInsets = getTabAreaInsets(tabPlacement);
- int fontHeight = metrics.getHeight();
- int selectedIndex = tabPane.getSelectedIndex();
- int theTabRunOverlay;
- int i, j;
- int x, y;
- int returnAt;
- boolean verticalTabRuns = tabPlacement == LEFT || tabPlacement == RIGHT;
- boolean leftToRight = PlasticUtils.isLeftToRight(tabPane);
-
- //
- // Calculate bounds within which a tab run must fit
- //
- switch (tabPlacement) {
- case LEFT :
- maxTabWidth = calculateMaxTabWidth(tabPlacement);
- x = insets.left + theTabAreaInsets.left;
- y = insets.top + theTabAreaInsets.top;
- returnAt = size.height - (insets.bottom + theTabAreaInsets.bottom);
- break;
- case RIGHT :
- maxTabWidth = calculateMaxTabWidth(tabPlacement);
- x = size.width - insets.right - theTabAreaInsets.right - maxTabWidth;
- y = insets.top + theTabAreaInsets.top;
- returnAt = size.height - (insets.bottom + theTabAreaInsets.bottom);
- break;
- case BOTTOM :
- maxTabHeight = calculateMaxTabHeight(tabPlacement);
- x = insets.left + theTabAreaInsets.left;
- y = size.height - insets.bottom - theTabAreaInsets.bottom - maxTabHeight;
- returnAt = size.width - (insets.right + theTabAreaInsets.right);
- break;
- case TOP :
- default :
- maxTabHeight = calculateMaxTabHeight(tabPlacement);
- x = insets.left + theTabAreaInsets.left;
- y = insets.top + theTabAreaInsets.top;
- returnAt = size.width - (insets.right + theTabAreaInsets.right);
- break;
- }
-
- theTabRunOverlay = getTabRunOverlay(tabPlacement);
-
- runCount = 0;
- selectedRun = -1;
- //keeps track of where we are in the current run.
- //this helps not to rely on fragile positioning
- //informaion to find out wheter the active Tab
- //is the first in run
- int tabInRun = -1;
- // make a copy of returnAt for the current run and modify
- // that so returnAt may still be used later on
- int runReturnAt = returnAt;
-
- if (tabCount == 0) {
- return;
- }
-
- // Run through tabs and partition them into runs
- Rectangle rect;
- for (i = 0; i < tabCount; i++) {
- rect = rects[i];
- tabInRun++;
-
- if (!verticalTabRuns) {
- // Tabs on TOP or BOTTOM....
- if (i > 0) {
- rect.x = rects[i - 1].x + rects[i - 1].width;
- } else {
- tabRuns[0] = 0;
- runCount = 1;
- maxTabWidth = 0;
- rect.x = x;
- // tabInRun = 0;
- }
- rect.width = calculateTabWidth(tabPlacement, i, metrics);
- maxTabWidth = Math.max(maxTabWidth, rect.width);
-
- // Never move a TAB down a run if it is the first in run.
- // Even if there isn't enough room, moving it to a fresh
- // line won't help.
- // if (rect.x != 2 + insets.left && rect.x + rect.width > returnAt) {
- // Never rely on phisical position information to determine
- // logical position (if you can avoid it)
- if (tabInRun != 0 && rect.x + rect.width > runReturnAt) {
- if (runCount > tabRuns.length - 1) {
- expandTabRunsArray();
- }
- // just created a new run, adjust some counters
- tabInRun = 0;
- tabRuns[runCount] = i;
- runCount++;
- rect.x = x;
- runReturnAt = runReturnAt - 2 * getTabRunIndent(tabPlacement, runCount);
- }
- // Initialize y position in case there's just one run
- rect.y = y;
- rect.height = maxTabHeight /* - 2*/;
-
- } else {
- // Tabs on LEFT or RIGHT...
- if (i > 0) {
- rect.y = rects[i - 1].y + rects[i - 1].height;
- } else {
- tabRuns[0] = 0;
- runCount = 1;
- maxTabHeight = 0;
- rect.y = y;
- // tabInRun = 0;
- }
- rect.height = calculateTabHeight(tabPlacement, i, fontHeight);
- maxTabHeight = Math.max(maxTabHeight, rect.height);
-
- // Never move a TAB over a run if it is the first in run.
- // Even if there isn't enough room, moving it to a fresh
- // run won't help.
- // if (rect.y != 2 + insets.top && rect.y + rect.height > returnAt) {
- if (tabInRun != 0 && rect.y + rect.height > runReturnAt) {
- if (runCount > tabRuns.length - 1) {
- expandTabRunsArray();
- }
- tabRuns[runCount] = i;
- runCount++;
- rect.y = y;
- tabInRun = 0;
- runReturnAt -= 2 * getTabRunIndent(tabPlacement, runCount);
- }
- // Initialize x position in case there's just one column
- rect.x = x;
- rect.width = maxTabWidth /* - 2*/;
-
- }
- if (i == selectedIndex) {
- selectedRun = runCount - 1;
- }
- }
-
- if (runCount > 1) {
- // Re-distribute tabs in case last run has leftover space
- //last line flush left is OK
- // normalizeTabRuns(tabPlacement, tabCount, verticalTabRuns? y : x, returnAt);
- //don't need to recalculate selectedRun if not changed
- // selectedRun = getRunForTab(tabCount, selectedIndex);
-
- // Rotate run array so that selected run is first
- if (shouldRotateTabRuns(tabPlacement)) {
- rotateTabRuns(tabPlacement, selectedRun);
- }
- }
-
- // Step through runs from back to front to calculate
- // tab y locations and to pad runs appropriately
- for (i = runCount - 1; i >= 0; i--) {
- int start = tabRuns[i];
- int next = tabRuns[i == runCount - 1 ? 0 : i + 1];
- int end = next != 0 ? next - 1 : tabCount - 1;
- int indent = getTabRunIndent(tabPlacement, i);
- if (!verticalTabRuns) {
- for (j = start; j <= end; j++) {
- rect = rects[j];
- rect.y = y;
- rect.x += indent;
- // try to make tabRunIndent symmetric
- // rect.width -= 2* indent + 20;
- }
- if (shouldPadTabRun(tabPlacement, i)) {
- padTabRun(tabPlacement, start, end, returnAt - 2 * indent);
- }
- if (tabPlacement == BOTTOM) {
- y -= maxTabHeight - theTabRunOverlay;
- } else {
- y += maxTabHeight - theTabRunOverlay;
- }
- } else {
- for (j = start; j <= end; j++) {
- rect = rects[j];
- rect.x = x;
- rect.y += indent;
- }
- if (shouldPadTabRun(tabPlacement, i)) {
- padTabRun(tabPlacement, start, end, returnAt - 2 * indent);
- }
- if (tabPlacement == RIGHT) {
- x -= maxTabWidth - theTabRunOverlay;
- } else {
- x += maxTabWidth - theTabRunOverlay;
- }
- }
- }
-
- // Pad the selected tab so that it appears raised in front
- padSelectedTab(tabPlacement, selectedIndex);
-
- // if right to left and tab placement on the top or
- // the bottom, flip x positions and adjust by widths
- if (!leftToRight && !verticalTabRuns) {
- int rightMargin = size.width - (insets.right + theTabAreaInsets.right);
- for (i = 0; i < tabCount; i++) {
- rects[i].x = rightMargin - rects[i].x - rects[i].width
- + renderer.getTabsOverlay();
- }
- }
- }
-
- /**
- * Overridden to insure the same behavior in JDK 6.0 as in JDK 5.0.
- */
- @Override
- protected void padSelectedTab(int tabPlacement, int selectedIndex) {
- if (selectedIndex >= 0) {
- Rectangle selRect = rects[selectedIndex];
- Insets padInsets = getSelectedTabPadInsets(tabPlacement);
- selRect.x -= padInsets.left;
- selRect.width += padInsets.left + padInsets.right;
- selRect.y -= padInsets.top;
- selRect.height += padInsets.top + padInsets.bottom;
- }
- }
-
- }
-
-
- private boolean requestFocusForVisibleComponent() {
- Component visibleComponent = getVisibleComponent();
- if (visibleComponent.isFocusable()) {
- visibleComponent.requestFocus();
- return true;
- }
- if (visibleComponent instanceof JComponent) {
- if (((JComponent) visibleComponent).requestDefaultFocus()) {
- return true;
- }
- }
- return false;
- }
-
- private static class ScrollTabsForwardAction extends AbstractAction {
-
- @Override
- public void actionPerformed(ActionEvent e) {
- JTabbedPane pane = null;
- Object src = e.getSource();
- if (src instanceof JTabbedPane) {
- pane = (JTabbedPane) src;
- } else if (src instanceof PlasticArrowButton) {
- pane = (JTabbedPane) ((PlasticArrowButton) src).getParent();
- } else {
- return; // shouldn't happen
- }
- PlasticTabbedPaneUI ui = (PlasticTabbedPaneUI) pane.getUI();
-
- if (ui.scrollableTabLayoutEnabled()) {
- ui.tabScroller.scrollForward(pane.getTabPlacement());
- }
- }
- }
-
- private static class ScrollTabsBackwardAction extends AbstractAction {
-
- @Override
- public void actionPerformed(ActionEvent e) {
- JTabbedPane pane = null;
- Object src = e.getSource();
- if (src instanceof JTabbedPane) {
- pane = (JTabbedPane) src;
- } else if (src instanceof PlasticArrowButton) {
- pane = (JTabbedPane) ((PlasticArrowButton) src).getParent();
- } else {
- return; // shouldn't happen
- }
- PlasticTabbedPaneUI ui = (PlasticTabbedPaneUI) pane.getUI();
-
- if (ui.scrollableTabLayoutEnabled()) {
- ui.tabScroller.scrollBackward(pane.getTabPlacement());
- }
- }
- }
-
- private final class TabbedPaneScrollLayout extends TabbedPaneLayout {
-
- @Override
- protected int preferredTabAreaHeight(int tabPlacement, int width) {
- return calculateMaxTabHeight(tabPlacement);
- }
-
- @Override
- protected int preferredTabAreaWidth(int tabPlacement, int height) {
- return calculateMaxTabWidth(tabPlacement);
- }
-
- @Override
- public void layoutContainer(Container parent) {
- int tabPlacement = tabPane.getTabPlacement();
- int tabCount = tabPane.getTabCount();
- Insets insets = tabPane.getInsets();
- int selectedIndex = tabPane.getSelectedIndex();
- Component visibleComponent = getVisibleComponent();
-
- calculateLayoutInfo();
-
- if (selectedIndex < 0) {
- if (visibleComponent != null) {
- // The last tab was removed, so remove the component
- setVisibleComponent(null);
- }
- } else {
- Component selectedComponent = tabPane.getComponentAt(selectedIndex);
- boolean shouldChangeFocus = false;
-
- // In order to allow programs to use a single component
- // as the display for multiple tabs, we will not change
- // the visible compnent if the currently selected tab
- // has a null component. This is a bit dicey, as we don't
- // explicitly state we support this in the spec, but since
- // programs are now depending on this, we're making it work.
- //
- if (selectedComponent != null) {
- if (selectedComponent != visibleComponent &&
- visibleComponent != null) {
- if (SwingUtilities.findFocusOwner(visibleComponent) != null) {
- shouldChangeFocus = true;
- }
- }
- setVisibleComponent(selectedComponent);
- }
- int tx, ty, tw, th; // tab area bounds
- int cx, cy, cw, ch; // content area bounds
- Insets contentInsets = getContentBorderInsets(tabPlacement);
- Rectangle bounds = tabPane.getBounds();
- int numChildren = tabPane.getComponentCount();
-
- if (numChildren > 0) {
- switch (tabPlacement) {
- case LEFT:
- // calculate tab area bounds
- tw = calculateTabAreaWidth(tabPlacement, runCount,
- maxTabWidth);
- th = bounds.height - insets.top - insets.bottom;
- tx = insets.left;
- ty = insets.top;
-
- // calculate content area bounds
- cx = tx + tw + contentInsets.left;
- cy = ty + contentInsets.top;
- cw = bounds.width - insets.left - insets.right - tw
- - contentInsets.left - contentInsets.right;
- ch = bounds.height - insets.top - insets.bottom
- - contentInsets.top - contentInsets.bottom;
- break;
- case RIGHT:
- // calculate tab area bounds
- tw = calculateTabAreaWidth(tabPlacement, runCount,
- maxTabWidth);
- th = bounds.height - insets.top - insets.bottom;
- tx = bounds.width - insets.right - tw;
- ty = insets.top;
-
- // calculate content area bounds
- cx = insets.left + contentInsets.left;
- cy = insets.top + contentInsets.top;
- cw = bounds.width - insets.left - insets.right - tw
- - contentInsets.left - contentInsets.right;
- ch = bounds.height - insets.top - insets.bottom
- - contentInsets.top - contentInsets.bottom;
- break;
- case BOTTOM:
- // calculate tab area bounds
- tw = bounds.width - insets.left - insets.right;
- th = calculateTabAreaHeight(tabPlacement, runCount,
- maxTabHeight);
- tx = insets.left;
- ty = bounds.height - insets.bottom - th;
-
- // calculate content area bounds
- cx = insets.left + contentInsets.left;
- cy = insets.top + contentInsets.top;
- cw = bounds.width - insets.left - insets.right
- - contentInsets.left - contentInsets.right;
- ch = bounds.height - insets.top - insets.bottom - th
- - contentInsets.top - contentInsets.bottom;
- break;
- case TOP:
- default:
- // calculate tab area bounds
- tw = bounds.width - insets.left - insets.right;
- th = calculateTabAreaHeight(tabPlacement, runCount,
- maxTabHeight);
- tx = insets.left;
- ty = insets.top;
-
- // calculate content area bounds
- cx = tx + contentInsets.left;
- cy = ty + th + contentInsets.top;
- cw = bounds.width - insets.left - insets.right
- - contentInsets.left - contentInsets.right;
- ch = bounds.height - insets.top - insets.bottom - th
- - contentInsets.top - contentInsets.bottom;
- }
-
- for (int i = 0; i < numChildren; i++) {
- Component child = tabPane.getComponent(i);
-
- if (tabScroller != null && child == tabScroller.viewport) {
- JViewport viewport = (JViewport) child;
- Rectangle viewRect = viewport.getViewRect();
- int vw = tw;
- int vh = th;
- Dimension butSize = tabScroller.scrollForwardButton.getPreferredSize();
- switch (tabPlacement) {
- case LEFT:
- case RIGHT:
- int totalTabHeight = rects[tabCount - 1].y
- + rects[tabCount - 1].height;
- if (totalTabHeight > th) {
- // Allow space for scrollbuttons
- vh = th > 2 * butSize.height ? th - 2
- * butSize.height : 0;
- if (totalTabHeight - viewRect.y <= vh) {
- // Scrolled to the end, so ensure the
- // viewport size is
- // such that the scroll offset aligns
- // with a tab
- vh = totalTabHeight - viewRect.y;
- }
- }
- break;
- case BOTTOM:
- case TOP:
- default:
- int totalTabWidth = rects[tabCount - 1].x
- + rects[tabCount - 1].width + renderer.getTabsOverlay();
- if (totalTabWidth > tw) {
- // Need to allow space for scrollbuttons
- vw = tw > 2 * butSize.width ? tw - 2
- * butSize.width : 0;
- if (totalTabWidth - viewRect.x <= vw) {
- // Scrolled to the end, so ensure the
- // viewport size is
- // such that the scroll offset aligns
- // with a tab
- vw = totalTabWidth - viewRect.x;
- }
- }
- }
- child.setBounds(tx, ty, vw, vh);
-
- } else if (tabScroller != null &&
- (child == tabScroller.scrollForwardButton ||
- child == tabScroller.scrollBackwardButton)) {
- Component scrollbutton = child;
- Dimension bsize = scrollbutton.getPreferredSize();
- int bx = 0;
- int by = 0;
- int bw = bsize.width;
- int bh = bsize.height;
- boolean visible = false;
-
- switch (tabPlacement) {
- case LEFT:
- case RIGHT:
- int totalTabHeight = rects[tabCount - 1].y
- + rects[tabCount - 1].height
- + renderer.getTabsOverlay();
- if (totalTabHeight > th) {
- visible = true;
- bx = tabPlacement == LEFT ? tx + tw
- - bsize.width : tx;
- by = child == tabScroller.scrollForwardButton ? bounds.height
- - insets.bottom - bsize.height
- : bounds.height - insets.bottom - 2
- * bsize.height;
- }
- break;
-
- case BOTTOM:
- case TOP:
- default:
- int totalTabWidth = rects[tabCount - 1].x
- + rects[tabCount - 1].width
- + renderer.getTabsOverlay();
-
- if (totalTabWidth > tw) {
- visible = true;
- bx = child == tabScroller.scrollForwardButton ? bounds.width
- - insets.left - bsize.width
- : bounds.width - insets.left - 2
- * bsize.width;
- by = tabPlacement == TOP ? ty + th
- - bsize.height : ty;
- }
- }
- child.setVisible(visible);
- if (visible) {
- child.setBounds(bx, by, bw, bh);
- }
-
- } else {
- // All content children...
- child.setBounds(cx, cy, cw, ch);
- }
- }
- if (shouldChangeFocus) {
- if (!requestFocusForVisibleComponent()) {
- tabPane.requestFocus();
- }
- }
- }
- }
- }
-
- @Override
- protected void calculateTabRects(int tabPlacement, int tabCount) {
- FontMetrics metrics = getFontMetrics();
- Dimension size = tabPane.getSize();
- Insets insets = tabPane.getInsets();
- Insets tabAreaInsets = getTabAreaInsets(tabPlacement);
- int fontHeight = metrics.getHeight();
- int selectedIndex = tabPane.getSelectedIndex();
- boolean verticalTabRuns = tabPlacement == LEFT || tabPlacement == RIGHT;
- boolean leftToRight = PlasticUtils.isLeftToRight(tabPane);
- int x = tabAreaInsets.left;
- int y = tabAreaInsets.top;
- int totalWidth = 0;
- int totalHeight = 0;
-
- //
- // Calculate bounds within which a tab run must fit
- //
- switch(tabPlacement) {
- case LEFT:
- case RIGHT:
- maxTabWidth = calculateMaxTabWidth(tabPlacement);
- break;
- case BOTTOM:
- case TOP:
- default:
- maxTabHeight = calculateMaxTabHeight(tabPlacement);
- }
-
- runCount = 0;
- selectedRun = -1;
-
- if (tabCount == 0) {
- return;
- }
-
- selectedRun = 0;
- runCount = 1;
-
- // Run through tabs and lay them out in a single run
- Rectangle rect;
- for (int i = 0; i < tabCount; i++) {
- rect = rects[i];
-
- if (!verticalTabRuns) {
- // Tabs on TOP or BOTTOM....
- if (i > 0) {
- rect.x = rects[i-1].x + rects[i-1].width;
- } else {
- tabRuns[0] = 0;
- maxTabWidth = 0;
- totalHeight += maxTabHeight;
- rect.x = x;
- }
- rect.width = calculateTabWidth(tabPlacement, i, metrics);
- totalWidth = rect.x + rect.width + renderer.getTabsOverlay();
- maxTabWidth = Math.max(maxTabWidth, rect.width);
-
- rect.y = y;
- rect.height = maxTabHeight/* - 2*/;
-
- } else {
- // Tabs on LEFT or RIGHT...
- if (i > 0) {
- rect.y = rects[i-1].y + rects[i-1].height;
- } else {
- tabRuns[0] = 0;
- maxTabHeight = 0;
- totalWidth = maxTabWidth;
- rect.y = y;
- }
- rect.height = calculateTabHeight(tabPlacement, i, fontHeight);
- totalHeight = rect.y + rect.height;
- maxTabHeight = Math.max(maxTabHeight, rect.height);
-
- rect.x = x;
- rect.width = maxTabWidth/* - 2*/;
-
- }
- }
-
- // Pad the selected tab so that it appears raised in front
- padSelectedTab(tabPlacement, selectedIndex);
-
- // if right to left and tab placement on the top or
- // the bottom, flip x positions and adjust by widths
- if (!leftToRight && !verticalTabRuns) {
- int rightMargin = size.width
- - (insets.right + tabAreaInsets.right);
- for (int i = 0; i < tabCount; i++) {
- rects[i].x = rightMargin - rects[i].x - rects[i].width;
- }
- }
- tabScroller.tabPanel.setPreferredSize(new Dimension(totalWidth, totalHeight));
- }
- }
-
- private final class ScrollableTabSupport implements ActionListener,
- ChangeListener {
-
- public ScrollableTabViewport viewport;
- public ScrollableTabPanel tabPanel;
- public JButton scrollForwardButton;
- public JButton scrollBackwardButton;
- public int leadingTabIndex;
- private final Point tabViewPosition = new Point(0, 0);
-
- ScrollableTabSupport(int tabPlacement) {
- viewport = new ScrollableTabViewport();
- tabPanel = new ScrollableTabPanel();
- viewport.setView(tabPanel);
- viewport.addChangeListener(this);
- createButtons();
- }
-
- /**
- * Recreates the scroll buttons and adds them to the TabbedPane.
- */
- void createButtons() {
- if (scrollForwardButton != null) {
- tabPane.remove(scrollForwardButton);
- scrollForwardButton.removeActionListener(this);
- tabPane.remove(scrollBackwardButton);
- scrollBackwardButton.removeActionListener(this);
- }
- int tabPlacement = tabPane.getTabPlacement();
- int width = UIManager.getInt("ScrollBar.width");
- if (tabPlacement == TOP || tabPlacement == BOTTOM) {
- scrollForwardButton = new ArrowButton(EAST, width);
- scrollBackwardButton = new ArrowButton(WEST, width);
- } else { // tabPlacement = LEFT || RIGHT
- scrollForwardButton = new ArrowButton(SOUTH, width);
- scrollBackwardButton = new ArrowButton(NORTH, width);
- }
- scrollForwardButton.addActionListener(this);
- scrollBackwardButton.addActionListener(this);
- tabPane.add(scrollForwardButton);
- tabPane.add(scrollBackwardButton);
- }
-
- public void scrollForward(int tabPlacement) {
- Dimension viewSize = viewport.getViewSize();
- Rectangle viewRect = viewport.getViewRect();
-
- if (tabPlacement == TOP || tabPlacement == BOTTOM) {
- if (viewRect.width >= viewSize.width - viewRect.x) {
- return; // no room left to scroll
- }
- } else { // tabPlacement == LEFT || tabPlacement == RIGHT
- if (viewRect.height >= viewSize.height - viewRect.y) {
- return;
- }
- }
- setLeadingTabIndex(tabPlacement, leadingTabIndex + 1);
- }
-
- public void scrollBackward(int tabPlacement) {
- if (leadingTabIndex == 0) {
- return; // no room left to scroll
- }
- setLeadingTabIndex(tabPlacement, leadingTabIndex - 1);
- }
-
- public void setLeadingTabIndex(int tabPlacement, int index) {
- leadingTabIndex = index;
- Dimension viewSize = viewport.getViewSize();
- Rectangle viewRect = viewport.getViewRect();
-
- switch (tabPlacement) {
- case TOP:
- case BOTTOM:
- tabViewPosition.x = leadingTabIndex == 0 ? 0
- : rects[leadingTabIndex].x - renderer.getTabsOverlay();
-
- if (viewSize.width - tabViewPosition.x < viewRect.width) {
- // We've scrolled to the end, so adjust the viewport size
- // to ensure the view position remains aligned on a tab
- // boundary
- Dimension extentSize = new Dimension(viewSize.width
- - tabViewPosition.x, viewRect.height);
- viewport.setExtentSize(extentSize);
- }
- break;
- case LEFT:
- case RIGHT:
- tabViewPosition.y = leadingTabIndex == 0 ? 0
- : rects[leadingTabIndex].y;
-
- if (viewSize.height - tabViewPosition.y < viewRect.height) {
- // We've scrolled to the end, so adjust the viewport size
- // to ensure the view position remains aligned on a tab
- // boundary
- Dimension extentSize = new Dimension(viewRect.width,
- viewSize.height - tabViewPosition.y);
- viewport.setExtentSize(extentSize);
- }
- }
- viewport.setViewPosition(tabViewPosition);
- }
-
- @Override
- public void stateChanged(ChangeEvent e) {
- JViewport viewport = (JViewport) e.getSource();
- int tabPlacement = tabPane.getTabPlacement();
- int tabCount = tabPane.getTabCount();
- Rectangle vpRect = viewport.getBounds();
- Dimension viewSize = viewport.getViewSize();
- Rectangle viewRect = viewport.getViewRect();
-
- leadingTabIndex = getClosestTab(viewRect.x, viewRect.y);
-
- // If the tab isn't right aligned, adjust it.
- if (leadingTabIndex + 1 < tabCount) {
- switch (tabPlacement) {
- case TOP:
- case BOTTOM:
- if (rects[leadingTabIndex].x < viewRect.x) {
- leadingTabIndex++;
- }
- break;
- case LEFT:
- case RIGHT:
- if (rects[leadingTabIndex].y < viewRect.y) {
- leadingTabIndex++;
- }
- break;
- }
- }
- Insets contentInsets = getContentBorderInsets(tabPlacement);
- switch (tabPlacement) {
- case LEFT:
- tabPane.repaint(vpRect.x + vpRect.width, vpRect.y,
- contentInsets.left, vpRect.height);
- scrollBackwardButton.setEnabled(viewRect.y > 0
- && leadingTabIndex > 0);
- scrollForwardButton.setEnabled(leadingTabIndex < tabCount - 1
- && viewSize.height - viewRect.y > viewRect.height);
- break;
- case RIGHT:
- tabPane.repaint(vpRect.x - contentInsets.right, vpRect.y,
- contentInsets.right, vpRect.height);
- scrollBackwardButton.setEnabled(viewRect.y > 0
- && leadingTabIndex > 0);
- scrollForwardButton.setEnabled(leadingTabIndex < tabCount - 1
- && viewSize.height - viewRect.y > viewRect.height);
- break;
- case BOTTOM:
- tabPane.repaint(vpRect.x, vpRect.y - contentInsets.bottom,
- vpRect.width, contentInsets.bottom);
- scrollBackwardButton.setEnabled(viewRect.x > 0
- && leadingTabIndex > 0);
- scrollForwardButton.setEnabled(leadingTabIndex < tabCount - 1
- && viewSize.width - viewRect.x > viewRect.width);
- break;
- case TOP:
- default:
- tabPane.repaint(vpRect.x, vpRect.y + vpRect.height,
- vpRect.width, contentInsets.top);
- scrollBackwardButton.setEnabled(viewRect.x > 0
- && leadingTabIndex > 0);
- scrollForwardButton.setEnabled(leadingTabIndex < tabCount - 1
- && viewSize.width - viewRect.x > viewRect.width);
- }
- }
-
- /**
- * ActionListener for the scroll buttons.
- */
- @Override
- public void actionPerformed(ActionEvent e) {
- ActionMap map = tabPane.getActionMap();
-
- if (map != null) {
- String actionKey;
-
- if (e.getSource() == scrollForwardButton) {
- actionKey = "scrollTabsForwardAction";
- } else {
- actionKey = "scrollTabsBackwardAction";
- }
- Action action = map.get(actionKey);
-
- if (action != null && action.isEnabled()) {
- action.actionPerformed(new ActionEvent(tabPane,
- ActionEvent.ACTION_PERFORMED, null, e.getWhen(), e
- .getModifiers()));
- }
- }
- }
-
- }
-
- private final class ScrollableTabViewport extends JViewport implements UIResource {
-
- public ScrollableTabViewport() {
- super();
- setName("TabbedPane.scrollableViewport");
- setScrollMode(SIMPLE_SCROLL_MODE);
- setOpaque(tabPane.isOpaque());
- Color bgColor = UIManager.getColor("TabbedPane.tabAreaBackground");
- if (bgColor == null) {
- bgColor = tabPane.getBackground();
- }
- setBackground(bgColor);
- }
- }
-
- private final class ScrollableTabPanel extends JPanel implements UIResource {
-
- public ScrollableTabPanel() {
- super(null);
- setOpaque(tabPane.isOpaque());
- Color bgColor = UIManager.getColor("TabbedPane.tabAreaBackground");
- if (bgColor == null) {
- bgColor = tabPane.getBackground();
- }
- setBackground(bgColor);
- }
-
- @Override
- public void paintComponent(Graphics g) {
- super.paintComponent(g);
- PlasticTabbedPaneUI.this.paintTabArea(g, tabPane.getTabPlacement(),
- tabPane.getSelectedIndex());
-
- }
- }
-
- private static final class ArrowButton extends JButton implements UIResource {
-
- private final int buttonWidth;
- private final int direction;
- private boolean mouseIsOver;
-
- ArrowButton(int direction, int buttonWidth) {
- this.direction = direction;
- this.buttonWidth = buttonWidth;
- setRequestFocusEnabled(false);
- }
-
- @Override
- protected void processMouseEvent(MouseEvent e) {
- super.processMouseEvent(e);
- switch (e.getID()) {
- case MouseEvent.MOUSE_ENTERED:
- mouseIsOver = true;
- revalidate();
- repaint();
- break;
- case MouseEvent.MOUSE_EXITED:
- mouseIsOver = false;
- revalidate();
- repaint();
- break;
- }
- }
-
- @Override
- protected void paintBorder(Graphics g) {
- if (mouseIsOver && isEnabled()) {
- super.paintBorder(g);
- }
- }
-
- @Override
- protected void paintComponent(Graphics g) {
- if (mouseIsOver) {
- super.paintComponent(g);
- } else {
- g.setColor(getBackground());
- g.fillRect(0, 0, getWidth(), getHeight());
- }
- paintArrow(g);
- }
-
- private void paintArrow(Graphics g) {
- Color oldColor = g.getColor();
-
- boolean isEnabled = isEnabled();
- g.setColor(isEnabled ? MetalLookAndFeel.getControlInfo()
- : MetalLookAndFeel.getControlDisabled());
-
- int arrowWidth, arrowHeight;
- switch (direction) {
- case NORTH:
- case SOUTH:
- arrowWidth = 9;
- arrowHeight = 5;
- break;
- case WEST:
- case EAST:
- default:
- arrowWidth = 5;
- arrowHeight = 9;
- break;
- }
- int x = (getWidth() - arrowWidth ) / 2;
- int y = (getHeight() - arrowHeight) / 2;
- g.translate(x, y);
-
- boolean paintShadow = !mouseIsOver || !isEnabled;
- Color shadow = isEnabled ? MetalLookAndFeel.getControlShadow()
- : UIManager.getColor("ScrollBar.highlight");
-
- switch (direction) {
- case NORTH:
- g.fillRect(0, 4, 9, 1);
- g.fillRect(1, 3, 7, 1);
- g.fillRect(2, 2, 5, 1);
- g.fillRect(3, 1, 3, 1);
- g.fillRect(4, 0, 1, 1);
- if (paintShadow) {
- g.setColor(shadow);
- g.fillRect(1, 5, 9, 1);
- }
- break;
- case SOUTH:
- g.fillRect(0, 0, 9, 1);
- g.fillRect(1, 1, 7, 1);
- g.fillRect(2, 2, 5, 1);
- g.fillRect(3, 3, 3, 1);
- g.fillRect(4, 4, 1, 1);
- if (paintShadow) {
- g.setColor(shadow);
- g.drawLine(5, 4, 8, 1);
- g.drawLine(5, 5, 9, 1);
- }
- break;
- case WEST:
- g.fillRect(0, 4, 1, 1);
- g.fillRect(1, 3, 1, 3);
- g.fillRect(2, 2, 1, 5);
- g.fillRect(3, 1, 1, 7);
- g.fillRect(4, 0, 1, 9);
- if (paintShadow) {
- g.setColor(shadow);
- g.fillRect(5, 1, 1, 9);
- }
- break;
- case EAST:
- g.fillRect(0, 0, 1, 9);
- g.fillRect(1, 1, 1, 7);
- g.fillRect(2, 2, 1, 5);
- g.fillRect(3, 3, 1, 3);
- g.fillRect(4, 4, 1, 1);
- if (paintShadow) {
- g.setColor(shadow);
- g.drawLine(1, 8, 4, 5);
- g.drawLine(1, 9, 5, 5);
- }
- break;
- }
-
- g.translate(-x, -y);
- g.setColor(oldColor);
- }
-
- @Override
- public Dimension getPreferredSize() {
- return new Dimension(buttonWidth, buttonWidth);
- }
-
- @Override
- public Dimension getMinimumSize() {
- return getPreferredSize();
- }
-
- @Override
- public Dimension getMaximumSize() {
- return new Dimension(Integer.MAX_VALUE, Integer.MAX_VALUE);
- }
- }
-
- /**
- * This is the abstract superclass for all TabbedPane renderers.
- * Those will be defined in the rest of this file
- */
- private abstract static class AbstractRenderer {
-
- protected static final Insets EMPTY_INSETS = new Insets(0, 0, 0, 0);
- protected static final Insets NORTH_INSETS = new Insets(1, 0, 0, 0);
- protected static final Insets WEST_INSETS = new Insets(0, 1, 0, 0);
- protected static final Insets SOUTH_INSETS = new Insets(0, 0, 1, 0);
- protected static final Insets EAST_INSETS = new Insets(0, 0, 0, 1);
-
- protected final JTabbedPane tabPane;
- protected final int tabPlacement;
- protected Color shadowColor;
- protected Color darkShadow;
- protected Color selectColor;
- protected Color selectLight;
- protected Color selectHighlight;
- protected Color lightHighlight;
- protected Color focus;
-
- private AbstractRenderer(JTabbedPane tabPane) {
- initColors();
- this.tabPane = tabPane;
- this.tabPlacement = tabPane.getTabPlacement();
- }
-
- private static AbstractRenderer createRenderer(JTabbedPane tabPane) {
- switch (tabPane.getTabPlacement()) {
- case SwingConstants.TOP :
- return new TopRenderer(tabPane);
- case SwingConstants.BOTTOM :
- return new BottomRenderer(tabPane);
- case SwingConstants.LEFT :
- return new LeftRenderer(tabPane);
- case SwingConstants.RIGHT :
- return new RightRenderer(tabPane);
- default :
- return new TopRenderer(tabPane);
- }
- }
-
- private static AbstractRenderer createEmbeddedRenderer(JTabbedPane tabPane) {
- switch (tabPane.getTabPlacement()) {
- case SwingConstants.TOP :
- return new TopEmbeddedRenderer(tabPane);
- case SwingConstants.BOTTOM :
- return new BottomEmbeddedRenderer(tabPane);
- case SwingConstants.LEFT :
- return new LeftEmbeddedRenderer(tabPane);
- case SwingConstants.RIGHT :
- return new RightEmbeddedRenderer(tabPane);
- default :
- return new TopEmbeddedRenderer(tabPane);
- }
- }
-
- private void initColors() {
- shadowColor = UIManager.getColor("TabbedPane.shadow");
- darkShadow = UIManager.getColor("TabbedPane.darkShadow");
- selectColor = UIManager.getColor("TabbedPane.selected");
- focus = UIManager.getColor("TabbedPane.focus");
- selectHighlight = UIManager.getColor("TabbedPane.selectHighlight");
- lightHighlight = UIManager.getColor("TabbedPane.highlight");
- selectLight =
- new Color(
- (2 * selectColor.getRed() + selectHighlight.getRed()) / 3,
- (2 * selectColor.getGreen() + selectHighlight.getGreen()) / 3,
- (2 * selectColor.getBlue() + selectHighlight.getBlue()) / 3);
- }
-
- protected boolean isFirstDisplayedTab(int tabIndex, int position, int paneBorder) {
- return tabIndex == 0;
-// return (position - paneBorder) < 8;
- }
-
- protected Insets getTabAreaInsets(Insets defaultInsets) {
- return defaultInsets;
- }
-
- protected Insets getContentBorderInsets(Insets defaultInsets) {
- return defaultInsets;
- }
-
- /**
- * Returns the amount by which the label should be shifted horizontally.
- */
- protected int getTabLabelShiftX(int tabIndex, boolean isSelected) {
- return 0;
- }
-
- /**
- * Returns the amount by which the label should be shifted vertically.
- */
- protected int getTabLabelShiftY(int tabIndex, boolean isSelected) {
- return 0;
- }
-
- /**
- * Returns the amount of overlap for two Runs.
- */
- protected int getTabRunOverlay(int tabRunOverlay) {
- return tabRunOverlay;
- }
-
- /**
- * Returns if a run should be padded with empty space
- * to take up as much room as the others.
- */
- protected boolean shouldPadTabRun(int run, boolean aPriori) {
- return aPriori;
- }
-
- /**
- * Returns the amount by which the run number {@code run}
- * should be indented. Add a few pixels for every run to make
- * diagonal lines align.
- */
- protected int getTabRunIndent(int run) {
- return 0;
- }
-
- /**
- * Returns the insets for the given tab.
- */
- protected abstract Insets getTabInsets(int tabIndex, Insets tabInsets);
-
- /**
- * Draws the rectancle around the Tab label which indicates keyboard focus.
- */
- protected abstract void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected);
-
- /**
- * Fills the background of the given tab to make sure overlap of
- * tabs is handled correctly.
- */
- protected abstract void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected);
-
- /**
- * Paints the border around the given tab.
- */
- protected abstract void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected);
-
- /**
- * Returns additional the insets for the selected tab. This allows to "raise"
- * The selected tab over the others
- */
- protected Insets getSelectedTabPadInsets() {
- return EMPTY_INSETS;
- }
-
- /**
- * Draws the top edge of the border around the content area.
- * Draw unbroken line for tabs are not on TOP
- * override where appropriate.
- */
- protected void paintContentBorderTopEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- if (isContentBorderPainted) {
- g.setColor(selectHighlight);
- g.fillRect(x, y, w - 1, 1);
- }
- }
-
- /**
- * Draws the bottom edge of the Border around the content area.
- * Draw broken line if selected tab is visible and adjacent to content
- * and TabPlacement is same as painted edge.
- */
- protected void paintContentBorderBottomEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- if (isContentBorderPainted) {
- g.setColor(darkShadow);
- g.fillRect(x, y + h - 1, w - 1, 1);
- }
- }
-
- /**
- * Draws the left edge of the Border around the content area.
- * Draw broken line if selected tab is visible and adjacent to content
- * and TabPlacement is same as painted edge
- */
- protected void paintContentBorderLeftEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- if (isContentBorderPainted) {
- g.setColor(selectHighlight);
- g.fillRect(x, y, 1, h - 1);
- }
- }
-
- /**
- * Draws the right edge of the Border around the content area.
- * Draw broken line if selected tab is visible and adjacent to content
- * and TabPlacement is same as painted edge
- */
- protected void paintContentBorderRightEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- if (isContentBorderPainted) {
- g.setColor(darkShadow);
- g.fillRect(x + w - 1, y, 1, h);
- }
- }
-
- /**
- * Returns the amount of overlap for two tabs.
- */
- protected int getTabsOverlay() {
- return 0;
- }
- }
-
- /**
- * The renderer for the case where tabs are displayed below the contents
- * and with minimal decoration.
- */
- private static final class BottomEmbeddedRenderer extends AbstractRenderer {
-
- private BottomEmbeddedRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected Insets getTabAreaInsets(Insets insets) {
- return EMPTY_INSETS;
- }
-
- @Override
- protected Insets getContentBorderInsets(Insets defaultInsets) {
- return SOUTH_INSETS;
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return EMPTY_INSETS;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top, tabInsets.left, tabInsets.bottom, tabInsets.right);
- }
-
- /**
- * Paints no focus: minimal decoration is really minimal.
- */
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- // Embedded tabs paint no focus.
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- g.setColor(selectColor);
- g.fillRect(x, y, w + 1, h);
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- int bottom = h;
- int right = w + 1;
-
- g.translate(x, y);
- if (isFirstDisplayedTab(tabIndex, x, tabPane.getBounds().x)) {
- if (isSelected) {
- // selected and first in line
- g.setColor(shadowColor);
- g.fillRect(right, 0, 1, bottom - 1);
- g.fillRect(right - 1, bottom - 1, 1, 1);
- // it is open to discussion if the outer border of the tab
- // should be painted because in the primary case it won't
- // be visible anyway. uncomment the following two lines if wanted
- // g.fillRect(0,bottom, right, 1);
- // g.fillRect(-1,0,1,bottom;
- g.setColor(selectHighlight);
- g.fillRect(0, 0, 1, bottom);
- g.fillRect(right - 1, 0, 1, bottom - 1);
- g.fillRect(1, bottom - 1, right - 2, 1);
- } else {
- //not selected and first in line
- }
- } else {
- if (isSelected) {
- //selected and not first in line
- g.setColor(shadowColor);
- g.fillRect(0, 0, 1, bottom - 1);
- g.fillRect(1, bottom - 1, 1, 1);
- g.fillRect(right, 0, 1, bottom - 1);
- g.fillRect(right - 1, bottom - 1, 1, 1);
- // outside line:
- // g.fillRect(2,bottom, right-3, 1);
- g.setColor(selectHighlight);
- g.fillRect(1, 0, 1, bottom - 1);
- g.fillRect(right - 1, 0, 1, bottom - 1);
- g.fillRect(2, bottom - 1, right - 3, 1);
- } else {
- g.setColor(shadowColor);
- g.fillRect(1, h / 2, 1, h - h / 2);
- }
- }
- g.translate(-x, -y);
- }
-
- @Override
- protected void paintContentBorderBottomEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
-
- g.setColor(shadowColor);
- g.fillRect(x, y + h - 1, w, 1);
- }
-
- }
-
- /**
- * The renderer for the case where Tabs are below the content and
- * decoration is standard.
- */
- private static final class BottomRenderer extends AbstractRenderer {
-
- private BottomRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected Insets getTabAreaInsets(Insets defaultInsets) {
- return new Insets(defaultInsets.top, defaultInsets.left + 5, defaultInsets.bottom, defaultInsets.right);
- }
-
- @Override
- protected int getTabLabelShiftY(int tabIndex, boolean isSelected) {
- return isSelected ? 0 : -1;
- }
-
- @Override
- protected int getTabRunOverlay(int tabRunOverlay) {
- return tabRunOverlay - 2;
- }
-
- @Override
- protected int getTabRunIndent(int run) {
- return 6 * run;
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return SOUTH_INSETS;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top, tabInsets.left - 2, tabInsets.bottom, tabInsets.right - 2);
- }
-
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
-
- if (!tabPane.hasFocus() || !isSelected) {
- return;
- }
- Rectangle tabRect = rects[tabIndex];
- int top = tabRect.y;
- int left = tabRect.x + 6;
- int height = tabRect.height - 3;
- int width = tabRect.width - 12;
- g.setColor(focus);
- g.drawRect(left, top, width, height);
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- g.setColor(selectColor);
- g.fillRect(x, y, w, h);
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- int bottom = h - 1;
- int right = w + 4;
-
- g.translate(x - 3, y);
-
- // Paint Border
- g.setColor(selectHighlight);
-
- // Paint left
- g.fillRect(0, 0, 1, 2);
- g.drawLine(0, 2, 4, bottom - 4);
- g.fillRect(5, bottom - 3, 1, 2);
- g.fillRect(6, bottom - 1, 1, 1);
-
- // Paint bootom
- g.fillRect(7, bottom, 1, 1);
- g.setColor(darkShadow);
- g.fillRect(8, bottom, right - 13, 1);
-
- // Paint right
- g.drawLine(right + 1, 0, right - 3, bottom - 4);
- g.fillRect(right - 4, bottom - 3, 1, 2);
- g.fillRect(right - 5, bottom - 1, 1, 1);
-
- g.translate(-x + 3, -y);
- }
-
- @Override
- protected void paintContentBorderBottomEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- int bottom = y + h - 1;
- int right = x + w - 1;
- g.translate(x, bottom);
- if (drawBroken && selRect.x >= x && selRect.x <= x + w) {
- // Break line to show visual connection to selected tab
- g.setColor(darkShadow);
- g.fillRect(0, 0, selRect.x - x - 2, 1);
- if (selRect.x + selRect.width < x + w - 2) {
- g.setColor(darkShadow);
- g.fillRect(selRect.x + selRect.width + 2 - x, 0, right - selRect.x - selRect.width - 2, 1);
- }
- } else {
- g.setColor(darkShadow);
- g.fillRect(0, 0, w - 1, 1);
- }
- g.translate(-x, -bottom);
- }
-
- @Override
- protected int getTabsOverlay() {
- return 4;
- }
-
- }
-
- /**
- * The renderer for tabs on the left with minimal decoration.
- */
- private static final class LeftEmbeddedRenderer extends AbstractRenderer {
-
- private LeftEmbeddedRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected Insets getTabAreaInsets(Insets insets) {
- return EMPTY_INSETS;
- }
-
- @Override
- protected Insets getContentBorderInsets(Insets defaultInsets) {
- return WEST_INSETS;
- }
-
- @Override
- protected int getTabRunOverlay(int tabRunOverlay) {
- return 0;
- }
-
- @Override
- protected boolean shouldPadTabRun(int run, boolean aPriori) {
- return false;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top, tabInsets.left, tabInsets.bottom, tabInsets.right);
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return EMPTY_INSETS;
- }
-
- /**
- * minimal decoration is really minimal: no focus.
- */
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- // Embedded tabs paint no focus.
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
- g.setColor(selectColor);
- g.fillRect(x, y, w, h);
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- int bottom = h;
- int right = w;
-
- g.translate(x, y);
-
- if (isFirstDisplayedTab(tabIndex, y, tabPane.getBounds().y)) {
- if (isSelected) {
- //selected and first in line
- g.setColor(selectHighlight);
- g.fillRect(0, 0, right, 1);
- g.fillRect(0, 0, 1, bottom - 1);
- g.fillRect(1, bottom - 1, right - 1, 1);
- g.setColor(shadowColor);
- g.fillRect(0, bottom - 1, 1, 1);
- g.fillRect(1, bottom, right - 1, 1);
- // outside line:
- // g.fillRect(-1,0,1,bottom-1)
- } else {
- //not selected but first in line
- }
- } else {
- if (isSelected) {
- //selected but not first in line
- g.setColor(selectHighlight);
- g.fillRect(1, 1, right - 1, 1);
- g.fillRect(0, 2, 1, bottom - 2);
- g.fillRect(1, bottom - 1, right - 1, 1);
- g.setColor(shadowColor);
- g.fillRect(1, 0, right - 1, 1);
- g.fillRect(0, 1, 1, 1);
- g.fillRect(0, bottom - 1, 1, 1);
- g.fillRect(1, bottom, right - 1, 1);
- // outside line:
- // g.fillRect(-1,2,1,bottom-3)
- } else {
- g.setColor(shadowColor);
- g.fillRect(0, 0, right / 3, 1);
- }
- }
-
- g.translate(-x, -y);
- }
-
- @Override
- protected void paintContentBorderLeftEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- g.setColor(shadowColor);
- g.fillRect(x, y, 1, h);
- }
- }
-
- /**
- * Renderer for tabs on the left with normal decoration.
- */
- private static final class LeftRenderer extends AbstractRenderer {
-
- private LeftRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected Insets getTabAreaInsets(Insets defaultInsets) {
- return new Insets(defaultInsets.top + 4, defaultInsets.left, defaultInsets.bottom, defaultInsets.right);
- }
-
- @Override
- protected int getTabLabelShiftX(int tabIndex, boolean isSelected) {
- return 1;
- }
-
- @Override
- protected int getTabRunOverlay(int tabRunOverlay) {
- return 1;
- }
-
- @Override
- protected boolean shouldPadTabRun(int run, boolean aPriori) {
- return false;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top, tabInsets.left - 5, tabInsets.bottom + 1, tabInsets.right - 5);
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return WEST_INSETS;
- }
-
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
-
- if (!tabPane.hasFocus() || !isSelected) {
- return;
- }
- Rectangle tabRect = rects[tabIndex];
- int top = tabRect.y + 2;
- int left = tabRect.x + 3;
- int height = tabRect.height - 5;
- int width = tabRect.width - 6;
- g.setColor(focus);
- g.drawRect(left, top, width, height);
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
- if (!isSelected) {
- g.setColor(selectLight);
- g.fillRect(x + 1, y + 1, w - 1, h - 2);
- } else {
- g.setColor(selectColor);
- g.fillRect(x + 1, y + 1, w - 3, h - 2);
- }
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- int bottom = h - 1;
- int left = 0;
- g.translate(x, y);
-
- // Paint Border
- g.setColor(selectHighlight);
- // Paint top
- g.fillRect(left + 2, 0, w - 2 - left, 1);
-
- // Paint left
- g.fillRect(left + 1, 1, 1, 1);
- g.fillRect(left, 2, 1, bottom - 3);
- g.setColor(darkShadow);
- g.fillRect(left + 1, bottom - 1, 1, 1);
-
- // Paint bottom
- g.fillRect(left + 2, bottom, w - 2 - left, 1);
-
- g.translate(-x, -y);
- }
-
- @Override
- protected void paintContentBorderLeftEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- g.setColor(selectHighlight);
- if (drawBroken && selRect.y >= y && selRect.y <= y + h) {
- // Break line to show visual connection to selected tab
- g.fillRect(x, y, 1, selRect.y + 1 - y);
- if (selRect.y + selRect.height < y + h - 2) {
- g.fillRect(x, selRect.y + selRect.height - 1, 1, y + h - selRect.y - selRect.height);
- }
- } else {
- g.fillRect(x, y, 1, h - 1);
- }
- }
-
- }
-
- /**
- * The renderer for tabs on the right with minimal decoration.
- */
- private static final class RightEmbeddedRenderer extends AbstractRenderer {
-
- private RightEmbeddedRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected Insets getTabAreaInsets(Insets insets) {
- return EMPTY_INSETS;
- }
-
- @Override
- protected Insets getContentBorderInsets(Insets defaultInsets) {
- return EAST_INSETS;
- }
-
- @Override
- protected int getTabRunIndent(int run) {
- return 4 * run;
- }
-
- @Override
- protected int getTabRunOverlay(int tabRunOverlay) {
- return 0;
- }
-
- @Override
- protected boolean shouldPadTabRun(int run, boolean aPriori) {
- return false;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top, tabInsets.left, tabInsets.bottom, tabInsets.right);
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return EMPTY_INSETS;
- }
-
- /**
- * Minimal decoration: no focus.
- */
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- // Embedded tabs paint no focus.
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- g.setColor(selectColor);
- g.fillRect(x, y, w, h);
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- int bottom = h;
- int right = w - 1;
-
- g.translate(x + 1, y);
-
- if (isFirstDisplayedTab(tabIndex, y, tabPane.getBounds().y)) {
- if (isSelected) {
- //selected and first in line
- g.setColor(shadowColor);
- //outside lines:
- // g.fillRect(0,-1,right,1);
- // g.fillRect(right,-1,1,bottom);
- g.fillRect(right - 1, bottom - 1, 1, 1);
- g.fillRect(0, bottom, right - 1, 1);
- g.setColor(selectHighlight);
- g.fillRect(0, 0, right - 1, 1);
- g.fillRect(right - 1, 0, 1, bottom - 1);
- g.fillRect(0, bottom - 1, right - 1, 1);
- }
- } else {
- if (isSelected) {
- //selected but not first in line
- g.setColor(shadowColor);
- g.fillRect(0, -1, right - 1, 1);
- g.fillRect(right - 1, 0, 1, 1);
- //outside line:
- // g.fillRect(right,0,1,bottom);
- g.fillRect(right - 1, bottom - 1, 1, 1);
- g.fillRect(0, bottom, right - 1, 1);
- g.setColor(selectHighlight);
- g.fillRect(0, 0, right - 1, 1);
- g.fillRect(right - 1, 1, 1, bottom - 2);
- g.fillRect(0, bottom - 1, right - 1, 1);
- } else {
- //not selected and not first in line
- g.setColor(shadowColor);
- g.fillRect(2 * right / 3, 0, right / 3, 1);
- }
- }
- g.translate(-x - 1, -y);
- }
-
- @Override
- protected void paintContentBorderRightEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- g.setColor(shadowColor);
- g.fillRect(x + w - 1, y, 1, h);
- }
-
- }
-
- /**
- * Renderer for tabs on the right with normal decoration.
- */
- private static final class RightRenderer extends AbstractRenderer {
-
- private RightRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected int getTabLabelShiftX(int tabIndex, boolean isSelected) {
- return 1;
- }
-
- @Override
- protected int getTabRunOverlay(int tabRunOverlay) {
- return 1;
- }
-
- @Override
- protected boolean shouldPadTabRun(int run, boolean aPriori) {
- return false;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top, tabInsets.left - 5, tabInsets.bottom + 1, tabInsets.right - 5);
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return EAST_INSETS;
- }
-
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
-
- if (!tabPane.hasFocus() || !isSelected) {
- return;
- }
- Rectangle tabRect = rects[tabIndex];
- int top = tabRect.y + 2;
- int left = tabRect.x + 3;
- int height = tabRect.height - 5;
- int width = tabRect.width - 6;
- g.setColor(focus);
- g.drawRect(left, top, width, height);
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
- if (!isSelected) {
- g.setColor(selectLight);
- g.fillRect(x, y, w, h);
- } else {
- g.setColor(selectColor);
- g.fillRect(x + 2, y, w - 2, h);
- }
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- int bottom = h - 1;
- int right = w;
-
- g.translate(x, y);
-
- // Paint Border
-
- g.setColor(selectHighlight);
- g.fillRect(0, 0, right - 1, 1);
- // Paint right
- g.setColor(darkShadow);
- g.fillRect(right - 1, 1, 1, 1);
- g.fillRect(right, 2, 1, bottom - 3);
- // Paint bottom
- g.fillRect(right - 1, bottom - 1, 1, 1);
- g.fillRect(0, bottom, right - 1, 1);
-
- g.translate(-x, -y);
- }
-
- @Override
- protected void paintContentBorderRightEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- g.setColor(darkShadow);
- if (drawBroken && selRect.y >= y && selRect.y <= y + h) {
- // Break line to show visual connection to selected tab
- g.fillRect(x + w - 1, y, 1, selRect.y - y);
- if (selRect.y + selRect.height < y + h - 2) {
- g.fillRect(x + w - 1, selRect.y + selRect.height, 1, y + h - selRect.y - selRect.height);
- }
- } else {
- g.fillRect(x + w - 1, y, 1, h - 1);
- }
- }
- }
-
- /**
- * Renderer for tabs on top with minimal decoration.
- */
- private static final class TopEmbeddedRenderer extends AbstractRenderer {
-
- private TopEmbeddedRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected Insets getTabAreaInsets(Insets insets) {
- return EMPTY_INSETS;
- }
-
- @Override
- protected Insets getContentBorderInsets(Insets defaultInsets) {
- return NORTH_INSETS;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top, tabInsets.left + 1, tabInsets.bottom, tabInsets.right);
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return EMPTY_INSETS;
- }
-
- /**
- * Minimal decoration: no focus.
- */
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- // Embedded tabs paint no focus.
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- g.setColor(selectColor);
- g.fillRect(x, y, w, h);
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- g.translate(x, y);
-
- int right = w;
- int bottom = h;
-
- if (isFirstDisplayedTab(tabIndex, x, tabPane.getBounds().x)) {
- if (isSelected) {
- g.setColor(selectHighlight);
- //left
- g.fillRect(0, 0, 1, bottom);
- //top
- g.fillRect(0, 0, right - 1, 1);
- //right
- g.fillRect(right - 1, 0, 1, bottom);
- g.setColor(shadowColor);
- //topright corner
- g.fillRect(right - 1, 0, 1, 1);
- //right
- g.fillRect(right, 1, 1, bottom);
- }
- } else {
- if (isSelected) {
- g.setColor(selectHighlight);
- //left
- g.fillRect(1, 1, 1, bottom - 1);
- //top
- g.fillRect(2, 0, right - 3, 1);
- //right
- g.fillRect(right - 1, 1, 1, bottom - 1);
- g.setColor(shadowColor);
- //left
- g.fillRect(0, 1, 1, bottom - 1);
- //topleft corner
- g.fillRect(1, 0, 1, 1);
- //topright corner
- g.fillRect(right - 1, 0, 1, 1);
- //right
- g.fillRect(right, 1, 1, bottom);
- } else {
- g.setColor(shadowColor);
- g.fillRect(0, 0, 1, bottom +2 - bottom / 2);
- }
- }
- g.translate(-x, -y);
- }
-
- @Override
- protected void paintContentBorderTopEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- g.setColor(shadowColor);
- g.fillRect(x, y, w, 1);
- }
-
- }
-
- /**
- * Renderer for tabs on top with normal decoration.
- */
- private static final class TopRenderer extends AbstractRenderer {
-
- private TopRenderer(JTabbedPane tabPane) {
- super(tabPane);
- }
-
- @Override
- protected Insets getTabAreaInsets(Insets defaultInsets) {
- return new Insets(defaultInsets.top, defaultInsets.left + 4, defaultInsets.bottom, defaultInsets.right);
- }
-
- @Override
- protected int getTabLabelShiftY(int tabIndex, boolean isSelected) {
- return isSelected ? -1 : 0;
- }
-
- @Override
- protected int getTabRunOverlay(int tabRunOverlay) {
- return tabRunOverlay - 2;
- }
-
- @Override
- protected int getTabRunIndent(int run) {
- return 6 * run;
- }
-
- @Override
- protected Insets getSelectedTabPadInsets() {
- return NORTH_INSETS;
- }
-
- @Override
- protected Insets getTabInsets(int tabIndex, Insets tabInsets) {
- return new Insets(tabInsets.top-1, tabInsets.left - 4, tabInsets.bottom, tabInsets.right - 4);
- }
-
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- Rectangle[] rects,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
-
- if (!tabPane.hasFocus() || !isSelected) {
- return;
- }
- Rectangle tabRect = rects[tabIndex];
- int top = tabRect.y +1 ;
- int left = tabRect.x + 4;
- int height = tabRect.height - 3;
- int width = tabRect.width - 9;
- g.setColor(focus);
- g.drawRect(left, top, width, height);
- }
-
- @Override
- protected void paintTabBackground(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- int sel = isSelected ? 0 : 1;
- g.setColor(selectColor);
- g.fillRect(x, y + sel, w, h / 2);
- g.fillRect(x - 1, y + sel + h / 2, w + 2, h - h / 2);
- }
-
- @Override
- protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {
-
- g.translate(x - 4, y);
-
- int top = 0;
- int right = w + 6;
-
- // Paint Border
- g.setColor(selectHighlight);
-
- // Paint left
- g.drawLine(1, h - 1, 4, top + 4);
- g.fillRect(5, top + 2, 1, 2);
- g.fillRect(6, top + 1, 1, 1);
-
- // Paint top
- g.fillRect(7, top, right - 12, 1);
-
- // Paint right
- g.setColor(darkShadow);
- g.drawLine(right, h - 1, right - 3, top + 4);
- g.fillRect(right - 4, top + 2, 1, 2);
- g.fillRect(right - 5, top + 1, 1, 1);
-
- g.translate(-x + 4, -y);
- }
-
- @Override
- protected void paintContentBorderTopEdge(
- Graphics g,
- int x,
- int y,
- int w,
- int h,
- boolean drawBroken,
- Rectangle selRect,
- boolean isContentBorderPainted) {
- int right = x + w - 1;
- int top = y;
- g.setColor(selectHighlight);
-
- if (drawBroken && selRect.x >= x && selRect.x <= x + w) {
- // Break line to show visual connection to selected tab
- g.fillRect(x, top, selRect.x - 2 - x, 1);
- if (selRect.x + selRect.width < x + w - 2) {
- g.fillRect(selRect.x + selRect.width + 2, top, right - 2 - selRect.x - selRect.width, 1);
- } else {
- g.fillRect(x + w - 2, top, 1, 1);
- }
- } else {
- g.fillRect(x, top, w - 1, 1);
- }
- }
-
- @Override
- protected int getTabsOverlay() {
- return 6;
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticTextAreaUI.java b/src/core/com/jgoodies/looks/plastic/PlasticTextAreaUI.java
deleted file mode 100644
index 9f4f5ee..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticTextAreaUI.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.beans.PropertyChangeEvent;
-
-import javax.swing.JComponent;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicTextAreaUI;
-import javax.swing.text.JTextComponent;
-
-
-/**
- * The JGoodies Plastic L&F implementation of {@code TextAreaUI}.
- * In addition to its superclass BasicTextAreaUI, it updates the
- * background colors using behavior from BasicTextFieldUI.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-public final class PlasticTextAreaUI extends BasicTextAreaUI {
-
- /**
- * Creates a UI for a JTextArea.
- *
- * @param c the text area
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new PlasticTextAreaUI();
- }
-
-
-
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- updateBackground((JTextComponent) c);
- }
-
-
- /**
- * This method gets called when a bound property is changed
- * on the associated JTextComponent. In addition to the superclass
- * behavior, this UI updates the background if the <em>editable</em> or
- * <em>enabled</em> property changes .
- *
- * @param evt the property change event
- */
- @Override
- protected void propertyChange(PropertyChangeEvent evt) {
- super.propertyChange(evt);
- String propertyName = evt.getPropertyName();
- if ( "editable".equals(propertyName)
- || "enabled".equals(propertyName)) {
- updateBackground((JTextComponent) evt.getSource());
- }
- }
-
-
- private static void updateBackground(JTextComponent c) {
- Color background = c.getBackground();
- if (!(background instanceof UIResource)) {
- return;
- }
- Color newColor = null;
- if (!c.isEnabled()) {
- newColor = UIManager.getColor("TextArea.disabledBackground");
- }
- if (newColor == null && !c.isEditable()) {
- newColor = UIManager.getColor("TextArea.inactiveBackground");
- }
- if (newColor == null) {
- newColor = UIManager.getColor("TextArea.background");
- }
- if (newColor != null && newColor != background) {
- c.setBackground(newColor);
- }
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticTextFieldUI.java b/src/core/com/jgoodies/looks/plastic/PlasticTextFieldUI.java
deleted file mode 100644
index 01ca6bd..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticTextFieldUI.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalTextFieldUI;
-import javax.swing.text.Caret;
-
-
-/**
- * The JGoodies Plastic L&F implementation of {@code TextFieldUI}.
- * In addition to its superclass MetalTextFieldUI, it can use a caret
- * that selects all text when the field gains focus via the keyboard.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class PlasticTextFieldUI extends MetalTextFieldUI {
-
- /**
- * Creates a UI for a JTextField.
- *
- * @param c the text field
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new PlasticTextFieldUI();
- }
-
-
- /**
- * Creates the caret for a field.
- *
- * @return the caret
- */
- @Override
- protected Caret createCaret() {
- return new PlasticFieldCaret();
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticTheme.java b/src/core/com/jgoodies/looks/plastic/PlasticTheme.java
deleted file mode 100644
index 47b5b2a..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticTheme.java
+++ /dev/null
@@ -1,203 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-
-import javax.swing.plaf.ColorUIResource;
-import javax.swing.plaf.FontUIResource;
-import javax.swing.plaf.metal.DefaultMetalTheme;
-
-import com.jgoodies.looks.FontPolicy;
-import com.jgoodies.looks.FontSet;
-
-/**
- * Unlike its superclass this theme class has relaxed access.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-public abstract class PlasticTheme extends DefaultMetalTheme {
-
- // Default 3D Effect Colors *********************************************
-
- public static final Color DARKEN_START = new Color( 0, 0, 0, 0);
- public static final Color DARKEN_STOP = new Color( 0, 0, 0, 64);
- public static final Color LT_DARKEN_STOP = new Color( 0, 0, 0, 32);
- public static final Color BRIGHTEN_START = new Color(255, 255, 255, 0);
- public static final Color BRIGHTEN_STOP = new Color(255, 255, 255, 128);
- public static final Color LT_BRIGHTEN_STOP = new Color(255, 255, 255, 64);
-
- protected static final ColorUIResource WHITE =
- new ColorUIResource(255, 255, 255);
-
- protected static final ColorUIResource BLACK = new ColorUIResource(0, 0, 0);
-
-
- // Instance Fields ********************************************************
-
- /**
- * Holds the set of fonts used by this theme.
- * It is lazily initialized using the shared FontPolicy
- * provided by the PlasticLookAndFeel.
- *
- * @see #getFontSet()
- * @see PlasticLookAndFeel#getFontPolicy()
- */
- private FontSet fontSet;
-
-
- // Accessing Colors *****************************************************
-
- @Override
- protected ColorUIResource getBlack() {
- return BLACK;
- }
-
- @Override
- protected ColorUIResource getWhite() {
- return WHITE;
- }
-
- @Override
- public ColorUIResource getSystemTextColor() {
- return getControlInfo();
- }
-
- public ColorUIResource getTitleTextColor() {
- return getPrimary1();
- }
-
- @Override
- public ColorUIResource getMenuForeground() {
- return getControlInfo();
- }
-
- public ColorUIResource getMenuItemBackground() {
- return getMenuBackground();
- }
-
- public ColorUIResource getMenuItemSelectedBackground() {
- return getMenuSelectedBackground();
- }
-
- public ColorUIResource getMenuItemSelectedForeground() {
- return getMenuSelectedForeground();
- }
-
- public ColorUIResource getSimpleInternalFrameForeground() {
- return getWhite();
- }
-
- public ColorUIResource getSimpleInternalFrameBackground() {
- return getPrimary1();
- }
-
- public ColorUIResource getToggleButtonCheckColor() {
- return getPrimary1();
- }
-
- // Accessing Fonts ******************************************************
-
- public FontUIResource getTitleTextFont() {
- return getFontSet().getTitleFont();
- }
-
- @Override
- public FontUIResource getControlTextFont() {
- return getFontSet().getControlFont();
- }
-
- @Override
- public FontUIResource getMenuTextFont() {
- return getFontSet().getMenuFont();
- }
-
- @Override
- public FontUIResource getSubTextFont() {
- return getFontSet().getSmallFont();
- }
-
- @Override
- public FontUIResource getSystemTextFont() {
- return getFontSet().getControlFont();
- }
-
- @Override
- public FontUIResource getUserTextFont() {
- return getFontSet().getControlFont();
- }
-
- @Override
- public FontUIResource getWindowTitleFont() {
- return getFontSet().getWindowTitleFont();
- }
-
- protected FontSet getFontSet() {
- if (fontSet == null) {
- FontPolicy policy = PlasticLookAndFeel.getFontPolicy();
- fontSet = policy.getFontSet("Plastic", null);
- }
- return fontSet;
- }
-
-
- // Custom Equals Implementation *****************************************
-
- /**
- * Plastic themes are equal if and only if their classes are the same.
- *
- * @return true if this theme is equal to the given object
- */
- @Override
- public boolean equals(Object o) {
- if (this == o) {
- return true;
- }
- if (o == null) {
- return false;
- }
- return getClass().equals(o.getClass());
- }
-
-
- /**
- * Returns this theme's hash code, the classes' hash code.
- *
- * @return this theme's hash code
- */
- @Override
- public int hashCode() {
- return getClass().hashCode();
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticToggleButtonUI.java b/src/core/com/jgoodies/looks/plastic/PlasticToggleButtonUI.java
deleted file mode 100644
index ccb112c..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticToggleButtonUI.java
+++ /dev/null
@@ -1,245 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.*;
-
-import javax.swing.*;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicHTML;
-import javax.swing.plaf.metal.MetalToggleButtonUI;
-import javax.swing.text.View;
-
-/**
- * The JGoodies Plastic L&F implementation of {@code ToggleButtonUI}.
- * It differs from its superclass in that it can add a pseudo 3D effect,
- * and that the border can paint the focus.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public class PlasticToggleButtonUI extends MetalToggleButtonUI {
-
- private static final PlasticToggleButtonUI INSTANCE =
- new PlasticToggleButtonUI();
-
- /*
- * Implementation note: The protected visibility prevents
- * the String value from being encrypted by the obfuscator.
- * An encrypted String key would break the client property lookup
- * in the #paint method below.
- */
- protected static final String HTML_KEY = BasicHTML.propertyKey;
-
- private boolean borderPaintsFocus;
-
- public static ComponentUI createUI(JComponent b) {
- return INSTANCE;
- }
-
- /**
- * In addition to the superclass we check if the border paints the focus.
- */
- @Override
- public void installDefaults(AbstractButton b) {
- super.installDefaults(b);
- borderPaintsFocus =
- Boolean.TRUE.equals(
- UIManager.get("ToggleButton.borderPaintsFocus"));
- }
-
-
- // Painting ***************************************************************
-
- @Override
- public void update(Graphics g, JComponent c) {
- AbstractButton b = (AbstractButton) c;
- if (c.isOpaque()) {
- if (isToolBarButton(b)) {
- c.setOpaque(false);
- } else if (b.isContentAreaFilled()) {
- g.setColor(c.getBackground());
- g.fillRect(0, 0, c.getWidth(), c.getHeight());
-
- if (is3D(b)) {
- Rectangle r =
- new Rectangle(
- 1,
- 1,
- c.getWidth() - 2,
- c.getHeight() - 1);
- PlasticUtils.add3DEffekt(g, r);
- }
- }
- }
- paint(g, c);
- }
-
- /**
- * Paints the focus close to the button's border.
- */
- @Override
- protected void paintFocus(
- Graphics g,
- AbstractButton b,
- Rectangle viewRect,
- Rectangle textRect,
- Rectangle iconRect) {
-
- if (borderPaintsFocus) {
- return;
- }
-
- boolean isDefault = false;
- int topLeftInset = isDefault ? 3 : 2;
- int width = b.getWidth() - 1 - topLeftInset * 2;
- int height = b.getHeight() - 1 - topLeftInset * 2;
-
- g.setColor(getFocusColor());
- g.drawRect(topLeftInset, topLeftInset, width - 1, height - 1);
- }
-
- /**
- * Unlike the BasicToggleButtonUI.paint, we don't fill the content area;
- * this has been done by the update method before.
- */
- @Override
- public void paint(Graphics g, JComponent c) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- Dimension size = b.getSize();
- FontMetrics fm = g.getFontMetrics();
-
- Insets i = c.getInsets();
-
- Rectangle viewRect = new Rectangle(size);
-
- viewRect.x += i.left;
- viewRect.y += i.top;
- viewRect.width -= (i.right + viewRect.x);
- viewRect.height -= (i.bottom + viewRect.y);
-
- Rectangle iconRect = new Rectangle();
- Rectangle textRect = new Rectangle();
-
- Font f = c.getFont();
- g.setFont(f);
-
- // layout the text and icon
- String text =
- SwingUtilities.layoutCompoundLabel(
- c,
- fm,
- b.getText(),
- b.getIcon(),
- b.getVerticalAlignment(),
- b.getHorizontalAlignment(),
- b.getVerticalTextPosition(),
- b.getHorizontalTextPosition(),
- viewRect,
- iconRect,
- textRect,
- b.getText() == null ? 0 : b.getIconTextGap());
-
- g.setColor(b.getBackground());
-
- if (model.isArmed() && model.isPressed() || model.isSelected()) {
- paintButtonPressed(g, b);
- } /*else if (b.isOpaque() && b.isContentAreaFilled() && !(is3D(b))) {
- g.fillRect(0, 0, size.width, size.height);
-
- Insets insets = b.getInsets();
- Insets margin = b.getMargin();
-
- g.fillRect(insets.left - margin.left, insets.top - margin.top,
- size.width - (insets.left-margin.left) - (insets.right - margin.right),
- size.height - (insets.top-margin.top) - (insets.bottom - margin.bottom));
-
- }*/
-
- // Paint the Icon
- if (b.getIcon() != null) {
- paintIcon(g, b, iconRect);
- }
-
- // Draw the Text
- if (text != null && !text.equals("")) {
- View v = (View) c.getClientProperty(HTML_KEY);
- if (v != null) {
- v.paint(g, textRect);
- } else {
- paintText(g, c, textRect, text);
- }
- }
-
- // draw the dashed focus line.
- if (b.isFocusPainted() && b.hasFocus()) {
- paintFocus(g, b, viewRect, textRect, iconRect);
- }
- }
-
- // Private Helper Code **************************************************************
-
- /**
- * Checks and answers if this is button is in a tool bar.
- *
- * @param b the button to check
- * @return true if in tool bar, false otherwise
- */
- protected boolean isToolBarButton(AbstractButton b) {
- Container parent = b.getParent();
- return parent != null
- && (parent instanceof JToolBar
- || parent.getParent() instanceof JToolBar);
- }
-
- /**
- * Checks and answers if this button shall use a pseudo 3D effect.
- *
- * @param b the button to check
- * @return true indicates a 3D effect, false flat
- */
- protected boolean is3D(AbstractButton b) {
- if (PlasticUtils.force3D(b)) {
- return true;
- }
- if (PlasticUtils.forceFlat(b)) {
- return false;
- }
- ButtonModel model = b.getModel();
- return PlasticUtils.is3D("ToggleButton.")
- && b.isBorderPainted()
- && model.isEnabled()
- && !model.isPressed();
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticToolBarSeparatorUI.java b/src/core/com/jgoodies/looks/plastic/PlasticToolBarSeparatorUI.java
deleted file mode 100644
index 995e6d1..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticToolBarSeparatorUI.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicToolBarSeparatorUI;
-
-/**
- * The JGoodies Plastic L&F implementation of {@code ToolBarSeparatorUI}.
- * It differs from its superclass in that it uses a shared UI delegate.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class PlasticToolBarSeparatorUI extends BasicToolBarSeparatorUI {
-
- /** Shared UI object. */
- private static ComponentUI toolBarSeparatorUI;
-
- public static ComponentUI createUI(JComponent c) {
- if (toolBarSeparatorUI == null) {
- toolBarSeparatorUI = new PlasticToolBarSeparatorUI();
- }
- return toolBarSeparatorUI;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticToolBarUI.java b/src/core/com/jgoodies/looks/plastic/PlasticToolBarUI.java
deleted file mode 100644
index a9ce12b..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticToolBarUI.java
+++ /dev/null
@@ -1,194 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Component;
-import java.awt.Container;
-import java.awt.Graphics;
-import java.awt.Rectangle;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.*;
-import javax.swing.border.Border;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalToolBarUI;
-
-import com.jgoodies.looks.BorderStyle;
-import com.jgoodies.looks.HeaderStyle;
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Plastic look and feel implementation of {@code ToolBarUI}.<p>
- *
- * Corrects the rollover borders and can handle optional {@code Border} types,
- * as specified by the {@code BorderStyle} or {@code HeaderStyle}
- * client properties.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.12 $
- */
-
-public class PlasticToolBarUI extends MetalToolBarUI {
-
- private static final String PROPERTY_PREFIX = "ToolBar.";
-
- private PropertyChangeListener listener;
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticToolBarUI();
- }
-
- // Rollover Borders *****************************************************
-
- @Override
- protected Border createRolloverBorder() {
- return PlasticBorders.getRolloverButtonBorder();
- }
-
- @Override
- protected void setBorderToRollover(Component c) {
- if (c instanceof AbstractButton) {
- super.setBorderToRollover(c);
- } else if (c instanceof Container) {
- Container cont = (Container) c;
- for (int i = 0; i < cont.getComponentCount(); i++) {
- super.setBorderToRollover(cont.getComponent(i));
- }
- }
- }
-
- // Handling Special Borders *********************************************
-
- /**
- * Installs a special border, if indicated by the {@code HeaderStyle}.
- */
- @Override
- protected void installDefaults() {
- super.installDefaults();
- installSpecialBorder();
- }
-
- @Override
- protected void installListeners() {
- super.installListeners();
- listener = createBorderStyleListener();
- toolBar.addPropertyChangeListener(listener);
- }
-
- @Override
- protected void uninstallListeners() {
- toolBar.removePropertyChangeListener(listener);
- super.uninstallListeners();
- }
-
- private PropertyChangeListener createBorderStyleListener() {
- return new PropertyChangeListener() {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String prop = e.getPropertyName();
- if (prop.equals(Options.HEADER_STYLE_KEY)
- || prop.equals(PlasticLookAndFeel.BORDER_STYLE_KEY)) {
- PlasticToolBarUI.this.installSpecialBorder();
- }
- }
-
- };
- }
-
- /**
- * Installs a special border, if either a look-dependent
- * {@code BorderStyle} or a look-independent
- * {@code HeaderStyle} has been specified.
- * A look specific {@code BorderStyle} shadows
- * a {@code HeaderStyle}.<p>
- *
- * Specifying a {@code HeaderStyle} is recommend.
- */
- private void installSpecialBorder() {
- String suffix;
- BorderStyle borderStyle =
- BorderStyle.from(toolBar, PlasticLookAndFeel.BORDER_STYLE_KEY);
- if (borderStyle == BorderStyle.EMPTY) {
- suffix = "emptyBorder";
- } else if (borderStyle == BorderStyle.ETCHED) {
- suffix = "etchedBorder";
- } else if (borderStyle == BorderStyle.SEPARATOR) {
- suffix = "separatorBorder";
- } else {
- HeaderStyle headerStyle = HeaderStyle.from(toolBar);
- if (headerStyle == HeaderStyle.BOTH) {
- suffix = "headerBorder";
- } else if (headerStyle == HeaderStyle.SINGLE && is3D()) {
- suffix = "etchedBorder";
- } else {
- suffix = "border";
- }
- }
- LookAndFeel.installBorder(toolBar, PROPERTY_PREFIX + suffix);
- }
-
- // 3D Effect ************************************************************
-
- @Override
- public void update(Graphics g, JComponent c) {
- if (c.isOpaque()) {
- g.setColor(c.getBackground());
- g.fillRect(0, 0, c.getWidth(), c.getHeight());
- if (is3D()) {
- Rectangle bounds =
- new Rectangle(0, 0, c.getWidth(), c.getHeight());
- boolean isHorizontal =
- ((JToolBar) c).getOrientation() == SwingConstants.HORIZONTAL;
- PlasticUtils.addLight3DEffekt(g, bounds, isHorizontal);
- }
- }
- paint(g, c);
- }
-
- /**
- * Checks and answers if we should add a pseudo 3D effect.
- */
- private boolean is3D() {
- if (PlasticUtils.force3D(toolBar)) {
- return true;
- }
- if (PlasticUtils.forceFlat(toolBar)) {
- return false;
- }
- return PlasticUtils.is3D(PROPERTY_PREFIX)
- && (HeaderStyle.from(toolBar) != null)
- && (BorderStyle.from(toolBar, PlasticLookAndFeel.BORDER_STYLE_KEY)
- != BorderStyle.EMPTY);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticTreeUI.java b/src/core/com/jgoodies/looks/plastic/PlasticTreeUI.java
deleted file mode 100644
index 1af2f87..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticTreeUI.java
+++ /dev/null
@@ -1,147 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicTreeUI;
-
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Plastic Look&Feel implementation of {@code TreeUI}.
- * It provides two line styles: angled dashed lines, or no lines at all.
- * By default, lines are drawn.
- * <p>
- * You can change the line style by setting a client property.
- * The property key and values are a subset of the values used
- * by the Metal L&F tree. To hide lines use one of the following:
- * <pre>
- * JTree tree1 = new JTree();
- * tree1.putClientProperty("JTree.lineStyle", "None");
- *
- * JTree tree2 = new JTree();
- * tree1.putClientProperty(Options.TREE_LINE_STYLE_KEY,
- * Options.TREE_LINE_STYLE_NONE_VALUE);
- * </pre>
- *
- * Although lines are shown by default, you could code:
- * <pre>
- * JTree tree1 = new JTree();
- * tree1.putClientProperty("JTree.lineStyle", "Angled");
- *
- * JTree tree2 = new JTree();
- * tree1.putClientProperty(Options.TREE_LINE_STYLE_KEY,
- * Options.TREE_LINE_STYLE_ANGLED_VALUE);
- * </pre>
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-
-public final class PlasticTreeUI extends BasicTreeUI {
-
- private boolean linesEnabled = true;
- private PropertyChangeListener lineStyleHandler;
-
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticTreeUI();
- }
-
- // Installation ***********************************************************
-
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- updateLineStyle(c.getClientProperty(Options.TREE_LINE_STYLE_KEY));
- lineStyleHandler = new LineStyleHandler();
- c.addPropertyChangeListener(lineStyleHandler);
- }
-
- @Override
- public void uninstallUI(JComponent c) {
- c.removePropertyChangeListener(lineStyleHandler);
- super.uninstallUI(c);
- }
-
-
- // Painting ***************************************************************
-
- @Override
- protected void paintVerticalLine(Graphics g, JComponent c, int x, int top, int bottom) {
- if (linesEnabled) {
- drawDashedVerticalLine(g, x, top, bottom);
- }
- }
-
- @Override
- protected void paintHorizontalLine(Graphics g, JComponent c, int y, int left, int right) {
- if (linesEnabled) {
- drawDashedHorizontalLine(g, y, left, right);
- }
- }
-
- // Draws the icon centered at (x,y)
- @Override
- protected void drawCentered(Component c, Graphics graphics, Icon icon, int x, int y) {
- icon.paintIcon(
- c,
- graphics,
- x - icon.getIconWidth() / 2 - 1,
- y - icon.getIconHeight() / 2);
- }
-
- // Helper Code ************************************************************
-
- private void updateLineStyle(Object lineStyle) {
- linesEnabled = !Options.TREE_LINE_STYLE_NONE_VALUE.equals(lineStyle);
- }
-
- // Listens for changes of the line style property
- private class LineStyleHandler implements PropertyChangeListener {
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String name = e.getPropertyName();
- Object value = e.getNewValue();
- if (name.equals(Options.TREE_LINE_STYLE_KEY)) {
- updateLineStyle(value);
- }
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticUtils.java b/src/core/com/jgoodies/looks/plastic/PlasticUtils.java
deleted file mode 100644
index 67e9653..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticUtils.java
+++ /dev/null
@@ -1,319 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.*;
-
-import javax.swing.JComponent;
-import javax.swing.UIManager;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-
-/**
- * Consists exclusively of static methods that provide convenience behavior.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-
-public final class PlasticUtils {
-
- private PlasticUtils() {
- // Overrides default constructor; prevents instantiation.
- }
-
-
- static void drawDark3DBorder(Graphics g, int x, int y, int w, int h) {
- drawFlush3DBorder(g, x, y, w, h);
- g.setColor(PlasticLookAndFeel.getControl());
- g.drawLine(x+1, y+1, 1, h - 3);
- g.drawLine(y+1, y+1, w - 3, 1);
- }
-
-
- static void drawDisabledBorder(Graphics g, int x, int y, int w, int h) {
- g.setColor(MetalLookAndFeel.getControlShadow());
- drawRect(g, x, y, w - 1, h - 1);
- }
-
-
- /*
- * Unlike {@code MetalUtils} we first draw with highlight then dark shadow
- */
- static void drawFlush3DBorder(Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlHighlight());
- drawRect(g, 1, 1, w - 2, h - 2);
- g.drawLine(0, h - 1, 0, h - 1);
- g.drawLine(w - 1, 0, w - 1, 0);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- drawRect(g, 0, 0, w - 2, h - 2);
- g.translate(-x, -y);
- }
-
-
- /*
- * Copied from {@code MetalUtils}.
- */
- static void drawPressed3DBorder(Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- drawFlush3DBorder(g, 0, 0, w, h);
- g.setColor(MetalLookAndFeel.getControlShadow());
- g.drawLine(1, 1, 1, h - 3);
- g.drawLine(1, 1, w - 3, 1);
- g.translate(-x, -y);
- }
-
-
- /*
- * Copied from {@code MetalUtils}.
- */
- static void drawButtonBorder(Graphics g, int x, int y, int w, int h, boolean active) {
- if (active) {
- drawActiveButtonBorder(g, x, y, w, h);
- } else {
- drawFlush3DBorder(g, x, y, w, h);
- }
- }
-
- /*
- * Copied from {@code MetalUtils}.
- */
- static void drawActiveButtonBorder(Graphics g, int x, int y, int w, int h) {
- drawFlush3DBorder(g, x, y, w, h);
- g.setColor( PlasticLookAndFeel.getPrimaryControl() );
- g.drawLine( x+1, y+1, x+1, h-3 );
- g.drawLine( x+1, y+1, w-3, x+1 );
- g.setColor( PlasticLookAndFeel.getPrimaryControlDarkShadow() );
- g.drawLine( x+2, h-2, w-2, h-2 );
- g.drawLine( w-2, y+2, w-2, h-2 );
- }
-
- /*
- * Modified edges.
- */
- static void drawDefaultButtonBorder(Graphics g, int x, int y, int w, int h, boolean active) {
- drawButtonBorder(g, x+1, y+1, w-1, h-1, active);
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow() );
- drawRect(g, 0, 0, w-3, h-3 );
- g.drawLine(w-2, 0, w-2, 0);
- g.drawLine(0, h-2, 0, h-2);
- g.setColor(PlasticLookAndFeel.getControl());
- g.drawLine(w-1, 0, w-1, 0);
- g.drawLine(0, h-1, 0, h-1);
- g.translate(-x, -y);
- }
-
- static void drawDefaultButtonPressedBorder(Graphics g, int x, int y, int w, int h) {
- drawPressed3DBorder(g, x + 1, y + 1, w - 1, h - 1);
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- drawRect(g, 0, 0, w - 3, h - 3);
- g.drawLine(w - 2, 0, w - 2, 0);
- g.drawLine(0, h - 2, 0, h - 2);
- g.setColor(PlasticLookAndFeel.getControl());
- g.drawLine(w - 1, 0, w - 1, 0);
- g.drawLine(0, h - 1, 0, h - 1);
- g.translate(-x, -y);
- }
-
- static void drawThinFlush3DBorder(Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlHighlight());
- g.drawLine(0, 0, w - 2, 0);
- g.drawLine(0, 0, 0, h - 2);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawLine(w - 1, 0, w - 1, h - 1);
- g.drawLine(0, h - 1, w - 1, h - 1);
- g.translate(-x, -y);
- }
-
-
- static void drawThinPressed3DBorder(Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(PlasticLookAndFeel.getControlDarkShadow());
- g.drawLine(0, 0, w - 2, 0);
- g.drawLine(0, 0, 0, h - 2);
- g.setColor(PlasticLookAndFeel.getControlHighlight());
- g.drawLine(w - 1, 0, w - 1, h - 1);
- g.drawLine(0, h - 1, w - 1, h - 1);
- g.translate(-x, -y);
- }
-
- /*
- * Convenience function for determining ComponentOrientation. Helps us
- * avoid having Munge directives throughout the code.
- */
- static boolean isLeftToRight(Component c) {
- return c.getComponentOrientation().isLeftToRight();
- }
-
-
- // 3D Effects ***********************************************************************
-
- /**
- * Checks and returns whether the specified component type has 3D effects.
- *
- * @param keyPrefix the prefix of the key used to lookup the setting
- * @return true if the component type shall be rendered with a 3D effect
- * @see #force3D(JComponent)
- * @see #forceFlat(JComponent)
- */
- static boolean is3D(String keyPrefix) {
- Object value = UIManager.get(keyPrefix + "is3DEnabled");
- return Boolean.TRUE.equals(value);
- }
-
-
- /**
- * Checks and returns whether we have a custom hint that forces the 3D mode.
- *
- * @param c the component to inspect
- * @return true if the given component has a 3D hint set
- * @see #forceFlat(JComponent)
- */
- static boolean force3D(JComponent c) {
- Object value = c.getClientProperty(PlasticLookAndFeel.IS_3D_KEY);
- return Boolean.TRUE.equals(value);
- }
-
-
- /**
- * Checks and returns whether we have a custom hint that prevents the 3D mode.
- *
- * @param c the component to inspect
- * @return true if the given component has a flat hint set
- * @see #force3D(JComponent)
- */
- static boolean forceFlat(JComponent c) {
- Object value = c.getClientProperty(PlasticLookAndFeel.IS_3D_KEY);
- return Boolean.FALSE.equals(value);
- }
-
-
- // Painting 3D Effects *************************************************************
-
- private static final float FRACTION_3D = 0.5f;
-
-
- private static void add3DEffekt(Graphics g, Rectangle r, boolean isHorizontal,
- Color startC0, Color stopC0, Color startC1, Color stopC1) {
-
- Graphics2D g2 = (Graphics2D) g;
- int xb0, yb0, xb1, yb1, xd0, yd0, xd1, yd1, width, height;
- if (isHorizontal) {
- width = r.width;
- height = (int) (r.height * FRACTION_3D);
- xb0 = r.x;
- yb0 = r.y;
- xb1 = xb0;
- yb1 = yb0 + height;
- xd0 = xb1;
- yd0 = yb1;
- xd1 = xd0;
- yd1 = r.y + r.height;
- } else {
- width = (int) (r.width * FRACTION_3D);
- height = r.height;
- xb0 = r.x;
- yb0 = r.y;
- xb1 = xb0 + width;
- yb1 = yb0;
- xd0 = xb1;
- yd0 = yb0;
- xd1 = r.x + r.width;
- yd1 = yd0;
- }
- g2.setPaint(new GradientPaint(xb0, yb0, stopC0, xb1, yb1, startC0));
- g2.fillRect(r.x, r.y, width, height);
- g2.setPaint(new GradientPaint(xd0, yd0, startC1, xd1, yd1, stopC1));
- g2.fillRect(xd0, yd0, width, height);
- }
-
-
- static void add3DEffekt(Graphics g, Rectangle r) {
- Color brightenStop = UIManager.getColor("Plastic.brightenStop");
- if (null == brightenStop) {
- brightenStop = PlasticTheme.BRIGHTEN_STOP;
- }
-
- // Add round sides
- Graphics2D g2 = (Graphics2D) g;
- int border = 10;
- g2.setPaint(new GradientPaint(r.x, r.y, brightenStop, r.x + border, r.y, PlasticTheme.BRIGHTEN_START));
- g2.fillRect(r.x, r.y, border, r.height);
- int x = r.x + r.width -border;
- int y = r.y;
- g2.setPaint(new GradientPaint(x, y, PlasticTheme.DARKEN_START, x + border, y, PlasticTheme.LT_DARKEN_STOP));
- g2.fillRect(x, y, border, r.height);
-
- add3DEffekt(g, r, true, PlasticTheme.BRIGHTEN_START, brightenStop, PlasticTheme.DARKEN_START, PlasticTheme.LT_DARKEN_STOP);
- }
-
-
- static void addLight3DEffekt(Graphics g, Rectangle r, boolean isHorizontal) {
- Color ltBrightenStop = UIManager.getColor("Plastic.ltBrightenStop");
- if (null == ltBrightenStop) {
- ltBrightenStop = PlasticTheme.LT_BRIGHTEN_STOP;
- }
-
- add3DEffekt(g, r, isHorizontal, PlasticTheme.BRIGHTEN_START, ltBrightenStop, PlasticTheme.DARKEN_START, PlasticTheme.LT_DARKEN_STOP);
- }
-
-
- /*
- * TODO: Required by the Chartster and JPathReport Filler; move to a
- * FillerUI.
- */
- public static void addLight3DEffekt(Graphics g, Rectangle r) {
- Color ltBrightenStop = UIManager.getColor("Plastic.ltBrightenStop");
- if (null == ltBrightenStop) {
- ltBrightenStop = PlasticTheme.LT_BRIGHTEN_STOP;
- }
-
- add3DEffekt(g, r, true, PlasticTheme.DARKEN_START, PlasticTheme.LT_DARKEN_STOP, PlasticTheme.BRIGHTEN_START, ltBrightenStop);
- }
-
-
- // Low level graphics ***************************************************
-
- /*
- * An optimized version of Graphics.drawRect.
- */
- private static void drawRect(Graphics g, int x, int y, int w, int h) {
- g.fillRect(x, y, w+1, 1);
- g.fillRect(x, y+1, 1, h);
- g.fillRect(x+1, y+h, w, 1);
- g.fillRect(x+w, y+1, 1, h);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPBorders.java b/src/core/com/jgoodies/looks/plastic/PlasticXPBorders.java
deleted file mode 100644
index d6f44c6..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPBorders.java
+++ /dev/null
@@ -1,414 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.awt.Insets;
-
-import javax.swing.*;
-import javax.swing.border.AbstractBorder;
-import javax.swing.border.Border;
-import javax.swing.border.CompoundBorder;
-import javax.swing.plaf.BorderUIResource;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicBorders;
-import javax.swing.plaf.metal.MetalBorders;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-import javax.swing.text.JTextComponent;
-
-
-/**
- * This class consists of a set of {@code Border}s used
- * by the JGoodies Plastic XP Look and Feel UI delegates.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.16 $
- */
-
-final class PlasticXPBorders {
-
- private PlasticXPBorders() {
- // Overrides default constructor; prevents instantiation.
- }
-
-
- // Accessing and Creating Borders ***************************************
-
- private static Border comboBoxArrowButtonBorder;
- private static Border comboBoxEditorBorder;
- private static Border scrollPaneBorder;
- private static Border textFieldBorder;
- private static Border spinnerBorder;
- private static Border rolloverButtonBorder;
-
-
- /*
- * Returns a border instance for a {@code JButton}.
- */
- static Border getButtonBorder(Insets buttonMargin) {
- return new BorderUIResource.CompoundBorderUIResource(
- new XPButtonBorder(buttonMargin),
- new BasicBorders.MarginBorder());
- }
-
- /*
- * Returns a border instance for a {@code JComboBox}'s arrow button.
- */
- static Border getComboBoxArrowButtonBorder() {
- if (comboBoxArrowButtonBorder == null) {
- comboBoxArrowButtonBorder = new CompoundBorder( // No UIResource
- new XPComboBoxArrowButtonBorder(),
- new BasicBorders.MarginBorder());
- }
- return comboBoxArrowButtonBorder;
- }
-
- /*
- * Returns a border instance for a {@code JComboBox}'s editor.
- */
- static Border getComboBoxEditorBorder() {
- if (comboBoxEditorBorder == null) {
- comboBoxEditorBorder = new CompoundBorder( // No UIResource
- new XPComboBoxEditorBorder(),
- new BasicBorders.MarginBorder());
- }
- return comboBoxEditorBorder;
- }
-
- /*
- * Returns a border instance for a {@code JScrollPane}.
- */
- static Border getScrollPaneBorder() {
- if (scrollPaneBorder == null) {
- scrollPaneBorder = new XPScrollPaneBorder();
- }
- return scrollPaneBorder;
- }
-
- /*
- * Returns a border instance for a {@code JTextField}.
- */
- static Border getTextFieldBorder() {
- if (textFieldBorder == null) {
- textFieldBorder = new BorderUIResource.CompoundBorderUIResource(
- new XPTextFieldBorder(),
- new BasicBorders.MarginBorder());
- }
- return textFieldBorder;
- }
-
- /*
- * Returns a border instance for a {@code JToggleButton}.
- */
- static Border getToggleButtonBorder(Insets buttonMargin) {
- return new BorderUIResource.CompoundBorderUIResource(
- new XPButtonBorder(buttonMargin),
- new BasicBorders.MarginBorder());
- }
-
- /*
- * Returns a border instance for a {@code JSpinner}.
- */
- static Border getSpinnerBorder() {
- if (spinnerBorder == null) {
- spinnerBorder = new XPSpinnerBorder();
- }
- return spinnerBorder;
- }
-
-
- /**
- * Returns a rollover border for buttons in a {@code JToolBar}.
- *
- * @return the lazily created rollover button border
- */
- static Border getRolloverButtonBorder() {
- if (rolloverButtonBorder == null) {
- rolloverButtonBorder = new CompoundBorder(
- new RolloverButtonBorder(),
- new PlasticBorders.RolloverMarginBorder());
- }
- return rolloverButtonBorder;
- }
-
- /**
- * A border for XP style buttons.
- */
- private static class XPButtonBorder extends AbstractBorder implements UIResource {
-
- protected final Insets insets;
-
- protected XPButtonBorder(Insets insets) {
- this.insets = insets;
- }
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton button = (AbstractButton) c;
- ButtonModel model = button.getModel();
-
- if (!model.isEnabled()) {
- PlasticXPUtils.drawDisabledButtonBorder(g, x, y, w, h);
- return;
- }
-
- boolean isPressed = model.isPressed() && model.isArmed();
- boolean isDefault = button instanceof JButton
- && ((JButton) button).isDefaultButton();
- boolean isFocused = button.isFocusPainted() && button.hasFocus();
-
- if (isPressed) {
- PlasticXPUtils.drawPressedButtonBorder(g, x, y, w, h);
- } else if (isFocused) {
- PlasticXPUtils.drawFocusedButtonBorder(g, x, y, w, h);
- } else if (isDefault) {
- PlasticXPUtils.drawDefaultButtonBorder(g, x, y, w, h);
- } else {
- PlasticXPUtils.drawPlainButtonBorder(g, x, y, w, h);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return insets; }
-
- @Override
- public Insets getBorderInsets(Component c, Insets newInsets) {
- newInsets.top = insets.top;
- newInsets.left = insets.left;
- newInsets.bottom = insets.bottom;
- newInsets.right = insets.right;
- return newInsets;
- }
- }
-
-
- /**
- * A border for combo box arrow buttons.
- */
- private static final class XPComboBoxArrowButtonBorder extends AbstractBorder implements UIResource {
-
- protected static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- PlasticComboBoxButton button = (PlasticComboBoxButton) c;
- JComboBox comboBox = button.getComboBox();
- ButtonModel model = button.getModel();
-
- if (!model.isEnabled()) {
- PlasticXPUtils.drawDisabledButtonBorder(g, x, y, w, h);
- } else {
- boolean isPressed = model.isPressed() && model.isArmed();
- boolean isFocused = comboBox.hasFocus();
- if (isPressed) {
- PlasticXPUtils.drawPressedButtonBorder(g, x, y, w, h);
- } else if (isFocused) {
- PlasticXPUtils.drawFocusedButtonBorder(g, x, y, w, h);
- } else {
- PlasticXPUtils.drawPlainButtonBorder(g, x, y, w, h);
- }
- }
- if (comboBox.isEditable()) {
- // Paint two pixel on the arrow button's left hand side.
- g.setColor(model.isEnabled()
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlShadow());
- g.fillRect(x, y, 1, 1);
- g.fillRect(x, y + h-1, 1, 1);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border for combo box editors.
- */
- private static final class XPComboBoxEditorBorder extends AbstractBorder {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 0);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.setColor(c.isEnabled()
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlShadow());
- PlasticXPUtils.drawRect(g, x, y, w+1, h-1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border for text fields.
- */
- private static final class XPTextFieldBorder extends AbstractBorder {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
-
- boolean enabled = c instanceof JTextComponent
- && c.isEnabled() && ((JTextComponent) c).isEditable()
- ||
- c.isEnabled();
-
- g.setColor(enabled
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlShadow());
- PlasticXPUtils.drawRect(g, x, y, w-1, h-1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
-
- @Override
- public Insets getBorderInsets(Component c, Insets newInsets) {
- newInsets.top = INSETS.top;
- newInsets.left = INSETS.left;
- newInsets.bottom = INSETS.bottom;
- newInsets.right = INSETS.right;
- return newInsets;
- }
- }
-
-
- /**
- * Unlike Metal we paint a simple rectangle.
- * Being a subclass of MetalBorders.ScrollPaneBorder ensures that
- * the ScrollPaneUI will update the ScrollbarsFreeStanding property.
- */
- private static final class XPScrollPaneBorder extends MetalBorders.ScrollPaneBorder {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.setColor(c.isEnabled()
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlShadow());
- PlasticXPUtils.drawRect(g, x, y, w-1, h-1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
-
- @Override
- public Insets getBorderInsets(Component c, Insets newInsets) {
- newInsets.top = INSETS.top;
- newInsets.left = INSETS.left;
- newInsets.bottom = INSETS.bottom;
- newInsets.right = INSETS.right;
- return newInsets;
- }
- }
-
-
- /**
- * A border for {@code JSpinner} components.
- */
- private static final class XPSpinnerBorder extends MetalBorders.ScrollPaneBorder {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.setColor(c.isEnabled()
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlShadow());
- // If you change the value of arrowButtonWidth, don't forget
- // to change it in PlasticXPSpinnerUI#SpinnerXPArrowButton too.
- int arrowButtonWidth = UIManager.getInt("ScrollBar.width") - 1;
- w -= arrowButtonWidth;
- g.fillRect(x, y, w, 1);
- g.fillRect(x, y+1, 1, h-1);
- g.fillRect(x+1, y+h-1, w-1, 1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
-
- @Override
- public Insets getBorderInsets(Component c, Insets newInsets) {
- newInsets.top = INSETS.top;
- newInsets.left = INSETS.left;
- newInsets.bottom = INSETS.bottom;
- newInsets.right = INSETS.right;
- return newInsets;
- }
- }
-
-
- /**
- * A rollover border for buttons in toolbars.
- */
- private static final class RolloverButtonBorder extends XPButtonBorder {
-
- private RolloverButtonBorder() {
- super(new Insets(3, 3, 3, 3));
- }
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- if (!model.isEnabled()) {
- return;
- }
-
- if (!(c instanceof JToggleButton)) {
- if (model.isRollover() && !(model.isPressed() && !model.isArmed())) {
- super.paintBorder( c, g, x, y, w, h );
- }
- return;
- }
-
- if (model.isRollover()) {
- if (model.isPressed() && model.isArmed()) {
- PlasticXPUtils.drawPressedButtonBorder(g, x, y, w, h);
- } else {
- PlasticXPUtils.drawPlainButtonBorder(g, x, y, w, h);
- }
- } else if (model.isSelected()) {
- PlasticXPUtils.drawPressedButtonBorder(g, x, y, w, h);
- }
- }
-
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPCheckBoxUI.java b/src/core/com/jgoodies/looks/plastic/PlasticXPCheckBoxUI.java
deleted file mode 100644
index a9469ca..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPCheckBoxUI.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.AbstractButton;
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicButtonListener;
-import javax.swing.plaf.metal.MetalCheckBoxUI;
-
-/**
- * The JGoodies PlasticXP l&l implementation of {@code CheckBoxUI}.
- * Unlike its superclass, it uses a button listener that sets the armed state
- * if the mouse is over.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class PlasticXPCheckBoxUI extends MetalCheckBoxUI {
-
- private static final PlasticXPCheckBoxUI INSTANCE = new PlasticXPCheckBoxUI();
-
- public static ComponentUI createUI(JComponent b){
- return INSTANCE;
- }
-
- @Override
- protected BasicButtonListener createButtonListener(AbstractButton b) {
- return new ActiveBasicButtonListener(b);
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPIconFactory.java b/src/core/com/jgoodies/looks/plastic/PlasticXPIconFactory.java
deleted file mode 100644
index 0fef2a3..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPIconFactory.java
+++ /dev/null
@@ -1,286 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.*;
-import java.io.Serializable;
-
-import javax.swing.*;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-
-import com.jgoodies.common.base.Strings;
-import com.jgoodies.looks.LookUtils;
-
-/**
- * Factory class that vends {@code Icon}s for the JGoodies
- * Plastic XP look&feel.
- * These icons are used extensively in PlasticXP via the defaults mechanism.
- * While other look and feels often use GIFs for icons, creating icons
- * in code facilitates switching to other themes.
- * <p>
- * Each method in this class returns either an {@code Icon} or
- * {@code null}, where {@code null} implies that there is
- * no default icon.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.13 $
- */
-public final class PlasticXPIconFactory {
-
- private static CheckBoxIcon checkBoxIcon;
- private static RadioButtonIcon radioButtonIcon;
-
-
- private PlasticXPIconFactory() {
- // Overrides default constructor; prevents instantiation.
- }
-
-
- /**
- * Lazily creates and returns the check box icon.
- *
- * @return the check box icon
- */
- static Icon getCheckBoxIcon() {
- if (checkBoxIcon == null) {
- checkBoxIcon = new CheckBoxIcon();
- }
- return checkBoxIcon;
- }
-
- /**
- * Lazily creates and returns the radio button icon.
- *
- * @return the check box icon
- */
- static Icon getRadioButtonIcon() {
- if (radioButtonIcon == null) {
- radioButtonIcon = new RadioButtonIcon();
- }
- return radioButtonIcon;
- }
-
-
- /**
- * Paints the the icon and focus border for Plastic XP check boxes.
- */
- private static final class CheckBoxIcon implements Icon, UIResource, Serializable {
-
- private static final int SIZE = LookUtils.IS_LOW_RESOLUTION ? 13 : 15;
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- JCheckBox cb = (JCheckBox) c;
- ButtonModel model = cb.getModel();
- Graphics2D g2 = (Graphics2D) g;
- boolean paintFocus = model.isArmed() && !model.isPressed()
- || cb.hasFocus() && Strings.isBlank(cb.getText());
-
- final RenderingHints.Key key = RenderingHints.KEY_ANTIALIASING;
- Object newAAHint = RenderingHints.VALUE_ANTIALIAS_ON;
- Object oldAAHint = g2.getRenderingHint(key);
- if (newAAHint != oldAAHint) {
- g2.setRenderingHint(key, newAAHint);
- } else {
- oldAAHint = null;
- }
-
- drawBorder(g2, model.isEnabled(), x, y, SIZE - 1, SIZE - 1);
- drawFill(g2, model.isPressed(), x + 1, y + 1, SIZE - 2, SIZE - 2);
- if (paintFocus) {
- drawFocus(g2, x + 1, y + 1, SIZE - 3, SIZE - 3);
- }
- if (model.isSelected()) {
- drawCheck(g2, model.isEnabled(), x + 3, y + 3, SIZE - 7, SIZE - 7);
- }
-
- if (oldAAHint != null) {
- g2.setRenderingHint(key, oldAAHint);
- }
- }
-
- private static void drawBorder(Graphics2D g2, boolean enabled, int x, int y, int width, int height) {
- g2.setColor(enabled
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlDisabled());
- g2.drawRect(x, y, width, height);
- }
-
- private static void drawCheck(Graphics2D g2, boolean enabled, int x, int y, int width, int height) {
- g2.setColor(enabled
- ? UIManager.getColor("CheckBox.check")
- : MetalLookAndFeel.getControlDisabled());
- int right = x + width;
- int bottom = y + height;
- int startY = y + height / 3;
- int turnX = x + width / 2 - 2;
- g2.drawLine(x , startY , turnX, bottom-3);
- g2.drawLine(x , startY + 1, turnX, bottom-2);
- g2.drawLine(x , startY + 2, turnX, bottom-1);
- g2.drawLine(turnX + 1, bottom - 2, right, y );
- g2.drawLine(turnX + 1, bottom - 1, right, y + 1 );
- g2.drawLine(turnX + 1, bottom , right, y + 2 );
- }
-
- private static void drawFill(Graphics2D g2, boolean pressed, int x, int y, int w, int h) {
- Color upperLeft;
- Color lowerRight;
- if (pressed) {
- upperLeft = MetalLookAndFeel.getControlShadow();
- lowerRight = PlasticLookAndFeel.getControlHighlight();
- } else {
- upperLeft = PlasticLookAndFeel.getControl();
- lowerRight = PlasticLookAndFeel.getControlHighlight().brighter();
- }
- g2.setPaint(new GradientPaint(x, y, upperLeft, x + w, y + h, lowerRight));
- g2.fillRect(x, y, w, h);
- }
-
- private static void drawFocus(Graphics2D g2, int x, int y, int width, int height) {
- g2.setPaint(new GradientPaint(
- x,
- y,
- PlasticLookAndFeel.getFocusColor().brighter(),
- width,
- height,
- PlasticLookAndFeel.getFocusColor() /*.darker()*/
- ));
- g2.drawRect(x, y, width, height);
- g2.drawRect(x + 1, y + 1, width - 2, height - 2);
- }
-
- }
-
-
- /**
- * Paints the the icon and focus border for Plastic XP check boxes.
- */
- private static final class RadioButtonIcon implements Icon, UIResource, Serializable {
-
- private static final int SIZE = LookUtils.IS_LOW_RESOLUTION ? 13 : 15;
-
- private static final Stroke FOCUS_STROKE = new BasicStroke(2);
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- Graphics2D g2 = (Graphics2D) g;
- AbstractButton rb = (AbstractButton) c;
- ButtonModel model = rb.getModel();
- boolean paintFocus = model.isArmed() && !model.isPressed()
- || rb.hasFocus() && Strings.isBlank(rb.getText());
-
- final RenderingHints.Key key = RenderingHints.KEY_ANTIALIASING;
- Object newAAHint = RenderingHints.VALUE_ANTIALIAS_ON;
- Object oldAAHint = g2.getRenderingHint(key);
- if (newAAHint != oldAAHint) {
- g2.setRenderingHint(key, newAAHint);
- } else {
- oldAAHint = null;
- }
-
- drawFill(g2, model.isPressed(), x, y, SIZE - 1, SIZE - 1);
- if (paintFocus) {
- drawFocus(g2, x + 1, y + 1, SIZE - 3, SIZE - 3);
- }
- if (model.isSelected()) {
- drawCheck(g2, c, model.isEnabled(), x + 4, y + 4, SIZE - 8, SIZE - 8);
- }
- drawBorder(g2, model.isEnabled(), x, y, SIZE-1, SIZE-1);
-
- if (oldAAHint != null) {
- g2.setRenderingHint(key, oldAAHint);
- }
- }
-
- private static void drawBorder(Graphics2D g2, boolean enabled, int x, int y, int w, int h) {
- g2.setColor(enabled
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlDisabled());
- g2.drawOval(x, y, w, h);
- }
-
- private static void drawCheck(Graphics2D g2, Component c, boolean enabled, int x, int y, int w, int h) {
- g2.translate(x,y);
- if (enabled) {
- g2.setColor(UIManager.getColor("RadioButton.check"));
- g2.fillOval(0,0,w,h);
- UIManager.getIcon("RadioButton.checkIcon").paintIcon(c, g2, 0,0);
- } else {
- g2.setColor(MetalLookAndFeel.getControlDisabled());
- g2.fillOval(0,0,w,h);
- }
- g2.translate(-x, -y);
- }
-
- private static void drawFill(Graphics2D g2, boolean pressed, int x, int y, int w, int h) {
- Color upperLeft;
- Color lowerRight;
- if (pressed) {
- upperLeft = MetalLookAndFeel.getControlShadow();
- lowerRight = PlasticLookAndFeel.getControlHighlight();
- } else {
- upperLeft = PlasticLookAndFeel.getControl();
- lowerRight = PlasticLookAndFeel.getControlHighlight().brighter();
- }
- g2.setPaint(new GradientPaint(x, y, upperLeft, x + w, y + h, lowerRight));
- g2.fillOval(x, y, w, h);
- }
-
- private static void drawFocus(Graphics2D g2, int x, int y, int w, int h) {
- g2.setPaint(
- new GradientPaint(
- x,
- y,
- PlasticLookAndFeel.getFocusColor().brighter(),
- w,
- h,
- PlasticLookAndFeel.getFocusColor()));
- Stroke stroke = g2.getStroke();
- g2.setStroke(FOCUS_STROKE);
- g2.drawOval(x, y, w, h);
- g2.setStroke(stroke);
- }
-
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPLookAndFeel.java b/src/core/com/jgoodies/looks/plastic/PlasticXPLookAndFeel.java
deleted file mode 100644
index a037d38..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPLookAndFeel.java
+++ /dev/null
@@ -1,182 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Insets;
-
-import javax.swing.UIDefaults;
-import javax.swing.border.Border;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.MicroLayout;
-
-
-/**
- * Intializes class and component defaults for the
- * JGoodies PlasticXP look&feel.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.17 $
- */
-public class PlasticXPLookAndFeel extends Plastic3DLookAndFeel {
-
- /**
- * Constructs the JGoodies PlasticXP look&feel.
- */
- public PlasticXPLookAndFeel() {
- // Provide an empty constructor for subclassing.
- }
-
- @Override
- public String getID() {
- return "JGoodies Plastic XP";
- }
-
- @Override
- public String getName() {
- return "JGoodies Plastic XP";
- }
-
- @Override
- public String getDescription() {
- return "The JGoodies Plastic XP Look and Feel"
- + " - \u00a9 2001-2012 JGoodies Karsten Lentzsch";
- }
-
- /**
- * Initializes the PlasticXP class defaults.
- * Overrides the UIS for check box, radio button, and spinner.
- *
- * @param table the UIDefaults table to work with
- */
- @Override
- protected void initClassDefaults(UIDefaults table) {
- super.initClassDefaults(table);
-
- final String uiClassnamePrefix = "com.jgoodies.looks.plastic.PlasticXP";
- Object[] uiDefaults = {
- // Uses a smooth icon
- "CheckBoxUI", uiClassnamePrefix + "CheckBoxUI",
-
- // Uses a smooth icon
- "RadioButtonUI", uiClassnamePrefix + "RadioButtonUI",
-
- // Changed buttons
- "SpinnerUI", uiClassnamePrefix + "SpinnerUI",
-
- // Uses rounded rollover borders
- "ToolBarUI", uiClassnamePrefix + "ToolBarUI"
- };
- table.putDefaults(uiDefaults);
- }
-
-
- /**
- * Initializes the PlasticXP component defaults.
- *
- * @param table the UIDefaults table to work with
- */
- @Override
- protected void initComponentDefaults(UIDefaults table) {
- super.initComponentDefaults(table);
-
- MicroLayout microLayout = getMicroLayoutPolicy().getMicroLayout(getName(), table);
- Insets buttonBorderInsets = microLayout.getButtonBorderInsets();
-
- Object buttonBorder = PlasticXPBorders.getButtonBorder(buttonBorderInsets);
- Object toggleButtonBorder = PlasticXPBorders.getToggleButtonBorder(buttonBorderInsets);
- Object checkBoxIcon = PlasticXPIconFactory.getCheckBoxIcon();
- Object comboBoxButtonBorder = PlasticXPBorders.getComboBoxArrowButtonBorder();
- Border comboBoxEditorBorder = PlasticXPBorders.getComboBoxEditorBorder();
- Object radioButtonIcon = PlasticXPIconFactory.getRadioButtonIcon();
- Object scrollPaneBorder = PlasticXPBorders.getScrollPaneBorder();
- Object textFieldBorder = PlasticXPBorders.getTextFieldBorder();
- Object spinnerBorder = PlasticXPBorders.getSpinnerBorder();
-
- String radioCheckIconName = SystemUtils.IS_LOW_RESOLUTION
- ? "icons/RadioLight5x5.png"
- : "icons/RadioLight7x7.png";
-
- Insets comboEditorInsets = microLayout.getComboBoxEditorInsets();
-
- Insets comboEditorBorderInsets = comboBoxEditorBorder.getBorderInsets(null);
- int comboBorderSize = comboEditorBorderInsets.left;
- int comboPopupBorderSize = microLayout.getComboPopupBorderSize();
- int comboRendererGap = comboEditorInsets.left + comboBorderSize - comboPopupBorderSize;
- Object comboRendererBorder = new EmptyBorder(1, comboRendererGap, 1, comboRendererGap);
- Object comboTableEditorInsets = new Insets(0, 0, 0, 0);
-
- Object[] defaults = {
- "Button.border", buttonBorder,
- "Button.borderPaintsFocus", Boolean.TRUE,
-
- "CheckBox.icon", checkBoxIcon,
- "CheckBox.check", getToggleButtonCheckColor(),
-
- "ComboBox.arrowButtonBorder", comboBoxButtonBorder,
- "ComboBox.editorBorder", comboBoxEditorBorder,
- "ComboBox.borderPaintsFocus", Boolean.TRUE,
- "ComboBox.editorBorderInsets", comboEditorBorderInsets, // Added by JGoodies
- "ComboBox.tableEditorInsets", comboTableEditorInsets,
- "ComboBox.rendererBorder", comboRendererBorder, // Added by JGoodies
-
- "FormattedTextField.border", textFieldBorder,
- "PasswordField.border", textFieldBorder,
- "Spinner.border", spinnerBorder,
-
- "ScrollPane.border", scrollPaneBorder,
- "Table.scrollPaneBorder", scrollPaneBorder,
-
- "RadioButton.icon", radioButtonIcon,
- "RadioButton.check", getToggleButtonCheckColor(),
- "RadioButton.interiorBackground", getControlHighlight(),
- "RadioButton.checkIcon", makeIcon(getClass(), radioCheckIconName),
-
- "TextField.border", textFieldBorder,
-
- "ToggleButton.border", toggleButtonBorder,
- "ToggleButton.borderPaintsFocus", Boolean.TRUE,
-
- "Tree.expandedIcon", makeIcon(getClass(), "icons/TreeExpanded.png"),
- "Tree.collapsedIcon", makeIcon(getClass(), "icons/TreeCollapsed.png")
- };
- table.putDefaults(defaults);
- }
-
-
- private static ColorUIResource getToggleButtonCheckColor() {
- return getPlasticTheme().getToggleButtonCheckColor();
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPRadioButtonUI.java b/src/core/com/jgoodies/looks/plastic/PlasticXPRadioButtonUI.java
deleted file mode 100644
index 3f45b79..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPRadioButtonUI.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.AbstractButton;
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicButtonListener;
-import javax.swing.plaf.metal.MetalRadioButtonUI;
-
-/**
- * The JGoodies PlasticXP L&F implementation of {@code RadioButtonUI}.
- * It differs from its superclass in that it uses a different icon
- * and has an active border that changes when the mouse is over.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class PlasticXPRadioButtonUI extends MetalRadioButtonUI {
-
- private static final PlasticXPRadioButtonUI INSTANCE =
- new PlasticXPRadioButtonUI();
-
- public static ComponentUI createUI(JComponent b) {
- return INSTANCE;
- }
-
- @Override
- protected BasicButtonListener createButtonListener(AbstractButton b) {
- return new ActiveBasicButtonListener(b);
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPSpinnerUI.java b/src/core/com/jgoodies/looks/plastic/PlasticXPSpinnerUI.java
deleted file mode 100644
index 43915c0..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPSpinnerUI.java
+++ /dev/null
@@ -1,216 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Graphics;
-
-import javax.swing.JComponent;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalLookAndFeel;
-
-
-/**
- * The JGoodies PlasticXP Look&Feel implementation of {@code SpinnerUI}.
- * Configures the default editor to adjust font baselines and component
- * bounds. Also, changes the border of the buttons and the size of the arrows.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-public final class PlasticXPSpinnerUI extends PlasticSpinnerUI {
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticXPSpinnerUI();
- }
-
-
- @Override
- protected Component createArrowButton(int direction) {
- return new SpinnerXPArrowButton(direction);
- }
-
-
- /**
- * It differs from its superclass in that it uses the same formula as JDK
- * to calculate the arrow height.
- */
- private static final class SpinnerXPArrowButton extends PlasticArrowButton {
-
- SpinnerXPArrowButton(int direction) {
- // If you change the value of the button width, don't forget
- // to change it in PlasticXPBorders#XPSpinnerBorder too.
- super(direction, UIManager.getInt("ScrollBar.width") - 1, false);
- }
-
- @Override
- protected int calculateArrowHeight(int height, int width) {
- int arrowHeight = Math.min((height - 4) / 3, (width - 4) / 3);
- return Math.max(arrowHeight, 3);
- }
-
- @Override
- protected boolean isPaintingNorthBottom() {
- return true;
- }
-
- @Override
- protected int calculateArrowOffset() {
- return 1;
- }
-
- @Override
- protected void paintNorth(Graphics g, boolean leftToRight, boolean isEnabled,
- Color arrowColor, boolean isPressed,
- int width, int height, int w, int h, int arrowHeight, int arrowOffset,
- boolean paintBottom) {
- if (!isFreeStanding) {
- height += 1;
- g.translate(0, -1);
- if (!leftToRight) {
- width += 1;
- g.translate(-1, 0);
- } else {
- width += 2;
- }
- }
-
- // Draw the arrow
- g.setColor(arrowColor);
- int startY = 1 + ((h + 1) - arrowHeight) / 2; // KL was (h + 1)
- int startX = w / 2;
- // System.out.println( "startX :" + startX + " startY :"+startY);
- for (int line = 0; line < arrowHeight; line++) {
- g.fillRect(startX - line - arrowOffset, startY + line,
- 2 * (line + 1), 1);
- }
-
- paintNorthBorder(g, isEnabled, width, height, paintBottom);
-
- if (!isFreeStanding) {
- height -= 1;
- g.translate(0, 1);
- if (!leftToRight) {
- width -= 1;
- g.translate(1, 0);
- } else {
- width -= 2;
- }
- }
- }
-
- private void paintNorthBorder(Graphics g, boolean isEnabled, int w, int h, boolean paintBottom) {
- if (isEnabled) {
- boolean isPressed = model.isPressed() && model.isArmed();
- if (isPressed) {
- PlasticXPUtils.drawPressedButtonBorder(g, 0, 1, w - 2, h);
- } else {
- PlasticXPUtils.drawPlainButtonBorder(g, 0, 1, w - 2, h);
- }
- } else {
- PlasticXPUtils.drawDisabledButtonBorder(g, 0, 1, w - 2, h + 1);
- }
- // Paint one pixel on the arrow button's left hand side.
- g.setColor(isEnabled
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlShadow());
- g.fillRect(0, 1, 1, 1);
-
- if (paintBottom) {
- g.fillRect(0, h - 1, w - 1, 1);
- }
- }
-
-
- @Override
- protected void paintSouth(Graphics g, boolean leftToRight, boolean isEnabled,
- Color arrowColor, boolean isPressed,
- int width, int height, int w, int h, int arrowHeight, int arrowOffset) {
-
- if (!isFreeStanding) {
- height += 1;
- if (!leftToRight) {
- width += 1;
- g.translate(-1, 0);
- } else {
- width += 2;
- }
- }
-
- // Draw the arrow
- g.setColor(arrowColor);
-
- int startY = (((h + 0) - arrowHeight) / 2) + arrowHeight - 2; // KL was h + 1
- int startX = w / 2;
-
- //System.out.println( "startX2 :" + startX + " startY2 :"+startY);
-
- for (int line = 0; line < arrowHeight; line++) {
- g.fillRect(startX - line - arrowOffset, startY - line,
- 2 * (line + 1), 1);
- }
-
- paintSouthBorder(g, isEnabled, width, height);
-
- if (!isFreeStanding) {
- height -= 1;
- if (!leftToRight) {
- width -= 1;
- g.translate(1, 0);
- } else {
- width -= 2;
- }
- }
- }
-
- private void paintSouthBorder(Graphics g, boolean isEnabled, int w, int h) {
- if (isEnabled) {
- boolean isPressed = model.isPressed() && model.isArmed();
- if (isPressed) {
- PlasticXPUtils.drawPressedButtonBorder(g, 0, -2, w - 2, h + 1);
- } else {
- PlasticXPUtils.drawPlainButtonBorder(g, 0, -2, w - 2, h + 1);
- }
- } else {
- PlasticXPUtils.drawDisabledButtonBorder(g, 0, -2, w-2, h + 1);
- }
- // Paint one pixel on the arrow button's left hand side.
- g.setColor(isEnabled
- ? PlasticLookAndFeel.getControlDarkShadow()
- : MetalLookAndFeel.getControlShadow());
- g.fillRect(0, h - 2, 1, 1);
- }
-
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPToolBarUI.java b/src/core/com/jgoodies/looks/plastic/PlasticXPToolBarUI.java
deleted file mode 100644
index 05ebe2d..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPToolBarUI.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import javax.swing.JComponent;
-import javax.swing.border.Border;
-import javax.swing.plaf.ComponentUI;
-
-/**
- * The JGoodies PlasticXP Look and Feel implementation of {@code ToolBarUI}.
- * It differs from its superclass in that it uses rollover borders with rounded
- * corners.<p>
- *
- * Thanks to Andrej Golovnin for his feedback and suggestions.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class PlasticXPToolBarUI extends PlasticToolBarUI {
-
- public static ComponentUI createUI(JComponent b) {
- return new PlasticXPToolBarUI();
- }
-
-
- // Rollover Borders *******************************************************
-
- @Override
- protected Border createRolloverBorder() {
- return PlasticXPBorders.getRolloverButtonBorder();
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/PlasticXPUtils.java b/src/core/com/jgoodies/looks/plastic/PlasticXPUtils.java
deleted file mode 100644
index de6e6a1..0000000
--- a/src/core/com/jgoodies/looks/plastic/PlasticXPUtils.java
+++ /dev/null
@@ -1,202 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic;
-
-import java.awt.Color;
-import java.awt.Graphics;
-
-import javax.swing.plaf.metal.MetalLookAndFeel;
-
-import com.jgoodies.looks.LookUtils;
-
-
-/**
- * Consists exclusively of static methods that provide convenience behavior.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.5 $
- */
-
-public final class PlasticXPUtils {
-
- private PlasticXPUtils() {
- // Overrides default constructor; prevents instantiation.
- }
-
- /**
- * Draws a plain border for an xp button.
- */
- static void drawPlainButtonBorder(Graphics g, int x, int y, int w, int h) {
- drawButtonBorder(g, x, y, w, h,
- PlasticLookAndFeel.getControl(),
- PlasticLookAndFeel.getControlDarkShadow(),
- LookUtils.getSlightlyBrighter(
- PlasticLookAndFeel.getControlDarkShadow(),
- 1.25f)
- );
- }
-
- /**
- * Draws a border for a pressed xp button.
- */
- static void drawPressedButtonBorder(Graphics g, int x, int y, int w, int h) {
- drawPlainButtonBorder(g, x, y, w, h);
- Color darkColor =
- translucentColor(PlasticLookAndFeel.getControlDarkShadow(),
- 128);
- Color lightColor =
- translucentColor(PlasticLookAndFeel.getControlHighlight(),
- 80);
- g.translate(x, y);
- g.setColor(darkColor);
- g.fillRect(2, 1, w-4, 1);
-
- g.setColor(lightColor);
- g.fillRect(2, h-2, w-4, 1);
- g.translate(-x, -y);
- }
-
- /**
- * Draws a border for a default xp button.
- */
- static void drawDefaultButtonBorder(Graphics g, int x, int y, int w, int h) {
- drawPlainButtonBorder(g, x, y, w, h);
- drawInnerButtonDecoration(g, x, y, w, h,
- PlasticLookAndFeel.getPrimaryControlDarkShadow());
- }
-
- /**
- * Draws a border for a focused xp button.
- */
- static void drawFocusedButtonBorder(Graphics g, int x, int y, int w, int h) {
- drawPlainButtonBorder(g, x, y, w, h);
- drawInnerButtonDecoration(g, x, y, w, h,
- PlasticLookAndFeel.getFocusColor());
- }
-
- /**
- * Draws a border for a disabled xp button.
- */
- static void drawDisabledButtonBorder(Graphics g, int x, int y, int w, int h) {
- drawButtonBorder(g, x, y, w, h,
- PlasticLookAndFeel.getControl(),
- MetalLookAndFeel.getControlShadow(),
- LookUtils.getSlightlyBrighter(
- MetalLookAndFeel.getControlShadow()));
- }
-
-
- /**
- * Draws a button border for an xp button with the given colors.
- */
- public static void drawButtonBorder(
- Graphics g,
- int x, int y, int w, int h,
- Color backgroundColor,
- Color edgeColor,
- Color cornerColor) {
-
- g.translate(x, y);
- // Edges
- g.setColor(edgeColor);
- drawRect(g, 0, 0, w-1, h-1);
-
- // Near corners
- g.setColor(cornerColor);
- g.fillRect(0, 0, 2, 2);
- g.fillRect(0, h-2, 2, 2);
- g.fillRect(w-2, 0, 2, 2);
- g.fillRect(w-2, h-2, 2, 2);
-
- // Corners
- g.setColor(backgroundColor);
- g.fillRect(0, 0, 1, 1);
- g.fillRect(0, h-1, 1, 1);
- g.fillRect(w-1, 0, 1, 1);
- g.fillRect(w-1, h-1, 1, 1);
-
- g.translate(-x, -y);
- }
-
-
- /**
- * Draws a button border for an xp button with the given colors.
- */
- private static void drawInnerButtonDecoration(
- Graphics g,
- int x, int y, int w, int h,
- Color baseColor) {
-
- Color lightColor = translucentColor(baseColor, 90);
- Color mediumColor = translucentColor(baseColor, 120);
- Color darkColor = translucentColor(baseColor, 200);
-
- g.translate(x, y);
- g.setColor(lightColor);
- g.fillRect(2, 1, w-4, 1);
-
- g.setColor(mediumColor);
- g.fillRect (1, 2, 1, h-4);
- g.fillRect (w-2, 2, 1, h-4);
- drawRect(g, 2, 2, w-5, h-5);
-
- g.setColor(darkColor);
- g.fillRect(2, h-2, w-4, 1);
- g.translate(-x, -y);
- }
-
-
- /**
- * An optimized version of Graphics.drawRect.
- */
- static void drawRect(Graphics g, int x, int y, int w, int h) {
- g.fillRect(x, y, w+1, 1);
- g.fillRect(x, y+1, 1, h);
- g.fillRect(x+1, y+h, w, 1);
- g.fillRect(x+w, y+1, 1, h);
- }
-
-
- /**
- * Returns a color that is a translucent copy of the given color.
- *
- * @param baseColor the base color
- * @param alpha the alpha value
- * @return the translucent color with specified alpha
- */
- private static Color translucentColor(Color baseColor, int alpha) {
- return new Color(baseColor.getRed(),
- baseColor.getGreen(),
- baseColor.getBlue(),
- alpha);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-error.png b/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-error.png
deleted file mode 100644
index cdd95ba..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-error.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-help.png b/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-help.png
deleted file mode 100644
index d60425f..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-help.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-information.png b/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-information.png
deleted file mode 100644
index 2ac5747..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-information.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-warning.png b/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-warning.png
deleted file mode 100644
index 7233d45..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/32x32/dialog-warning.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-error.png b/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-error.png
deleted file mode 100644
index d636129..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-error.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-help.png b/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-help.png
deleted file mode 100644
index 2716610..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-help.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-information.png b/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-information.png
deleted file mode 100644
index e4a4c23..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-information.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-warning.png b/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-warning.png
deleted file mode 100644
index 0f9383a..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/48x48/dialog-warning.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/CDDrive.gif b/src/core/com/jgoodies/looks/plastic/icons/CDDrive.gif
deleted file mode 100644
index 58915c4..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/CDDrive.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/Computer.gif b/src/core/com/jgoodies/looks/plastic/icons/Computer.gif
deleted file mode 100644
index 234a04e..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/Computer.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/File.gif b/src/core/com/jgoodies/looks/plastic/icons/File.gif
deleted file mode 100644
index ae038c8..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/File.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/FloppyDrive.gif b/src/core/com/jgoodies/looks/plastic/icons/FloppyDrive.gif
deleted file mode 100644
index a2e0dd2..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/FloppyDrive.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/HardDrive.gif b/src/core/com/jgoodies/looks/plastic/icons/HardDrive.gif
deleted file mode 100644
index 9c67c7b..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/HardDrive.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/HomeFolder.gif b/src/core/com/jgoodies/looks/plastic/icons/HomeFolder.gif
deleted file mode 100644
index 949c2db..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/HomeFolder.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/NewFolder.gif b/src/core/com/jgoodies/looks/plastic/icons/NewFolder.gif
deleted file mode 100644
index eecdb6f..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/NewFolder.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/RadioLight5x5.png b/src/core/com/jgoodies/looks/plastic/icons/RadioLight5x5.png
deleted file mode 100644
index 4fdc43d..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/RadioLight5x5.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/RadioLight7x7.png b/src/core/com/jgoodies/looks/plastic/icons/RadioLight7x7.png
deleted file mode 100644
index 3fdb132..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/RadioLight7x7.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/TreeClosed.gif b/src/core/com/jgoodies/looks/plastic/icons/TreeClosed.gif
deleted file mode 100644
index cb80e94..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/TreeClosed.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/TreeCollapsed.png b/src/core/com/jgoodies/looks/plastic/icons/TreeCollapsed.png
deleted file mode 100644
index 92e6b2b..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/TreeCollapsed.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/TreeExpanded.png b/src/core/com/jgoodies/looks/plastic/icons/TreeExpanded.png
deleted file mode 100644
index 7879fb1..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/TreeExpanded.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/TreeLeaf.gif b/src/core/com/jgoodies/looks/plastic/icons/TreeLeaf.gif
deleted file mode 100644
index 510f554..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/TreeLeaf.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/TreeOpen.gif b/src/core/com/jgoodies/looks/plastic/icons/TreeOpen.gif
deleted file mode 100644
index d197345..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/TreeOpen.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/icons/UpFolder.gif b/src/core/com/jgoodies/looks/plastic/icons/UpFolder.gif
deleted file mode 100644
index 61ba99d..0000000
Binary files a/src/core/com/jgoodies/looks/plastic/icons/UpFolder.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/plastic/package.html b/src/core/com/jgoodies/looks/plastic/package.html
deleted file mode 100644
index 71714a8..0000000
--- a/src/core/com/jgoodies/looks/plastic/package.html
+++ /dev/null
@@ -1,65 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
- Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- o Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- o Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
- o Neither the name of JGoodies Karsten Lentzsch nor the names of
- its contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
- OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
- JavaDoc uses all text between the "body" tags.
- The first sentence is used as short description.
--->
-</head>
-<body bgcolor="white">
-
-Contains the classes for the JGoodies Plastic L&Fs.
-
-<!--
-<h2>Package Specification</h2>
-
-##### FILL IN ANY SPECS NEEDED BY JAVA COMPATIBILITY KIT #####
-<ul>
- <li><a href="">##### REFER TO ANY FRAMEMAKER SPECIFICATION HERE #####</a>
-</ul>
--->
-
-<h2>Related Documentation</h2>
-
-For more information see:
-<ul>
- <li><a href="http://www.jgoodies.com/articles/" >
- http://www.jgoodies.com/articles/</a>
-</ul>
-<!-- Put @see and @since tags down here. -->
-
- at see com.jgoodies.looks
- at see com.jgoodies.looks.common
- at see com.jgoodies.looks.plastic.theme
- at see com.jgoodies.looks.windows
-
-</body>
-</html>
diff --git a/src/core/com/jgoodies/looks/plastic/theme/AbstractSkyTheme.java b/src/core/com/jgoodies/looks/plastic/theme/AbstractSkyTheme.java
deleted file mode 100644
index 6314001..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/AbstractSkyTheme.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A theme with low saturated blue primary colors and a light gray
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public abstract class AbstractSkyTheme extends SkyBluer {
-
- private static final ColorUIResource SECONDARY2 =
- new ColorUIResource(164, 164, 164);
-
- private static final ColorUIResource SECONDARY3 =
- new ColorUIResource(225, 225, 225);
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.GRAY_DARK;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.BLUE_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.BLUE_LOW_LIGHTEST;
- }
-
- @Override
- protected ColorUIResource getSecondary1() {
- return Colors.GRAY_MEDIUM;
- }
- @Override
- protected ColorUIResource getSecondary2() {
- return SECONDARY2;
- }
-
- @Override
- protected ColorUIResource getSecondary3() {
- return SECONDARY3;
- }
-
- // Background
- @Override
- public ColorUIResource getPrimaryControlShadow() {
- return getPrimary3();
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedBackground() {
- return getPrimary1();
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- {
- PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY,
- null,
- "ScrollBar.thumbHighlight",
- getPrimaryControlHighlight(),
- };
- table.putDefaults(uiDefaults);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/BrownSugar.java b/src/core/com/jgoodies/looks/plastic/theme/BrownSugar.java
deleted file mode 100644
index e268cce..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/BrownSugar.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-/**
- * An inverted theme with light foreground colors and a dark brown
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class BrownSugar extends InvertedColorTheme {
-
- private final ColorUIResource softWhite = new ColorUIResource(165, 157, 143);
-
- private final ColorUIResource primary1 = new ColorUIResource( 83, 83, 61); //90, 90, 66);// Dunkel: Rollbalkenrahmen-Dunkel
- private final ColorUIResource primary2 = new ColorUIResource(115, 107, 82); //132, 123, 90);// Mittel: Rollbalkenhintergrund
- private final ColorUIResource primary3 = new ColorUIResource(156, 156, 123); //148, 140, 107); //181, 173, 148); // Hell: Ordnerfläche, Selektion, Rollbalken-Hoch, Menühintergrund
-
- private final ColorUIResource secondary1 = new ColorUIResource( 35, 33, 29); // Abwärts (dunkler)73, 59, 23);
- private final ColorUIResource secondary2 = new ColorUIResource(105, 99, 87); // Aufwärts (heller)136, 112, 46);
- private final ColorUIResource secondary3 = new ColorUIResource( 92, 87, 76); // Fläche 134, 104, 22);
-
-
- @Override
- public String getName() { return "Brown Sugar"; }
-
-
- @Override
- protected ColorUIResource getPrimary1() { return primary1; }
- @Override
- protected ColorUIResource getPrimary2() { return primary2; }
- @Override
- protected ColorUIResource getPrimary3() { return primary3; }
- @Override
- protected ColorUIResource getSecondary1() { return secondary1; }
- @Override
- protected ColorUIResource getSecondary2() { return secondary2; }
- @Override
- protected ColorUIResource getSecondary3() { return secondary3; }
- @Override
- protected ColorUIResource getSoftWhite() { return softWhite; }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/Colors.java b/src/core/com/jgoodies/looks/plastic/theme/Colors.java
deleted file mode 100644
index df990c1..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/Colors.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import java.awt.Color;
-
-import javax.swing.plaf.ColorUIResource;
-
-/**
- * Consists of base colors useful for building new color themes.
- * <p>
- * The field names use the following naming convention:
- * <color name>_<saturation>_<brightness>,
- * for example: {@code BLUE_HIGH_LIGHT} and {@code GREEN_MEDIUM_LIGHTER}.<p>
- *
- * The saturation values are: {@code LOW}, {@code MEDIUM},
- * and {@code HIGH}. Brightness values are:
- * {@code DARKEST}, {@code DARKER}, {@code DARK},
- * {@code MEDIUM}, {@code LIGHT}, {@code LIGHTER},
- * and {@code LIGHTEST}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-final class Colors {
-
- // Gray Colors **********************************************************************
-
- static final ColorUIResource GRAY_DARKEST = new ColorUIResource( 64, 64, 64);
- static final ColorUIResource GRAY_DARKER = new ColorUIResource( 82, 82, 82);
- static final ColorUIResource GRAY_DARK = new ColorUIResource( 90, 90, 90);
- static final ColorUIResource GRAY_MEDIUMDARK = new ColorUIResource(110, 110, 110);
- static final ColorUIResource GRAY_MEDIUM = new ColorUIResource(128, 128, 128);
- static final ColorUIResource GRAY_MEDIUMLIGHT = new ColorUIResource(150,
- 150, 150);
- static final ColorUIResource GRAY_LIGHT = new ColorUIResource(170, 170, 170);
- static final ColorUIResource GRAY_LIGHTER = new ColorUIResource(220, 220, 220);
- static final ColorUIResource GRAY_LIGHTER2 = new ColorUIResource(230, 230, 230);
- static final ColorUIResource GRAY_LIGHTEST = new ColorUIResource(240, 240, 240);
-
- // Brown Colors *********************************************************************
-
- static final ColorUIResource BROWN_LIGHTEST = new ColorUIResource(242, 241, 238);
-
- // Blue Colors *********************************************************************
-
- static final ColorUIResource BLUE_LOW_MEDIUM = new ColorUIResource(166, 202, 240);
- static final ColorUIResource BLUE_LOW_LIGHTEST = new ColorUIResource(195, 212, 232);
-
- static final ColorUIResource BLUE_MEDIUM_DARKEST = new ColorUIResource( 44, 73, 135);
- static final ColorUIResource BLUE_MEDIUM_DARK = new ColorUIResource( 49, 106, 196);
- static final ColorUIResource BLUE_MEDIUM_MEDIUM = new ColorUIResource( 85, 115, 170); // 58, 110, 165);
- static final ColorUIResource BLUE_MEDIUM_LIGHTEST = new ColorUIResource(172, 210, 248); //189, 220, 251); //153, 179, 205);
-
- // Green Colors *********************************************************************
-
- static final ColorUIResource GREEN_LOW_DARK = new ColorUIResource( 75, 148, 75);
- static final ColorUIResource GREEN_LOW_MEDIUM = new ColorUIResource(112, 190, 112);
- static final ColorUIResource GREEN_LOW_LIGHTEST = new ColorUIResource(200, 222, 200);
-
- static final ColorUIResource GREEN_CHECK = new ColorUIResource( 33, 161, 33);
-
- // Pink Colors **********************************************************************
-
- static final ColorUIResource PINK_HIGH_DARK = new ColorUIResource(128, 0, 128); //192, 0, 192);
- static final ColorUIResource PINK_LOW_DARK = new ColorUIResource(128, 70, 128); //192, 0, 192);
- static final ColorUIResource PINK_LOW_MEDIUM = new ColorUIResource(190, 150, 190);
- static final ColorUIResource PINK_LOW_LIGHTER = new ColorUIResource(233, 207, 233);
-
- // Red Colors **********************************************************************
-
- static final ColorUIResource RED_LOW_DARK = new ColorUIResource(128, 70, 70);
- static final ColorUIResource RED_LOW_MEDIUM = new ColorUIResource(190, 112, 112);
- static final ColorUIResource RED_LOW_LIGHTER = new ColorUIResource(222, 200, 200);
-
- // Yellow Colors *******************************************************************
-
- static final ColorUIResource YELLOW_LOW_MEDIUMDARK = new ColorUIResource(182, 149, 18);
- static final ColorUIResource YELLOW_LOW_MEDIUM = new ColorUIResource(244, 214, 96);
- static final ColorUIResource YELLOW_LOW_LIGHTEST = new ColorUIResource(249, 225, 131);
-
- // Focus Colors *********************************************************************
-
- static final ColorUIResource BLUE_FOCUS = BLUE_MEDIUM_LIGHTEST;
- static final ColorUIResource ORANGE_FOCUS = new ColorUIResource(245, 165, 16);
- static final ColorUIResource YELLOW_FOCUS = new ColorUIResource(255, 223, 63);
- static final ColorUIResource GRAY_FOCUS = new ColorUIResource(Color.LIGHT_GRAY);
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/DarkStar.java b/src/core/com/jgoodies/looks/plastic/theme/DarkStar.java
deleted file mode 100644
index c4885a8..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/DarkStar.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-
-/**
- * An inverted theme with light foreground colors and a black
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-
-public class DarkStar extends InvertedColorTheme {
-
- private final ColorUIResource softWhite = new ColorUIResource(154, 154, 154);
-
- private final ColorUIResource primary1 = new ColorUIResource( 83, 83, 61); //90, 90, 66);// Dunkel: Rollbalkenrahmen-Dunkel
- private final ColorUIResource primary2 = new ColorUIResource(115, 107, 82); //132, 123, 90);// Mittel: Rollbalkenhintergrund
- private final ColorUIResource primary3 = new ColorUIResource(156, 156, 123); //148, 140, 107); //181, 173, 148); // Hell: Ordnerfläche, Selektion, Rollbalken-Hoch, Menühintergrund
-
- private final ColorUIResource secondary1 = new ColorUIResource( 32, 32, 32); // Abwärts (dunkler)73, 59, 23);
- private final ColorUIResource secondary2 = new ColorUIResource( 96, 96, 96); // Aufwärts (heller)136, 112, 46);
- private final ColorUIResource secondary3 = new ColorUIResource( 84, 84, 84); // Fläche 134, 104, 22);
-
-
- @Override
- public String getName() { return "Dark Star"; }
-
-
- @Override
- protected ColorUIResource getPrimary1() { return primary1; }
- @Override
- protected ColorUIResource getPrimary2() { return primary2; }
- @Override
- protected ColorUIResource getPrimary3() { return primary3; }
- @Override
- protected ColorUIResource getSecondary1() { return secondary1; }
- @Override
- protected ColorUIResource getSecondary2() { return secondary2; }
- @Override
- protected ColorUIResource getSecondary3() { return secondary3; }
- @Override
- protected ColorUIResource getSoftWhite() { return softWhite; }
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/DesertBlue.java b/src/core/com/jgoodies/looks/plastic/theme/DesertBlue.java
deleted file mode 100644
index c136acf..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/DesertBlue.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-
-/**
- * A theme with low saturated blue primary colors and a light brown
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public class DesertBlue extends DesertBluer {
-
- @Override
- public String getName() { return "Desert Blue"; }
-
-
- private static final ColorUIResource SECONDARY2 = new ColorUIResource(148, 144, 140);
- private static final ColorUIResource SECONDARY3 = new ColorUIResource(211, 210, 204);
-
-
-
- @Override
- protected ColorUIResource getPrimary1() { return Colors.GRAY_DARK; }
- @Override
- protected ColorUIResource getPrimary2() { return Colors.BLUE_LOW_MEDIUM; }
- @Override
- protected ColorUIResource getPrimary3() { return Colors.BLUE_LOW_LIGHTEST; }
-
- @Override
- protected ColorUIResource getSecondary1() { return Colors.GRAY_MEDIUM; }
- @Override
- protected ColorUIResource getSecondary2() { return SECONDARY2; }
- @Override
- protected ColorUIResource getSecondary3() { return SECONDARY3; }
-
- @Override
- public ColorUIResource getTitleTextColor() { return Colors.BLUE_MEDIUM_DARKEST;}
-
- @Override
- public ColorUIResource getFocusColor() {
- return PlasticLookAndFeel.getHighContrastFocusColorsEnabled()
- ? Colors.YELLOW_FOCUS
- : Colors.BLUE_MEDIUM_DARK;
- }
- // Background
- @Override
- public ColorUIResource getPrimaryControlShadow() { return getPrimary3(); }
- @Override
- public ColorUIResource getMenuItemSelectedBackground() { return getPrimary1(); }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults = {
- "ScrollBar.is3DEnabled", Boolean.FALSE,
- "ScrollBar.thumbHighlight", getPrimaryControlHighlight(),
- PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY, null,
- };
- table.putDefaults(uiDefaults);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/DesertBluer.java b/src/core/com/jgoodies/looks/plastic/theme/DesertBluer.java
deleted file mode 100644
index fd498f4..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/DesertBluer.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-
-/**
- * A theme with medium saturated blue primary colors and a light brown
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public class DesertBluer extends SkyBluer {
-
- private final ColorUIResource primary1 = new ColorUIResource( 10, 36, 106);
- private final ColorUIResource primary2 = new ColorUIResource( 85, 115, 170);
- private final ColorUIResource primary3 = new ColorUIResource(172, 210, 248);
-
- private final ColorUIResource secondary2 = new ColorUIResource(148, 144, 140);
- private final ColorUIResource secondary3 = new ColorUIResource(212, 208, 200);
-
-
- @Override
- public String getName() { return "Desert Bluer"; }
-
-
- @Override
- protected ColorUIResource getPrimary1() { return primary1; }
- @Override
- protected ColorUIResource getPrimary2() { return primary2; }
- @Override
- protected ColorUIResource getPrimary3() { return primary3; }
- @Override
- protected ColorUIResource getSecondary1() { return Colors.GRAY_MEDIUM; }
- @Override
- protected ColorUIResource getSecondary2() { return secondary2; }
- @Override
- protected ColorUIResource getSecondary3() { return secondary3; }
-
- @Override
- public ColorUIResource getTextHighlightColor() { return getPrimary1(); }
- @Override
- public ColorUIResource getHighlightedTextColor() { return getWhite(); }
- @Override
- public ColorUIResource getMenuItemSelectedBackground() { return getPrimary1(); }
-
- @Override
- public ColorUIResource getFocusColor() {
- return PlasticLookAndFeel.getHighContrastFocusColorsEnabled()
- ? Colors.ORANGE_FOCUS
- : super.getFocusColor();
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/DesertGreen.java b/src/core/com/jgoodies/looks/plastic/theme/DesertGreen.java
deleted file mode 100644
index 7423808..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/DesertGreen.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-/**
- * A theme with low saturated green primary colors and a light brown
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class DesertGreen extends DesertBlue {
-
- @Override
- public String getName() {
- return "Desert Green";
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.GREEN_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.GREEN_LOW_LIGHTEST;
- }
-
- @Override
- public ColorUIResource getTitleTextColor() {
- return Colors.GRAY_DARKER;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/DesertRed.java b/src/core/com/jgoodies/looks/plastic/theme/DesertRed.java
deleted file mode 100644
index 7c56811..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/DesertRed.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-/**
- * A theme with low saturated red primary colors and a light brown
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class DesertRed extends DesertBlue {
-
- @Override
- public String getName() {
- return "Desert Red";
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.RED_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.RED_LOW_LIGHTER;
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return Colors.PINK_LOW_DARK;
- }
-
- @Override
- public ColorUIResource getTitleTextColor() {
- return Colors.GRAY_DARKER;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/DesertYellow.java b/src/core/com/jgoodies/looks/plastic/theme/DesertYellow.java
deleted file mode 100644
index d1807a1..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/DesertYellow.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A theme with low saturated yellow primary colors and a light brown
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class DesertYellow extends DesertBlue {
-
- @Override
- public String getName() {
- return "Desert Yellow";
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.YELLOW_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.YELLOW_LOW_LIGHTEST;
- }
-
- @Override
- public ColorUIResource getTitleTextColor() {
- return Colors.GRAY_DARKER;
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedBackground() {
- return Colors.YELLOW_LOW_MEDIUMDARK;
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- {
- "ScrollBar.is3DEnabled",
- Boolean.TRUE,
- PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY,
- new Integer(30),
- };
- table.putDefaults(uiDefaults);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/ExperienceBlue.java b/src/core/com/jgoodies/looks/plastic/theme/ExperienceBlue.java
deleted file mode 100644
index cba22c7..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/ExperienceBlue.java
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A theme with low saturated blue primary colors and a light brown
- * window background. It has been optimized to work with Windows XP
- * default desktop settings.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public class ExperienceBlue extends DesertBluer {
-
-
- @Override
- public String getName() {
- return "Experience Blue";
- }
-
- protected static final ColorUIResource LUNA_BACKGROUND =
- new ColorUIResource(236, 233, 216);
-
- protected static final ColorUIResource LUNA_BACKGROUND_DARKER =
- new ColorUIResource(189, 190, 176);
-
-
- private static final ColorUIResource SECONDARY1 =
- Colors.GRAY_MEDIUM;
-
- private static final ColorUIResource SECONDARY2 =
- LUNA_BACKGROUND_DARKER;
-
- private static final ColorUIResource SECONDARY3 =
- LUNA_BACKGROUND;
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.BLUE_MEDIUM_DARK;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.BLUE_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.BLUE_LOW_LIGHTEST;
- }
-
- @Override
- protected ColorUIResource getSecondary1() {
- return SECONDARY1;
- }
-
- @Override
- protected ColorUIResource getSecondary2() {
- return SECONDARY2;
- }
-
- @Override
- protected ColorUIResource getSecondary3() {
- return SECONDARY3;
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return Colors.ORANGE_FOCUS;
- }
-
- @Override
- public ColorUIResource getPrimaryControlShadow() {
- return getPrimary3();
- }
-
- @Override
- public ColorUIResource getMenuSelectedBackground() {
- return getPrimary1();
- }
- @Override
- public ColorUIResource getMenuSelectedForeground() {
- return WHITE;
- }
-
- @Override
- public ColorUIResource getMenuItemBackground() {
- return WHITE;
- }
-
- @Override
- public ColorUIResource getToggleButtonCheckColor() {
- return Colors.GREEN_CHECK;
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- {
- "ScrollBar.thumbHighlight",
- getPrimaryControlHighlight(),
- PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY,
- new Integer(22),
- };
- table.putDefaults(uiDefaults);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/ExperienceGreen.java b/src/core/com/jgoodies/looks/plastic/theme/ExperienceGreen.java
deleted file mode 100644
index d11c5f0..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/ExperienceGreen.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-/**
- * A theme with low saturated green primary colors and a light brown
- * window background. It has been optimized to work with Windows XP
- * default desktop settings.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class ExperienceGreen extends ExperienceBlue {
-
- @Override
- public String getName() {
- return "Experience Green";
- }
-
- private static final ColorUIResource FOCUS =
- new ColorUIResource(245, 165, 16);
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.GREEN_LOW_DARK;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.GREEN_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.GREEN_LOW_LIGHTEST;
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return FOCUS;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/ExperienceRoyale.java b/src/core/com/jgoodies/looks/plastic/theme/ExperienceRoyale.java
deleted file mode 100644
index 669b493..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/ExperienceRoyale.java
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A theme with low saturated blue primary colors and a light gray/blueish
- * window background. It has been optimized to work with Windows XP
- * using the "Royale" desktop theme.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- *
- * @since 2.0.3
- */
-public class ExperienceRoyale extends DesertBluer {
-
- @Override
- public String getName() {
- return "Experience Royale";
- }
-
- protected static final ColorUIResource ROYALE_BACKGROUND =
- new ColorUIResource(235, 233, 237);
-
- protected static final ColorUIResource ROYALE_BACKGROUND_DARKER =
- new ColorUIResource(167, 166, 170);
-
- protected static final ColorUIResource ROYALE_SELECTION =
- new ColorUIResource(51, 94, 168);
-
- private static final ColorUIResource SECONDARY1 =
- Colors.GRAY_MEDIUM;
-
- private static final ColorUIResource SECONDARY2 =
- ROYALE_BACKGROUND_DARKER;
-
- private static final ColorUIResource SECONDARY3 =
- ROYALE_BACKGROUND;
-
- @Override
- protected ColorUIResource getPrimary1() {
- return ROYALE_SELECTION;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.BLUE_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.BLUE_LOW_LIGHTEST;
- }
-
- @Override
- protected ColorUIResource getSecondary1() {
- return SECONDARY1;
- }
-
- @Override
- protected ColorUIResource getSecondary2() {
- return SECONDARY2;
- }
-
- @Override
- protected ColorUIResource getSecondary3() {
- return SECONDARY3;
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return Colors.ORANGE_FOCUS;
- }
-
- @Override
- public ColorUIResource getPrimaryControlShadow() {
- return getPrimary3();
- }
-
- @Override
- public ColorUIResource getMenuSelectedBackground() {
- return getPrimary1();
- }
- @Override
- public ColorUIResource getMenuSelectedForeground() {
- return WHITE;
- }
-
- @Override
- public ColorUIResource getMenuItemBackground() {
- return WHITE;
- }
-
- @Override
- public ColorUIResource getToggleButtonCheckColor() {
- return Colors.GREEN_CHECK;
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- {
- "ScrollBar.thumbHighlight",
- getPrimaryControlHighlight(),
- PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY,
- new Integer(22),
- };
- table.putDefaults(uiDefaults);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/InvertedColorTheme.java b/src/core/com/jgoodies/looks/plastic/theme/InvertedColorTheme.java
deleted file mode 100644
index 2171747..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/InvertedColorTheme.java
+++ /dev/null
@@ -1,214 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import java.awt.Color;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticTheme;
-
-/**
- * The abstract superclass of all inverted Plastic themes,
- * that have light foreground and dark window background colors.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public abstract class InvertedColorTheme extends PlasticTheme {
-
- private final ColorUIResource softWhite =
- new ColorUIResource(154, 154, 154);
-
- private final ColorUIResource primary1 = new ColorUIResource(83, 83, 61);
- //90, 90, 66);// Dunkel: Rollbalkenrahmen-Dunkel
-
- private final ColorUIResource primary2 = new ColorUIResource(115, 107, 82);
- //132, 123, 90);// Mittel: Rollbalkenhintergrund
-
- private final ColorUIResource primary3 = new ColorUIResource(156, 156, 123);
- //148, 140, 107); //181, 173, 148); // Hell: Ordnerfläche, Selektion, Rollbalken-Hoch, Menühintergrund
-
- private final ColorUIResource secondary1 = new ColorUIResource(32, 32, 32);
- // Abwärts (dunkler)73, 59, 23);
-
- private final ColorUIResource secondary2 = new ColorUIResource(96, 96, 96);
- // Aufwärts (heller)136, 112, 46);
-
- private final ColorUIResource secondary3 = new ColorUIResource(84, 84, 84);
- // Fläche 134, 104, 22);
-
- @Override
- public ColorUIResource getSimpleInternalFrameBackground() {
- return getWhite();
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults = {
- "TextField.ineditableForeground",
- getSoftWhite(),
- "Plastic.brightenStop",
- new Color(255, 255, 255, 20),
- "Plastic.ltBrightenStop",
- new Color(255, 255, 255, 16),
- "SimpleInternalFrame.activeTitleBackground",
- getPrimary2()
- };
- table.putDefaults(uiDefaults);
- }
-
- @Override
- public ColorUIResource getControlDisabled() {
- return getSoftWhite();
- }
-
- @Override
- public ColorUIResource getControlHighlight() {
- return getSoftWhite();
- }
-
- @Override
- public ColorUIResource getControlInfo() {
- return getWhite();
- }
-
- @Override
- public ColorUIResource getInactiveSystemTextColor() {
- return getSoftWhite();
- }
-
- @Override
- public ColorUIResource getMenuDisabledForeground() {
- return getSoftWhite();
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedBackground() {
- return getPrimary3();
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedForeground() {
- return getBlack();
- }
-
- @Override
- public ColorUIResource getMenuSelectedBackground() {
- return getPrimary2();
- }
-
- @Override
- public ColorUIResource getMenuSelectedForeground() {
- return getWhite();
- }
-
- @Override
- protected ColorUIResource getPrimary1() {
- return primary1;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return primary2;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return primary3;
- }
- @Override
- public ColorUIResource getPrimaryControlHighlight() {
- return getSoftWhite();
- }
-
- @Override
- protected ColorUIResource getSecondary1() {
- return secondary1;
- }
-
- @Override
- protected ColorUIResource getSecondary2() {
- return secondary2;
- }
-
- @Override
- protected ColorUIResource getSecondary3() {
- return secondary3;
- }
-
- @Override
- public ColorUIResource getSeparatorBackground() {
- return getSoftWhite();
- }
-
- protected ColorUIResource getSoftWhite() {
- return softWhite;
- }
-
- @Override
- public ColorUIResource getTitleTextColor() {
- return getControlInfo();
- }
-
- @Override
- public ColorUIResource getToggleButtonCheckColor() {
- return getWhite();
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return Colors.GRAY_FOCUS;
- }
-
-// public FontUIResource getControlTextFont() {
-// return getFont();
-// }
-//
-// public FontUIResource getMenuTextFont() {
-// return getFont();
-// }
-//
-// public FontUIResource getWindowTitleFont() {
-// return getFont();
-// }
-//
-// public FontUIResource getSystemTextFont() {
-// return getFont();
-// }
-//
-// public FontUIResource getUserTextFont() {
-// return getFont();
-// }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/LightGray.java b/src/core/com/jgoodies/looks/plastic/theme/LightGray.java
deleted file mode 100644
index b947c9a..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/LightGray.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A very light color theme intended to be used on Windows Vista in Aero style.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @since 2.0.3
- */
-public class LightGray extends ExperienceBlue {
-
- private static final ColorUIResource GRAY_VERY_LIGHT =
- new ColorUIResource(244, 244, 244);
-
- @Override
- public String getName() {
- return "Light Gray";
- }
-
- @Override
- protected ColorUIResource getPrimary1() {
- return new ColorUIResource(51, 153, 255); // Selection
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.GRAY_MEDIUMLIGHT;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return new ColorUIResource(225, 240, 255); // GRAY_VERY_LIGHT;
- }
-
- @Override
- protected ColorUIResource getSecondary1() { // 3D Schattenseite
- return Colors.GRAY_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getSecondary2() { // Disabled Border
- return getPrimary2();
- }
-
- @Override
- protected ColorUIResource getSecondary3() {
- return GRAY_VERY_LIGHT; // Window background
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return PlasticLookAndFeel.getHighContrastFocusColorsEnabled()
- ? Colors.ORANGE_FOCUS
- : Colors.BLUE_MEDIUM_DARK;
- }
-
- @Override
- public ColorUIResource getTitleTextColor() {
- return Colors.GRAY_DARKEST;
- }
-
- @Override
- public ColorUIResource getSimpleInternalFrameBackground() {
- return Colors.GRAY_MEDIUMDARK;
- }
-
- @Override
-public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- { PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY, new Integer(30),
- "TabbedPane.selected", getWhite(),
- "TabbedPane.selectHighlight", Colors.GRAY_MEDIUM,
- };
- table.putDefaults(uiDefaults);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/Silver.java b/src/core/com/jgoodies/looks/plastic/theme/Silver.java
deleted file mode 100644
index a9353fc..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/Silver.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A completely gray or silver theme that has been optimized to work
- * in Windows XP environments.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public class Silver extends ExperienceBlue {
-
- private static final ColorUIResource GRAY_LIGHT_LIGHTER =
- new ColorUIResource(190, 190, 190);
-
- @Override
- public String getName() {
- return "Silver";
- }
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.GRAY_MEDIUMDARK;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.GRAY_MEDIUMLIGHT;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return GRAY_LIGHT_LIGHTER;
- }
-
- @Override
- protected ColorUIResource getSecondary1() {
- return Colors.GRAY_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getSecondary2() {
- return getPrimary2();
- }
-
- @Override
- protected ColorUIResource getSecondary3() {
- return Colors.GRAY_LIGHTER2;
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return PlasticLookAndFeel.getHighContrastFocusColorsEnabled()
- ? Colors.ORANGE_FOCUS
- : Colors.BLUE_MEDIUM_DARK;
- }
-
- @Override
- public ColorUIResource getTitleTextColor() {
- return Colors.GRAY_DARKEST;
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- { PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY, new Integer(50), };
- table.putDefaults(uiDefaults);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/SkyBlue.java b/src/core/com/jgoodies/looks/plastic/theme/SkyBlue.java
deleted file mode 100644
index 1204914..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/SkyBlue.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-/**
- * A theme with low saturated blue primary colors and a light gray
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class SkyBlue extends AbstractSkyTheme {
-
- @Override
- public String getName() {
- return "Sky Blue";
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/SkyBluer.java b/src/core/com/jgoodies/looks/plastic/theme/SkyBluer.java
deleted file mode 100644
index a401d94..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/SkyBluer.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-import com.jgoodies.looks.plastic.PlasticTheme;
-
-/**
- * A theme with medium blue primary colors and a light gray window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public class SkyBluer extends PlasticTheme {
-
- @Override
- public String getName() {
- return "Sky Bluer";
- }
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.BLUE_MEDIUM_DARKEST;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.BLUE_MEDIUM_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.BLUE_MEDIUM_LIGHTEST;
- }
-
- @Override
- protected ColorUIResource getSecondary1() {
- return Colors.GRAY_MEDIUMDARK;
- }
-
- @Override
- protected ColorUIResource getSecondary2() {
- return Colors.GRAY_LIGHT;
- }
-
- @Override
- protected ColorUIResource getSecondary3() {
- return Colors.GRAY_LIGHTER;
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedBackground() {
- return getPrimary2();
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedForeground() {
- return getWhite();
- }
-
- @Override
- public ColorUIResource getMenuSelectedBackground() {
- return getSecondary2();
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return PlasticLookAndFeel.getHighContrastFocusColorsEnabled()
- ? Colors.YELLOW_FOCUS
- : super.getFocusColor();
- }
-
- /*
- * TODO: The following two lines are likely an improvement.
- * However, they require a rewrite of the PlasticInternalFrameTitlePanel.
- public ColorUIResource getWindowTitleBackground() { return getPrimary1(); }
- public ColorUIResource getWindowTitleForeground() { return WHITE; }
- */
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- { PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY, new Integer(30), };
- table.putDefaults(uiDefaults);
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/SkyGreen.java b/src/core/com/jgoodies/looks/plastic/theme/SkyGreen.java
deleted file mode 100644
index 97825f4..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/SkyGreen.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-/**
- * A theme with low saturated green primary colors and a light gray
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class SkyGreen extends AbstractSkyTheme {
-
- @Override
- public String getName() {
- return "Sky Green";
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.GREEN_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.GREEN_LOW_LIGHTEST;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/plastic/theme/SkyKrupp.java b/src/core/com/jgoodies/looks/plastic/theme/SkyKrupp.java
deleted file mode 100644
index 9ef10ae..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/SkyKrupp.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-
-/**
- * A theme with metal blue primary colors and a light gray window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-
-public class SkyKrupp extends AbstractSkyTheme {
-
- @Override
- public String getName() {
- return "Sky Krupp";
- }
-
- private final ColorUIResource primary1 = new ColorUIResource(54, 54, 90);
- private final ColorUIResource primary2 = new ColorUIResource(156, 156, 178);
- private final ColorUIResource primary3 = new ColorUIResource(197, 197, 221);
-
- @Override
- protected ColorUIResource getPrimary1() {
- return primary1;
- }
- @Override
- protected ColorUIResource getPrimary2() {
- return primary2;
- }
- @Override
- protected ColorUIResource getPrimary3() {
- return primary3;
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedBackground() {
- return getPrimary1();
- }
- @Override
- public ColorUIResource getMenuItemSelectedForeground() {
- return getWhite();
- }
- @Override
- public ColorUIResource getMenuSelectedBackground() {
- return getSecondary2();
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return PlasticLookAndFeel.getHighContrastFocusColorsEnabled()
- ? Colors.ORANGE_FOCUS
- : Colors.GRAY_DARK;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/SkyPink.java b/src/core/com/jgoodies/looks/plastic/theme/SkyPink.java
deleted file mode 100644
index 38e3c68..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/SkyPink.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A theme with pink foreground and a light gray window background color.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class SkyPink extends AbstractSkyTheme {
-
- @Override
- public String getName() {
- return "Sky Pink";
- }
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.PINK_LOW_DARK;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.PINK_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.PINK_LOW_LIGHTER;
- }
-
- @Override
- public ColorUIResource getHighlightedTextColor() {
- return getControlTextColor();
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- { PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY, new Integer(30), };
- table.putDefaults(uiDefaults);
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/SkyRed.java b/src/core/com/jgoodies/looks/plastic/theme/SkyRed.java
deleted file mode 100644
index ef14b7d..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/SkyRed.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.plaf.ColorUIResource;
-
-/**
- * A theme with low saturated red primary colors and a light gray
- * window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public class SkyRed extends AbstractSkyTheme {
-
- @Override
- public String getName() {
- return "Sky Red";
- }
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.RED_LOW_DARK;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.RED_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.RED_LOW_LIGHTER;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/SkyYellow.java b/src/core/com/jgoodies/looks/plastic/theme/SkyYellow.java
deleted file mode 100644
index de5d1e3..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/SkyYellow.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.plastic.theme;
-
-import javax.swing.UIDefaults;
-import javax.swing.plaf.ColorUIResource;
-
-import com.jgoodies.looks.plastic.PlasticScrollBarUI;
-
-/**
- * A theme with yellow primary colors and a light gray window background.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-
-public class SkyYellow extends AbstractSkyTheme {
-
- @Override
- public String getName() {
- return "Sky Yellow";
- }
-
- @Override
- protected ColorUIResource getPrimary1() {
- return Colors.GRAY_DARK;
- }
-
- @Override
- protected ColorUIResource getPrimary2() {
- return Colors.YELLOW_LOW_MEDIUM;
- }
-
- @Override
- protected ColorUIResource getPrimary3() {
- return Colors.YELLOW_LOW_LIGHTEST;
- }
-
- @Override
- public ColorUIResource getFocusColor() {
- return Colors.ORANGE_FOCUS;
- }
-
- @Override
- public ColorUIResource getPrimaryControlShadow() {
- return getPrimary3();
- }
-
- @Override
- public ColorUIResource getMenuItemSelectedBackground() {
- return Colors.YELLOW_LOW_MEDIUMDARK;
- }
-
- @Override
- public void addCustomEntriesToTable(UIDefaults table) {
- super.addCustomEntriesToTable(table);
- Object[] uiDefaults =
- { PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY, new Integer(30), };
- table.putDefaults(uiDefaults);
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/plastic/theme/package.html b/src/core/com/jgoodies/looks/plastic/theme/package.html
deleted file mode 100644
index cf44ff2..0000000
--- a/src/core/com/jgoodies/looks/plastic/theme/package.html
+++ /dev/null
@@ -1,65 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
- Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- o Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- o Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
- o Neither the name of JGoodies Karsten Lentzsch nor the names of
- its contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
- OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
- JavaDoc uses all text between the "body" tags.
- The first sentence is used as short description.
--->
-</head>
-<body bgcolor="white">
-
-Contains theme classes for the JGoodies Plastic L&Fs.
-
-<!--
-<h2>Package Specification</h2>
-
-##### FILL IN ANY SPECS NEEDED BY JAVA COMPATIBILITY KIT #####
-<ul>
- <li><a href="">##### REFER TO ANY FRAMEMAKER SPECIFICATION HERE #####</a>
-</ul>
--->
-
-<h2>Related Documentation</h2>
-
-For more information see:
-<ul>
- <li><a href="http://www.jgoodies.com/articles/" >
- http://www.jgoodies.com/articles/</a>
-</ul>
-<!-- Put @see and @since tags down here. -->
-
- at see com.jgoodies.looks
- at see com.jgoodies.looks.common
- at see com.jgoodies.looks.plastic
- at see com.jgoodies.looks.windows
-
-</body>
-</html>
diff --git a/src/core/com/jgoodies/looks/windows/WindowsArrowButton.java b/src/core/com/jgoodies/looks/windows/WindowsArrowButton.java
deleted file mode 100644
index fe5efa0..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsArrowButton.java
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Dimension;
-import java.awt.Graphics;
-
-import javax.swing.UIManager;
-import javax.swing.plaf.basic.BasicArrowButton;
-
-/**
- * The JGoodies Windows Look&Feel implementation for
- * arrow buttons used in scrollbars and comboboxes.
- * <p>
- * It differs from {@code BasicArrowButton} in that the preferred size
- * is always a square.
- * It differs from {@code WindowsScrollBarUI.WindowsArrowButton}
- * in that the triangle is black and positioned correctly.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-final class WindowsArrowButton extends BasicArrowButton {
-
- public WindowsArrowButton(int direction) {
- super(direction);
- }
-
- @Override
- public Dimension getPreferredSize() {
- int width = Math.max(5, UIManager.getInt("ScrollBar.width"));
- return new Dimension(width, width);
- }
-
- @Override
- public void paintTriangle(
- Graphics g,
- int x,
- int y,
- int size,
- int triangleDirection,
- boolean enabled) {
- Color oldColor = g.getColor();
- int mid, i, j;
-
- j = 0;
- size = Math.max(size, 2);
- mid = (size - 1) / 2; // Modified by JGoodies
-
- g.translate(x, y);
- g.setColor(UIManager.getColor(enabled ? "controlText" : "controlShadow"));
-
- switch (triangleDirection) {
- case NORTH :
- for (i = 0; i < size; i++) {
- g.drawLine(mid - i, i, mid + i, i);
- }
- if (!enabled) {
- g.setColor(UIManager.getColor("controlLtHighlight"));
- g.drawLine(mid - i + 2, i, mid + i, i);
- }
- break;
- case SOUTH :
- if (!enabled) {
- g.translate(1, 1);
- g.setColor(UIManager.getColor("controlLtHighlight"));
- for (i = size - 1; i >= 0; i--) {
- g.drawLine(mid - i, j, mid + i, j);
- j++;
- }
- g.translate(-1, -1);
- g.setColor(UIManager.getColor("controlShadow"));
- }
-
- j = 0;
- for (i = size - 1; i >= 0; i--) {
- g.drawLine(mid - i, j, mid + i, j);
- j++;
- }
- break;
- case WEST :
- for (i = 0; i < size; i++) {
- g.drawLine(i, mid - i, i, mid + i);
- }
- if (!enabled) {
- g.setColor(UIManager.getColor("controlLtHighlight"));
- g.drawLine(i, mid - i + 2, i, mid + i);
- }
- break;
- case EAST :
- if (!enabled) {
- g.translate(1, 1);
- g.setColor(UIManager.getColor("controlLtHighlight"));
- for (i = size - 1; i >= 0; i--) {
- g.drawLine(j, mid - i, j, mid + i);
- j++;
- }
- g.translate(-1, -1);
- g.setColor(UIManager.getColor("controlShadow"));
- }
-
- j = 0;
- for (i = size - 1; i >= 0; i--) {
- g.drawLine(j, mid - i, j, mid + i);
- j++;
- }
- break;
- }
- g.translate(-x, -y);
- g.setColor(oldColor);
- }
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsBorders.java b/src/core/com/jgoodies/looks/windows/WindowsBorders.java
deleted file mode 100644
index 0bcec27..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsBorders.java
+++ /dev/null
@@ -1,614 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Graphics;
-import java.awt.Insets;
-
-import javax.swing.*;
-import javax.swing.border.AbstractBorder;
-import javax.swing.border.Border;
-import javax.swing.border.CompoundBorder;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.BorderUIResource;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicBorders;
-import javax.swing.plaf.basic.BasicGraphicsUtils;
-
-/**
- * Consists of static inner classes that define different
- * {@code Borders} used in the JGoodies Windows look&feel.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-final class WindowsBorders {
-
- private WindowsBorders() {
- // Overrides default constructor; prevents instantiation.
- }
-
- // Accessing and Creating Borders ***************************************************
-
- private static Border menuBorder;
- private static Border xpMenuBorder;
- private static Border menuItemBorder;
- private static Border popupMenuBorder;
- private static Border noMarginPopupMenuBorder;
- private static Border separatorBorder;
- private static Border etchedBorder;
- private static Border menuBarHeaderBorder;
- private static Border toolBarHeaderBorder;
- private static Border rolloverButtonBorder;
-
-
- /**
- * Returns a {@code Border} for a {@code JButton}.
- */
- public static Border getButtonBorder() {
- UIDefaults table = UIManager.getLookAndFeelDefaults();
- Border outerBorder = new ButtonBorder(table.getColor("Button.shadow"),
- table.getColor("Button.darkShadow"), table
- .getColor("Button.light"), table
- .getColor("Button.highlight"), table
- .getColor("controlText"));
-
- Border buttonBorder = new BorderUIResource.CompoundBorderUIResource(
- outerBorder, new BasicBorders.MarginBorder());
- return buttonBorder;
- }
-
-
- /**
- * Returns a Border for a JMenu in classic mode.
- */
- static Border getMenuBorder() {
- if (menuBorder == null) {
- menuBorder = new BorderUIResource.CompoundBorderUIResource(
- new MenuBorder(),
- new BasicBorders.MarginBorder());
- }
- return menuBorder;
- }
-
- /**
- * Returns a Border for a JMenu in XP mode.
- */
- static Border getXPMenuBorder() {
- if (xpMenuBorder == null) {
- xpMenuBorder = new BasicBorders.MarginBorder();
- }
- return xpMenuBorder;
- }
-
- /**
- * Returns a border instance for a {@code JMenuItem}.
- */
- static Border getMenuItemBorder() {
- if (menuItemBorder == null) {
- menuItemBorder = new BorderUIResource(new BasicBorders.MarginBorder());
- }
- return menuItemBorder;
- }
-
- /**
- * Returns a separator border instance for {@code JMenuBar} or {@code JToolBar}.
- */
- static Border getSeparatorBorder() {
- if (separatorBorder == null) {
- separatorBorder = new BorderUIResource.CompoundBorderUIResource(
- new SeparatorBorder(),
- new BasicBorders.MarginBorder());
- }
- return separatorBorder;
- }
-
- /**
- * Returns an etched border instance for {@code JMenuBar} or {@code JToolBar}.
- */
- static Border getEtchedBorder() {
- if (etchedBorder == null) {
- etchedBorder = new BorderUIResource.CompoundBorderUIResource(
- new EtchedBorder(),
- new BasicBorders.MarginBorder());
- }
- return etchedBorder;
- }
-
- /**
- * Returns a special border for a {@code JMenuBar} that
- * is used in a header just above a {@code JToolBar}.
- */
- static Border getMenuBarHeaderBorder() {
- if (menuBarHeaderBorder == null) {
- menuBarHeaderBorder = new BorderUIResource.CompoundBorderUIResource(
- new MenuBarHeaderBorder(),
- new BasicBorders.MarginBorder());
- }
- return menuBarHeaderBorder;
- }
-
- /**
- * Returns a border instance for a {@code JPopupMenu}.
- *
- * @return the lazily created popup menu border
- */
- static Border getPopupMenuBorder() {
- if (popupMenuBorder == null) {
- popupMenuBorder = new PopupMenuBorder();
- }
- return popupMenuBorder;
- }
-
- /**
- * Returns a no-margin border instance for a {@code JPopupMenu}.
- *
- * @return the lazily created no-margin popup menu border
- */
- static Border getNoMarginPopupMenuBorder() {
- if (noMarginPopupMenuBorder == null) {
- noMarginPopupMenuBorder = new NoMarginPopupMenuBorder();
- }
- return noMarginPopupMenuBorder;
- }
-
- /**
- * Returns a special border for a {@code JToolBar} that
- * is used in a header just below a {@code JMenuBar}.
- */
- static Border getToolBarHeaderBorder() {
- if (toolBarHeaderBorder == null) {
- toolBarHeaderBorder = new BorderUIResource.CompoundBorderUIResource(
- new ToolBarHeaderBorder(),
- new BasicBorders.MarginBorder());
- }
- return toolBarHeaderBorder;
- }
-
- /**
- * Returns a border for a rollover {@code AbstractButton}.
- */
- static Border getRolloverButtonBorder() {
- if (rolloverButtonBorder == null) {
- rolloverButtonBorder = new CompoundBorder( // No UIResource
- new RolloverButtonBorder(),
- new RolloverMarginBorder());
- }
- return rolloverButtonBorder;
- }
-
-
- // Helper Classes *******************************************************************
-
-
- // Copied from BasicBorders, has correct black color for the outer default rectangle.
- private static final class ButtonBorder extends AbstractBorder implements UIResource {
-
- private static final Insets EMPTY_INSETS = new Insets(0, 0, 0, 0);
-
- private final Color shadow;
- private final Color darkShadow;
- private final Color highlight;
- private final Color lightHighlight;
- private final Color defaultColor;
-
- public ButtonBorder(Color shadow, Color darkShadow,
- Color highlight, Color lightHighlight, Color defaultColor) {
- this.shadow = shadow;
- this.darkShadow = darkShadow;
- this.highlight = highlight;
- this.lightHighlight = lightHighlight;
- this.defaultColor = defaultColor;
- }
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) {
- boolean isPressed = false;
- boolean isDefault = false;
-
- if (c instanceof AbstractButton) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- isPressed = model.isPressed() && model.isArmed();
- if (c instanceof JButton) {
- isDefault = ((JButton) c).isDefaultButton();
- }
- }
- drawBezel(g, x, y, width, height, isPressed, isDefault, shadow,
- darkShadow, highlight, lightHighlight, defaultColor);
- }
-
- @Override
- public Insets getBorderInsets(Component c) {
- return getBorderInsets(c, EMPTY_INSETS);
- }
-
- @Override
- public Insets getBorderInsets(Component c, Insets insets) {
- // leave room for default visual
- insets.top = 2;
- insets.left = insets.bottom = insets.right = 3;
- return insets;
- }
-
- }
-
- /**
- * An abstract superclass for borders.
- */
- private abstract static class AbstractButtonBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(2, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton button = (AbstractButton) c;
- ButtonModel model = button.getModel();
-
- //
- //System.out.println("Pressed=" + model.isPressed() + "; armed=" + model.isArmed());
- //if (!model.isArmed()) return;
-
- if (model.isPressed()) {
- WindowsUtils.drawPressed3DBorder(g, x, y, w, h);
- } else {
- WindowsUtils.drawFlush3DBorder(g, x, y, w, h);
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for {@code Buttons} that have the rollover property enabled.
- */
- private static final class RolloverButtonBorder extends AbstractButtonBorder {
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- if (!model.isEnabled()) {
- return;
- }
-
- if (!(c instanceof JToggleButton)) {
- if (model.isRollover()) {
- super.paintBorder(c, g, x, y, w, h);
- }
- return;
- }
-
- if (model.isSelected()) {
- WindowsUtils.drawPressed3DBorder(g, x, y, w, h);
- } else if (model.isRollover()) {
- super.paintBorder(c, g, x, y, w, h);
- /*
- if (model.isPressed() && model.isArmed()) {
- ExtMetalUtils.drawPressed3DBorder(g, x, y, w, h);
- } else {
- ExtMetalUtils.drawFlush3DBorder(g, x, y, w, h);
- }*/
- }
- }
- }
-
-
- /**
- * A border which is like a Margin border but it will only honor the margin
- * if the margin has been explicitly set by the developer.
- */
- private static final class RolloverMarginBorder extends EmptyBorder {
-
- private RolloverMarginBorder() {
- super(1, 1, 1, 1);
- }
-
-
- @Override
- public Insets getBorderInsets(Component c) {
- return getBorderInsets(c, new Insets(0, 0, 0, 0));
- }
-
-
- @Override
- public Insets getBorderInsets(Component c, Insets insets) {
- Insets margin = null;
-
- if (c instanceof AbstractButton) {
- margin = ((AbstractButton) c).getMargin();
- }
- if (margin == null || margin instanceof UIResource) {
- // default margin so replace
- insets.left = left;
- insets.top = top;
- insets.right = right;
- insets.bottom = bottom;
- } else {
- // Margin which has been explicitly set by the user.
- insets.left = margin.left;
- insets.top = margin.top;
- insets.right = margin.right;
- insets.bottom = margin.bottom;
- }
- return insets;
- }
- }
-
- /**
- * A border that looks like a separator line; used for menu bars and tool bars.
- */
- private static final class SeparatorBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(0, 3, 2, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor( UIManager.getColor("Separator.foreground"));
- g.drawLine( 0, h - 2, w - 1, h - 2 );
-
- g.setColor( UIManager.getColor("Separator.background"));
- g.drawLine( 0, h - 1, w - 1, h - 1 );
- g.translate(-x, -y);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A thin raised border.
- */
- static final class ThinRaisedBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- WindowsUtils.drawFlush3DBorder(g, x, y, w, h);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A thin lowered border.
- */
- static final class ThinLoweredBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- WindowsUtils.drawPressed3DBorder(g, x, y, w, h);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for menu bars and tool bars in {@code HeaderStyle.SINGLE}.
- * The bar is wrapped by an inner thin raised border,
- * which in turn is wrapped by an outer thin lowered border.
- */
- private static final class EtchedBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(2, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- WindowsUtils.drawPressed3DBorder(g, x, y, w, h);
- WindowsUtils.drawFlush3DBorder (g, x + 1, y + 1, w - 2, h - 2);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for menu bars in {@code HeaderStyle.BOTH}.
- * The menu bar and tool bar are wrapped by a thin raised border,
- * both together are wrapped by a thin lowered border.
- */
- private static final class MenuBarHeaderBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(2, 2, 1, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- WindowsUtils.drawPressed3DBorder(g, x, y, w, h + 1);
- WindowsUtils.drawFlush3DBorder (g, x + 1, y + 1, w - 2, h - 1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static final class PopupMenuBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(3, 3, 3, 3);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(UIManager.getColor("controlShadow"));
- g.drawRect(0, 0, w-1, h-1);
- g.setColor(UIManager.getColor("MenuItem.background"));
- g.drawRect(1, 1, w-3, h-3);
- g.drawRect(2, 2, w-5, h-5);
- g.translate(-x, -y);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- private static final class NoMarginPopupMenuBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(UIManager.getColor("controlShadow"));
- g.drawRect(0, 0, w-1, h-1);
-// g.setColor(UIManager.getColor("MenuItem.background"));
-// g.drawRect(1, 1, 0, h-3);
- g.translate(-x, -y);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
- /**
- * A border used for tool bars in {@code HeaderStyle.BOTH}.
- * The menu bar and tool bar are wrapped by a thin raised border,
- * both together are wrapped by a thin lowered border.
- */
- private static final class ToolBarHeaderBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(1, 2, 2, 2);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- WindowsUtils.drawPressed3DBorder(g, x, y - 1, w, h + 1);
- WindowsUtils.drawFlush3DBorder (g, x + 1, y, w - 2, h - 1);
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
- }
-
-
- /**
- * A border used for menus.
- */
- private static final class MenuBorder extends AbstractBorder implements UIResource {
-
- private static final Insets INSETS = new Insets(1, 1, 1, 1);
-
- @Override
- public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- //System.out.println("rollover=" + model.isRollover());
- //if ((3 < 4) || model.isRollover()) { // && !(model.isPressed() && !model.isArmed())) {
- if (model.isSelected()) {
- WindowsUtils.drawPressed3DBorder(g, x, y, w, h);
- } else if (model.isRollover()) {
- WindowsUtils.drawFlush3DBorder(g, x, y, w, h);
- //}
- }
- }
-
- @Override
- public Insets getBorderInsets(Component c) { return INSETS; }
-
- }
-
-
- // Helper Code **********************************************************************
-
- // Copied from BasicGraphicsUtils, has an additional color for the default rectangle.
- private static void drawBezel(Graphics g, int x, int y, int w, int h,
- boolean isPressed, boolean isDefault,
- Color shadow, Color darkShadow,
- Color highlight, Color lightHighlight, Color defaultColor)
- {
- Color oldColor = g.getColor(); // Make no net change to g
- g.translate(x, y);
-
- if (isPressed && isDefault) {
- g.setColor(darkShadow);
- g.drawRect(0, 0, w - 1, h - 1);
- g.setColor(shadow);
- g.drawRect(1, 1, w - 3, h - 3);
- } else if (isPressed) {
- BasicGraphicsUtils.drawLoweredBezel(g, x, y, w, h,
- shadow, darkShadow, highlight, lightHighlight);
- } else if (isDefault) {
- g.setColor(defaultColor);
- g.drawRect(0, 0, w-1, h-1);
-
- g.setColor(lightHighlight);
- g.drawLine(1, 1, 1, h-3);
- g.drawLine(2, 1, w-3, 1);
-
- g.setColor(highlight);
- g.drawLine(2, 2, 2, h-4);
- g.drawLine(3, 2, w-4, 2);
-
- g.setColor(shadow);
- g.drawLine(2, h-3, w-3, h-3);
- g.drawLine(w-3, 2, w-3, h-4);
-
- g.setColor(darkShadow);
- g.drawLine(1, h-2, w-2, h-2);
- g.drawLine(w-2, h-2, w-2, 1);
- } else {
- g.setColor(lightHighlight);
- g.drawLine(0, 0, 0, h-1);
- g.drawLine(1, 0, w-2, 0);
-
- g.setColor(highlight);
- g.drawLine(1, 1, 1, h-3);
- g.drawLine(2, 1, w-3, 1);
-
- g.setColor(shadow);
- g.drawLine(1, h-2, w-2, h-2);
- g.drawLine(w-2, 1, w-2, h-3);
-
- g.setColor(darkShadow);
- g.drawLine(0, h-1, w-1, h-1);
- g.drawLine(w-1, h-1, w-1, 0);
- }
- g.translate(-x, -y);
- g.setColor(oldColor);
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsButtonUI.java b/src/core/com/jgoodies/looks/windows/WindowsButtonUI.java
deleted file mode 100644
index f9b91ce..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsButtonUI.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Dimension;
-
-import javax.swing.AbstractButton;
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicGraphicsUtils;
-
-/**
- * The JGoodies Windows look&feel implementation of {@code ButtonUI}.<p>
- *
- * Unlike its superclass it returns even and odd preferred heights.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class WindowsButtonUI extends com.sun.java.swing.plaf.windows.WindowsButtonUI {
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsButtonUI();
- }
-
- @Override
- public Dimension getPreferredSize(JComponent c) {
- AbstractButton b = (AbstractButton) c;
- Dimension d = BasicGraphicsUtils.getPreferredButtonSize(b, b
- .getIconTextGap());
-
- /* Ensure that the width of the button is odd,
- * to improve the painting of the dashed focus line
- */
- if (d != null && b.isFocusPainted()) {
- if (d.width % 2 == 0) {
- d.width += 1;
- }
- }
- return d;
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsComboBoxEditor.java b/src/core/com/jgoodies/looks/windows/WindowsComboBoxEditor.java
deleted file mode 100644
index e08f3b1..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsComboBoxEditor.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import javax.swing.plaf.basic.BasicComboBoxEditor;
-
-import com.jgoodies.looks.common.ComboBoxEditorTextField;
-
-/**
- * The default editor for editable combo boxes in the
- * JGoodies Windows Look&Feel.<p>
- *
- * It differs from its superclass in that the border is quite the same as for
- * text fields: a compound border with an inner {@code MarginBorder}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.12 $
- */
-class WindowsComboBoxEditor extends BasicComboBoxEditor {
-
- WindowsComboBoxEditor(boolean isTableCellEditor) {
- editor = new ComboBoxEditorTextField(isTableCellEditor);
- }
-
- @Override
- public void setItem(Object item) {
- super.setItem(item);
- editor.selectAll();
- }
-
- /**
- * A subclass of BasicComboBoxEditor that implements UIResource.
- * BasicComboBoxEditor and WindowsComboBoxEditor don't implement UIResource
- * directly so that applications can safely override the cellRenderer
- * property with BasicListCellRenderer subclasses.
- */
- static final class UIResource extends WindowsComboBoxEditor implements
- javax.swing.plaf.UIResource {
-
- UIResource(boolean isTableCellEditor) {
- super(isTableCellEditor);
- }
- }
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsComboBoxUI.java b/src/core/com/jgoodies/looks/windows/WindowsComboBoxUI.java
deleted file mode 100644
index ba59a56..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsComboBoxUI.java
+++ /dev/null
@@ -1,591 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Component;
-import java.awt.Container;
-import java.awt.Dimension;
-import java.awt.Graphics;
-import java.awt.Insets;
-import java.awt.LayoutManager;
-import java.awt.Rectangle;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.ComboBoxEditor;
-import javax.swing.DefaultListCellRenderer;
-import javax.swing.JButton;
-import javax.swing.JComboBox;
-import javax.swing.JComponent;
-import javax.swing.JPanel;
-import javax.swing.JScrollBar;
-import javax.swing.JTextField;
-import javax.swing.ListCellRenderer;
-import javax.swing.SwingConstants;
-import javax.swing.UIManager;
-import javax.swing.border.Border;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.plaf.basic.BasicComboBoxRenderer;
-import javax.swing.plaf.basic.BasicComboBoxUI;
-import javax.swing.plaf.basic.BasicComboPopup;
-import javax.swing.plaf.basic.ComboPopup;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.Options;
-import com.sun.java.swing.plaf.windows.WindowsTextFieldUI;
-
-/**
- * The JGoodies Windows Look&Feel implementation of
- * {@link javax.swing.plaf.ComboBoxUI}.
- * Corrects the editor insets for editable combo boxes
- * as well as the render insets for non-editable combos. And it has
- * the same height as text fields - unless you change the renderer.<p>
- *
- * Also, this class offers to use the combo's popup prototype display value
- * to compute the popup menu width. This is an optional feature of
- * the JGoodies Windows L&f implemented via a client property key.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.26 $
- *
- * @see Options#COMBO_POPUP_PROTOTYPE_DISPLAY_VALUE_KEY
- */
-public class WindowsComboBoxUI extends com.sun.java.swing.plaf.windows.WindowsComboBoxUI {
-
- private static final String CELL_EDITOR_KEY = "JComboBox.isTableCellEditor";
-
- /**
- * Used to determine the minimum height of a text field,
- * which in turn is used to answer the combobox's minimum height.
- */
- private static final JTextField PHANTOM = new JTextField("Phantom");
-
- private static final Insets EMPTY_INSETS = new Insets(0, 0, 0, 0);
- private static final Border EMPTY_BORDER = new EmptyBorder(EMPTY_INSETS);
-
-
- private boolean tableCellEditor;
- private PropertyChangeListener propertyChangeListener;
-
-
- // ************************************************************************
-
- public static ComponentUI createUI(JComponent b) {
- ensurePhantomHasWindowsUI();
- return new WindowsComboBoxUI();
- }
-
-
- /**
- * Ensures that the phantom text field has a Windows text field UI.
- */
- private static void ensurePhantomHasWindowsUI() {
- if (!(PHANTOM.getUI() instanceof WindowsTextFieldUI)) {
- PHANTOM.updateUI();
- }
- }
-
-
- // ************************************************************************
-
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- tableCellEditor = isTableCellEditor();
- }
-
- @Override
- protected void installListeners() {
- super.installListeners();
- propertyChangeListener = new TableCellEditorPropertyChangeHandler();
- comboBox.addPropertyChangeListener(CELL_EDITOR_KEY, propertyChangeListener);
- }
-
- @Override
- protected void uninstallListeners() {
- super.uninstallListeners();
- comboBox.removePropertyChangeListener(CELL_EDITOR_KEY, propertyChangeListener);
- propertyChangeListener = null;
- }
-
-
- /**
- * Creates the arrow button that is to be used in the combo box.<p>
- *
- * Overridden to paint black triangles.
- */
- @Override
- protected JButton createArrowButton() {
- return SystemUtils.IS_LAF_WINDOWS_XP_ENABLED
- ? super.createArrowButton()
- : new WindowsArrowButton(SwingConstants.SOUTH);
- }
-
-
- /**
- * Creates the editor that is to be used in editable combo boxes.
- * This method only gets called if a custom editor has not already
- * been installed in the JComboBox.
- */
- @Override
- protected ComboBoxEditor createEditor() {
- return new com.jgoodies.looks.windows.WindowsComboBoxEditor.UIResource(tableCellEditor);
- }
-
-
- /**
- * Creates a layout manager for managing the components which
- * make up the combo box.<p>
- *
- * Overriden to use a layout that has a fixed width arrow button.
- *
- * @return an instance of a layout manager
- */
- @Override
- protected LayoutManager createLayoutManager() {
- return new WindowsComboBoxLayoutManager();
- }
-
-
- @Override
- protected void configureEditor() {
- super.configureEditor();
- if (!comboBox.isEnabled()) {
- editor.setBackground(UIManager.getColor("ComboBox.disabledBackground"));
- }
- }
-
- /**
- * Creates a ComboPopup that honors the optional combo popup display value
- * that is used to compute the popup menu width.
- */
- @Override
- protected ComboPopup createPopup() {
- return new WindowsComboPopup(comboBox);
- }
-
-
- /**
- * Creates the default renderer that will be used in a non-editiable combo
- * box. A default renderer will used only if a renderer has not been
- * explicitly set with {@code setRenderer}.<p>
- *
- * This method differs from the superclass implementation in that
- * it uses an empty border with the default left and right text insets,
- * the same as used by a combo box editor.
- *
- * @return a {@code ListCellRender} used for the combo box
- * @see javax.swing.JComboBox#setRenderer
- */
- @Override
- protected ListCellRenderer createRenderer() {
- if (tableCellEditor) {
- return super.createRenderer();
- }
- BasicComboBoxRenderer renderer = new BasicComboBoxRenderer.UIResource();
- renderer.setBorder(UIManager.getBorder("ComboBox.rendererBorder"));
- return renderer;
- }
-
-
- /**
- * The minumum size is the size of the display area plus insets plus the button.
- */
- @Override
- public Dimension getMinimumSize(JComponent c) {
- if (!isMinimumSizeDirty) {
- return new Dimension(cachedMinimumSize);
- }
- Dimension size = getDisplaySize();
- Insets insets = getInsets();
- size.height += insets.top + insets.bottom;
- int buttonWidth = getEditableButtonWidth();
- size.width += insets.left + insets.right + buttonWidth;
- // The combo editor benefits from extra space for the caret.
- // To make editable and non-editable equally wide,
- // we always add 1 pixel.
- size.width += 1;
-
- // Honor corrections made in #paintCurrentValue
- ListCellRenderer renderer = comboBox.getRenderer();
- if (renderer instanceof JComponent) {
- JComponent component = (JComponent) renderer;
- Insets rendererInsets = component.getInsets();
- Insets editorInsets = UIManager.getInsets("ComboBox.editorInsets");
- int offsetLeft = Math.max(0, editorInsets.left - rendererInsets.left);
- int offsetRight = Math.max(0, editorInsets.right - rendererInsets.right);
- // int offsetTop = Math.max(0, editorInsets.top - rendererInsets.top);
- // int offsetBottom = Math.max(0, editorInsets.bottom - rendererInsets.bottom);
- size.width += offsetLeft + offsetRight;
- //size.height += offsetTop + offsetBottom;
- }
-
- // The height is oriented on the JTextField height
- Dimension textFieldSize = PHANTOM.getMinimumSize();
- size.height = SystemUtils.IS_OS_WINDOWS_6_OR_LATER && !SystemUtils.IS_LAF_WINDOWS_XP_ENABLED
- ? textFieldSize.height
- : Math.max(textFieldSize.height, size.height);
-
- cachedMinimumSize.setSize(size.width, size.height);
- isMinimumSizeDirty = false;
-
- return new Dimension(size);
- }
-
- /**
- * Delegates to #getMinimumSize(Component).
- * Overridden to return the same result in JDK 1.5 as in JDK 1.4.
- */
- @Override
- public Dimension getPreferredSize(JComponent c) {
- return getMinimumSize(c);
- }
-
-
- /**
- * Paints the currently selected item.
- */
- @Override
- public void paintCurrentValue(Graphics g, Rectangle bounds, boolean hasFocus) {
- ListCellRenderer renderer = comboBox.getRenderer();
- Component c;
- boolean isVistaReadOnlyCombo = isVistaXPStyleReadOnlyCombo();
-
- if (hasFocus && !isPopupVisible(comboBox)) {
- c = renderer.getListCellRendererComponent(listBox,
- comboBox.getSelectedItem(),
- -1,
- true,
- false);
- } else {
- c = renderer.getListCellRendererComponent(listBox,
- comboBox.getSelectedItem(),
- -1,
- false,
- false );
- c.setBackground(UIManager.getColor("ComboBox.background"));
- }
- Border oldBorder = null;
- Rectangle originalBounds = new Rectangle(bounds);
- if (c instanceof JComponent && !tableCellEditor) {
- JComponent component = (JComponent) c;
- if (isRendererBorderRemovable(component)) {
- oldBorder = component.getBorder();
- component.setBorder(EMPTY_BORDER); //new WindowsBorders.DashedBorder(c.getForeground(), 1));
- }
- Insets rendererInsets = component.getInsets();
- Insets editorInsets = UIManager.getInsets("ComboBox.editorInsets");
- int offsetLeft = Math.max(0, editorInsets.left - rendererInsets.left);
- int offsetRight = Math.max(0, editorInsets.right - rendererInsets.right);
- int offsetTop = Math.max(0, editorInsets.top - rendererInsets.top);
- int offsetBottom = Math.max(0, editorInsets.bottom - rendererInsets.bottom);
- bounds.x += offsetLeft;
- bounds.y += offsetTop;
- bounds.width -= offsetLeft + offsetRight - 1;
- bounds.height -= offsetTop + offsetBottom;
- }
-
- c.setFont(comboBox.getFont());
- if (hasFocus && !isPopupVisible(comboBox) && !isVistaReadOnlyCombo) {
- c.setForeground(listBox.getSelectionForeground());
- c.setBackground(listBox.getSelectionBackground());
- } else {
- if (comboBox.isEnabled()) {
- c.setForeground(comboBox.getForeground());
- c.setBackground(comboBox.getBackground());
- } else {
- c.setForeground(UIManager.getColor("ComboBox.disabledForeground"));
- c.setBackground(UIManager.getColor("ComboBox.disabledBackground"));
- }
- }
-
- // Fix for 4238829: should lay out the JPanel.
- boolean shouldValidate = c instanceof JPanel;
-
- Boolean oldOpaque = null;
- if (isVistaReadOnlyCombo && c instanceof JComponent && !(c instanceof DefaultListCellRenderer)) {
- oldOpaque = Boolean.valueOf(c.isOpaque());
- ((JComponent) c).setOpaque(false);
- }
- currentValuePane.paintComponent(g, c, comboBox, bounds.x, bounds.y,
- bounds.width, bounds.height, shouldValidate);
- if (hasFocus) {
- Color oldColor = g.getColor();
- g.setColor(comboBox.getForeground());
- if (isVistaReadOnlyCombo) {
- int width = originalBounds.width - 2;
- if (width % 2 == 0) {
- width += 1;
- }
- WindowsUtils.drawRoundedDashedRect(g,
- originalBounds.x+1, originalBounds.y+1,
- width, originalBounds.height-2);
- } /*else {
- BasicGraphicsUtils.drawDashedRect(g,
- bounds.x, bounds.y, bounds.width, bounds.height);
- }*/
- g.setColor(oldColor);
- }
- if (oldOpaque != null) {
- ((JComponent) c).setOpaque(oldOpaque.booleanValue());
- }
- if (oldBorder != null) {
- ((JComponent) c).setBorder(oldBorder);
- }
- }
-
- /**
- * Checks and answer whether the border of the given renderer component
- * can be removed temporarily, so the combo's selection background will
- * be consistent with the default renderer and native appearance.
- * This test is invoked from {@code #paintCurrentValue}.<p>
- *
- * It is safe to remove an EmptyBorder if the component doesn't override
- * {@code #update}, {@code #paint} and {@code #paintBorder}.
- * Since we know the default renderer, we can remove its border.<p>
- *
- * Custom renderers may set a hint to make their border removable.
- * To do so, set the client property "isBorderRemovable"
- * to {@code Boolean.TRUE}. If this client property is set,
- * its value will be returned. If it is not set, {@code true} is returned
- * if and only if the component's border is an EmptyBorder.
- *
- * @param rendererComponent the renderer component to check
- * @return true if the component's border can be removed, false if not
- * @see #paintCurrentValue(Graphics, Rectangle, boolean)
- */
- protected boolean isRendererBorderRemovable(JComponent rendererComponent) {
- if (rendererComponent instanceof BasicComboBoxRenderer.UIResource) {
- return true;
- }
- Object hint = rendererComponent.getClientProperty(Options.COMBO_RENDERER_IS_BORDER_REMOVABLE);
- if (hint != null) {
- return Boolean.TRUE.equals(hint);
- }
- Border border = rendererComponent.getBorder();
- return border instanceof EmptyBorder;
- }
-
-
- private boolean isVistaXPStyleReadOnlyCombo() {
- return SystemUtils.IS_OS_WINDOWS_6_OR_LATER
- && SystemUtils.IS_LAF_WINDOWS_XP_ENABLED
- && !comboBox.isEditable();
- }
-
-
- /**
- * Returns the area that is reserved for drawing the currently selected item.
- */
- @Override
- protected Rectangle rectangleForCurrentValue() {
- int width = comboBox.getWidth();
- int height = comboBox.getHeight();
- Insets insets = getInsets();
- int buttonWidth = getEditableButtonWidth();
- if (arrowButton != null) {
- buttonWidth = arrowButton.getWidth();
- }
- if (comboBox.getComponentOrientation().isLeftToRight()) {
- return new Rectangle(
- insets.left,
- insets.top,
- width - (insets.left + insets.right + buttonWidth),
- height - (insets.top + insets.bottom));
- }
- return new Rectangle(
- insets.left + buttonWidth,
- insets.top ,
- width - (insets.left + insets.right + buttonWidth),
- height - (insets.top + insets.bottom));
- }
-
-
- // Helper Code ************************************************************
-
- /**
- * Computes and returns the width of the arrow button in editable state.
- *
- * @return the width of the arrow button in editable state
- */
- private static int getEditableButtonWidth() {
- return UIManager.getInt("ScrollBar.width");
- }
-
- /**
- * Checks and answers if this UI's combo has a client property
- * that indicates that the combo is used as a table cell editor.
- *
- * @return {@code true} if the table cell editor client property
- * is set to {@code Boolean.TRUE}, {@code false} otherwise
- */
- private boolean isTableCellEditor() {
- return Boolean.TRUE.equals(comboBox.getClientProperty(CELL_EDITOR_KEY));
- }
-
-
- // Collaborator Classes ***************************************************
-
- /**
- * This layout manager handles the 'standard' layout of combo boxes.
- * It puts the arrow button to the right and the editor to the left.
- * If there is no editor it still keeps the arrow button to the right.
- *
- * Overriden to use a fixed arrow button width.
- */
- private final class WindowsComboBoxLayoutManager
- extends BasicComboBoxUI.ComboBoxLayoutManager {
-
- @Override
- public void layoutContainer(Container parent) {
- JComboBox cb = (JComboBox) parent;
-
- int width = cb.getWidth();
- int height = cb.getHeight();
-
- Insets insets = getInsets();
- int buttonWidth = getEditableButtonWidth();
- int buttonHeight = height - (insets.top + insets.bottom);
-
- if (arrowButton != null) {
- if (cb.getComponentOrientation().isLeftToRight()) {
- arrowButton.setBounds(
- width - (insets.right + buttonWidth),
- insets.top,
- buttonWidth,
- buttonHeight);
- } else {
- arrowButton.setBounds(
- insets.left,
- insets.top,
- buttonWidth,
- buttonHeight);
- }
- }
- if (editor != null) {
- editor.setBounds(rectangleForCurrentValue());
- }
- }
-
- }
-
-
- /**
- * Differs from the BasicComboPopup in that it uses the standard
- * popmenu border and honors an optional popup prototype display value.
- */
- private static final class WindowsComboPopup extends BasicComboPopup {
-
- private WindowsComboPopup(JComboBox combo) {
- super(combo);
- }
-
- /**
- * Calculates the placement and size of the popup portion
- * of the combo box based on the combo box location and
- * the enclosing screen bounds. If no transformations are required,
- * then the returned rectangle will have the same values
- * as the parameters.<p>
- *
- * In addition to the superclass behavior, this class offers
- * to use the combo's popup prototype display value to compute
- * the popup menu width. This is an optional feature of
- * the JGoodies Windows L&f implemented via a client property key.<p>
- *
- * If a prototype is set, the popup width is the maximum of the
- * combobox width and the prototype based popup width.
- * For the latter the renderer is used to render the prototype.
- * The prototype based popup width is the prototype's width
- * plus the scrollbar width - if any. The scrollbar test checks
- * if there are more items than the combo's maximum row count.
- *
- * @param px starting x location
- * @param py starting y location
- * @param pw starting width
- * @param ph starting height
- * @return a rectangle which represents the placement and size of the popup
- *
- * @see Options#COMBO_POPUP_PROTOTYPE_DISPLAY_VALUE_KEY
- * @see JComboBox#getMaximumRowCount()
- */
- @Override
- protected Rectangle computePopupBounds(int px, int py, int pw, int ph) {
- Rectangle defaultBounds = super.computePopupBounds(px, py, pw, ph);
- Object popupPrototypeDisplayValue = comboBox.getClientProperty(
- Options.COMBO_POPUP_PROTOTYPE_DISPLAY_VALUE_KEY);
- if (popupPrototypeDisplayValue == null) {
- return defaultBounds;
- }
-
- ListCellRenderer renderer = list.getCellRenderer();
- Component c = renderer.getListCellRendererComponent(
- list, popupPrototypeDisplayValue, -1, true, true);
- pw = c.getPreferredSize().width;
- boolean hasVerticalScrollBar =
- comboBox.getItemCount() > comboBox.getMaximumRowCount();
- if (hasVerticalScrollBar) {
- // Add the scrollbar width.
- JScrollBar verticalBar = scroller.getVerticalScrollBar();
- pw += verticalBar.getPreferredSize().width;
- }
- Rectangle prototypeBasedBounds = super.computePopupBounds(px, py, pw, ph);
- return prototypeBasedBounds.width > defaultBounds.width
- ? prototypeBasedBounds
- : defaultBounds;
- }
-
- }
-
-
- // Handling Combo Changes *************************************************
-
- /**
- * Listens to changes in the table cell editor client property
- * and updates the default editor - if any - to use the correct
- * insets for this case.
- */
- private final class TableCellEditorPropertyChangeHandler implements PropertyChangeListener {
- @Override
- public void propertyChange(PropertyChangeEvent evt) {
- tableCellEditor = isTableCellEditor();
- if (comboBox.getRenderer() == null || comboBox.getRenderer() instanceof UIResource) {
- comboBox.setRenderer(createRenderer());
- }
- if (comboBox.getEditor() == null || comboBox.getEditor() instanceof UIResource) {
- comboBox.setEditor(createEditor());
- }
- }
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsFieldCaret.java b/src/core/com/jgoodies/looks/windows/WindowsFieldCaret.java
deleted file mode 100644
index 3d7b4b2..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsFieldCaret.java
+++ /dev/null
@@ -1,394 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.EventQueue;
-import java.awt.Graphics;
-import java.awt.Insets;
-import java.awt.Rectangle;
-import java.awt.Shape;
-import java.awt.event.FocusEvent;
-import java.awt.event.MouseEvent;
-
-import javax.swing.BoundedRangeModel;
-import javax.swing.JFormattedTextField;
-import javax.swing.JTextField;
-import javax.swing.SwingUtilities;
-import javax.swing.plaf.TextUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.text.BadLocationException;
-import javax.swing.text.DefaultCaret;
-import javax.swing.text.DefaultHighlighter;
-import javax.swing.text.Highlighter;
-import javax.swing.text.JTextComponent;
-import javax.swing.text.LayeredHighlighter;
-import javax.swing.text.Position;
-import javax.swing.text.View;
-
-import com.jgoodies.looks.Options;
-
-/**
- * WindowsFieldCaret has different scrolling behavior than the DefaultCaret.
- * Also, this caret is visible in non-editable fields,
- * and the text is selected after a keyboard focus gained event.
- * For the latter see also issue #4337647 in Sun's bug database.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.16 $
- *
- */
-final class WindowsFieldCaret extends DefaultCaret implements UIResource {
-
- private static final LayeredHighlighter.LayerPainter WindowsPainter =
- new WindowsHighlightPainter(null);
-
-
- WindowsFieldCaret() {
- super();
- }
-
-
- // Begin of Added Code ----------------------------------------------
-
- private boolean isKeyboardFocusEvent = true;
-
-
- @Override
- public void focusGained(FocusEvent e) {
- final JTextComponent c = getComponent();
- if (c == null) {
- return;
- }
- if (c.isEnabled()) {
- setVisible(true);
- setSelectionVisible(true);
- }
- if ( !c.isEnabled()
- || !isKeyboardFocusEvent
- || !Options.isSelectOnFocusGainActive(c)) {
- return;
- }
- if (c instanceof JFormattedTextField) {
- EventQueue.invokeLater(new Runnable() {
- @Override
- public void run() {
- selectAll();
- }
- });
- } else {
- selectAll();
- }
- }
-
-
- private void selectAll() {
- final JTextComponent c = getComponent();
- if (c == null) {
- return;
- }
- boolean backward = Boolean.TRUE.equals(c.getClientProperty(Options.INVERT_SELECTION_CLIENT_KEY));
- if (backward) {
- setDot(c.getDocument().getLength());
- moveDot(0);
- } else {
- setDot(0);
- moveDot(c.getDocument().getLength());
- }
- }
-
-
- @Override
- public void focusLost(FocusEvent e) {
- super.focusLost(e);
- if (!e.isTemporary()) {
- isKeyboardFocusEvent = true;
- if ( getComponent() != null
- && Boolean.TRUE.equals(getComponent().getClientProperty(Options.SET_CARET_TO_START_ON_FOCUS_LOST_CLIENT_KEY))) {
- setDot(0);
- }
- }
- }
-
-
- @Override
- public void mousePressed(MouseEvent e) {
- if (SwingUtilities.isLeftMouseButton(e) || e.isPopupTrigger()) {
- isKeyboardFocusEvent = false;
- }
- super.mousePressed(e);
-
- }
-
-
- @Override
- public void mouseReleased(MouseEvent e) {
- super.mouseReleased(e);
- // super.mousePressed() does not transfer focus on popup clicks.
- // Windows does.
- if (e.isPopupTrigger()) {
- isKeyboardFocusEvent = false;
- if ( getComponent() != null
- && getComponent().isEnabled()
- && getComponent().isRequestFocusEnabled()) {
- getComponent().requestFocus();
- }
- }
- }
-
- // End of Added Code ------------------------------------------------
-
- /**
- * Adjusts the visibility of the caret according to
- * the windows feel which seems to be to move the
- * caret out into the field by about a quarter of
- * a field length if not visible.
- */
- @Override
- protected void adjustVisibility(Rectangle r) {
- SwingUtilities.invokeLater(new SafeScroller(r));
- }
-
-
- /**
- * Gets the painter for the Highlighter.
- *
- * @return the painter
- */
- @Override
- protected Highlighter.HighlightPainter getSelectionPainter() {
- return WindowsPainter;
- }
-
-
- private final class SafeScroller implements Runnable {
-
- SafeScroller(Rectangle r) {
- this.r = r;
- }
-
-
- @Override
- public void run() {
- JTextField field = (JTextField) getComponent();
- if (field == null) {
- return;
- }
- TextUI ui = field.getUI();
- int dot = getDot();
- // PENDING: We need to expose the bias in DefaultCaret.
- Position.Bias bias = Position.Bias.Forward;
- Rectangle startRect = null;
- try {
- startRect = ui.modelToView(field, dot, bias);
- } catch (BadLocationException ble) {}
-
- Insets i = field.getInsets();
- BoundedRangeModel vis = field.getHorizontalVisibility();
- int x = r.x + vis.getValue() - i.left;
- int quarterSpan = vis.getExtent() / 4;
- if (r.x < i.left) {
- vis.setValue(x - quarterSpan);
- } else if (r.x + r.width > i.left + vis.getExtent()+1) {
- vis.setValue(x - 3 * quarterSpan);
- }
- // If we scroll, our visual location will have changed,
- // but we won't have updated our internal location as
- // the model hasn't changed. This checks for the change,
- // and if necessary, resets the internal location.
- if (startRect == null) {
- return;
- }
- try {
- Rectangle endRect;
- endRect = ui.modelToView(field, dot, bias);
- if (endRect != null && !endRect.equals(startRect)){
- damage(endRect);
- }
- } catch (BadLocationException ble) {}
- }
-
- private final Rectangle r;
- }
-
- // Helper Classes *********************************************************
-
- private static final class WindowsHighlightPainter extends
- DefaultHighlighter.DefaultHighlightPainter {
- WindowsHighlightPainter(Color c) {
- super(c);
- }
-
-
- // --- HighlightPainter methods ---------------------------------------
-
- /**
- * Paints a highlight.
- *
- * @param g the graphics context
- * @param offs0 the starting model offset >= 0
- * @param offs1 the ending model offset >= offs1
- * @param bounds the bounding box for the highlight
- * @param c the editor
- */
- @Override
- public void paint(Graphics g, int offs0, int offs1, Shape bounds,
- JTextComponent c) {
- Rectangle alloc = bounds.getBounds();
- try {
- // --- determine locations ---
- TextUI mapper = c.getUI();
- Rectangle p0 = mapper.modelToView(c, offs0);
- Rectangle p1 = mapper.modelToView(c, offs1);
-
- // --- render ---
- Color color = getColor();
-
- if (color == null) {
- g.setColor(c.getSelectionColor());
- } else {
- g.setColor(color);
- }
- boolean firstIsDot = false;
- boolean secondIsDot = false;
- if (c.isEditable()) {
- int dot = c.getCaretPosition();
- firstIsDot = offs0 == dot;
- secondIsDot = offs1 == dot;
- }
- if (p0.y == p1.y) {
- // same line, render a rectangle
- Rectangle r = p0.union(p1);
- if (r.width > 0) {
- if (firstIsDot) {
- r.x++;
- r.width--;
- } else if (secondIsDot) {
- r.width--;
- }
- }
- g.fillRect(r.x, r.y, r.width, r.height);
- } else {
- // different lines
- int p0ToMarginWidth = alloc.x + alloc.width - p0.x;
- if (firstIsDot && p0ToMarginWidth > 0) {
- p0.x++;
- p0ToMarginWidth--;
- }
- g.fillRect(p0.x, p0.y, p0ToMarginWidth, p0.height);
- if (p0.y + p0.height != p1.y) {
- g.fillRect(alloc.x, p0.y + p0.height, alloc.width, p1.y
- - (p0.y + p0.height));
- }
- if (secondIsDot && p1.x > alloc.x) {
- p1.x--;
- }
- g.fillRect(alloc.x, p1.y, p1.x - alloc.x, p1.height);
- }
- } catch (BadLocationException e) {
- // can't render
- }
- }
-
-
- // --- LayerPainter methods ----------------------------
- /**
- * Paints a portion of a highlight.
- *
- * @param g the graphics context
- * @param offs0 the starting model offset >= 0
- * @param offs1 the ending model offset >= offs1
- * @param bounds the bounding box of the view, which is not
- * necessarily the region to paint.
- * @param c the editor
- * @param view View painting for
- * @return region drawing occured in
- */
- @Override
- public Shape paintLayer(Graphics g, int offs0, int offs1, Shape bounds,
- JTextComponent c, View view) {
- Color color = getColor();
-
- if (color == null) {
- g.setColor(c.getSelectionColor());
- } else {
- g.setColor(color);
- }
- boolean firstIsDot = false;
- boolean secondIsDot = false;
- if (c.isEditable()) {
- int dot = c.getCaretPosition();
- firstIsDot = offs0 == dot;
- secondIsDot = offs1 == dot;
- }
- if (offs0 == view.getStartOffset() && offs1 == view.getEndOffset()) {
- // Contained in view, can just use bounds.
- Rectangle alloc;
- if (bounds instanceof Rectangle) {
- alloc = (Rectangle) bounds;
- } else {
- alloc = bounds.getBounds();
- }
- if (firstIsDot && alloc.width > 0) {
- g.fillRect(alloc.x + 1, alloc.y, alloc.width - 1,
- alloc.height);
- } else if (secondIsDot && alloc.width > 0) {
- g.fillRect(alloc.x, alloc.y, alloc.width - 1, alloc.height);
- } else {
- g.fillRect(alloc.x, alloc.y, alloc.width, alloc.height);
- }
- return alloc;
- }
- // Should only render part of View.
- try {
- // --- determine locations ---
- Shape shape = view.modelToView(offs0,
- Position.Bias.Forward, offs1,
- Position.Bias.Backward, bounds);
- Rectangle r = shape instanceof Rectangle
- ? (Rectangle) shape
- : shape.getBounds();
- if (firstIsDot && r.width > 0) {
- g.fillRect(r.x + 1, r.y, r.width - 1, r.height);
- } else if (secondIsDot && r.width > 0) {
- g.fillRect(r.x, r.y, r.width - 1, r.height);
- } else {
- g.fillRect(r.x, r.y, r.width, r.height);
- }
- return r;
- } catch (BadLocationException e) {
- return null;
- }
- }
-
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsFormattedTextFieldUI.java b/src/core/com/jgoodies/looks/windows/WindowsFormattedTextFieldUI.java
deleted file mode 100644
index 943ad9e..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsFormattedTextFieldUI.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicFormattedTextFieldUI;
-import javax.swing.text.Caret;
-
-/**
- * The JGoodies Windows L&F implementation of {@code FormattedTextFieldUI}.
- * It uses a caret that selects all text if the field gains focus
- * after a keyboard focus traversal.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class WindowsFormattedTextFieldUI extends BasicFormattedTextFieldUI {
-
- /**
- * Creates a UI for a JFormattedTextField.
- *
- * @param c the formatted text field
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new WindowsFormattedTextFieldUI();
- }
-
-
- /**
- * Creates the caret for a field.
- *
- * @return the caret
- */
- @Override
- protected Caret createCaret() {
- return new WindowsFieldCaret();
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsIconFactory.java b/src/core/com/jgoodies/looks/windows/WindowsIconFactory.java
deleted file mode 100644
index e871bfd..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsIconFactory.java
+++ /dev/null
@@ -1,221 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.io.Serializable;
-
-import javax.swing.*;
-import javax.swing.plaf.UIResource;
-
-/**
- * Factory class that vends {@code Icon}s used in the JGoodies Windows look&feel.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-final class WindowsIconFactory {
-
- private WindowsIconFactory() {
- // Overrides default constructor; prevents instantiation.
- }
-
- // Accessing and Creating Icons *****************************************************
-
- private static Icon checkBoxIcon;
- private static Icon radioButtonIcon;
-
-
- /**
- * Returns an {@code Icon} for a {@code JCheckBox}.
- */
- static Icon getCheckBoxIcon() {
- if (checkBoxIcon == null) {
- checkBoxIcon = new CheckBoxIcon();
- }
- return checkBoxIcon;
- }
-
-
- /**
- * Returns an {@code Icon} for a {@code JCheckBox}.
- */
- static Icon getRadioButtonIcon() {
- if (radioButtonIcon == null) {
- radioButtonIcon = new RadioButtonIcon();
- }
- return radioButtonIcon;
- }
-
-
- // Helper Classes *******************************************************************
-
- // Paints the icon for a check box.
- private static class CheckBoxIcon implements Icon, Serializable {
-
- private static final int SIZE = 13;
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- JCheckBox cb = (JCheckBox) c;
- ButtonModel model = cb.getModel();
-
- // outer bevel
- if (!cb.isBorderPaintedFlat()) {
- // Outer top/left
- g.setColor(UIManager.getColor("CheckBox.shadow"));
- g.drawLine(x, y, x+11, y);
- g.drawLine(x, y+1, x, y+11);
-
- // Outer bottom/right
- g.setColor(UIManager.getColor("CheckBox.highlight"));
- g.drawLine(x+12, y, x+12, y+12);
- g.drawLine(x, y+12, x+11, y+12);
-
- // Inner top.left
- g.setColor(UIManager.getColor("CheckBox.darkShadow"));
- g.drawLine(x+1, y+1, x+10, y+1);
- g.drawLine(x+1, y+2, x+1, y+10);
-
- // Inner bottom/right
- g.setColor(UIManager.getColor("CheckBox.light"));
- g.drawLine(x+1, y+11, x+11, y+11);
- g.drawLine(x+11, y+1, x+11, y+10);
- } else {
- g.setColor(UIManager.getColor("CheckBox.shadow"));
- g.drawRect(x+1, y+1, SIZE-3, SIZE-3);
- }
- // inside box
- g.setColor(UIManager.getColor(
- (model.isPressed() && model.isArmed()) || !model.isEnabled()
- ? "CheckBox.background"
- : "CheckBox.interiorBackground"));
- g.fillRect(x+2, y+2, SIZE-4, SIZE-4);
-
- g.setColor(UIManager.getColor(model.isEnabled()
- ? "CheckBox.checkColor" // Modified by JGoodies
- : "CheckBox.shadow"));
-
- // paint check
- if (model.isSelected()) {
- g.drawLine(x+9, y+3, x+9, y+3);
- g.drawLine(x+8, y+4, x+9, y+4);
- g.drawLine(x+7, y+5, x+9, y+5);
- g.drawLine(x+6, y+6, x+8, y+6);
- g.drawLine(x+3, y+7, x+7, y+7);
- g.drawLine(x+4, y+8, x+6, y+8);
- g.drawLine(x+5, y+9, x+5, y+9);
- g.drawLine(x+3, y+5, x+3, y+5);
- g.drawLine(x+3, y+6, x+4, y+6);
- }
- }
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
- }
-
-
- // Paints the icon for a radio button.
- private static class RadioButtonIcon implements Icon, UIResource, Serializable {
-
- private static final int SIZE = 13;
-
- @Override
- public void paintIcon(Component c, Graphics g, int x, int y) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- // fill interior
- g.setColor(UIManager.getColor(
- (model.isPressed() && model.isArmed()) || !model.isEnabled()
- ? "RadioButton.background"
- : "RadioButton.interiorBackground"));
- g.fillRect(x+2, y+2, 8, 8);
-
-
- // outter left arc
- g.setColor(UIManager.getColor("RadioButton.shadow"));
- g.drawLine(x+4, y+0, x+7, y+0);
- g.drawLine(x+2, y+1, x+3, y+1);
- g.drawLine(x+8, y+1, x+9, y+1);
- g.drawLine(x+1, y+2, x+1, y+3);
- g.drawLine(x+0, y+4, x+0, y+7);
- g.drawLine(x+1, y+8, x+1, y+9);
-
- // outter right arc
- g.setColor(UIManager.getColor("RadioButton.highlight"));
- g.drawLine(x+2, y+10, x+3, y+10);
- g.drawLine(x+4, y+11, x+7, y+11);
- g.drawLine(x+8, y+10, x+9, y+10);
- g.drawLine(x+10, y+9, x+10, y+8);
- g.drawLine(x+11, y+7, x+11, y+4);
- g.drawLine(x+10, y+3, x+10, y+2);
-
-
- // inner left arc
- g.setColor(UIManager.getColor("RadioButton.darkShadow"));
- g.drawLine(x+4, y+1, x+7, y+1);
- g.drawLine(x+2, y+2, x+3, y+2);
- g.drawLine(x+8, y+2, x+9, y+2);
- g.drawLine(x+2, y+3, x+2, y+3);
- g.drawLine(x+1, y+4, x+1, y+7);
- g.drawLine(x+2, y+8, x+2, y+8);
-
-
- // inner right arc
- g.setColor(UIManager.getColor("RadioButton.light"));
- g.drawLine(x+2, y+9, x+3, y+9);
- g.drawLine(x+4, y+10, x+7, y+10);
- g.drawLine(x+8, y+9, x+9, y+9);
- g.drawLine(x+9, y+8, x+9, y+8);
- g.drawLine(x+10, y+7, x+10, y+4);
- g.drawLine(x+9, y+3, x+9, y+3);
-
-
- // indicate whether selected or not
- if(model.isSelected()) {
- g.setColor(UIManager.getColor("RadioButton.checkColor")); // Modified by JGoodies
- g.fillRect(x+4, y+5, 4, 2);
- g.fillRect(x+5, y+4, 2, 4);
- }
- }
-
- @Override
- public int getIconWidth() { return SIZE; }
- @Override
- public int getIconHeight() { return SIZE; }
-
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsLookAndFeel.java b/src/core/com/jgoodies/looks/windows/WindowsLookAndFeel.java
deleted file mode 100644
index 6467926..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsLookAndFeel.java
+++ /dev/null
@@ -1,712 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Font;
-import java.awt.Insets;
-import java.lang.reflect.Method;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.LookAndFeel;
-import javax.swing.UIDefaults;
-import javax.swing.UIManager;
-import javax.swing.border.Border;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.IconUIResource;
-import javax.swing.plaf.InsetsUIResource;
-import javax.swing.plaf.basic.BasicBorders;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.FontPolicies;
-import com.jgoodies.looks.FontPolicy;
-import com.jgoodies.looks.FontSet;
-import com.jgoodies.looks.LookUtils;
-import com.jgoodies.looks.MicroLayout;
-import com.jgoodies.looks.MicroLayoutPolicies;
-import com.jgoodies.looks.MicroLayoutPolicy;
-import com.jgoodies.looks.Options;
-import com.jgoodies.looks.common.MinimumSizedIcon;
-import com.jgoodies.looks.common.RGBGrayFilter;
-import com.jgoodies.looks.common.ShadowPopupFactory;
-
-/**
- * The main class of the JGoodies Windows Look&Feel.
- * This look provides several corrections and extensions to Sun's Windows L&F.
- * In addition it tries to provide a unified look for the J2SE 1.4.0x, 1.4.1x,
- * 1.4.2, and 1.5 environments.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.48 $
- */
-public class WindowsLookAndFeel extends com.sun.java.swing.plaf.windows.WindowsLookAndFeel {
-
- /**
- * An optional client property key for JMenu and JToolBar
- * to set a border style - shadows the header style.
- */
- public static final String BORDER_STYLE_KEY = "jgoodies.windows.borderStyle";
-
-
- /**
- * Returns the String "JGoodies Windows".
- * Note that this L&f's ID ("Windows") is inherited
- * from the superclass, because we don't do any fundamental changes.
- *
- * @see LookAndFeel#getID()
- */
- @Override
- public String getName() {
- return "JGoodies Windows";
- }
-
-
- @Override
- public String getDescription() {
- return "The JGoodies Windows Look and Feel"
- + " - \u00a9 2001-2012 JGoodies Karsten Lentzsch";
- }
-
-
- // Optional Settings ******************************************************
-
- /**
- * Looks up and retrieves the FontPolicy used by
- * the JGoodies Windows Look&Feel.
- * If a FontPolicy has been set for this look, it'll be returned.
- * Otherwise, this method checks if a FontPolicy or FontSet is defined
- * in the system properties or UIDefaults. If so, it is returned.
- * If no FontPolicy has been set for this look, in the system
- * properties or UIDefaults, the default Windows font policy
- * will be returned.
- *
- * @return the FontPolicy set for this Look&feel - if any,
- * the FontPolicy specified in the system properties or UIDefaults
- * - if any, or the default Windows font policy.
- *
- * @see #setFontPolicy
- * @see Options#WINDOWS_FONT_POLICY_KEY
- * @see FontPolicies
- * @see FontPolicies#customSettingsPolicy(FontPolicy)
- * @see FontPolicies#getDefaultWindowsPolicy()
- */
- public static FontPolicy getFontPolicy() {
- FontPolicy policy =
- (FontPolicy) UIManager.get(Options.WINDOWS_FONT_POLICY_KEY);
- if (policy != null) {
- return policy;
- }
-
- FontPolicy defaultPolicy = FontPolicies.getDefaultWindowsPolicy();
- return FontPolicies.customSettingsPolicy(defaultPolicy);
- }
-
-
- /**
- * Sets the FontPolicy to be used with the JGoodies Windows L&F.
- * If the specified policy is {@code null}, the default will be reset.
- *
- * @param fontPolicy the FontPolicy to be used with the JGoodies Windows
- * L&F, or {@code null} to reset to the default
- *
- * @see #getFontPolicy()
- * @see Options#WINDOWS_FONT_POLICY_KEY
- */
- public static void setFontPolicy(FontPolicy fontPolicy) {
- UIManager.put(Options.WINDOWS_FONT_POLICY_KEY, fontPolicy);
- }
-
-
- /**
- * Looks up and retrieves the MicroLayoutPolicy used by
- * the JGoodies Windows Look&Feel.
- * If a MicroLayoutPolicy has been set for this look, it'll be returned.
- * Otherwise, the default Windows micro layout policy will be returned.
- *
- * @return the MicroLayoutPolicy set for this Look&feel - if any,
- * or the default Windows MicroLayoutPolicy.
- *
- * @see #setMicroLayoutPolicy
- * @see Options#WINDOWS_MICRO_LAYOUT_POLICY_KEY
- * @see MicroLayoutPolicies
- * @see MicroLayoutPolicies#getDefaultWindowsPolicy()
- */
- public static MicroLayoutPolicy getMicroLayoutPolicy() {
- MicroLayoutPolicy policy =
- (MicroLayoutPolicy) UIManager.get(Options.WINDOWS_MICRO_LAYOUT_POLICY_KEY);
- return policy != null
- ? policy
- : MicroLayoutPolicies.getDefaultWindowsPolicy();
- }
-
-
- /**
- * Sets the MicroLayoutPolicy to be used with the JGoodies Windows L&F.
- * If the specified policy is {@code null}, the default will be reset.
- *
- * @param microLayoutPolicy the MicroLayoutPolicy to be used with
- * the JGoodies Windows L&F, or {@code null} to reset
- * to the default
- *
- * @see #getMicroLayoutPolicy()
- * @see Options#WINDOWS_MICRO_LAYOUT_POLICY_KEY
- */
- public static void setMicroLayoutPolicy(MicroLayout microLayoutPolicy) {
- UIManager.put(Options.WINDOWS_MICRO_LAYOUT_POLICY_KEY, microLayoutPolicy);
- }
-
-
- // Overriding Superclass Behavior ***************************************
-
- /**
- * Invoked during {@code UIManager#setLookAndFeel}. In addition
- * to the superclass behavior, we install the ShadowPopupFactory.
- *
- * @see #uninitialize
- */
- @Override
- public void initialize() {
- super.initialize();
- ShadowPopupFactory.install();
- }
-
-
- /**
- * Invoked during {@code UIManager#setLookAndFeel}. In addition
- * to the superclass behavior, we uninstall the ShadowPopupFactory.
- *
- * @see #initialize
- */
- @Override
- public void uninitialize() {
- super.uninitialize();
- ShadowPopupFactory.uninstall();
- }
-
-
- /**
- * Returns an icon with a disabled appearance. This method is used
- * to generate a disabled icon when one has not been specified.<p>
- *
- * This method will be used only on JDK 5.0 and later.
- *
- * @param component the component that will display the icon, may be null.
- * @param icon the icon to generate disabled icon from.
- * @return disabled icon, or null if a suitable icon can not be generated.
- */
- @Override
- public Icon getDisabledIcon(JComponent component, Icon icon) {
- Icon disabledIcon = RGBGrayFilter.getDisabledIcon(component, icon);
- return disabledIcon != null
- ? new IconUIResource(disabledIcon)
- : null;
- }
-
-
- /**
- * Initializes the class defaults, that is, overrides some UI delegates
- * with JGoodies Windows implementations.
- */
- @Override
- protected void initClassDefaults(UIDefaults table) {
- super.initClassDefaults(table);
- final String windowsPrefix = "com.jgoodies.looks.windows.Windows";
- final String commonPrefix = "com.jgoodies.looks.common.ExtBasic";
-
- // Overwrite some of the uiDefaults.
- Object[] uiDefaults = {
- // Modified size
- "ComboBoxUI", windowsPrefix + "ComboBoxUI",
-
- // Modified preferred height: can be even or odd
- "ButtonUI", windowsPrefix + "ButtonUI",
-
- // Can installs an optional etched border
- "ScrollPaneUI", windowsPrefix + "ScrollPaneUI",
-
- // Optional style and optional special borders
- "MenuBarUI", windowsPrefix + "MenuBarUI",
-
- // Provides an option for a no margin border
- "PopupMenuUI", windowsPrefix + "PopupMenuUI",
-
- // Honors the screen resolution and uses a minimum button width
- "OptionPaneUI", windowsPrefix + "OptionPaneUI",
-
- // 1.4.1 has ugly one touch triangles
- "SplitPaneUI", windowsPrefix + "SplitPaneUI",
-
- // Work in progress: Can have a flat presentation
- "TabbedPaneUI", windowsPrefix + "TabbedPaneUI",
-
- // Selects text after focus gained via keyboard
- "TextFieldUI", windowsPrefix + "TextFieldUI",
- "FormattedTextFieldUI", windowsPrefix + "FormattedTextFieldUI",
-
- // Selects text after focus gained via keyboard
- // Renders a dot, not the star ("*") character on Java 1.4 and 5
- "PasswordFieldUI", windowsPrefix + "PasswordFieldUI",
-
-
- // Updates the disabled and inactive background
- "TextAreaUI", windowsPrefix + "TextAreaUI",
-
- // Corrected position of the tree button icon
- "TreeUI", windowsPrefix + "TreeUI",
-
- // Just to use shared UI delegate
- "SeparatorUI", windowsPrefix + "SeparatorUI",
-
- "SpinnerUI", windowsPrefix + "SpinnerUI"};
-
- // Aligned menu items
- if ( !SystemUtils.IS_OS_WINDOWS_6_OR_LATER
- || !SystemUtils.IS_LAF_WINDOWS_XP_ENABLED) {
- uiDefaults = append(uiDefaults,
- "MenuItemUI", windowsPrefix + "MenuItemUI");
- uiDefaults = append(uiDefaults,
- "CheckBoxMenuItemUI", commonPrefix + "CheckBoxMenuItemUI");
- uiDefaults = append(uiDefaults,
- "RadioButtonMenuItemUI", commonPrefix + "RadioButtonMenuItemUI");
- // Has padding above and below the separator lines
- uiDefaults = append(uiDefaults,
- "PopupMenuSeparatorUI", commonPrefix + "PopupMenuSeparatorUI");
- }
-
- if (SystemUtils.IS_LAF_WINDOWS_XP_ENABLED) {
- // Aligned menu items
- if (!SystemUtils.IS_OS_WINDOWS_6_OR_LATER) {
- uiDefaults = append(uiDefaults,
- "MenuUI", windowsPrefix + "XPMenuUI");
- }
-
- // Optional style and optional special borders;
- // rollover borders for compound buttons
- uiDefaults = append(uiDefaults,
- "ToolBarUI", windowsPrefix + "XPToolBarUI");
-
- // Honors XP table header style for custom user renderers.
- uiDefaults = append(uiDefaults,
- "TableHeaderUI", windowsPrefix + "XPTableHeaderUI");
- } else {
- // Aligned menu items
- uiDefaults = append(uiDefaults,
- "MenuUI", commonPrefix + "MenuUI");
-
- // Optional style and optional special borders;
- // rollover borders corrected
- uiDefaults = append(uiDefaults,
- "ToolBarUI", windowsPrefix + "ToolBarUI");
-
- // Black arrows
- uiDefaults = append(uiDefaults,
- "ScrollBarUI", windowsPrefix + "ScrollBarUI");
- }
- table.putDefaults(uiDefaults);
- }
-
- /**
- * Initializes the component defaults.
- */
- @Override
- protected void initComponentDefaults(UIDefaults table) {
- super.initComponentDefaults(table);
-
- final boolean isXP = SystemUtils.IS_LAF_WINDOWS_XP_ENABLED;
- final boolean isClassic = !isXP;
- final boolean isVista = SystemUtils.IS_OS_WINDOWS_6_OR_LATER;
-
- initFontDefaults(table);
-
- if (isClassic) {
- initComponentDefaultsClassic(table);
- }
- MicroLayout microLayout = getMicroLayoutPolicy().getMicroLayout("Windows", table);
- if (!isVista || !SystemUtils.IS_LAF_WINDOWS_XP_ENABLED) {
- initMenuItemDefaults(table, microLayout);
- }
-
- Object marginBorder = new BasicBorders.MarginBorder();
- Object checkBoxMargin = microLayout.getCheckBoxMargin();
-
- Object etchedBorder = new UIDefaults.ProxyLazyValue(
- "javax.swing.plaf.BorderUIResource",
- "getEtchedBorderUIResource");
- Object buttonBorder = new SimpleProxyLazyValue(
- "com.jgoodies.looks.windows.WindowsLookAndFeel",
- "getButtonBorder");
-
- Object menuBorder = isXP
- ? WindowsBorders.getXPMenuBorder()
- : WindowsBorders.getMenuBorder();
-
- Object menuBarEmptyBorder = marginBorder;
- Object menuBarSeparatorBorder = WindowsBorders.getSeparatorBorder();
- Object menuBarEtchedBorder = WindowsBorders.getEtchedBorder();
- Object menuBarHeaderBorder = WindowsBorders.getMenuBarHeaderBorder();
-
- Object toolBarEmptyBorder = marginBorder;
- Object toolBarSeparatorBorder = WindowsBorders.getSeparatorBorder();
- Object toolBarEtchedBorder = WindowsBorders.getEtchedBorder();
- Object toolBarHeaderBorder = WindowsBorders.getToolBarHeaderBorder();
-
- Object buttonMargin = microLayout.getButtonMargin();
-
- Object toolBarSeparatorSize = null;
-
- Object textInsets = microLayout.getTextInsets();
- Object wrappedTextInsets = microLayout.getWrappedTextInsets();
- Insets comboEditorInsets = microLayout.getComboBoxEditorInsets();
-
- int comboBorderSize = microLayout.getComboBorderSize();
- int comboPopupBorderSize = microLayout.getComboPopupBorderSize();
- int comboRendererGap = comboEditorInsets.left + comboBorderSize - comboPopupBorderSize;
- Object comboRendererBorder = new EmptyBorder(1, comboRendererGap, 1, comboRendererGap);
- Object comboTableEditorInsets = new Insets(0, 0, 0, 0);
-
- Object popupMenuSeparatorMargin = microLayout.getPopupMenuSeparatorMargin();
-
- // Should be active.
- int treeFontSize = table.getFont("Tree.font").getSize();
- Integer rowHeight = new Integer(treeFontSize + 6);
-
- Color controlColor = table.getColor("control");
- Object disabledTextBackground = table.getColor("TextField.disabledBackground");
- Object inactiveTextBackground = table.getColor("TextField.inactiveBackground");
-
- Object comboBoxDisabledBackground = isVista && isXP
- ? table.getColor("ComboBox.background")
- : disabledTextBackground;
-
- Object menuBarBackground = isXP
- ? table.get("control")
- : table.get("menu");
- Object menuSelectionBackground = isXP
- ? table.get("MenuItem.selectionBackground")
- : table.get("Menu.background");
- Object menuSelectionForeground = isXP
- ? table.get("MenuItem.selectionForeground")
- : table.get("Menu.foreground");
-
- Character passwordEchoChar = new Character(isXP ? '\u25CF' : '*');
-
- Object[] defaults = {
- "Button.border", buttonBorder,
- "Button.margin", buttonMargin, // Sun's 14px margin is too wide
-
- // 1.4.2 uses a 2 pixel non-standard border that leads to bad
- // alignment in the typical case that the border is not painted
- "CheckBox.border", marginBorder,
- "CheckBox.margin", checkBoxMargin,
-
- "ComboBox.disabledBackground", comboBoxDisabledBackground,
- "ComboBox.editorBorder", marginBorder,
- "ComboBox.editorColumns", new Integer(5),
- "ComboBox.editorInsets", comboEditorInsets, // Added by JGoodies
- "ComboBox.tableEditorInsets", comboTableEditorInsets,
- "ComboBox.rendererBorder", comboRendererBorder, // Added by JGoodies
-
- "EditorPane.margin", wrappedTextInsets,
-
- // Begin 1.3 und 1.4.0
- "Menu.border", menuBorder, // Fixed in 1.4.1
- "Menu.borderPainted", Boolean.TRUE,
- "Menu.background", menuBarBackground,
- "Menu.selectionForeground", menuSelectionForeground,
- "Menu.selectionBackground", menuSelectionBackground,
- // End 1.3 und 1.4.0
-
- "MenuBar.background", menuBarBackground,
- "MenuBar.border", menuBarSeparatorBorder, // 1.4.1 Separator wrong
- "MenuBar.emptyBorder", menuBarEmptyBorder, // Added by JGoodies
- "MenuBar.separatorBorder", menuBarSeparatorBorder, // Added by JGoodies
- "MenuBar.etchedBorder", menuBarEtchedBorder, // Added by JGoodies
- "MenuBar.headerBorder", menuBarHeaderBorder, // Added by JGoodies
-
- "FormattedTextField.disabledBackground", disabledTextBackground, // for readonly
- "FormattedTextField.inactiveBackground", inactiveTextBackground, // for readonly
- "FormattedTextField.margin", textInsets, // Poor in 1.6
-
- "PasswordField.margin", textInsets, // Poor in 1.6
- "PasswordField.echoChar", passwordEchoChar,
-
- "PopupMenu.border", WindowsBorders.getPopupMenuBorder(),
- "PopupMenu.noMarginBorder", WindowsBorders.getNoMarginPopupMenuBorder(),
- "PopupMenuSeparator.margin", popupMenuSeparatorMargin,
-
- "ScrollPane.etchedBorder", etchedBorder, // Added by JGoodies
-
- "Spinner.defaultEditorInsets", textInsets, // Added by JGoodies
-
- // 1.4.1 uses a 2 pixel non-standard border, that leads to bad
- // alignment in the typical case that the border is not painted
- "RadioButton.border", marginBorder,
- "RadioButton.margin", checkBoxMargin,
-
- "Spinner.border", table.get("TextField.border"),
-
- "Table.gridColor", controlColor, // 1.4.1 Bug; active
- "TextArea.margin", wrappedTextInsets, // 1.4.1 Bug
- "TextArea.disabledBackground", disabledTextBackground,
- "TextArea.inactiveBackground", inactiveTextBackground,
- "TextField.margin", textInsets, // 1.4.1 Bug
- "ToggleButton.margin", buttonMargin, // Sun's 14px margin is too wide
-
- "ToolBar.emptyBorder", toolBarEmptyBorder, // Added by JGoodies
- "ToolBar.separatorBorder", toolBarSeparatorBorder, // Added by JGoodies
- "ToolBar.etchedBorder", toolBarEtchedBorder, // Added by JGoodies
- "ToolBar.headerBorder", toolBarHeaderBorder, // Added by JGoodies
- "ToolBar.separatorSize", toolBarSeparatorSize,
- "ToolBar.margin", new InsetsUIResource(0, 10, 0, 0),
-
- "Tree.selectionBorderColor", controlColor, // 1.4.1 Bug; active
- "Tree.rowHeight", rowHeight, // 1.4.1 Bug
- };
- table.putDefaults(defaults);
- }
-
- /**
- * Initializes component defaults required in classic mode only.
- */
- private static void initComponentDefaultsClassic(UIDefaults table) {
- Object checkBoxIcon = new SimpleProxyLazyValue(
- "com.jgoodies.looks.windows.WindowsLookAndFeel",
- "getCheckBoxIcon");
-
- Object radioButtonIcon = new SimpleProxyLazyValue(
- "com.jgoodies.looks.windows.WindowsLookAndFeel",
- "getRadioButtonIcon");
-
- Border winInsetBorder = new BasicBorders.FieldBorder(table
- .getColor("controlShadow"), table
- .getColor("controlDkShadow"),
- table.getColor("controlHighlight"), table
- .getColor("controlLtHighlight"));
-
- Object[] defaults = {
- "CheckBox.checkColor", table.get("controlText"), // kind-of black
- "CheckBox.icon", checkBoxIcon,
- "RadioButton.checkColor", table.get("controlText"), // kind-of black
- "RadioButton.icon", radioButtonIcon,
- "Table.scrollPaneBorder", winInsetBorder, // 1.4.1 Bug
-
- };
- table.putDefaults(defaults);
- }
-
-
- /**
- * Looks up the correct control font and sets it for all controls.
- */
- private static void initFontDefaults(UIDefaults table) {
- FontPolicy fontChoicePolicy = getFontPolicy();
- FontSet fontSet = fontChoicePolicy.getFontSet("Windows", table);
- initFontDefaults(table, fontSet);
- }
-
-
- private static void initMenuItemDefaults(UIDefaults table, MicroLayout microLayout) {
- Object menuMargin = microLayout.getMenuMargin();
- Object menuItemMargin = microLayout.getMenuItemMargin();
- Icon menuItemCheckIcon = new MinimumSizedIcon();
- Object[] defaults = {
-
- "Menu.margin", menuMargin, // 1.4.1 Bug
-
- "MenuItem.borderPainted", Boolean.TRUE,
- "MenuItem.checkIcon", menuItemCheckIcon, // Aligns menu items
- "MenuItem.margin", menuItemMargin, // 1.4.1 Bug
- "CheckBoxMenuItem.margin", menuItemMargin, // 1.4.1 Bug
- "RadioButtonMenuItem.margin", menuItemMargin, // 1.4.1 Bug
- };
- table.putDefaults(defaults);
- }
-
-
- /**
- * Sets Fonts in the given FontSet as defaults for all known
- * component types in the given UIDefaults table.
- *
- * @param table the UIDefaults table used to set fonts
- * @param fontSet describes the set of Fonts to be installed
- */
- private static void initFontDefaults(UIDefaults table, FontSet fontSet) {
- Font controlFont = fontSet.getControlFont();
- Font menuFont = fontSet.getMenuFont();
- Font messageFont = fontSet.getMessageFont();
- Font toolTipFont = fontSet.getSmallFont();
- Font titleFont = fontSet.getTitleFont();
- Font windowFont = fontSet.getWindowTitleFont();
-
- Object[] defaults = {
- "Button.font", controlFont,
- "CheckBox.font", controlFont,
- "ColorChooser.font", controlFont,
- "ComboBox.font", controlFont,
- "EditorPane.font", controlFont,
- "FormattedTextField.font", controlFont,
- "Label.font", controlFont,
- "List.font", controlFont,
- "Panel.font", controlFont,
- "PasswordField.font", controlFont,
- "ProgressBar.font", controlFont,
- "RadioButton.font", controlFont,
- "ScrollPane.font", controlFont,
- "Spinner.font", controlFont,
- "TabbedPane.font", controlFont,
- "Table.font", controlFont,
- "TableHeader.font", controlFont,
- "TextArea.font", controlFont,
- "TextField.font", controlFont,
- "TextPane.font", controlFont,
- "ToolBar.font", controlFont,
- "ToggleButton.font", controlFont,
- "Tree.font", controlFont,
- "Viewport.font", controlFont,
-
- "InternalFrame.titleFont", windowFont, // controlBold
- "OptionPane.font", messageFont,
- "OptionPane.messageFont", messageFont,
- "OptionPane.buttonFont", messageFont,
- "TitledBorder.font", titleFont,
- "ToolTip.font", toolTipFont,
-
- "CheckBoxMenuItem.font", menuFont,
- "CheckBoxMenuItem.acceleratorFont", menuFont, // 1.3 only ?
- "Menu.font", menuFont,
- "Menu.acceleratorFont", menuFont,
- "MenuBar.font", menuFont,
- "MenuItem.font", menuFont,
- "MenuItem.acceleratorFont", menuFont,
- "PopupMenu.font", menuFont,
- "RadioButtonMenuItem.font", menuFont,
- "RadioButtonMenuItem.acceleratorFont", menuFont, // 1.3 only ?
- };
- table.putDefaults(defaults);
- }
-
-
- // Getters for Proxy Access (Referred classes can stay package visible) ***
-
- public static Border getButtonBorder() {
- return WindowsBorders.getButtonBorder();
- }
-
- public static Icon getCheckBoxIcon() {
- return WindowsIconFactory.getCheckBoxIcon();
- }
-
- public static Icon getRadioButtonIcon() {
- return WindowsIconFactory.getRadioButtonIcon();
- }
-
-
- // Helper Code ************************************************************
-
- /**
- * Appends the key and value to the given source array and returns
- * a copy that has the two new elements at its end.
- *
- * @return an array with the key and value appended
- */
- private static Object[] append(Object[] source, String key, Object value) {
- int length = source.length;
- Object[] destination = new Object[length + 2];
- System.arraycopy(source, 0, destination, 0, length);
- destination[length] = key;
- destination[length + 1] = value;
- return destination;
- }
-
-
- // Helper Class ***********************************************************
-
- /**
- * This class provides an implementation of {@code LazyValue} that
- * can be used to delay loading of the Class for the instance to be created.
- * It also avoids creation of an anonymous inner class for the
- * {@code LazyValue}
- * subclass. Both of these improve performance at the time that a
- * a Look and Feel is loaded, at the cost of a slight performance
- * reduction the first time {@code createValue} is called
- * (since Reflection APIs are used).
- */
- private static class SimpleProxyLazyValue implements UIDefaults.LazyValue {
-
- private final String className;
- private final String methodName;
-
- /**
- * Creates a {@code LazyValue} which will construct an instance
- * when asked.
- *
- * @param c a {@code String} specifying the classname of the class
- * containing a static method to be called for instance creation
- * @param m a {@code String} specifying the static
- * method to be called on class c
- */
- public SimpleProxyLazyValue(String c, String m) {
- className = c;
- methodName = m;
- }
-
- /**
- * Creates the value retrieved from the {@code UIDefaults} table.
- * The object is created each time it is accessed.
- *
- * @param table a {@code UIDefaults} table
- * @return the created {@code Object}
- */
- @Override
- public Object createValue(UIDefaults table) {
- Object instance = null;
- try {
- Class c;
- // We use a separate ClassLoader
- ClassLoader classLoader = table != null
- ? (ClassLoader) table.get("ClassLoader")
- : Thread.currentThread().getContextClassLoader();
- if (classLoader == null) {
- classLoader = getClass().getClassLoader();
- }
- c = Class.forName(className, true, classLoader);
- Method m = c.getMethod(methodName, (Class[]) null);
- instance = m.invoke(c, (Object[]) null);
- } catch (Throwable t) {
- LookUtils.log("Problem creating " + className + " with method "
- + methodName + t);
- }
- return instance;
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsMenuBarUI.java b/src/core/com/jgoodies/looks/windows/WindowsMenuBarUI.java
deleted file mode 100644
index 1688f51..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsMenuBarUI.java
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.JComponent;
-import javax.swing.LookAndFeel;
-import javax.swing.plaf.ComponentUI;
-
-import com.jgoodies.looks.BorderStyle;
-import com.jgoodies.looks.HeaderStyle;
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Windows look and feel implemenation of {@code MenuBarUI}.<p>
- *
- * Can handle optional {@code Border} types as specified by the
- * {@code BorderStyle} or {@code HeaderStyle} client properties.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class WindowsMenuBarUI extends com.sun.java.swing.plaf.windows.WindowsMenuBarUI {
-
- private PropertyChangeListener listener;
-
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsMenuBarUI();
- }
-
-
- // Handling Special Borders *********************************************************
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- installSpecialBorder();
- }
-
-
- @Override
- protected void installListeners() {
- super.installListeners();
- listener = createBorderStyleListener();
- menuBar.addPropertyChangeListener(listener);
- }
-
-
- @Override
- protected void uninstallListeners() {
- menuBar.removePropertyChangeListener(listener);
- super.uninstallListeners();
- }
-
-
- private PropertyChangeListener createBorderStyleListener() {
- return new PropertyChangeListener() {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String prop = e.getPropertyName();
- if (prop.equals(Options.HEADER_STYLE_KEY) ||
- prop.equals(WindowsLookAndFeel.BORDER_STYLE_KEY)) {
- WindowsMenuBarUI.this.installSpecialBorder();
- }
- }
-
- };
- }
-
-
- /**
- * Installs a special border, if either a look-dependent
- * {@code BorderStyle} or a look-independent
- * {@code HeaderStyle} has been specified.
- * A look specific BorderStyle shadows
- * a HeaderStyle.<p>
- *
- * Specifying a HeaderStyle is recommend.
- */
- private void installSpecialBorder() {
- String suffix;
- BorderStyle borderStyle = BorderStyle.from(menuBar,
- WindowsLookAndFeel.BORDER_STYLE_KEY);
- if (borderStyle == BorderStyle.EMPTY) {
- suffix = "emptyBorder";
- } else if (borderStyle == BorderStyle.ETCHED) {
- suffix = "etchedBorder";
- } else if (borderStyle == BorderStyle.SEPARATOR) {
- suffix = "separatorBorder";
- } else if (HeaderStyle.from(menuBar) == HeaderStyle.BOTH) {
- suffix = "headerBorder";
- } else {
- return;
- }
-
- LookAndFeel.installBorder(menuBar, "MenuBar." + suffix);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsMenuItemRenderer.java b/src/core/com/jgoodies/looks/windows/WindowsMenuItemRenderer.java
deleted file mode 100644
index c7ebc46..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsMenuItemRenderer.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Font;
-
-import javax.swing.JMenuItem;
-import javax.swing.UIManager;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.common.MenuItemRenderer;
-
-/**
- * Renders and lays out Windows menu items.
- * It overrides superclass behavior for the mnemonic check
- * and the text shadow feature.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.7 $
- */
-final class WindowsMenuItemRenderer extends MenuItemRenderer {
-
- /**
- * Constructs a WindowsMenuItemRenderer for the specified menu item and settings.
- */
- public WindowsMenuItemRenderer(JMenuItem menuItem, boolean iconBorderEnabled,
- Font acceleratorFont,
- Color selectionForeground,
- Color disabledForeground,
- Color acceleratorForeground,
- Color acceleratorSelectionForeground) {
- super(menuItem, iconBorderEnabled, acceleratorFont, selectionForeground, disabledForeground,
- acceleratorForeground, acceleratorSelectionForeground);
- }
-
-
- @Override
- protected boolean isMnemonicHidden() {
- return com.sun.java.swing.plaf.windows.WindowsLookAndFeel.isMnemonicHidden();
- }
-
-
- @Override
- protected boolean disabledTextHasShadow() {
- return (!SystemUtils.IS_LAF_WINDOWS_XP_ENABLED)
- || (UIManager.getColor("MenuItem.disabledForeground") == null);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsMenuItemUI.java b/src/core/com/jgoodies/looks/windows/WindowsMenuItemUI.java
deleted file mode 100644
index e731de7..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsMenuItemUI.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Font;
-
-import javax.swing.JComponent;
-import javax.swing.JMenuItem;
-import javax.swing.plaf.ComponentUI;
-
-import com.jgoodies.looks.common.ExtBasicMenuItemUI;
-import com.jgoodies.looks.common.MenuItemRenderer;
-
-/**
- * The JGoodies Windows look&feel implementation of {@code MenuItemUI}.<p>
- *
- * It differs from the superclass in that it uses a Windows specific
- * menu item renderer that checks if mnemonics shall be shown or hidden
- * and may paint disabled text with a shadow.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class WindowsMenuItemUI extends ExtBasicMenuItemUI {
-
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsMenuItemUI();
- }
-
-
- @Override
- protected MenuItemRenderer createRenderer(
- JMenuItem menuItem,
- boolean iconBorderEnabled,
- Font acceleratorFont,
- Color selectionForeground,
- Color disabledForeground,
- Color acceleratorForeground,
- Color acceleratorSelectionForeground) {
- return new WindowsMenuItemRenderer(
- menuItem,
- iconBorderEnabled(),
- acceleratorFont,
- selectionForeground,
- disabledForeground,
- acceleratorForeground,
- acceleratorSelectionForeground);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsOptionPaneUI.java b/src/core/com/jgoodies/looks/windows/WindowsOptionPaneUI.java
deleted file mode 100644
index f0be8a0..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsOptionPaneUI.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Container;
-
-import javax.swing.JComponent;
-import javax.swing.JPanel;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicOptionPaneUI;
-
-import com.jgoodies.looks.common.ExtButtonAreaLayout;
-
-/**
- * The JGoodies Windows Look&Feel implementation of
- * {@code OptionPaneUI}. Honors the screen resolution and uses a
- * minimum button with that complies better with the Windows UI style guide.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class WindowsOptionPaneUI extends BasicOptionPaneUI {
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsOptionPaneUI();
- }
-
- /**
- * Creates and returns a Container containin the buttons. The buttons
- * are created by calling {@code getButtons}.
- */
- @Override
- protected Container createButtonArea() {
- JPanel bottom = new JPanel(new ExtButtonAreaLayout(true, 6));
- bottom.setBorder(UIManager.getBorder("OptionPane.buttonAreaBorder"));
- addButtonComponents(bottom, getButtons(), getInitialValueIndex());
- return bottom;
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsPasswordFieldUI.java b/src/core/com/jgoodies/looks/windows/WindowsPasswordFieldUI.java
deleted file mode 100644
index 954d643..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsPasswordFieldUI.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-
-import javax.swing.JComponent;
-import javax.swing.JPasswordField;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.text.Caret;
-
-/**
- * The JGoodies Windows Look&Feel implementation of a password field UI
- * delegate. It differs from its superclass in that it utilizes a custom caret.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class WindowsPasswordFieldUI extends com.sun.java.swing.plaf.windows.WindowsPasswordFieldUI {
-
- /**
- * Creates a UI for a {@link JPasswordField}.
- *
- * @param c the password field component
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new WindowsPasswordFieldUI();
- }
-
-
- /**
- * Creates the caret for a field.
- *
- * @return the caret
- */
- @Override
- protected Caret createCaret() {
- return new WindowsFieldCaret();
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsPopupMenuUI.java b/src/core/com/jgoodies/looks/windows/WindowsPopupMenuUI.java
deleted file mode 100644
index dc97c1d..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsPopupMenuUI.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.BoxLayout;
-import javax.swing.JComponent;
-import javax.swing.LookAndFeel;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-
-import com.jgoodies.looks.Options;
-import com.jgoodies.looks.common.PopupMenuLayout;
-
-/**
- * The JGoodies Windows look&feel implementation of {@code PopMenuUI}.
- * It differs from the superclass in that it provides an option to get a
- * narrow border. You can set a client property
- * {@link Options#NO_MARGIN_KEY} to indicate that this popup menu
- * has a border without margin. That is useful in the special case
- * where the popup contains only a single component, for example
- * a JScrollPane.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- *
- * @see com.jgoodies.looks.Options#NO_MARGIN_KEY
- */
-public final class WindowsPopupMenuUI extends com.sun.java.swing.plaf.windows.WindowsPopupMenuUI {
-
- private PropertyChangeListener borderListener;
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsPopupMenuUI();
- }
-
-
- @Override
- public void installDefaults() {
- super.installDefaults();
- installBorder();
- if ( (popupMenu.getLayout() == null)
- || (popupMenu.getLayout() instanceof UIResource)) {
- popupMenu.setLayout(new PopupMenuLayout(popupMenu, BoxLayout.Y_AXIS));
- }
- }
-
- @Override
- public void installListeners() {
- super.installListeners();
- borderListener = new BorderStyleChangeHandler();
- popupMenu.addPropertyChangeListener(Options.NO_MARGIN_KEY, borderListener);
- }
-
- @Override
- protected void uninstallListeners() {
- popupMenu.removePropertyChangeListener(Options.NO_MARGIN_KEY, borderListener);
- super.uninstallListeners();
- }
-
- // Narrow Border **********************************************************
-
- private final class BorderStyleChangeHandler implements PropertyChangeListener {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- installBorder();
- }
-
- }
-
- /**
- * Installs a border without margin, iff the client property
- * {@code Options.NO_MARGIN_KEY} is set to {@code Boolean.TRUE}.
- */
- private void installBorder() {
- boolean useNarrowBorder = Boolean.TRUE.equals(
- popupMenu.getClientProperty(Options.NO_MARGIN_KEY));
- String suffix = useNarrowBorder ? "noMarginBorder" : "border";
- LookAndFeel.installBorder(popupMenu, "PopupMenu." + suffix);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsScrollBarUI.java b/src/core/com/jgoodies/looks/windows/WindowsScrollBarUI.java
deleted file mode 100644
index 5eaee56..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsScrollBarUI.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import javax.swing.JButton;
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-
-/**
- * The JGoodies Windows L&F implementation of* {@code ScrollBarUI}.
- * It differs from Sun's Windows Look in that it paints black button triangles
- * and that it honors the {@code ScrollBar.width} property to determine
- * the preferred size.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-public final class WindowsScrollBarUI extends com.sun.java.swing.plaf.windows.WindowsScrollBarUI {
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsScrollBarUI();
- }
-
-
- @Override
- protected JButton createDecreaseButton(int orientation) {
- return new WindowsArrowButton(orientation);
- }
-
-
- @Override
- protected JButton createIncreaseButton(int orientation) {
- return createDecreaseButton(orientation);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsScrollPaneUI.java b/src/core/com/jgoodies/looks/windows/WindowsScrollPaneUI.java
deleted file mode 100644
index b190afe..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsScrollPaneUI.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.JComponent;
-import javax.swing.JScrollPane;
-import javax.swing.LookAndFeel;
-import javax.swing.plaf.ComponentUI;
-
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Windows L&F implementation of {@code ScrollPaneUI}.
- * Installs an etched border if the client property
- * {@code Options.IS_ETCHED_KEY} is set.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see com.jgoodies.looks.Options#IS_ETCHED_KEY
- */
-public final class WindowsScrollPaneUI extends com.sun.java.swing.plaf.windows.WindowsScrollPaneUI {
-
- private PropertyChangeListener borderStyleChangeHandler;
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsScrollPaneUI();
- }
-
- @Override
- protected void installDefaults(JScrollPane scrollPane) {
- super.installDefaults(scrollPane);
- installEtchedBorder(scrollPane);
- }
-
- private static void installEtchedBorder(JScrollPane scrollPane) {
- Object value = scrollPane.getClientProperty(Options.IS_ETCHED_KEY);
- boolean hasEtchedBorder = Boolean.TRUE.equals(value);
- LookAndFeel.installBorder(scrollPane,
- hasEtchedBorder
- ? "ScrollPane.etchedBorder"
- : "ScrollPane.border");
- }
-
-
- // Managing the Etched Property *******************************************
-
- @Override
- public void installListeners(JScrollPane scrollPane) {
- super.installListeners(scrollPane);
- borderStyleChangeHandler = new BorderStyleChangeHandler();
- scrollPane.addPropertyChangeListener(Options.IS_ETCHED_KEY, borderStyleChangeHandler);
- }
-
- @Override
- protected void uninstallListeners(JComponent c) {
- ((JScrollPane) c).removePropertyChangeListener(Options.IS_ETCHED_KEY,
- borderStyleChangeHandler);
- super.uninstallListeners(c);
- }
-
- private class BorderStyleChangeHandler implements PropertyChangeListener {
-
- @Override
- public void propertyChange(PropertyChangeEvent evt) {
- JScrollPane scrollPane = (JScrollPane) evt.getSource();
- installEtchedBorder(scrollPane);
- }
-
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsSeparatorUI.java b/src/core/com/jgoodies/looks/windows/WindowsSeparatorUI.java
deleted file mode 100644
index 55a6beb..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsSeparatorUI.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicSeparatorUI;
-
-
-/**
- * The JGoodies Windows L&F implementation of {@code SeparatorUI}.
- * It differs from its superclass in that it uses a shared UI delegate.<p>
- *
- * Thanks to Andrej Golovnin for his feedback and suggestions.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class WindowsSeparatorUI extends BasicSeparatorUI {
-
- /** Shared UI object. */
- private static ComponentUI separatorUI;
-
- public static ComponentUI createUI(JComponent c) {
- if (separatorUI == null) {
- separatorUI = new WindowsSeparatorUI();
- }
- return separatorUI;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsSpinnerUI.java b/src/core/com/jgoodies/looks/windows/WindowsSpinnerUI.java
deleted file mode 100644
index 8342528..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsSpinnerUI.java
+++ /dev/null
@@ -1,201 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Component;
-import java.awt.Insets;
-import java.awt.LayoutManager;
-
-import javax.swing.*;
-import javax.swing.border.EmptyBorder;
-import javax.swing.plaf.ComponentUI;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.common.ExtBasicSpinnerLayout;
-
-/**
- * The JGoodies Windows L&F implementation of {@code SpinnerUI}.
- * Configures the default editor to adjust font baselines and component
- * bounds, by setting an empty border with the default text insets.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.13 $
- */
-public final class WindowsSpinnerUI extends com.sun.java.swing.plaf.windows.WindowsSpinnerUI {
-
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsSpinnerUI();
- }
-
-
- /**
- * Create a component that will replace the spinner models value with the
- * object returned by {@code spinner.getPreviousValue}. By default
- * the {@code previousButton} is a JButton who's {@code ActionListener}
- * updates it's {@code JSpinner} ancestors model. If a
- * previousButton isn't needed (in a subclass) then override this method to
- * return null.
- *
- * @return a component that will replace the spinners model with the next
- * value in the sequence, or null
- * @see #installUI
- * @see #createNextButton
- */
- @Override
- protected Component createPreviousButton() {
- if (SystemUtils.IS_LAF_WINDOWS_XP_ENABLED) {
- return super.createPreviousButton();
- }
-
- Component c = new WindowsArrowButton(SwingConstants.SOUTH);
- installPreviousButtonListeners(c);
- return c;
- }
-
-
- /**
- * Create a component that will replace the spinner models value with the
- * object returned by {@code spinner.getNextValue}. By default the
- * {@code nextButton} is a JButton who's {@code ActionListener}
- * updates it's {@code JSpinner} ancestors model. If a nextButton
- * isn't needed (in a subclass) then override this method to return null.
- *
- * @return a component that will replace the spinners model with the next
- * value in the sequence, or null
- * @see #installUI
- * @see #createPreviousButton
- */
- @Override
- protected Component createNextButton() {
- if (SystemUtils.IS_LAF_WINDOWS_XP_ENABLED) {
- return super.createNextButton();
- }
-
- Component c = new WindowsArrowButton(SwingConstants.NORTH);
- installNextButtonListeners(c);
- return c;
- }
-
-
- /**
- * This method is called by installUI to get the editor component of the
- * {@code JSpinner}. By default it just returns {@code JSpinner.getEditor()}.
- * Subclasses can override {@code createEditor} to return a
- * component that contains the spinner's editor or null, if they're going
- * to handle adding the editor to the {@code JSpinner} in an {@code installUI}
- * override.
- * <p>
- * Typically this method would be overridden to wrap the editor with a
- * container with a custom border, since one can't assume that the editors
- * border can be set directly.
- * <p>
- * The {@code replaceEditor} method is called when the spinners
- * editor is changed with {@code JSpinner.setEditor}. If you've
- * overriden this method, then you'll probably want to override {@code replaceEditor}
- * as well.
- *
- * @return the JSpinners editor JComponent, spinner.getEditor() by default
- * @see #installUI
- * @see #replaceEditor
- * @see JSpinner#getEditor
- */
- @Override
- protected JComponent createEditor() {
- JComponent editor = spinner.getEditor();
- configureEditorBorder(editor);
- return editor;
- }
-
-
- /**
- * Create a {@code LayoutManager} that manages the {@code editor},
- * {@code nextButton}, and {@code previousButton} children
- * of the JSpinner. These three children must be added with a constraint
- * that identifies their role: "Editor", "Next", and "Previous". The
- * default layout manager can handle the absence of any of these children.
- *
- * @return a LayoutManager for the editor, next button, and previous
- * button.
- * @see #createNextButton
- * @see #createPreviousButton
- * @see #createEditor
- */
- @Override
- protected LayoutManager createLayout() {
- return new ExtBasicSpinnerLayout();
- }
-
-
- /**
- * Called by the {@code PropertyChangeListener} when the {@code JSpinner}
- * editor property changes. It's the responsibility of this method to
- * remove the old editor and add the new one. By default this operation is
- * just:
- *
- * <pre>
- * spinner.remove(oldEditor); spinner.add(newEditor, "Editor");
- * </pre>
- *
- *
- * The implementation of {@code replaceEditor} should be coordinated
- * with the {@code createEditor} method.
- *
- * @see #createEditor
- * @see #createPropertyChangeListener
- */
- @Override
- protected void replaceEditor(JComponent oldEditor, JComponent newEditor) {
- spinner.remove(oldEditor);
- configureEditorBorder(newEditor);
- spinner.add(newEditor, "Editor");
- }
-
-
- /**
- * Sets an empty border with consistent insets.
- */
- private static void configureEditorBorder(JComponent editor) {
- if (editor instanceof JSpinner.DefaultEditor) {
- JSpinner.DefaultEditor defaultEditor = (JSpinner.DefaultEditor) editor;
- JTextField editorField = defaultEditor.getTextField();
- Insets insets = UIManager.getInsets("Spinner.defaultEditorInsets");
- editorField.setBorder(new EmptyBorder(insets));
- } else if ( editor instanceof JPanel
- && editor.getBorder() == null
- && editor.getComponentCount() > 0) {
- JComponent editorField = (JComponent) editor.getComponent(0);
- Insets insets = UIManager.getInsets("Spinner.defaultEditorInsets");
- editorField.setBorder(new EmptyBorder(insets));
- }
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsSplitPaneDivider.java b/src/core/com/jgoodies/looks/windows/WindowsSplitPaneDivider.java
deleted file mode 100644
index a95cc7b..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsSplitPaneDivider.java
+++ /dev/null
@@ -1,359 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.*;
-
-import javax.swing.JButton;
-import javax.swing.JSplitPane;
-import javax.swing.UIManager;
-import javax.swing.border.Border;
-import javax.swing.plaf.basic.BasicSplitPaneDivider;
-import javax.swing.plaf.basic.BasicSplitPaneUI;
-
-/**
- * Paints nicely rendered one touch triangles.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see WindowsSplitPaneUI
- */
-final class WindowsSplitPaneDivider extends BasicSplitPaneDivider {
-
- private static final int EXT_ONE_TOUCH_SIZE = 5;
- private static final int EXT_ONE_TOUCH_OFFSET = 2;
- private static final int EXT_BLOCKSIZE = 6;
-
- /**
- * Used to lay out a WindowsSplitPaneDivider. Layout for the divider
- * involves appropriately moving the left/right buttons around.
- * <p>
- * This inner class is marked "public" due to a compiler bug.
- * This class should be treated as a "protected" inner class.
- * Instantiate it only within subclasses of MetalSplitPaneDivider.
- */
- public final class ExtWindowsDividerLayout implements LayoutManager {
- @Override
- public void layoutContainer(Container c) {
- JButton theLeftButton = getLeftButtonFromSuper();
- JButton theRightButton = getRightButtonFromSuper();
- JSplitPane theSplitPane = getSplitPaneFromSuper();
- int theOrientation = getOrientationFromSuper();
- int oneTouchSize = getOneTouchSize();
- int oneTouchOffset = getOneTouchOffset();
- int blockSize = 5;
- //getBlockSize(); //Math.min(getDividerSize(), oneTouchSize);
-
- // This layout differs from the one used in BasicSplitPaneDivider.
- // It does not center justify the oneTouchExpadable buttons.
- // This was necessary in order to meet the spec of the Metal
- // splitpane divider.
- if (theLeftButton != null
- && theRightButton != null
- && c == WindowsSplitPaneDivider.this) {
- if (theSplitPane.isOneTouchExpandable()) {
- if (theOrientation == JSplitPane.VERTICAL_SPLIT) {
- theLeftButton.setBounds(
- oneTouchOffset,
- 0,
- blockSize * 2,
- blockSize);
- theRightButton.setBounds(
- oneTouchOffset + oneTouchSize * 2,
- 0,
- blockSize * 2,
- blockSize);
- } else {
- theLeftButton.setBounds(
- 0,
- oneTouchOffset,
- blockSize,
- blockSize * 2);
- theRightButton.setBounds(
- 0,
- oneTouchOffset + oneTouchSize * 2,
- blockSize,
- blockSize * 2);
- }
- } else {
- theLeftButton.setBounds(-5, -5, 1, 1);
- theRightButton.setBounds(-5, -5, 1, 1);
- }
- }
- }
-
- @Override
- public Dimension minimumLayoutSize(Container c) {
- return new Dimension(0, 0);
- }
- @Override
- public Dimension preferredLayoutSize(Container c) {
- return new Dimension(0, 0);
- }
- @Override
- public void removeLayoutComponent(Component c) {
- // Unused method; implements LayoutManager.
- }
- @Override
- public void addLayoutComponent(String string, Component c) {
- // Unused method; implements LayoutManager.
- }
- }
-
- public WindowsSplitPaneDivider(BasicSplitPaneUI ui) {
- super(ui);
- setLayout(new ExtWindowsDividerLayout());
- }
-
- /**
- * Creates and return an instance of JButton that can be used to
- * collapse the left component in the metal split pane.
- */
- @Override
- protected JButton createLeftOneTouchButton() {
- JButton b = new JButton() {
- // Sprite buffer for the arrow image of the left button
- int[][] buffer = { { 0, 0, 0, 2, 2, 0, 0, 0, 0 }, {
- 0, 0, 2, 1, 1, 1, 0, 0, 0 }, {
- 0, 2, 1, 1, 1, 1, 1, 0, 0 }, {
- 2, 1, 1, 1, 1, 1, 1, 1, 0 }, {
- 0, 3, 3, 3, 3, 3, 3, 3, 3 }
- };
-
- @Override
- public void setBorder(Border border) {
- // Ignore borders
- }
-
- @Override
- public void paint(Graphics g) {
- JSplitPane theSplitPane = getSplitPaneFromSuper();
- if (theSplitPane != null) {
- int theOrientation = getOrientationFromSuper();
- int blockSize = buffer.length + 1;
- //Math.min(getDividerSize(), oneTouchSize);
-
- // Initialize the color array
- Color[] colors =
- {
- this.getBackground(),
- UIManager.getColor("controlDkShadow"),
- Color.black,
- //UIManager.getColor(),
- UIManager.getColor("controlLtHighlight")};
-
- // Fill the background first ...
- g.setColor(this.getBackground());
- g.fillRect(0, 0, this.getWidth(), this.getHeight());
-
- // ... then draw the arrow.
- if (getModel().isPressed()) {
- // Adjust color mapping for pressed button state
- colors[1] = colors[2];
- }
- if (theOrientation == JSplitPane.VERTICAL_SPLIT) {
- // Draw the image for a vertical split
- for (int i = 1; i <= buffer[0].length; i++) {
- for (int j = 1; j < blockSize; j++) {
- if (buffer[j - 1][i - 1] == 0) {
- continue;
- }
- g.setColor(colors[buffer[j - 1][i - 1]]);
- g.drawLine(i - 1, j, i - 1, j);
- }
- }
- } else {
- // Draw the image for a horizontal split
- // by simply swaping the i and j axis.
- // Except the drawLine() call this code is
- // identical to the code block above. This was done
- // in order to remove the additional orientation
- // check for each pixel.
- for (int i = 1; i <= buffer[0].length; i++) {
- for (int j = 1; j < blockSize; j++) {
- if (buffer[j - 1][i - 1] == 0) {
- // Nothing needs
- // to be drawn
- continue;
- }
- // Set the color from the
- // color map
- g.setColor(colors[buffer[j - 1][i - 1]]);
- // Draw a pixel
- g.drawLine(j - 1, i, j - 1, i);
- }
- }
- }
- }
- }
-
- };
- b.setFocusPainted(false);
- b.setBorderPainted(false);
- b.setFocusable(false);
- b.setOpaque(false);
- return b;
- }
-
- /**
- * Creates and return an instance of JButton that can be used to
- * collapse the right component in the metal split pane.
- */
- @Override
- protected JButton createRightOneTouchButton() {
- JButton b = new JButton() {
- // Sprite buffer for the arrow image of the right button
- int[][] buffer = { { 2, 2, 2, 2, 2, 2, 2, 2 }, {
- 0, 1, 1, 1, 1, 1, 1, 3 }, {
- 0, 0, 1, 1, 1, 1, 3, 0 }, {
- 0, 0, 0, 1, 1, 3, 0, 0 }, {
- 0, 0, 0, 0, 3, 0, 0, 0 }
- };
-
- @Override
- public void setBorder(Border border) {
- // Ignore borders
- }
-
- @Override
- public void paint(Graphics g) {
- JSplitPane theSplitPane = getSplitPaneFromSuper();
- if (theSplitPane != null) {
- int theOrientation = getOrientationFromSuper();
- int blockSize = buffer.length + 1;
- //Math.min(getDividerSize(), oneTouchSize);
-
- // Initialize the color array
- Color[] colors =
- {
- this.getBackground(),
- UIManager.getColor("controlDkShadow"),
- Color.black,
- //UIManager.getColor("controlDkShadow"),
- UIManager.getColor("controlLtHighlight")};
-
- // Fill the background first ...
- g.setColor(this.getBackground());
- g.fillRect(0, 0, this.getWidth(), this.getHeight());
-
- // ... then draw the arrow.
- if (getModel().isPressed()) {
- // Adjust color mapping for pressed button state
- colors[1] = colors[2];
- }
- if (theOrientation == JSplitPane.VERTICAL_SPLIT) {
- // Draw the image for a vertical split
- for (int i = 1; i <= buffer[0].length; i++) {
- for (int j = 1; j < blockSize; j++) {
- if (buffer[j - 1][i - 1] == 0) {
- continue;
- }
- g.setColor(colors[buffer[j - 1][i - 1]]);
- g.drawLine(i, j, i, j);
- }
- }
- } else {
- // Draw the image for a horizontal split
- // by simply swaping the i and j axis.
- // Except the drawLine() call this code is
- // identical to the code block above. This was done
- // in order to remove the additional orientation
- // check for each pixel.
- for (int i = 1; i <= buffer[0].length; i++) {
- for (int j = 1; j < blockSize; j++) {
- if (buffer[j - 1][i - 1] == 0) {
- // Nothing needs
- // to be drawn
- continue;
- }
- // Set the color from the
- // color map
- g.setColor(colors[buffer[j - 1][i - 1]]);
- // Draw a pixel
- g.drawLine(j - 1, i, j - 1, i);
- }
- }
- }
- }
- }
- };
- b.setFocusPainted(false);
- b.setBorderPainted(false);
- b.setFocusable(false);
- b.setOpaque(false);
- return b;
- }
-
- static int getBlockSize() {
- return EXT_BLOCKSIZE;
- }
-
- static int getOneTouchOffset() {
- return EXT_ONE_TOUCH_OFFSET;
- }
-
- static int getOneTouchSize() {
- return EXT_ONE_TOUCH_SIZE;
- }
-
- int getOrientationFromSuper() {
- return super.orientation;
- }
-
- JButton getLeftButtonFromSuper() {
- return super.leftButton;
- }
-
- JButton getRightButtonFromSuper() {
- return super.rightButton;
- }
-
- JSplitPane getSplitPaneFromSuper() {
- return super.splitPane;
- }
-
- @Override
- public void paint(Graphics g) {
- if (splitPane.isOpaque()) {
- Color bgColor = splitPane.hasFocus()
- ? UIManager.getColor("SplitPane.shadow")
- : getBackground();
-
- if (bgColor != null) {
- g.setColor(bgColor);
- g.fillRect(0, 0, getWidth(), getHeight());
- }
- }
- super.paint(g);
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsSplitPaneUI.java b/src/core/com/jgoodies/looks/windows/WindowsSplitPaneUI.java
deleted file mode 100644
index 586ffa9..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsSplitPaneUI.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicSplitPaneDivider;
-
-
-/**
- * The JGoodies Windows L&F implementation of {@code SplitPaneUI}.
- * Uses a special divider that paints modified one-touch buttons.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see com.jgoodies.looks.windows.WindowsSplitPaneDivider
- */
-public final class WindowsSplitPaneUI extends com.sun.java.swing.plaf.windows.WindowsSplitPaneUI {
-
-
- /**
- * Creates and returns a {@code WindowsSplitPaneUI} instance.
- */
- public static ComponentUI createUI(JComponent x) {
- return new WindowsSplitPaneUI();
- }
-
-
- /**
- * Creates and returns the modified default divider.
- */
- @Override
- public BasicSplitPaneDivider createDefaultDivider() {
- return new WindowsSplitPaneDivider(this);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsTabbedPaneUI.java b/src/core/com/jgoodies/looks/windows/WindowsTabbedPaneUI.java
deleted file mode 100644
index eb1f11d..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsTabbedPaneUI.java
+++ /dev/null
@@ -1,598 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.FontMetrics;
-import java.awt.Graphics;
-import java.awt.Insets;
-import java.awt.Rectangle;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.SwingConstants;
-import javax.swing.SwingUtilities;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicGraphicsUtils;
-import javax.swing.plaf.basic.BasicTabbedPaneUI;
-import javax.swing.text.View;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Windows L&F implementation of {@code TabbedPaneUI}.<p>
- *
- * The flat appearance is work in progress; currently it works only
- * for a single line of tabs and paints distored tabs for multiple lines.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-public final class WindowsTabbedPaneUI extends com.sun.java.swing.plaf.windows.WindowsTabbedPaneUI {
-
-
- /** Insets used for the embedded style content border. */
- private static final Insets EMPTY_INSETS = new Insets(0, 0, 0, 0);
-
- /** Insets used if we paint no content border. */
- private static final int INSET = SystemUtils.IS_LAF_WINDOWS_XP_ENABLED ? -1 : 1;
- private static final Insets NO_CONTENT_BORDER_NORTH_INSETS = new Insets(INSET, 0, 0, 0);
- private static final Insets NO_CONTENT_BORDER_WEST_INSETS = new Insets(0, INSET, 0, 0);
- private static final Insets NO_CONTENT_BORDER_SOUTH_INSETS = new Insets(0, 0, INSET, 0);
- private static final Insets NO_CONTENT_BORDER_EAST_INSETS = new Insets(0, 0, 0, INSET);
-
- /** Insets used if we paint content border. */
- private static final Insets CONTENT_BORDER_NORTH_INSETS = new Insets(0, 2, 4, 4);
- private static final Insets CONTENT_BORDER_WEST_INSETS = new Insets(2, 0, 4, 4);
- private static final Insets CONTENT_BORDER_SOUTH_INSETS = new Insets(4, 2, 0, 4);
- private static final Insets CONTENT_BORDER_EAST_INSETS = new Insets(2, 4, 4, 0);
-
-
- /**
- * Describes if tabs are painted with or without icons.
- */
- private static boolean isTabIconsEnabled = Options.isTabIconsEnabled();
-
- /**
- * Describes if we paint no content border or not; this is false by default.
- * You can disable the content border by setting the client property
- * Options.NO_CONTENT_BORDER_KEY to Boolean.TRUE;
- */
- private Boolean noContentBorder;
-
- /**
- * Describes if we paint tabs in an embedded style that is with
- * less decoration; this is false by default.
- * You can enable the embedded tabs style by setting the client property
- * Options.EMBEDDED_TABS_KEY to Boolean.TRUE.
- */
- private Boolean embeddedTabs;
-
- /**
- * Creates and answers the {@code WindowsTabbedPaneUI}.
- *
- * @see javax.swing.plaf.ComponentUI#createUI(JComponent)
- */
- public static ComponentUI createUI(JComponent x) {
- return new WindowsTabbedPaneUI();
- }
-
-
- /**
- * Installs the UI.
- *
- * @see javax.swing.plaf.ComponentUI#installUI(JComponent)
- */
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- embeddedTabs = (Boolean) c.getClientProperty(Options.EMBEDDED_TABS_KEY);
- noContentBorder = (Boolean) c.getClientProperty(Options.NO_CONTENT_BORDER_KEY);
- }
-
-
- /**
- * Checks and answers if content border will be painted.
- * This is controlled by the component's client property
- * Options.NO_CONTENT_BORDER or Options.EMBEDDED.
- */
- private boolean hasNoContentBorder() {
- return hasEmbeddedTabs() || Boolean.TRUE.equals(noContentBorder);
- }
-
- /**
- * Checks and answers if tabs are painted with minimal decoration.
- */
- private boolean hasEmbeddedTabs() {
- return embeddedTabs == null
- ? false
- : embeddedTabs.booleanValue();
- }
-
- /**
- * Creates and answer a handler that listens to property changes.
- * Unlike the superclass BasicTabbedPane, the PlasticTabbedPaneUI
- * uses an extended Handler.
- */
- @Override
- protected PropertyChangeListener createPropertyChangeListener() {
- return new MyPropertyChangeHandler();
- }
-
- private void doLayout() {
- tabPane.revalidate();
- tabPane.repaint();
- }
-
- /**
- * Updates the embedded tabs property. This message is sent by
- * my PropertyChangeHandler whenever the embedded tabs property changes.
- */
- private void embeddedTabsPropertyChanged(Boolean newValue) {
- embeddedTabs = newValue;
- doLayout();
- }
-
- /**
- * Updates the no content border property. This message is sent
- * by my PropertyChangeHandler whenever the noContentBorder
- * property changes.
- */
- private void noContentBorderPropertyChanged(Boolean newValue) {
- noContentBorder = newValue;
- doLayout();
- }
-
-
-
- /**
- * Answers the icon for the tab with the specified index.
- * In case, we have globally switched of the use tab icons,
- * we answer {@code null} if and only if we have a title.
- */
- @Override
- protected Icon getIconForTab(int tabIndex) {
- String title = tabPane.getTitleAt(tabIndex);
- boolean hasTitle = title != null && title.length() > 0;
- return !isTabIconsEnabled && hasTitle
- ? null
- : super.getIconForTab(tabIndex);
- }
-
- @Override
- protected Insets getContentBorderInsets(int tabPlacement) {
- if (!hasNoContentBorder()) {
- if (SystemUtils.IS_LAF_WINDOWS_XP_ENABLED) {
- switch (tabPlacement) {
- case RIGHT :
- return CONTENT_BORDER_EAST_INSETS;
- case LEFT :
- return CONTENT_BORDER_WEST_INSETS;
- case TOP :
- return CONTENT_BORDER_NORTH_INSETS;
- case BOTTOM :
- default :
- return CONTENT_BORDER_SOUTH_INSETS;
- }
- }
- return contentBorderInsets;
- } else if (hasEmbeddedTabs()) {
- return EMPTY_INSETS;
- } else {
- switch (tabPlacement) {
- case RIGHT :
- return NO_CONTENT_BORDER_EAST_INSETS;
- case LEFT :
- return NO_CONTENT_BORDER_WEST_INSETS;
- case TOP :
- return NO_CONTENT_BORDER_NORTH_INSETS;
- case BOTTOM :
- default :
- return NO_CONTENT_BORDER_SOUTH_INSETS;
- }
- }
- }
-
- @Override
- protected int getTabLabelShiftX(int tabPlacement, int tabIndex, boolean isSelected) {
- switch (tabPlacement) {
- case RIGHT :
- return isSelected ? 2 : 0;
- case LEFT :
- return isSelected ? -2 : 0;
- case TOP :
- case BOTTOM :
- default :
- return 0;
- }
- }
-
- @Override
- protected int getTabLabelShiftY(int tabPlacement, int tabIndex, boolean isSelected) {
- return 0;
- }
-
- @Override
- protected Insets getSelectedTabPadInsets(int tabPlacement) {
- if (hasEmbeddedTabs()) {
- return EMPTY_INSETS;
- } else if (hasNoContentBorder()) {
- int inset = SystemUtils.IS_LAF_WINDOWS_XP_ENABLED ? 1 : 0;
- switch (tabPlacement) {
- case LEFT: return new Insets(1, 2, 1, inset);
- case RIGHT: return new Insets(1, inset, 1, 2);
- case TOP: return new Insets(2, 2, inset, 2);
- case BOTTOM: return new Insets(inset, 2, 2, 2);
- default: return EMPTY_INSETS;
- }
- } else {
- Insets superInsets = super.getSelectedTabPadInsets(tabPlacement);
- int equalized = superInsets.left + superInsets.right / 2;
- superInsets.left = superInsets.right = equalized;
- return superInsets;
- }
- }
-
-
- @Override
- protected Insets getTabAreaInsets(int tabPlacement) {
- return hasEmbeddedTabs()
- ? /*new Insets(1,1,1,1)*/EMPTY_INSETS
- : super.getTabAreaInsets(tabPlacement);
- }
-
- /**
- * Paints the top edge of the pane's content border.
- */
- @Override
- protected void paintContentBorderTopEdge(Graphics g, int tabPlacement,
- int selectedIndex,
- int x, int y, int w, int h) {
- if (hasNoContentBorder() && tabPlacement != TOP) {
- return;
- }
- Rectangle selRect = selectedIndex < 0
- ? null
- : getTabBounds(selectedIndex, calcRect);
- if (tabPlacement != TOP || selectedIndex < 0 ||
- selRect.y + selRect.height + 1 < y ||
- selRect.x < x || selRect.x > x + w) {
- // no special case, do the super thing
- super.paintContentBorderTopEdge(g, tabPlacement, selectedIndex, x, y, w, h);
- } else {
- g.setColor(lightHighlight);
- g.fillRect(x, y, selRect.x + 1-x, 1);
- g.fillRect(selRect.x + selRect.width, y,
- x+w-2 -selRect.x-selRect.width, 1);
- }
- }
-
- /**
- * Paints the bottom edge of the pane's content border.
- */
- @Override
- protected void paintContentBorderBottomEdge(Graphics g, int tabPlacement,
- int selectedIndex,
- int x, int y, int w, int h) {
- if (!hasNoContentBorder()) {
- Rectangle selRect = selectedIndex < 0 ? null :
- getTabBounds(selectedIndex, calcRect);
- if (tabPlacement != BOTTOM || selectedIndex < 0 ||
- selRect.y - 1 > h + y ||
- selRect.x < x || selRect.x > x + w) {
- // no special case, do the super thing
- super.paintContentBorderBottomEdge(g, tabPlacement, selectedIndex, x, y, w, h);
- } else {
- g.setColor(lightHighlight);
- g.fillRect(x,y+h-1,1,1);
- g.setColor(shadow);
- g.fillRect(x+1, y+h-2, selRect.x - 1-x, 1);
- g.fillRect(selRect.x + selRect.width, y+h-2, x+w-2-selRect.x-selRect.width, 1);
- g.setColor(darkShadow);
- g.fillRect(x, y+h-1, selRect.x - x, 1);
- g.fillRect(selRect.x + selRect.width -1, y+h-1, x+w-selRect.x-selRect.width, 1);
- }
- } else if (!(tabPlacement == BOTTOM)) {
- // no content border really means only one content border:
- // the one edge that touches the tabs
- } else {
- g.setColor(shadow);
- g.fillRect(x,y+h,w,1);
- }
- }
-
- /**
- * Paints the left Edge of the pane's content border.
- */
- @Override
- protected void paintContentBorderLeftEdge(Graphics g, int tabPlacement,
- int selectedIndex,
- int x, int y, int w, int h) {
- if (!hasNoContentBorder()) {
- Rectangle selRect = selectedIndex < 0 ? null :
- getTabBounds(selectedIndex, calcRect);
- if (tabPlacement != LEFT || selectedIndex < 0 ||
- selRect.x + selRect.width + 1 < x ||
- selRect.y < y || selRect.y > y + h) {
- // no special case, do the super thing
- super.paintContentBorderLeftEdge(g, tabPlacement, selectedIndex, x, y, w, h);
- } else {
- g.setColor(lightHighlight);
- g.fillRect(x, y, 1, selRect.y + 1 - y);
- g.fillRect(x, selRect.y + selRect.height,
- 1, y+h-1-selRect.y-selRect.height);
-
- }
- } else if (!(tabPlacement == LEFT)) {
- // no content border really means only one content border:
- // the one edge that touches the tabs
- } else {
- g.setColor(shadow);
- g.fillRect(x,y,1,h);
- }
- }
-
- /**
- * Paints the right Edge of the pane's content border.
- */
- @Override
- protected void paintContentBorderRightEdge(Graphics g, int tabPlacement,
- int selectedIndex,
- int x, int y, int w, int h) {
- if (!hasNoContentBorder()) {
- Rectangle selRect = selectedIndex < 0 ? null :
- getTabBounds(selectedIndex, calcRect);
- if (tabPlacement != RIGHT || selectedIndex < 0 ||
- selRect.x - 1 > x+w ||
- selRect.y < y || selRect.y > y + h) {
- // no special case, do the super thing
- super.paintContentBorderRightEdge(g, tabPlacement, selectedIndex, x, y, w, h);
- } else {
- g.setColor(lightHighlight);
- g.fillRect(x+w-1, y,1,1);
- g.setColor(shadow);
- g.fillRect(x+w-2, y+1, 1, selRect.y - 1-y);
- g.fillRect(x+w-2, selRect.y + selRect.height,
- 1, y+h-1-selRect.y- selRect.height);
- g.setColor(darkShadow);
- g.fillRect(x+w-1, y, 1, selRect.y - y);
- g.fillRect(x+w-1, selRect.y + selRect.height-1,
- 1, y+h-selRect.y-selRect.height);
-
- }
- } else if (!(tabPlacement == RIGHT)) {
- // no content border really means only one content border:
- // the one edge that touches the tabs
- } else {
- g.setColor(shadow);
- g.fillRect(x+w,y,1,h);
- }
- }
-
-
- /**
- * Paints the border for a single tab; it does not paint the tab's background.
- */
- @Override
- protected void paintTabBorder(
- Graphics g,
- int tabPlacement,
- int tabIndex,
- int x,
- int y,
- int w,
- int h,
- boolean isSelected) {
- if (!hasEmbeddedTabs()) {
- super.paintTabBorder(g, tabPlacement, tabIndex, x, y, w, h, isSelected);
- return;
- }
- g.translate(x - 1, y - 1);
- int w1, w2, w3;
- int h1, h2, h3;
- switch (tabPlacement) {
- case TOP :
- w1 = 1;
- w2 = w - 2;
- w3 = 1;
- h1 = 1;
- h2 = h - 1;
- h3 = 0;
- break;
- case BOTTOM :
- w1 = 1;
- w2 = w - 2;
- w3 = 1;
- h1 = 0;
- h2 = h - 1;
- h3 = 1;
- break;
- case LEFT :
- w1 = 1;
- w2 = w - 1;
- w3 = 0;
- h1 = 1;
- h2 = h - 3;
- h3 = 1;
- break;
- case RIGHT :
- default :
- w1 = 0;
- w2 = w - 1;
- w3 = 1;
- h1 = 1;
- h2 = h - 3;
- h3 = 1;
- }
- if (isSelected) {
- g.setColor(lightHighlight);
- g.drawRect(w1, h1, w1 + w2 + w3, h1 + h2 + h3);
- g.setColor(shadow);
- g.fillRect(1 + w1, 0, w2, h1);
- g.fillRect(0, 1 + h1, w1, h2);
- g.fillRect(2 * w1 + w2 + 2 * w3, 1 + h1, w3, h2);
- g.fillRect(1 + w1, 2 * h1 + h2 + 2 * h3, w2, h3);
- g.fillRect(1, 1, w1, h1);
- g.fillRect(2 * w1 + w2 + w3, 1, w3, h1);
- g.fillRect(1, 2 * h1 + h2 + h3, w1, h3);
- g.fillRect(2 * w1 + w2 + w3, 2 * h1 + h2 + h3, w3, h3);
- } else {
- g.setColor(shadow);
- g.fillRect(w1 + w2 + 2 * w3, h3 * h2 /2, w3, h2* 2 /3);
- g.fillRect(w3*w2 /2, h1 + h2 + 2 * h3, w2/2 +2, h3);
- }
- g.translate(-x + 1, -y + 1);
- }
-
- @Override
- protected void paintFocusIndicator(
- Graphics g,
- int tabPlacement,
- Rectangle[] rectangles,
- int tabIndex,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- if (!hasEmbeddedTabs()) {
- super.paintFocusIndicator(g, tabPlacement, rectangles, tabIndex, iconRect, textRect, isSelected);
- return;
- }
- if (tabPane.hasFocus() && isSelected) {
- g.setColor(focus);
- BasicGraphicsUtils.drawDashedRect(g, textRect.x - 2, textRect.y, textRect.width + 3, textRect.height);
- }
- }
-
- @Override
- protected boolean shouldRotateTabRuns(int tabPlacement) {
- return !hasEmbeddedTabs();
- }
-
- /**
- * Copied here from super(super)class to avoid labels being centered on
- * vertical tab runs if they consist of icon and text.
- */
- @Override
- protected void layoutLabel(
- int tabPlacement,
- FontMetrics metrics,
- int tabIndex,
- String title,
- Icon icon,
- Rectangle tabRect,
- Rectangle iconRect,
- Rectangle textRect,
- boolean isSelected) {
- textRect.x = textRect.y = iconRect.x = iconRect.y = 0;
-
- //fix of issue #4
- View v = getTextViewForTab(tabIndex);
- if (v != null) {
- tabPane.putClientProperty("html", v);
- }
-
- int xNudge = getTabLabelShiftX(tabPlacement, tabIndex, isSelected);
- int yNudge = getTabLabelShiftY(tabPlacement, tabIndex, isSelected);
- if ((tabPlacement == RIGHT || tabPlacement == LEFT) && icon != null && title != null && !title.equals("")) {
- /* vertical tab runs look ugly if icons and text are centered */
- SwingUtilities.layoutCompoundLabel(
- tabPane,
- metrics,
- title,
- icon,
- SwingConstants.CENTER,
- SwingConstants.LEFT,
- SwingConstants.CENTER,
- SwingConstants.TRAILING,
- tabRect,
- iconRect,
- textRect,
- textIconGap);
- xNudge += 4;
- } else { /* original superclass behavior */
- SwingUtilities.layoutCompoundLabel(
- tabPane,
- metrics,
- title,
- icon,
- SwingConstants.CENTER,
- SwingConstants.CENTER,
- SwingConstants.CENTER,
- SwingConstants.TRAILING,
- tabRect,
- iconRect,
- textRect,
- textIconGap);
- }
-
- //fix of issue #4
- tabPane.putClientProperty("html", null);
-
- iconRect.x += xNudge;
- iconRect.y += yNudge;
- textRect.x += xNudge;
- textRect.y += yNudge;
- }
-
-
- /**
- * Catches and handles property change events. In addition to the super
- * class behavior we listen to changes of the ancestor, tab placement,
- * and JGoodies options for content border, and embedded tabs.
- */
- private final class MyPropertyChangeHandler extends BasicTabbedPaneUI.PropertyChangeHandler {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- super.propertyChange(e);
-
- String pName = e.getPropertyName();
- if (null == pName) {
- return;
- }
- if (pName.equals(Options.EMBEDDED_TABS_KEY)) {
- embeddedTabsPropertyChanged((Boolean)e.getNewValue());
- return;
- }
- if (pName.equals(Options.NO_CONTENT_BORDER_KEY)) {
- noContentBorderPropertyChanged((Boolean)e.getNewValue());
- return;
- }
-
- }
-
- }
-
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsTextAreaUI.java b/src/core/com/jgoodies/looks/windows/WindowsTextAreaUI.java
deleted file mode 100644
index c173f50..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsTextAreaUI.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.beans.PropertyChangeEvent;
-
-import javax.swing.JComponent;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-import javax.swing.text.JTextComponent;
-
-
-/**
- * The JGoodies Windows L&F implementation of {@code TextAreaUI}.
- * In addition to its superclass WindowsTextAreaUI, it updates the
- * background colors using behavior from BasicTextFieldUI.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.11 $
- */
-public final class WindowsTextAreaUI extends com.sun.java.swing.plaf.windows.WindowsTextAreaUI {
-
- /**
- * Creates a UI for a JTextArea.
- *
- * @param c the text area
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new WindowsTextAreaUI();
- }
-
-
-
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- updateBackground((JTextComponent) c);
- }
-
-
- /**
- * This method gets called when a bound property is changed
- * on the associated JTextComponent. In addition to the superclass
- * behavior, this UI updates the background if the <em>editable</em> or
- * <em>enabled</em> property changes.
- */
- @Override
- protected void propertyChange(PropertyChangeEvent evt) {
- super.propertyChange(evt);
- String propertyName = evt.getPropertyName();
- if ( "editable".equals(propertyName)
- || "enabled".equals(propertyName)) {
- updateBackground((JTextComponent) evt.getSource());
- }
- }
-
-
- private static void updateBackground(JTextComponent c) {
- Color background = c.getBackground();
- if (!(background instanceof UIResource)) {
- return;
- }
- Color newColor = null;
- if (!c.isEnabled()) {
- newColor = UIManager.getColor("TextArea.disabledBackground");
- }
- if (newColor == null && !c.isEditable()) {
- newColor = UIManager.getColor("TextArea.inactiveBackground");
- }
- if (newColor == null) {
- newColor = UIManager.getColor("TextArea.background");
- }
- if (newColor != null && newColor != background) {
- c.setBackground(newColor);
- }
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsTextFieldUI.java b/src/core/com/jgoodies/looks/windows/WindowsTextFieldUI.java
deleted file mode 100644
index 57f8171..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsTextFieldUI.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Dimension;
-
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.text.Caret;
-
-/**
- * The JGoodies Windows L&F implementation of {@code TextFieldUI}.
- * In addition to its superclass WindowsTextFieldUI, it uses a caret
- * that selects all text if the field gains focus after a keyboard
- * focus traversal.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public final class WindowsTextFieldUI extends
- com.sun.java.swing.plaf.windows.WindowsTextFieldUI {
-
- /**
- * Creates a UI for a JTextField.
- *
- * @param c the text field
- * @return the UI
- */
- public static ComponentUI createUI(JComponent c) {
- return new WindowsTextFieldUI();
- }
-
-
- /**
- * Creates the caret for a field.
- *
- * @return the caret
- */
- @Override
- protected Caret createCaret() {
- return new WindowsFieldCaret();
- }
-
-
- /**
- * The WindowsFieldCaret requires an extra pixel width.
- */
- @Override
- public Dimension getPreferredSize(JComponent c) {
- Dimension dim = super.getPreferredSize(c);
- return new Dimension(dim.width + 1, dim.height);
- }
-
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsToolBarSeparatorUI.java b/src/core/com/jgoodies/looks/windows/WindowsToolBarSeparatorUI.java
deleted file mode 100644
index ac61ab3..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsToolBarSeparatorUI.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Dimension;
-import java.awt.Graphics;
-
-import javax.swing.JComponent;
-import javax.swing.JSeparator;
-import javax.swing.SwingConstants;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.basic.BasicToolBarSeparatorUI;
-
-/**
- * A Windows tool bar separator that honors the tool bar's border.
- * Used in in 1.4.0, 1.4.1 and 1.4.2 with XP turned off.
- * In addition this class reuses a single UI instance.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-public final class WindowsToolBarSeparatorUI
- extends BasicToolBarSeparatorUI {
-
- /** Shared UI component. */
- private static WindowsToolBarSeparatorUI toolBarSeparatorUI;
-
- public static ComponentUI createUI(JComponent c) {
- if (toolBarSeparatorUI == null) {
- toolBarSeparatorUI = new WindowsToolBarSeparatorUI();
- }
- return toolBarSeparatorUI;
- }
-
- @Override
- public void paint(Graphics g, JComponent c) {
- Color temp = g.getColor();
-
- Color shadowColor = UIManager.getColor("ToolBar.shadow");
- Color highlightColor = UIManager.getColor("ToolBar.highlight");
-
- Dimension size = c.getSize();
-
- if (((JSeparator) c).getOrientation() == SwingConstants.VERTICAL) {
- int x = size.width / 2 - 1;
- g.setColor(shadowColor);
- g.drawLine(x, 0, x, size.height - 1);
- g.setColor(highlightColor);
- g.drawLine(x + 1, 0, x + 1, size.height - 1);
- } else {
- int y = size.height / 2 - 1;
- g.setColor(shadowColor);
- g.drawLine(0, y, size.width - 1, y);
- g.setColor(highlightColor);
- g.drawLine(0, y + 1, size.width - 1, y + 1);
- }
- g.setColor(temp);
- }
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsToolBarUI.java b/src/core/com/jgoodies/looks/windows/WindowsToolBarUI.java
deleted file mode 100644
index 7d2adf2..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsToolBarUI.java
+++ /dev/null
@@ -1,159 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Component;
-import java.awt.Container;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.AbstractButton;
-import javax.swing.JComponent;
-import javax.swing.LookAndFeel;
-import javax.swing.border.Border;
-import javax.swing.event.MouseInputListener;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.metal.MetalToolBarUI;
-
-import com.jgoodies.looks.BorderStyle;
-import com.jgoodies.looks.HeaderStyle;
-import com.jgoodies.looks.Options;
-
-/**
- * Corrects superclass behavior for rollover borders
- * and adds behavior for handling different types of borders.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public final class WindowsToolBarUI extends MetalToolBarUI {
-
- private PropertyChangeListener listener;
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsToolBarUI();
- }
-
- // Handling Special Borders *********************************************
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- installSpecialBorder();
- }
-
- @Override
- protected void installListeners() {
- super.installListeners();
- listener = createBorderStyleListener();
- toolBar.addPropertyChangeListener(listener);
- }
-
- @Override
- protected void uninstallListeners() {
- toolBar.removePropertyChangeListener(listener);
- super.uninstallListeners();
- }
-
- private PropertyChangeListener createBorderStyleListener() {
- return new PropertyChangeListener() {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String prop = e.getPropertyName();
- if (prop.equals(Options.HEADER_STYLE_KEY)
- || prop.equals(WindowsLookAndFeel.BORDER_STYLE_KEY)) {
- WindowsToolBarUI.this.installSpecialBorder();
- }
- }
-
- };
- }
-
- /**
- * Installs a special border, if either a look-dependent
- * {@code BorderStyle} or a look-independent
- * {@code HeaderStyle} has been specified.
- * A look specific BorderStyle shadows a HeaderStyle.<p>
- *
- * Specifying a HeaderStyle is recommend.
- */
- private void installSpecialBorder() {
- String suffix;
- BorderStyle borderStyle =
- BorderStyle.from(toolBar, WindowsLookAndFeel.BORDER_STYLE_KEY);
- if (borderStyle == BorderStyle.EMPTY) {
- suffix = "emptyBorder";
- } else if (borderStyle == BorderStyle.SEPARATOR) {
- suffix = "separatorBorder";
- } else if (borderStyle == BorderStyle.ETCHED) {
- suffix = "etchedBorder";
- } else if (HeaderStyle.from(toolBar) == HeaderStyle.BOTH) {
- suffix = "headerBorder";
- } else {
- return;
- }
- LookAndFeel.installBorder(toolBar, "ToolBar." + suffix);
- }
-
-
- // Misc *****************************************************************
-
- /**
- * Unlike the superclass MetalToolBarUI,
- * this class uses the docking listener from the BasicToolBarUI.
- */
- @Override
- protected MouseInputListener createDockingListener( ) {
- return new DockingListener(toolBar);
- }
-
-
- // Handling Rollover Borders ********************************************
-
- @Override
- protected Border createRolloverBorder() {
- return WindowsBorders.getRolloverButtonBorder();
- }
-
- @Override
- protected void setBorderToRollover(Component c) {
- if (c instanceof AbstractButton) {
- super.setBorderToRollover(c);
- } else if (c instanceof Container) {
- Container cont = (Container) c;
- for (int i = 0; i < cont.getComponentCount(); i++) {
- super.setBorderToRollover(cont.getComponent(i));
- }
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsTreeUI.java b/src/core/com/jgoodies/looks/windows/WindowsTreeUI.java
deleted file mode 100644
index ee12e18..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsTreeUI.java
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.plaf.ComponentUI;
-
-import com.jgoodies.looks.Options;
-
-/**
- * The JGoodies Windows Look&Feel implementation of {@code TreeUI}.
- * Corrects the position of the tree button icon and provides two line styles:
- * angled dashed lines, or no lines at all. By default, lines are drawn.<p>
- *
- * You can change the line style by setting a client property.
- * The property key and values are a subset of the values used
- * by the Metal L&F tree. To hide lines use one of the following:
- * <pre>
- * JTree tree1 = new JTree();
- * tree1.putClientProperty("JTree.lineStyle", "None");
- *
- * JTree tree2 = new JTree();
- * tree1.putClientProperty(Options.TREE_LINE_STYLE_KEY,
- * Options.TREE_LINE_STYLE_NONE_VALUE);
- * </pre>
- *
- * Although lines are shown by default, you could code:
- * <pre>
- * JTree tree1 = new JTree();
- * tree1.putClientProperty("JTree.lineStyle", "Angled");
- *
- * JTree tree2 = new JTree();
- * tree1.putClientProperty(Options.TREE_LINE_STYLE_KEY,
- * Options.TREE_LINE_STYLE_ANGLED_VALUE);
- * </pre>
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
-
-public final class WindowsTreeUI extends com.sun.java.swing.plaf.windows.WindowsTreeUI {
-
- private boolean linesEnabled = true;
- private PropertyChangeListener lineStyleHandler;
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsTreeUI();
- }
-
-
- // Installation ***********************************************************
-
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- updateLineStyle(c.getClientProperty(Options.TREE_LINE_STYLE_KEY));
- lineStyleHandler = new LineStyleHandler();
- c.addPropertyChangeListener(lineStyleHandler);
- }
-
- @Override
- public void uninstallUI(JComponent c) {
- c.removePropertyChangeListener(lineStyleHandler);
- super.uninstallUI(c);
- }
-
-
- // Painting ***************************************************************
-
- @Override
- protected void paintVerticalLine(Graphics g, JComponent c, int x, int top, int bottom) {
- if (linesEnabled) {
- super.paintVerticalLine(g, c, x, top, bottom);
- }
- }
-
- @Override
- protected void paintHorizontalLine(Graphics g, JComponent c, int y, int left, int right) {
- if (linesEnabled) {
- super.paintHorizontalLine(g, c, y, left, right);
- }
- }
-
- // Draws the icon centered at (x,y)
- @Override
- protected void drawCentered(Component c, Graphics graphics, Icon icon, int x, int y) {
- icon.paintIcon(c, graphics,
- x - icon.getIconWidth() / 2 - 1,
- y - icon.getIconHeight() / 2);
- }
-
-
- // Helper Code ************************************************************
-
- private void updateLineStyle(Object lineStyle) {
- linesEnabled = !Options.TREE_LINE_STYLE_NONE_VALUE.equals(lineStyle);
- }
-
- // Listens for changes of the line style property
- private class LineStyleHandler implements PropertyChangeListener {
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String name = e.getPropertyName();
- Object value = e.getNewValue();
- if (name.equals(Options.TREE_LINE_STYLE_KEY)) {
- updateLineStyle(value);
- }
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsUtils.java b/src/core/com/jgoodies/looks/windows/WindowsUtils.java
deleted file mode 100644
index bb600d5..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsUtils.java
+++ /dev/null
@@ -1,229 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Graphics;
-
-import javax.swing.UIManager;
-
-/**
- * Drawing utils.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.8 $
- */
-
-final class WindowsUtils {
-
- private WindowsUtils() {
- // Override default constructor; prevents instantiation.
- }
-
- /*
- static class CheckBoxIcon implements Icon, Serializable, UIResource {
- final static int csize = 13;
-
- private final Color background;
- private final Color highlight;
- private final Color shadow;
- private final Color darkShadow;
-
- CheckBoxIcon(Color background, Color highlight, Color shadow, Color darkShadow) {
- this.background = background;
- this.highlight = highlight;
- this.shadow = shadow;
- this.darkShadow = darkShadow;
- }
-
- public void paintIcon(Component c, Graphics g, int x, int y) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- // outer bevel
- g.setColor(background);
- g.fill3DRect(x, y, csize, csize, false);
-
- // inner bevel
- g.setColor(shadow);
- g.fill3DRect(x + 1, y + 1, csize - 2, csize - 2, false);
-
- // inside box
- if ((model.isPressed() && model.isArmed()) || !model.isEnabled()) {
- g.setColor(background);
- } else {
- g.setColor(highlight);
- }
- g.fillRect(x + 2, y + 2, csize - 4, csize - 4);
-
- if (model.isEnabled()) {
- g.setColor(darkShadow);
- } else {
- g.setColor(shadow);
- }
-
- // paint check
- if (model.isSelected()) {
- g.drawLine(x + 9, y + 3, x + 9, y + 3);
- g.drawLine(x + 8, y + 4, x + 9, y + 4);
- g.drawLine(x + 7, y + 5, x + 9, y + 5);
- g.drawLine(x + 6, y + 6, x + 8, y + 6);
- g.drawLine(x + 3, y + 7, x + 7, y + 7);
- g.drawLine(x + 4, y + 8, x + 6, y + 8);
- g.drawLine(x + 5, y + 9, x + 5, y + 9);
- g.drawLine(x + 3, y + 5, x + 3, y + 5);
- g.drawLine(x + 3, y + 6, x + 4, y + 6);
- }
- }
-
- public int getIconWidth() {
- return csize;
- }
-
- public int getIconHeight() {
- return csize;
- }
- }
-
- static class RadioButtonIcon implements Icon, Serializable, UIResource {
- private final Color background;
- private final Color highlight;
- private final Color shadow;
- private final Color darkShadow;
-
- RadioButtonIcon(Color background, Color highlight, Color shadow, Color darkShadow) {
- this.background = background;
- this.highlight = highlight;
- this.shadow = shadow;
- this.darkShadow = darkShadow;
- }
-
- public void paintIcon(Component c, Graphics g, int x, int y) {
- AbstractButton b = (AbstractButton) c;
- ButtonModel model = b.getModel();
-
- // fill interior
- if ((model.isPressed() && model.isArmed()) || !model.isEnabled()) {
- g.setColor(background);
- } else {
- g.setColor(highlight);
- }
- g.fillRect(x + 2, y + 2, 8, 8);
-
- // outter left arc
- g.setColor(shadow);
- g.drawLine(x + 4, y + 0, x + 7, y + 0);
- g.drawLine(x + 2, y + 1, x + 3, y + 1);
- g.drawLine(x + 8, y + 1, x + 9, y + 1);
- g.drawLine(x + 1, y + 2, x + 1, y + 3);
- g.drawLine(x + 0, y + 4, x + 0, y + 7);
- g.drawLine(x + 1, y + 8, x + 1, y + 9);
-
- // outter right arc
- g.setColor(highlight);
- g.drawLine(x + 2, y + 10, x + 3, y + 10);
- g.drawLine(x + 4, y + 11, x + 7, y + 11);
- g.drawLine(x + 8, y + 10, x + 9, y + 10);
- g.drawLine(x + 10, y + 9, x + 10, y + 8);
- g.drawLine(x + 11, y + 7, x + 11, y + 4);
- g.drawLine(x + 10, y + 3, x + 10, y + 2);
-
- // inner left arc
- g.setColor(darkShadow);
- g.drawLine(x + 4, y + 1, x + 7, y + 1);
- g.drawLine(x + 2, y + 2, x + 3, y + 2);
- g.drawLine(x + 8, y + 2, x + 9, y + 2);
- g.drawLine(x + 2, y + 3, x + 2, y + 3);
- g.drawLine(x + 1, y + 4, x + 1, y + 7);
- g.drawLine(x + 2, y + 8, x + 2, y + 8);
-
- // inner right arc
- g.setColor(background);
- g.drawLine(x + 2, y + 9, x + 3, y + 9);
- g.drawLine(x + 4, y + 10, x + 7, y + 10);
- g.drawLine(x + 8, y + 9, x + 9, y + 9);
- g.drawLine(x + 9, y + 8, x + 9, y + 8);
- g.drawLine(x + 10, y + 7, x + 10, y + 4);
- g.drawLine(x + 9, y + 3, x + 9, y + 3);
-
- // indicate whether selected or not
- if (model.isSelected()) {
- g.setColor(darkShadow);
- g.fillRect(x + 4, y + 5, 4, 2);
- g.fillRect(x + 5, y + 4, 2, 4);
- }
- }
-
- public int getIconWidth() {
- return 13;
- }
-
- public int getIconHeight() {
- return 13;
- }
- }
- */
-
- public static void drawRoundedDashedRect(Graphics g, int x, int y, int width, int height) {
- for (int vx = x+1; vx < (x + width); vx += 2) {
- g.fillRect(vx, y, 1, 1);
- g.fillRect(vx, y + height-1, 1, 1);
- }
- int offset = (width + 1) % 2;
- for (int vy = y+1; vy < (y + height - offset); vy += 2) {
- g.fillRect(x, vy, 1, 1);
- g.fillRect(x + width-1, vy+offset, 1, 1);
- }
- }
-
-
- static void drawFlush3DBorder(Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(UIManager.getColor("controlLtHighlight"));
- g.drawLine(0, 0, w - 2, 0);
- g.drawLine(0, 0, 0, h - 2);
- g.setColor(UIManager.getColor("controlShadow"));
- g.drawLine(w - 1, 0, w - 1, h - 1);
- g.drawLine(0, h - 1, w - 1, h - 1);
- g.translate(-x, -y);
- }
-
-
- static void drawPressed3DBorder(Graphics g, int x, int y, int w, int h) {
- g.translate(x, y);
- g.setColor(UIManager.getColor("controlShadow"));
- g.drawLine(0, 0, w - 2, 0);
- g.drawLine(0, 0, 0, h - 2);
- g.setColor(UIManager.getColor("controlLtHighlight"));
- g.drawLine(w - 1, 0, w - 1, h - 1);
- g.drawLine(0, h - 1, w - 1, h - 1);
- g.translate(-x, -y);
- }
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsXPMenuUI.java b/src/core/com/jgoodies/looks/windows/WindowsXPMenuUI.java
deleted file mode 100644
index d398c46..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsXPMenuUI.java
+++ /dev/null
@@ -1,200 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Color;
-import java.awt.Dimension;
-import java.awt.Graphics;
-
-import javax.swing.ButtonModel;
-import javax.swing.Icon;
-import javax.swing.JComponent;
-import javax.swing.JMenu;
-import javax.swing.JMenuItem;
-import javax.swing.UIManager;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.plaf.UIResource;
-
-import com.jgoodies.looks.common.MenuItemRenderer;
-
-/**
- * The JGoodies Windows XP look&feel implementation of {@code MenuUI}.<p>
- *
- * It differs from the superclass in that it uses an overhauled menu
- * rendering an aligmnent system. Furthermore, you can set a client property
- * <tt>Options.NO_ICONS_KEY</tt> to indicate that this menu has no icons.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- *
- * @see com.jgoodies.looks.Options
- */
-
-public final class WindowsXPMenuUI extends com.sun.java.swing.plaf.windows.WindowsMenuUI {
-
- private static final String MENU_PROPERTY_PREFIX = "Menu";
- private static final String SUBMENU_PROPERTY_PREFIX = "MenuItem";
-
- // May be changed to SUBMENU_PROPERTY_PREFIX later
- private String propertyPrefix = MENU_PROPERTY_PREFIX;
-
- private MenuItemRenderer renderer;
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsXPMenuUI();
- }
-
- // Install and Uninstall **************************************************
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- if (arrowIcon == null || arrowIcon instanceof UIResource) {
- arrowIcon = UIManager.getIcon("Menu.arrowIcon");
- }
- renderer =
- new MenuItemRenderer(
- menuItem,
- false,
- acceleratorFont,
- selectionForeground,
- disabledForeground,
- acceleratorForeground,
- acceleratorSelectionForeground);
- Integer gap =
- (Integer) UIManager.get(getPropertyPrefix() + ".textIconGap");
- defaultTextIconGap = gap != null ? gap.intValue() : 2;
- }
-
- @Override
- protected void uninstallDefaults() {
- super.uninstallDefaults();
- renderer = null;
- }
-
- @Override
- protected String getPropertyPrefix() {
- return propertyPrefix;
- }
-
- @Override
- protected Dimension getPreferredMenuItemSize(
- JComponent c,
- Icon aCheckIcon,
- Icon anArrowIcon,
- int textIconGap) {
-
- if (isSubMenu(menuItem)) {
- ensureSubMenuInstalled();
- return renderer.getPreferredMenuItemSize(
- c,
- aCheckIcon,
- anArrowIcon,
- textIconGap);
- }
- Dimension size =
- super.getPreferredMenuItemSize(
- c,
- aCheckIcon,
- anArrowIcon,
- textIconGap);
- int width = size.width;
- int height = size.height;
- if (height % 2 == 1) {
- height--;
- }
- return new Dimension(width, height);
- }
-
- @Override
- protected void paintMenuItem(
- Graphics g,
- JComponent c,
- Icon aCheckIcon,
- Icon anArrowIcon,
- Color background,
- Color foreground,
- int textIconGap) {
- if (isSubMenu(menuItem)) {
- renderer.paintMenuItem(
- g,
- c,
- aCheckIcon,
- anArrowIcon,
- background,
- foreground,
- textIconGap);
- } else {
- super.paintMenuItem(
- g,
- c,
- aCheckIcon,
- anArrowIcon,
- background,
- foreground,
- textIconGap);
- }
- }
-
- /**
- * Checks if we have already detected the correct menu type,
- * menu in menu bar vs. sub menu; reinstalls if necessary.
- */
- private void ensureSubMenuInstalled() {
- if (propertyPrefix.equals(SUBMENU_PROPERTY_PREFIX)) {
- return;
- }
-
- ButtonModel model = menuItem.getModel();
-
- //save values of armed and selected properties.
- //they will be resetted in #ununinstallDefaults().
- boolean oldArmed = model.isArmed();
- boolean oldSelected = model.isSelected();
-
- uninstallDefaults();
- propertyPrefix = SUBMENU_PROPERTY_PREFIX;
- installDefaults();
-
- //restore values of armed and selected properties
- model.setArmed(oldArmed);
- model.setSelected(oldSelected);
- }
-
-
- // Helper Code **********************************************************
-
- private static boolean isSubMenu(JMenuItem aMenuItem) {
- return !((JMenu) aMenuItem).isTopLevelMenu();
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/WindowsXPTableHeaderUI.java b/src/core/com/jgoodies/looks/windows/WindowsXPTableHeaderUI.java
deleted file mode 100644
index 6a51714..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsXPTableHeaderUI.java
+++ /dev/null
@@ -1,206 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Component;
-import java.awt.Graphics;
-import java.awt.Point;
-import java.awt.Rectangle;
-
-import javax.swing.JComponent;
-import javax.swing.JTable;
-import javax.swing.plaf.ComponentUI;
-import javax.swing.table.TableCellRenderer;
-import javax.swing.table.TableColumn;
-import javax.swing.table.TableColumnModel;
-
-import com.sun.java.swing.plaf.windows.WindowsTableHeaderUI;
-
-
-/**
- * The JGoodies Windows L&F implementation of {@code TableHeaderUI}.
- * A Windows table header that honors the XP header style even if the user
- * uses custom non-opaque renderers. The renderers should be a subclass of
- * {@code JComponent} because we need to replace the border by the one
- * specified in the XP style.<p>
- *
- * Thanks to Andrej Golovnin for his feedback and suggestions.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public final class WindowsXPTableHeaderUI extends WindowsTableHeaderUI {
-
- private TableCellRenderer xpRenderer;
-
- public static ComponentUI createUI(JComponent h) {
- return new WindowsXPTableHeaderUI();
- }
-
- @Override
- public void installUI(JComponent c) {
- super.installUI(c);
- xpRenderer = header.getDefaultRenderer();
- }
-
- @Override
- public void uninstallUI(JComponent c) {
- xpRenderer = null;
- super.uninstallUI(c);
- }
-
- @Override
- public void paint(Graphics g, JComponent c) {
- TableColumnModel cm = header.getColumnModel();
- if (cm.getColumnCount() <= 0) {
- return;
- }
- boolean ltr = header.getComponentOrientation().isLeftToRight();
-
- Rectangle clip = g.getClipBounds();
- Point left = clip.getLocation();
- Point right = new Point(clip.x + clip.width - 1, clip.y);
- int cMin = header.columnAtPoint(ltr ? left : right);
- int cMax = header.columnAtPoint(ltr ? right : left);
- // This should never happen.
- if (cMin == -1) {
- cMin = 0;
- }
- // If the table does not have enough columns to fill the view we'll get
- // -1.
- // Replace this with the index of the last column.
- if (cMax == -1) {
- cMax = cm.getColumnCount() - 1;
- }
-
- TableColumn draggedColumn = header.getDraggedColumn();
- int columnWidth;
- Rectangle cellRect = header.getHeaderRect(cMin);
- TableColumn aColumn;
- if (ltr) {
- for (int column = cMin; column <= cMax; column++) {
- aColumn = cm.getColumn(column);
- columnWidth = aColumn.getWidth();
- cellRect.width = columnWidth;
- if (aColumn != draggedColumn) {
- paintCell(g, cellRect, column);
- }
- cellRect.x += columnWidth;
- }
- } else {
- for (int column = cMax; column >= cMin; column--) {
- aColumn = cm.getColumn(column);
- columnWidth = aColumn.getWidth();
- cellRect.width = columnWidth;
- if (aColumn != draggedColumn) {
- paintCell(g, cellRect, column);
- }
- cellRect.x += columnWidth;
- }
- }
-
- // Paint the dragged column if we are dragging.
- if (draggedColumn != null) {
- int draggedColumnIndex = viewIndexForColumn(draggedColumn);
- Rectangle draggedCellRect = header
- .getHeaderRect(draggedColumnIndex);
-
- // Draw a gray well in place of the moving column.
- g.setColor(header.getParent().getBackground());
- g.fillRect(draggedCellRect.x, draggedCellRect.y,
- draggedCellRect.width, draggedCellRect.height);
-
- draggedCellRect.x += header.getDraggedDistance();
-
- // Fill the background.
- g.setColor(header.getBackground());
- g.fillRect(draggedCellRect.x, draggedCellRect.y,
- draggedCellRect.width, draggedCellRect.height);
-
- paintCell(g, draggedCellRect, draggedColumnIndex);
- }
-
- // Remove all components in the rendererPane.
- rendererPane.removeAll();
- }
-
- private void paintCell(Graphics g, Rectangle cellRect, int columnIndex) {
- TableColumn aColumn = header.getColumnModel().getColumn(columnIndex);
- TableCellRenderer renderer = aColumn.getHeaderRenderer();
- if (renderer == null) {
- renderer = header.getDefaultRenderer();
- }
-
- JTable table = header.getTable();
- Component background = xpRenderer.getTableCellRendererComponent(table,
- null, false, false, -1, columnIndex);
- Component c = renderer.getTableCellRendererComponent(table,
- aColumn.getHeaderValue(), false, false, -1, columnIndex);
-
- if (c != background) {
- // The DefaultTableCellRenderer is used in the most cases as
- // the base class for all header renderers. And due to
- // the optimizations in its #isOpaque method, we have to add
- // the component to the renderer pane to determine its
- // non-opaqueness.
- rendererPane.add(c);
- if (!c.isOpaque()) {
- rendererPane.paintComponent(g, background, header, cellRect.x,
- cellRect.y, cellRect.width, cellRect.height, true);
-
- // All custom header renderers will use TableHeader.cellBorder
- // returned by UIManager#getBorder. But this one does not
- // comply with the Windows XP style. It is the one used by
- // Windows Classis L&F. So replace the border of the custom
- // renderers component by the one which comply with XP style.
- if (c instanceof JComponent
- && background instanceof JComponent) {
- ((JComponent) c).setBorder(
- ((JComponent) background).getBorder());
- }
- }
- }
-
- rendererPane.paintComponent(g, c, header, cellRect.x, cellRect.y,
- cellRect.width, cellRect.height, true);
- }
-
- private int viewIndexForColumn(TableColumn aColumn) {
- TableColumnModel cm = header.getColumnModel();
- for (int column = cm.getColumnCount() - 1; column >= 0; column--) {
- if (cm.getColumn(column) == aColumn) {
- return column;
- }
- }
- return -1;
- }
-
-}
diff --git a/src/core/com/jgoodies/looks/windows/WindowsXPToolBarUI.java b/src/core/com/jgoodies/looks/windows/WindowsXPToolBarUI.java
deleted file mode 100644
index 95b61e9..0000000
--- a/src/core/com/jgoodies/looks/windows/WindowsXPToolBarUI.java
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.windows;
-
-import java.awt.Component;
-import java.awt.Container;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import javax.swing.AbstractButton;
-import javax.swing.JComponent;
-import javax.swing.LookAndFeel;
-import javax.swing.plaf.ComponentUI;
-
-import com.jgoodies.looks.BorderStyle;
-import com.jgoodies.looks.HeaderStyle;
-import com.jgoodies.looks.Options;
-import com.sun.java.swing.plaf.windows.WindowsToolBarUI;
-
-/**
- * Adds behavior for handling different types of borders.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.10 $
- */
-public final class WindowsXPToolBarUI extends WindowsToolBarUI {
-
- private PropertyChangeListener listener;
-
- public static ComponentUI createUI(JComponent b) {
- return new WindowsXPToolBarUI();
- }
-
-
- // Handling Special Borders *********************************************
-
- @Override
- protected void installDefaults() {
- super.installDefaults();
- installSpecialBorder();
- }
-
-
- @Override
- protected void installListeners() {
- super.installListeners();
- listener = createBorderStyleListener();
- toolBar.addPropertyChangeListener(listener);
- }
-
-
- @Override
- protected void uninstallListeners() {
- toolBar.removePropertyChangeListener(listener);
- super.uninstallListeners();
- }
-
-
- private PropertyChangeListener createBorderStyleListener() {
- return new PropertyChangeListener() {
-
- @Override
- public void propertyChange(PropertyChangeEvent e) {
- String prop = e.getPropertyName();
- if (prop.equals(Options.HEADER_STYLE_KEY)
- || prop.equals(WindowsLookAndFeel.BORDER_STYLE_KEY)) {
- WindowsXPToolBarUI.this.installSpecialBorder();
- }
- }
-
- };
- }
-
-
- /**
- * Installs a special border, if either a look-dependent
- * {@code BorderStyle} or a look-independent {@code HeaderStyle}
- * has been specified. A look specific BorderStyle shadows
- * a HeaderStyle.<p>
- *
- * Specifying a HeaderStyle is recommend.
- */
- private void installSpecialBorder() {
- String suffix;
- BorderStyle borderStyle = BorderStyle.from(toolBar,
- WindowsLookAndFeel.BORDER_STYLE_KEY);
- if (borderStyle == BorderStyle.EMPTY) {
- suffix = "emptyBorder";
- } else if (borderStyle == BorderStyle.SEPARATOR) {
- suffix = "separatorBorder";
- } else if (borderStyle == BorderStyle.ETCHED) {
- suffix = "etchedBorder";
- } else if (HeaderStyle.from(toolBar) == HeaderStyle.BOTH) {
- suffix = "headerBorder";
- } else {
- suffix = "border";
- }
- LookAndFeel.installBorder(toolBar, "ToolBar." + suffix);
- }
-
-
- // Handling Rollover Borders ********************************************
-
- @Override
- protected void setBorderToRollover(Component c) {
- if (c instanceof AbstractButton) {
- super.setBorderToRollover(c);
- } else if (c instanceof Container) {
- Container cont = (Container) c;
- for (int i = 0; i < cont.getComponentCount(); i++) {
- super.setBorderToRollover(cont.getComponent(i));
- }
- }
- }
-
-
-}
\ No newline at end of file
diff --git a/src/core/com/jgoodies/looks/windows/icons/Computer.gif b/src/core/com/jgoodies/looks/windows/icons/Computer.gif
deleted file mode 100644
index 4bcbeb2..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/Computer.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/DetailsView.gif b/src/core/com/jgoodies/looks/windows/icons/DetailsView.gif
deleted file mode 100644
index 4011722..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/DetailsView.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/Directory.gif b/src/core/com/jgoodies/looks/windows/icons/Directory.gif
deleted file mode 100644
index d16442b..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/Directory.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/FavoriteFolder.gif b/src/core/com/jgoodies/looks/windows/icons/FavoriteFolder.gif
deleted file mode 100644
index b6a66a9..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/FavoriteFolder.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/File.gif b/src/core/com/jgoodies/looks/windows/icons/File.gif
deleted file mode 100644
index f239de3..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/File.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/FloppyDrive.gif b/src/core/com/jgoodies/looks/windows/icons/FloppyDrive.gif
deleted file mode 100644
index 394f51f..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/FloppyDrive.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/HardDrive.gif b/src/core/com/jgoodies/looks/windows/icons/HardDrive.gif
deleted file mode 100644
index 6a4537d..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/HardDrive.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/HomeFolder.gif b/src/core/com/jgoodies/looks/windows/icons/HomeFolder.gif
deleted file mode 100644
index 97ed9a3..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/HomeFolder.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/ListView.gif b/src/core/com/jgoodies/looks/windows/icons/ListView.gif
deleted file mode 100644
index c169842..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/ListView.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/NewFolder.gif b/src/core/com/jgoodies/looks/windows/icons/NewFolder.gif
deleted file mode 100644
index 6c9601d..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/NewFolder.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/TreeClosed.gif b/src/core/com/jgoodies/looks/windows/icons/TreeClosed.gif
deleted file mode 100644
index 6f56b48..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/TreeClosed.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/TreeLeaf.gif b/src/core/com/jgoodies/looks/windows/icons/TreeLeaf.gif
deleted file mode 100644
index 505b9e6..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/TreeLeaf.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/TreeOpen.gif b/src/core/com/jgoodies/looks/windows/icons/TreeOpen.gif
deleted file mode 100644
index 5b8e83d..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/TreeOpen.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/UpFolder.gif b/src/core/com/jgoodies/looks/windows/icons/UpFolder.gif
deleted file mode 100644
index ce4a2bb..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/UpFolder.gif and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/xp/TreeClosed.png b/src/core/com/jgoodies/looks/windows/icons/xp/TreeClosed.png
deleted file mode 100644
index 093e39e..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/xp/TreeClosed.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/icons/xp/TreeOpen.png b/src/core/com/jgoodies/looks/windows/icons/xp/TreeOpen.png
deleted file mode 100644
index 855ac88..0000000
Binary files a/src/core/com/jgoodies/looks/windows/icons/xp/TreeOpen.png and /dev/null differ
diff --git a/src/core/com/jgoodies/looks/windows/package.html b/src/core/com/jgoodies/looks/windows/package.html
deleted file mode 100644
index 35260af..0000000
--- a/src/core/com/jgoodies/looks/windows/package.html
+++ /dev/null
@@ -1,65 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
- Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- o Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- o Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
- o Neither the name of JGoodies Karsten Lentzsch nor the names of
- its contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
- OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
- JavaDoc uses all text between the "body" tags.
- The first sentence is used as short description.
--->
-</head>
-<body bgcolor="white">
-
-Contains the classes for the JGoodies Windows L&F.
-
-<!--
-<h2>Package Specification</h2>
-
-##### FILL IN ANY SPECS NEEDED BY JAVA COMPATIBILITY KIT #####
-<ul>
- <li><a href="">##### REFER TO ANY FRAMEMAKER SPECIFICATION HERE #####</a>
-</ul>
--->
-
-<h2>Related Documentation</h2>
-
-For more information see:
-<ul>
- <li><a href="http://www.jgoodies.com/articles/" >
- http://www.jgoodies.com/articles/</a>
-</ul>
-<!-- Put @see and @since tags down here. -->
-
- at see com.jgoodies.looks
- at see com.jgoodies.looks.common
- at see com.jgoodies.looks.plastic
- at see com.jgoodies.looks.plastic.theme
-
-</body>
-</html>
diff --git a/src/core/overview.html b/src/core/overview.html
deleted file mode 100644
index 3368577..0000000
--- a/src/core/overview.html
+++ /dev/null
@@ -1,67 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
- Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- o Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- o Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
- o Neither the name of JGoodies Karsten Lentzsch nor the names of
- its contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
- OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
- JavaDoc uses all text between the "body" tags.
- The first sentence is used as short description.
--->
-</head>
-<body bgcolor="white">
-
- This document describes the API of the JGoodies Looks,
- a library that makes your Swing applications and applets look better.
- The package consists of a Windows look&feel and the Plastic look&feel family.
- These have been optimized for readability, precise micro-design and usability.
-
- <p>
- The JGoodies Looks require Java 6 or later.
- Versions for older Java runtimes are available at
- <a href="http://joodies.com/downloads/archive.html">here</a>.
-
-
- <h2>Getting Started</h2>
-
- First, download and run the
- <a href="http://www.jgoodies.com/freeware/looksdemo/index.html">JGoodies Looks Demo</a>.
- Then follow the <a href="../quickstart.html">Quick Start</a> and
- read the <a href="../guide/index.html">user's guide</a>.
-
- If you want to use a JGoodies l&f in NetBeans read
- <a href="../netbeans.html">here</a>.
-
- As a next step you can study the
- <a href="http://www.jgoodies.com/articles/">JGoodies articles and presentations</a>.
-
-
-
-
-</body>
-</html>
diff --git a/src/icons/dialog-question-oliv.svg b/src/icons/dialog-question-oliv.svg
deleted file mode 100644
index 15b890b..0000000
--- a/src/icons/dialog-question-oliv.svg
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!-- Created with Inkscape (http://www.inkscape.org/) -->
-<svg
- xmlns:dc="http://purl.org/dc/elements/1.1/"
- xmlns:cc="http://web.resource.org/cc/"
- xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:svg="http://www.w3.org/2000/svg"
- xmlns="http://www.w3.org/2000/svg"
- xmlns:xlink="http://www.w3.org/1999/xlink"
- xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
- xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
- width="48px"
- height="48px"
- id="svg1800"
- sodipodi:version="0.32"
- inkscape:version="0.43"
- sodipodi:docbase="D:\workspaces\default\Looks\src\icons"
- sodipodi:docname="dialog-question-oliv.svg"
- inkscape:export-filename="D:\temp\tango-icon-theme-0.7.2\48x48\dialog-question.png"
- inkscape:export-xdpi="90"
- inkscape:export-ydpi="90">
- <defs
- id="defs3">
- <linearGradient
- id="linearGradient4126"
- inkscape:collect="always">
- <stop
- id="stop4128"
- offset="0"
- style="stop-color:#000000;stop-opacity:1;" />
- <stop
- id="stop4130"
- offset="1"
- style="stop-color:#000000;stop-opacity:0;" />
- </linearGradient>
- <radialGradient
- inkscape:collect="always"
- xlink:href="#linearGradient4126"
- id="radialGradient3976"
- gradientUnits="userSpaceOnUse"
- gradientTransform="matrix(1,0,0,0.5,1.876291e-14,20)"
- cx="23.857143"
- cy="40.000000"
- fx="23.857143"
- fy="40.000000"
- r="17.142857" />
- <linearGradient
- id="linearGradient2431">
- <stop
- style="stop-color:#ffffff;stop-opacity:1;"
- offset="0"
- id="stop2433" />
- <stop
- style="stop-color:#b8b8b8;stop-opacity:1;"
- offset="1"
- id="stop2435" />
- </linearGradient>
- <radialGradient
- inkscape:collect="always"
- xlink:href="#linearGradient2431"
- id="radialGradient2437"
- cx="-19.515638"
- cy="16.855663"
- fx="-19.515638"
- fy="16.855663"
- r="8.7536434"
- gradientTransform="matrix(4.445991,-8.852599e-16,1.367217e-15,6.8665,67.25071,-104.6679)"
- gradientUnits="userSpaceOnUse" />
- <linearGradient
- inkscape:collect="always"
- id="linearGradient3101">
- <stop
- style="stop-color:#000000;stop-opacity:1;"
- offset="0"
- id="stop3103" />
- <stop
- style="stop-color:#000000;stop-opacity:0;"
- offset="1"
- id="stop3105" />
- </linearGradient>
- <radialGradient
- inkscape:collect="always"
- xlink:href="#linearGradient3101"
- id="radialGradient3107"
- cx="17.3125"
- cy="25.53125"
- fx="17.3125"
- fy="25.53125"
- r="9.6875"
- gradientTransform="matrix(1,0,0,0.351613,7.793249e-16,16.55413)"
- gradientUnits="userSpaceOnUse" />
- </defs>
- <sodipodi:namedview
- fill="#edd400"
- id="base"
- pagecolor="#ffffff"
- bordercolor="#666666"
- borderopacity="0.20392157"
- inkscape:pageopacity="0.0"
- inkscape:pageshadow="2"
- inkscape:zoom="14.729854"
- inkscape:cx="24.298113"
- inkscape:cy="23.52043"
- inkscape:current-layer="layer1"
- showgrid="false"
- inkscape:grid-bbox="true"
- inkscape:document-units="px"
- inkscape:showpageshadow="false"
- inkscape:window-width="891"
- inkscape:window-height="900"
- inkscape:window-x="120"
- inkscape:window-y="21" />
- <metadata
- id="metadata4">
- <rdf:RDF>
- <cc:Work
- rdf:about="">
- <dc:format>image/svg+xml</dc:format>
- <dc:type
- rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
- <cc:license
- rdf:resource="http://creativecommons.org/licenses/by-sa/2.0/" />
- <dc:title>Emblem Important</dc:title>
- <dc:creator>
- <cc:Agent>
- <dc:title>Jakub Steiner</dc:title>
- </cc:Agent>
- </dc:creator>
- <dc:subject>
- <rdf:Bag>
- <rdf:li>emblem</rdf:li>
- <rdf:li>photos</rdf:li>
- <rdf:li>pictures</rdf:li>
- <rdf:li>raw</rdf:li>
- <rdf:li>jpeg</rdf:li>
- </rdf:Bag>
- </dc:subject>
- </cc:Work>
- <cc:License
- rdf:about="http://creativecommons.org/licenses/by-sa/2.0/">
- <cc:permits
- rdf:resource="http://web.resource.org/cc/Reproduction" />
- <cc:permits
- rdf:resource="http://web.resource.org/cc/Distribution" />
- <cc:requires
- rdf:resource="http://web.resource.org/cc/Notice" />
- <cc:requires
- rdf:resource="http://web.resource.org/cc/Attribution" />
- <cc:permits
- rdf:resource="http://web.resource.org/cc/DerivativeWorks" />
- <cc:requires
- rdf:resource="http://web.resource.org/cc/ShareAlike" />
- </cc:License>
- </rdf:RDF>
- </metadata>
- <g
- id="layer1"
- inkscape:label="Layer 1"
- inkscape:groupmode="layer">
- <path
- inkscape:r_cy="true"
- inkscape:r_cx="true"
- transform="matrix(1.070555,0,0,0.525,-1.434199,20.28442)"
- d="M 41 40 A 17.142857 8.5714283 0 1 1 6.7142868,40 A 17.142857 8.5714283 0 1 1 41 40 z"
- sodipodi:ry="8.5714283"
- sodipodi:rx="17.142857"
- sodipodi:cy="40"
- sodipodi:cx="23.857143"
- id="path6548"
- style="opacity:0.6;color:#000000;fill:url(#radialGradient3976);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:10;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:block;overflow:visible"
- sodipodi:type="arc" />
- <path
- sodipodi:type="arc"
- style="opacity:1.0000000;fill:#8d9642;fill-opacity:1;fill-rule:nonzero;stroke:#4d5506;stroke-width:0.98214624;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0.0000000;stroke-opacity:1"
- id="path1650"
- sodipodi:cx="24.130018"
- sodipodi:cy="23.428040"
- sodipodi:rx="22.008699"
- sodipodi:ry="21.213203"
- d="M 46.138718 23.428040 A 22.008699 21.213203 0 1 1 2.1213188,23.428040 A 22.008699 21.213203 0 1 1 46.138718 23.428040 z"
- transform="matrix(0.944630,0.000000,0.000000,0.980053,1.504174,-1.556912)" />
- <path
- sodipodi:type="arc"
- style="opacity:1.0000000;fill:none;fill-opacity:1.0000000;fill-rule:nonzero;stroke:#b0b778;stroke-width:0.98214942;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-dashoffset:0.0000000;stroke-opacity:1"
- id="path3392"
- sodipodi:cx="24.130018"
- sodipodi:cy="23.428040"
- sodipodi:rx="22.008699"
- sodipodi:ry="21.213203"
- d="M 46.138718 23.428040 A 22.008699 21.213203 0 1 1 2.1213188,23.428040 A 22.008699 21.213203 0 1 1 46.138718 23.428040 z"
- transform="matrix(0.914086,0.000000,0.000000,0.948364,2.380576,-0.905815)" />
- <path
- style="fill:#fffeff;fill-opacity:0.21390374;fill-rule:nonzero;stroke:none;stroke-width:1.0000000;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dashoffset:0.0000000;stroke-opacity:1.0000000"
- d="M 43.676426,20.476780 C 43.676426,31.307396 37.624257,16.170581 25.001688,20.863168 C 12.279172,25.592912 4.4350535,31.307396 4.4350535,20.476780 C 4.4350535,9.6461627 13.225120,0.85609769 24.055740,0.85609769 C 34.886359,0.85609769 43.676426,9.6461627 43.676426,20.476780 z "
- id="path3068"
- sodipodi:nodetypes="czssc" />
- <path
- sodipodi:type="inkscape:offset"
- inkscape:radius="0.13495015"
- inkscape:original="M -20.25 6 C -21.298341 6.000026 -22.372769 6.1244771 -23.5 6.34375 C -24.627244 6.563073 -25.886043 6.8832479 -27.25 7.34375 L -27.25 12.5 C -26.100219 11.776335 -24.997109 11.236862 -23.9375 10.875 C -22.877902 10.502213 -21.881822 10.312521 -20.96875 10.3125 C -19.999334 10.312521 -19.259834 10.530174 -18.71875 10.96875 C -18.177686 11.396402 -17.906262 12.013726 -17.90625 12.78125 C -17.906261 13.285654 -18.039408 13.776881 -18.34375 14.28125 C -18.636843 14.785651 -19.107484 15.33609 -19.75 15.90625 L -20.84375 16.84375 C -22.038631 17.918325 -22.815518 18.829509 -23.1875 19.53125 C -23.559495 20.22205 -23.750005 21.007137 -23.75 21.90625 L -23.75 22.71875 L -17.65625 22.71875 L -17.65625 21.96875 C -17.656262 21.475338 -17.517981 21.030712 -17.28125 20.625 C -17.044542 20.208345 -16.547785 19.648586 -15.78125 18.96875 L -14.71875 18.03125 C -13.659161 17.055386 -12.908389 16.156813 -12.46875 15.3125 C -12.029144 14.457253 -11.781268 13.480828 -11.78125 12.40625 C -11.781268 10.311973 -12.525902 8.7417969 -13.96875 7.65625 C -15.41163 6.559783 -17.499549 6.0000261 -20.25 6 z M -23.75 25.15625 L -23.75 31 L -17.65625 31 L -17.65625 25.15625 L -23.75 25.15625 z "
- xlink:href="#text2215"
- style="font-size:34.15322876px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:url(#radialGradient2437);fill-opacity:1;stroke:#ffffff;stroke-width:1.09947276px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.78612713;font-family:Bitstream Vera Sans"
- id="path1554"
- d="M -20.25,5.875 C -21.309019,5.8750263 -22.397637,5.9982356 -23.53125,6.21875 C -24.664175,6.4391783 -25.911412,6.7562625 -27.28125,7.21875 C -27.291632,7.21754 -27.302118,7.21754 -27.3125,7.21875 C -27.324563,7.2273788 -27.335121,7.237937 -27.34375,7.25 C -27.355813,7.2586288 -27.366371,7.269187 -27.375,7.28125 C -27.37621,7.2916315 -27.37621,7.3021185 -27.375,7.3125 C -27.37621,7.3228815 -27.37621,7.3333685 -27.375,7.34375 L -27.375,12.5 C -27.37621,12.510382 -27.37621,12.520868 -27.375,12.53125 C -27.37621,12.541632 -27.37621,12.552118 -27.375,12.5625 C -27.366371,12.574563 -27.355813,12.585121 -27.34375,12.59375 C -27.335121,12.605813 -27.324563,12.616371 -27.3125,12.625 C -27.302118,12.62621 -27.291632,12.62621 -27.28125,12.625 C -27.270868,12.62621 -27.260382,12.62621 -27.25,12.625 C -27.239618,12.62621 -27.229132,12.62621 -27.21875,12.625 C -27.208368,12.62621 -27.197882,12.62621 -27.1875,12.625 C -26.045062,11.905957 -24.954148,11.357862 -23.90625,11 C -22.858109,10.631244 -21.863134,10.437521 -20.96875,10.4375 C -20.019532,10.437521 -19.323825,10.648045 -18.8125,11.0625 C -18.303777,11.46459 -18.031262,12.04554 -18.03125,12.78125 C -18.03126,13.261907 -18.175438,13.73266 -18.46875,14.21875 C -18.751741,14.705766 -19.209015,15.249245 -19.84375,15.8125 L -20.9375,16.75 C -22.138959,17.83049 -22.926743,18.741022 -23.3125,19.46875 C -23.695613,20.180196 -23.875005,20.988074 -23.875,21.90625 L -23.875,22.71875 C -23.87621,22.729132 -23.87621,22.739618 -23.875,22.75 C -23.87621,22.760382 -23.87621,22.770868 -23.875,22.78125 C -23.866371,22.793313 -23.855813,22.803871 -23.84375,22.8125 C -23.835121,22.824563 -23.824563,22.835121 -23.8125,22.84375 C -23.802118,22.84496 -23.791632,22.84496 -23.78125,22.84375 C -23.770868,22.84496 -23.760382,22.84496 -23.75,22.84375 L -17.65625,22.84375 C -17.645868,22.84496 -17.635382,22.84496 -17.625,22.84375 C -17.614618,22.84496 -17.604132,22.84496 -17.59375,22.84375 C -17.581687,22.835121 -17.571129,22.824563 -17.5625,22.8125 C -17.550437,22.803871 -17.539879,22.793313 -17.53125,22.78125 C -17.53004,22.770868 -17.53004,22.760382 -17.53125,22.75 C -17.53004,22.739618 -17.53004,22.729132 -17.53125,22.71875 L -17.53125,21.96875 C -17.531261,21.500554 -17.38288,21.075901 -17.15625,20.6875 C -16.933955,20.296216 -16.448177,19.737141 -15.6875,19.0625 L -14.625,18.125 C -13.558412,17.14269 -12.794341,16.240346 -12.34375,15.375 C -11.894481,14.500954 -11.656268,13.50158 -11.65625,12.40625 C -11.656268,10.279985 -12.400019,8.6722224 -13.875,7.5625 C -15.350197,6.4414748 -17.48124,5.8750263 -20.25,5.875 z M -23.8125,25.03125 C -23.824563,25.039879 -23.835121,25.050437 -23.84375,25.0625 C -23.855813,25.071129 -23.866371,25.081687 -23.875,25.09375 C -23.87621,25.104132 -23.87621,25.114618 -23.875,25.125 C -23.87621,25.135382 -23.87621,25.145868 -23.875,25.15625 L -23.875,31 C -23.87621,31.010382 -23.87621,31.020868 -23.875,31.03125 C -23.87621,31.041632 -23.87621,31.052118 -23.875,31.0625 C -23.866371,31.074563 -23.855813,31.085121 -23.84375,31.09375 C -23.835121,31.105813 -23.824563,31.116371 -23.8125,31.125 C -23.802118,31.12621 -23.791632,31.12621 -23.78125,31.125 C -23.770868,31.12621 -23.760382,31.12621 -23.75,31.125 L -17.65625,31.125 C -17.645868,31.12621 -17.635382,31.12621 -17.625,31.125 C -17.614618,31.12621 -17.604132,31.12621 -17.59375,31.125 C -17.581687,31.116371 -17.571129,31.105813 -17.5625,31.09375 C -17.550437,31.085121 -17.539879,31.074563 -17.53125,31.0625 C -17.53004,31.052118 -17.53004,31.041632 -17.53125,31.03125 C -17.53004,31.020868 -17.53004,31.010382 -17.53125,31 L -17.53125,25.15625 C -17.53004,25.145868 -17.53004,25.135382 -17.53125,25.125 C -17.53004,25.114618 -17.53004,25.104132 -17.53125,25.09375 C -17.539879,25.081687 -17.550437,25.071129 -17.5625,25.0625 C -17.571129,25.050437 -17.581687,25.039879 -17.59375,25.03125 C -17.604132,25.03004 -17.614618,25.03004 -17.625,25.03125 C -17.635382,25.03004 -17.645868,25.03004 -17.65625,25.03125 L -23.75,25.03125 C -23.760382,25.03004 -23.770868,25.03004 -23.78125,25.03125 C -23.791632,25.03004 -23.802118,25.03004 -23.8125,25.03125 z "
- transform="matrix(0.849895,0,0,0.835205,41.34595,5.61814)"
- inkscape:href="#text2215" />
- </g>
-</svg>
diff --git a/src/icons/dialog-question.svg b/src/icons/dialog-question.svg
deleted file mode 100644
index 351106e..0000000
--- a/src/icons/dialog-question.svg
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!-- Created with Inkscape (http://www.inkscape.org/) -->
-<svg
- xmlns:dc="http://purl.org/dc/elements/1.1/"
- xmlns:cc="http://web.resource.org/cc/"
- xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:svg="http://www.w3.org/2000/svg"
- xmlns="http://www.w3.org/2000/svg"
- xmlns:xlink="http://www.w3.org/1999/xlink"
- xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
- xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
- width="48px"
- height="48px"
- id="svg1800"
- sodipodi:version="0.32"
- inkscape:version="0.43"
- sodipodi:docbase="D:\workspaces\default\Looks\src\icons"
- sodipodi:docname="dialog-question.svg"
- inkscape:export-filename="D:\temp\tango-icon-theme-0.7.2\48x48\dialog-question.png"
- inkscape:export-xdpi="90"
- inkscape:export-ydpi="90">
- <defs
- id="defs3">
- <linearGradient
- id="linearGradient4126"
- inkscape:collect="always">
- <stop
- id="stop4128"
- offset="0"
- style="stop-color:#000000;stop-opacity:1;" />
- <stop
- id="stop4130"
- offset="1"
- style="stop-color:#000000;stop-opacity:0;" />
- </linearGradient>
- <radialGradient
- inkscape:collect="always"
- xlink:href="#linearGradient4126"
- id="radialGradient3976"
- gradientUnits="userSpaceOnUse"
- gradientTransform="matrix(1,0,0,0.5,1.876291e-14,20)"
- cx="23.857143"
- cy="40.000000"
- fx="23.857143"
- fy="40.000000"
- r="17.142857" />
- <linearGradient
- id="linearGradient2431">
- <stop
- style="stop-color:#ffffff;stop-opacity:1;"
- offset="0"
- id="stop2433" />
- <stop
- style="stop-color:#b8b8b8;stop-opacity:1;"
- offset="1"
- id="stop2435" />
- </linearGradient>
- <radialGradient
- inkscape:collect="always"
- xlink:href="#linearGradient2431"
- id="radialGradient2437"
- cx="-19.515638"
- cy="16.855663"
- fx="-19.515638"
- fy="16.855663"
- r="8.7536434"
- gradientTransform="matrix(4.445991,-8.852599e-16,1.367217e-15,6.8665,67.25071,-104.6679)"
- gradientUnits="userSpaceOnUse" />
- <linearGradient
- inkscape:collect="always"
- id="linearGradient3101">
- <stop
- style="stop-color:#000000;stop-opacity:1;"
- offset="0"
- id="stop3103" />
- <stop
- style="stop-color:#000000;stop-opacity:0;"
- offset="1"
- id="stop3105" />
- </linearGradient>
- <radialGradient
- inkscape:collect="always"
- xlink:href="#linearGradient3101"
- id="radialGradient3107"
- cx="17.3125"
- cy="25.53125"
- fx="17.3125"
- fy="25.53125"
- r="9.6875"
- gradientTransform="matrix(1,0,0,0.351613,7.793249e-16,16.55413)"
- gradientUnits="userSpaceOnUse" />
- </defs>
- <sodipodi:namedview
- fill="#edd400"
- id="base"
- pagecolor="#ffffff"
- bordercolor="#666666"
- borderopacity="0.20392157"
- inkscape:pageopacity="0.0"
- inkscape:pageshadow="2"
- inkscape:zoom="14.729854"
- inkscape:cx="24.298113"
- inkscape:cy="23.52043"
- inkscape:current-layer="layer1"
- showgrid="false"
- inkscape:grid-bbox="true"
- inkscape:document-units="px"
- inkscape:showpageshadow="false"
- inkscape:window-width="891"
- inkscape:window-height="900"
- inkscape:window-x="1284"
- inkscape:window-y="17" />
- <metadata
- id="metadata4">
- <rdf:RDF>
- <cc:Work
- rdf:about="">
- <dc:format>image/svg+xml</dc:format>
- <dc:type
- rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
- <cc:license
- rdf:resource="http://creativecommons.org/licenses/by-sa/2.0/" />
- <dc:title>Emblem Important</dc:title>
- <dc:creator>
- <cc:Agent>
- <dc:title>Jakub Steiner</dc:title>
- </cc:Agent>
- </dc:creator>
- <dc:subject>
- <rdf:Bag>
- <rdf:li>emblem</rdf:li>
- <rdf:li>photos</rdf:li>
- <rdf:li>pictures</rdf:li>
- <rdf:li>raw</rdf:li>
- <rdf:li>jpeg</rdf:li>
- </rdf:Bag>
- </dc:subject>
- </cc:Work>
- <cc:License
- rdf:about="http://creativecommons.org/licenses/by-sa/2.0/">
- <cc:permits
- rdf:resource="http://web.resource.org/cc/Reproduction" />
- <cc:permits
- rdf:resource="http://web.resource.org/cc/Distribution" />
- <cc:requires
- rdf:resource="http://web.resource.org/cc/Notice" />
- <cc:requires
- rdf:resource="http://web.resource.org/cc/Attribution" />
- <cc:permits
- rdf:resource="http://web.resource.org/cc/DerivativeWorks" />
- <cc:requires
- rdf:resource="http://web.resource.org/cc/ShareAlike" />
- </cc:License>
- </rdf:RDF>
- </metadata>
- <g
- id="layer1"
- inkscape:label="Layer 1"
- inkscape:groupmode="layer">
- <path
- inkscape:r_cy="true"
- inkscape:r_cx="true"
- transform="matrix(1.070555,0,0,0.525,-1.434199,20.28442)"
- d="M 41 40 A 17.142857 8.5714283 0 1 1 6.7142868,40 A 17.142857 8.5714283 0 1 1 41 40 z"
- sodipodi:ry="8.5714283"
- sodipodi:rx="17.142857"
- sodipodi:cy="40"
- sodipodi:cx="23.857143"
- id="path6548"
- style="opacity:0.6;color:#000000;fill:url(#radialGradient3976);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:10;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:block;overflow:visible"
- sodipodi:type="arc" />
- <path
- sodipodi:type="arc"
- style="opacity:1.0000000;fill:#65a826;fill-opacity:1;fill-rule:nonzero;stroke:#3b7304;stroke-width:0.98214624;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0.0000000;stroke-opacity:1"
- id="path1650"
- sodipodi:cx="24.130018"
- sodipodi:cy="23.428040"
- sodipodi:rx="22.008699"
- sodipodi:ry="21.213203"
- d="M 46.138718 23.428040 A 22.008699 21.213203 0 1 1 2.1213188,23.428040 A 22.008699 21.213203 0 1 1 46.138718 23.428040 z"
- transform="matrix(0.944630,0.000000,0.000000,0.980053,1.504174,-1.556912)" />
- <path
- sodipodi:type="arc"
- style="opacity:1.0000000;fill:none;fill-opacity:1.0000000;fill-rule:nonzero;stroke:#4e9a06;stroke-width:0.98214942;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-dashoffset:0.0000000;stroke-opacity:1"
- id="path3392"
- sodipodi:cx="24.130018"
- sodipodi:cy="23.428040"
- sodipodi:rx="22.008699"
- sodipodi:ry="21.213203"
- d="M 46.138718 23.428040 A 22.008699 21.213203 0 1 1 2.1213188,23.428040 A 22.008699 21.213203 0 1 1 46.138718 23.428040 z"
- transform="matrix(0.914086,0.000000,0.000000,0.948364,2.380576,-0.905815)" />
- <path
- style="fill:#fffeff;fill-opacity:0.21390374;fill-rule:nonzero;stroke:none;stroke-width:1.0000000;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dashoffset:0.0000000;stroke-opacity:1.0000000"
- d="M 43.676426,20.476780 C 43.676426,31.307396 37.624257,16.170581 25.001688,20.863168 C 12.279172,25.592912 4.4350535,31.307396 4.4350535,20.476780 C 4.4350535,9.6461627 13.225120,0.85609769 24.055740,0.85609769 C 34.886359,0.85609769 43.676426,9.6461627 43.676426,20.476780 z "
- id="path3068"
- sodipodi:nodetypes="czssc" />
- <path
- sodipodi:type="inkscape:offset"
- inkscape:radius="0.13495015"
- inkscape:original="M -20.25 6 C -21.298341 6.000026 -22.372769 6.1244771 -23.5 6.34375 C -24.627244 6.563073 -25.886043 6.8832479 -27.25 7.34375 L -27.25 12.5 C -26.100219 11.776335 -24.997109 11.236862 -23.9375 10.875 C -22.877902 10.502213 -21.881822 10.312521 -20.96875 10.3125 C -19.999334 10.312521 -19.259834 10.530174 -18.71875 10.96875 C -18.177686 11.396402 -17.906262 12.013726 -17.90625 12.78125 C -17.906261 13.285654 -18.039408 13.776881 -18.34375 14.28125 C -18.636843 14.785651 -19.107484 15.33609 -19.75 15.90625 L -20.84375 16.84375 C -22.038631 17.918325 -22.815518 18.829509 -23.1875 19.53125 C -23.559495 20.22205 -23.750005 21.007137 -23.75 21.90625 L -23.75 22.71875 L -17.65625 22.71875 L -17.65625 21.96875 C -17.656262 21.475338 -17.517981 21.030712 -17.28125 20.625 C -17.044542 20.208345 -16.547785 19.648586 -15.78125 18.96875 L -14.71875 18.03125 C -13.659161 17.055386 -12.908389 16.156813 -12.46875 15.3125 C -12.029144 14.457253 -11.781268 13.480828 -11.78125 12.40625 C -11.781268 10.311973 -12.525902 8.7417969 -13.96875 7.65625 C -15.41163 6.559783 -17.499549 6.0000261 -20.25 6 z M -23.75 25.15625 L -23.75 31 L -17.65625 31 L -17.65625 25.15625 L -23.75 25.15625 z "
- xlink:href="#text2215"
- style="font-size:34.15322876px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:url(#radialGradient2437);fill-opacity:1;stroke:#ffffff;stroke-width:1.09947276px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.78612713;font-family:Bitstream Vera Sans"
- id="path1554"
- d="M -20.25,5.875 C -21.309019,5.8750263 -22.397637,5.9982356 -23.53125,6.21875 C -24.664175,6.4391783 -25.911412,6.7562625 -27.28125,7.21875 C -27.291632,7.21754 -27.302118,7.21754 -27.3125,7.21875 C -27.324563,7.2273788 -27.335121,7.237937 -27.34375,7.25 C -27.355813,7.2586288 -27.366371,7.269187 -27.375,7.28125 C -27.37621,7.2916315 -27.37621,7.3021185 -27.375,7.3125 C -27.37621,7.3228815 -27.37621,7.3333685 -27.375,7.34375 L -27.375,12.5 C -27.37621,12.510382 -27.37621,12.520868 -27.375,12.53125 C -27.37621,12.541632 -27.37621,12.552118 -27.375,12.5625 C -27.366371,12.574563 -27.355813,12.585121 -27.34375,12.59375 C -27.335121,12.605813 -27.324563,12.616371 -27.3125,12.625 C -27.302118,12.62621 -27.291632,12.62621 -27.28125,12.625 C -27.270868,12.62621 -27.260382,12.62621 -27.25,12.625 C -27.239618,12.62621 -27.229132,12.62621 -27.21875,12.625 C -27.208368,12.62621 -27.197882,12.62621 -27.1875,12.625 C -26.045062,11.905957 -24.954148,11.357862 -23.90625,11 C -22.858109,10.631244 -21.863134,10.437521 -20.96875,10.4375 C -20.019532,10.437521 -19.323825,10.648045 -18.8125,11.0625 C -18.303777,11.46459 -18.031262,12.04554 -18.03125,12.78125 C -18.03126,13.261907 -18.175438,13.73266 -18.46875,14.21875 C -18.751741,14.705766 -19.209015,15.249245 -19.84375,15.8125 L -20.9375,16.75 C -22.138959,17.83049 -22.926743,18.741022 -23.3125,19.46875 C -23.695613,20.180196 -23.875005,20.988074 -23.875,21.90625 L -23.875,22.71875 C -23.87621,22.729132 -23.87621,22.739618 -23.875,22.75 C -23.87621,22.760382 -23.87621,22.770868 -23.875,22.78125 C -23.866371,22.793313 -23.855813,22.803871 -23.84375,22.8125 C -23.835121,22.824563 -23.824563,22.835121 -23.8125,22.84375 C -23.802118,22.84496 -23.791632,22.84496 -23.78125,22.84375 C -23.770868,22.84496 -23.760382,22.84496 -23.75,22.84375 L -17.65625,22.84375 C -17.645868,22.84496 -17.635382,22.84496 -17.625,22.84375 C -17.614618,22.84496 -17.604132,22.84496 -17.59375,22.84375 C -17.581687,22.835121 -17.571129,22.824563 -17.5625,22.8125 C -17.550437,22.803871 -17.539879,22.793313 -17.53125,22.78125 C -17.53004,22.770868 -17.53004,22.760382 -17.53125,22.75 C -17.53004,22.739618 -17.53004,22.729132 -17.53125,22.71875 L -17.53125,21.96875 C -17.531261,21.500554 -17.38288,21.075901 -17.15625,20.6875 C -16.933955,20.296216 -16.448177,19.737141 -15.6875,19.0625 L -14.625,18.125 C -13.558412,17.14269 -12.794341,16.240346 -12.34375,15.375 C -11.894481,14.500954 -11.656268,13.50158 -11.65625,12.40625 C -11.656268,10.279985 -12.400019,8.6722224 -13.875,7.5625 C -15.350197,6.4414748 -17.48124,5.8750263 -20.25,5.875 z M -23.8125,25.03125 C -23.824563,25.039879 -23.835121,25.050437 -23.84375,25.0625 C -23.855813,25.071129 -23.866371,25.081687 -23.875,25.09375 C -23.87621,25.104132 -23.87621,25.114618 -23.875,25.125 C -23.87621,25.135382 -23.87621,25.145868 -23.875,25.15625 L -23.875,31 C -23.87621,31.010382 -23.87621,31.020868 -23.875,31.03125 C -23.87621,31.041632 -23.87621,31.052118 -23.875,31.0625 C -23.866371,31.074563 -23.855813,31.085121 -23.84375,31.09375 C -23.835121,31.105813 -23.824563,31.116371 -23.8125,31.125 C -23.802118,31.12621 -23.791632,31.12621 -23.78125,31.125 C -23.770868,31.12621 -23.760382,31.12621 -23.75,31.125 L -17.65625,31.125 C -17.645868,31.12621 -17.635382,31.12621 -17.625,31.125 C -17.614618,31.12621 -17.604132,31.12621 -17.59375,31.125 C -17.581687,31.116371 -17.571129,31.105813 -17.5625,31.09375 C -17.550437,31.085121 -17.539879,31.074563 -17.53125,31.0625 C -17.53004,31.052118 -17.53004,31.041632 -17.53125,31.03125 C -17.53004,31.020868 -17.53004,31.010382 -17.53125,31 L -17.53125,25.15625 C -17.53004,25.145868 -17.53004,25.135382 -17.53125,25.125 C -17.53004,25.114618 -17.53004,25.104132 -17.53125,25.09375 C -17.539879,25.081687 -17.550437,25.071129 -17.5625,25.0625 C -17.571129,25.050437 -17.581687,25.039879 -17.59375,25.03125 C -17.604132,25.03004 -17.614618,25.03004 -17.625,25.03125 C -17.635382,25.03004 -17.645868,25.03004 -17.65625,25.03125 L -23.75,25.03125 C -23.760382,25.03004 -23.770868,25.03004 -23.78125,25.03125 C -23.791632,25.03004 -23.802118,25.03004 -23.8125,25.03125 z "
- transform="matrix(0.849895,0,0,0.835205,41.34595,5.61814)"
- inkscape:href="#text2215" />
- </g>
-</svg>
diff --git a/src/test/com/jgoodies/looks/tests/AllLooksTests.java b/src/test/com/jgoodies/looks/tests/AllLooksTests.java
deleted file mode 100644
index 8730b1d..0000000
--- a/src/test/com/jgoodies/looks/tests/AllLooksTests.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.tests;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * A test suite for all tests related to the JGoodies Looks.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.9 $
- */
- at RunWith(Suite.class)
- at Suite.SuiteClasses({
- FontsTest.class,
- OptionsTest.class
-})
-public final class AllLooksTests {
-
- // Just a suite definition class.
-
-}
diff --git a/src/test/com/jgoodies/looks/tests/FontTest.java b/src/test/com/jgoodies/looks/tests/FontTest.java
deleted file mode 100644
index 81d8f77..0000000
--- a/src/test/com/jgoodies/looks/tests/FontTest.java
+++ /dev/null
@@ -1,322 +0,0 @@
-package com.jgoodies.looks.tests;
-
-
-import java.awt.*;
-import java.util.Locale;
-
-import javax.swing.*;
-import javax.swing.text.JTextComponent;
-
-import com.jgoodies.common.base.SystemUtils;
-import com.jgoodies.looks.FontSet;
-import com.jgoodies.looks.Fonts;
-import com.jgoodies.looks.LookUtils;
-import com.jgoodies.looks.plastic.PlasticLookAndFeel;
-import com.jgoodies.looks.plastic.PlasticXPLookAndFeel;
-import com.jgoodies.looks.windows.WindowsLookAndFeel;
-
-
-/**
- * An application that displays the system configuration
- * and font information in a JTextArea. These information
- * may help me understand the font setup on Chinese, Japanese,
- * Korean and other non-western Windows editions.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.2 $
- */
-public final class FontTest {
-
- private JTextComponent textArea;
-
-
- // Launching **************************************************************
-
- /**
- * Builds and the UI.
- */
- public static void main(String[] args) {
- FontTest instance = new FontTest();
- instance.buildInterface();
- }
-
-
- // Building the UI ********************************************************
-
- private void initComponents() {
- textArea = new JTextArea();
- textArea.setText(readConfiguration());
- }
-
-
- /**
- * Creates and configures a frame, builds the menu bar, builds the
- * content, locates the frame on the screen, and finally shows the frame.
- */
- private void buildInterface() {
- initComponents();
-
- JFrame frame = new JFrame();
- frame.setContentPane(buildContentPane());
- frame.setSize(400, 600);
- locateOnScreen(frame);
- frame.setTitle("JGoodies Looks :: FontTest");
- frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
- frame.setVisible(true);
- }
-
-
- private JComponent buildContentPane() {
- JPanel panel = new JPanel(new BorderLayout());
- panel.add(new JScrollPane(textArea), BorderLayout.CENTER);
- return panel;
- }
-
-
- /**
- * Locates the frame on the screen center.
- */
- private static void locateOnScreen(Frame frame) {
- Dimension paneSize = frame.getSize();
- Dimension screenSize = frame.getToolkit().getScreenSize();
- frame.setLocation(
- (screenSize.width - paneSize.width) / 2,
- (screenSize.height - paneSize.height) / 2);
- }
-
-
- // Configuration **********************************************************
-
- private static String readConfiguration() {
- StringBuffer buffer = new StringBuffer();
-
- buffer.append("Please copy the information below to your clipboard");
- buffer.append("\nand send them to dev at looks.dev.java.net");
-
- addSystemProperties(buffer, "Java environment:",
- new String[]{
- "java.vendor",
- "java.version",
- "java.runtime.version",
- "java.vm.version",
- "sun.desktop"});
-
- addSystemProperties(buffer, "Operating System:",
- new String[]{
- "os.name",
- "os.version"});
- if (SystemUtils.IS_OS_WINDOWS) {
- addWindowsSettings(buffer, "Windows Settings:");
- }
-
- addAWTProperties(buffer, "AWT Properties:");
-
- addSystemProperties(buffer, "User Settings:",
- new String[]{
- "user.language",
- "user.country",
- "user.timezone"});
-
- addDesktopProperties(buffer, "Desktop Properties:",
- new String[]{
- "win.defaultGUI.font",
- "win.icon.font",
- "win.menu.font",
- "win.messagebox.font",
- "win.ansiVar.font",
- "win.ansiFixed.font",
- "win.frame.captionFont",
- "win.tooltip.font"});
-
- addInternationalizationProperties(buffer);
-
- addFontSet(buffer, "JGoodies Windows L&f:", getWindowsFontSet());
- addFontSet(buffer, "JGoodies Plastic L&fs:", getPlasticFontSet());
-
- buffer.append("\n\n");
- return buffer.toString();
- }
-
-
- private static void addSystemProperties(StringBuffer buffer, String description, String[] keys) {
- buffer.append("\n\n");
- buffer.append(description);
- for (String key : keys) {
- String value = LookUtils.getSystemProperty(key, "n/a");
- buffer.append("\n ");
- buffer.append(key);
- buffer.append('=');
- buffer.append(value);
- }
- }
-
-
- private static void addDesktopProperties(StringBuffer buffer, String description, String[] keys) {
- Toolkit toolkit = Toolkit.getDefaultToolkit();
- buffer.append("\n\n");
- buffer.append(description);
- for (String key : keys) {
- Object value = toolkit.getDesktopProperty(key);
- String printString;
- if (value == null) {
- printString = "n/a";
- } else if (value instanceof Font) {
- printString = encodeFont((Font) value);
- } else {
- printString = value.toString();
- }
- buffer.append("\n ");
- buffer.append(key);
- buffer.append('=');
- buffer.append(printString);
- }
- }
-
-
- private static void addInternationalizationProperties(StringBuffer buffer) {
- Toolkit toolkit = Toolkit.getDefaultToolkit();
- buffer.append("\n\n");
- buffer.append("Internationalization:");
- Locale locale = Locale.getDefault();
- buffer.append("\n defaultLocale.getDisplayName(Locale.ENGLISH)=");
- buffer.append(locale.getDisplayName(Locale.ENGLISH));
- buffer.append("\n defaultLocale.getDisplayLanguage(Locale.ENGLISH)=");
- buffer.append(locale.getDisplayLanguage(Locale.ENGLISH));
- buffer.append("\n defaultLocale.getDisplayLanguage(defaultLocale)=");
- buffer.append(locale.getDisplayLanguage(locale));
- buffer.append("\n locale has localized display language=" + localeHasLocalizedDisplayLanguage(locale));
- Font defaultGUIFont = (Font) toolkit.getDesktopProperty("win.defaultGUI.font");
- if (defaultGUIFont != null) {
- buffer.append("\n defaultGUI font can display localized text=");
- buffer.append(yesNoDontKnow(Fonts.canDisplayLocalizedText(defaultGUIFont, locale)));
- }
- Font iconFont = (Font) toolkit.getDesktopProperty("win.icon.font");
- if (iconFont != null) {
- buffer.append("\n icon font can display localized text=");
- buffer.append(yesNoDontKnow(Fonts.canDisplayLocalizedText(iconFont, locale)));
- }
- }
-
-
- private static String yesNoDontKnow(Boolean b) {
- if (Boolean.TRUE.equals(b)) {
- return "yes";
- } else if (Boolean.FALSE.equals(b)) {
- return "no";
- } else {
- return "don't know";
- }
- }
-
-
- private static void addFontSet(StringBuffer buffer, String description, FontSet fontSet) {
- buffer.append("\n\n");
- buffer.append(description);
- if (fontSet == null) {
- buffer.append("\n n/a");
- return;
- }
- buffer.append("\n controlFont=");
- buffer.append(encodeFont(fontSet.getControlFont()));
- buffer.append("\n menuFont=");
- buffer.append(encodeFont(fontSet.getMenuFont()));
- buffer.append("\n titleFont=");
- buffer.append(encodeFont(fontSet.getTitleFont()));
- buffer.append("\n messageFont=");
- buffer.append(encodeFont(fontSet.getMessageFont()));
- buffer.append("\n smallFont=");
- buffer.append(encodeFont(fontSet.getSmallFont()));
- buffer.append("\n windowTitleFont=");
- buffer.append(encodeFont(fontSet.getWindowTitleFont()));
- }
-
-
- private static void addWindowsSettings(StringBuffer buffer, String description) {
- buffer.append("\n\n");
- buffer.append(description);
- buffer.append("\n Modern Windows=");
- buffer.append(LookUtils.IS_OS_WINDOWS_MODERN);
- buffer.append("\n Windows XP=");
- buffer.append(SystemUtils.IS_OS_WINDOWS_XP);
- buffer.append("\n Windows 6 or later=");
- buffer.append(SystemUtils.IS_OS_WINDOWS_6_OR_LATER);
- buffer.append("\n Windows L&f XP Mode=");
- buffer.append(SystemUtils.IS_LAF_WINDOWS_XP_ENABLED);
- }
-
-
- private static void addAWTProperties(StringBuffer buffer, String description) {
- Toolkit toolkit = Toolkit.getDefaultToolkit();
- buffer.append("\n\n");
- buffer.append(description);
- buffer.append("\n awt.toolkit=");
- buffer.append(toolkit.getClass().getName());
- buffer.append("\n screen.size=");
- buffer.append(toolkit.getScreenSize().width);
- buffer.append(" x ");
- buffer.append(toolkit.getScreenSize().height);
- buffer.append("\n screen.resolution=");
- buffer.append(toolkit.getScreenResolution());
- buffer.append(" ");
- buffer.append(SystemUtils.IS_LOW_RESOLUTION ? "(low)" : "(high)");
- }
-
-
- private static String encodeFont(Font font) {
- StringBuffer buffer = new StringBuffer(font.getName());
- buffer.append('-');
- String style = font.isBold()
- ? font.isItalic() ? "bolditalic" : "bold"
- : font.isItalic() ? "italic" : "plain";
- buffer.append(style);
- buffer.append('-');
- buffer.append(font.getSize());
- if (!font.getName().equals(font.getFamily())) {
- buffer.append(" family=");
- buffer.append(font.getFamily());
- }
- return buffer.toString();
- }
-
-
- private static FontSet getWindowsFontSet() {
- try {
- UIManager.setLookAndFeel(new WindowsLookAndFeel());
- return WindowsLookAndFeel.getFontPolicy().getFontSet("Windows", UIManager.getDefaults());
- } catch (UnsupportedLookAndFeelException e) {
- return null;
- }
- }
-
-
- private static FontSet getPlasticFontSet() {
- try {
- UIManager.setLookAndFeel(new PlasticXPLookAndFeel());
- return PlasticLookAndFeel.getFontPolicy().getFontSet("Plastic", UIManager.getDefaults());
- } catch (UnsupportedLookAndFeelException e) {
- return null;
- }
- }
-
-
- // Helper Code ************************************************************
-
- /**
- * Checks and answers whether the locale's display language
- * is available in a localized form, for example "Deutsch" for the
- * German locale.
- *
- * @param locale the Locale to test
- * @return true if the display language is localized, false if not
- */
- private static boolean localeHasLocalizedDisplayLanguage(Locale locale) {
- if (locale.getLanguage().equals(Locale.ENGLISH.getLanguage())) {
- return true;
- }
- String englishDisplayLanguage = locale.getDisplayLanguage(Locale.ENGLISH);
- String localizedDisplayLanguage = locale.getDisplayLanguage(locale);
- return !englishDisplayLanguage.equals(localizedDisplayLanguage);
- }
-
-
-}
\ No newline at end of file
diff --git a/src/test/com/jgoodies/looks/tests/FontsTest.java b/src/test/com/jgoodies/looks/tests/FontsTest.java
deleted file mode 100644
index 219a55d..0000000
--- a/src/test/com/jgoodies/looks/tests/FontsTest.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.tests;
-
-import java.awt.Font;
-import java.util.Locale;
-
-import junit.framework.TestCase;
-
-import com.jgoodies.looks.Fonts;
-
-/**
- * A test case for class {@link Fonts}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.6 $
- */
-public final class FontsTest extends TestCase {
-
- /**
- * Checks the localization display test for a bunch of combinations
- * of font and locale.
- */
- public static void testCanDisplayLocalizedText() {
- Font tahoma = new Font("Tahoma", Font.PLAIN, 12);
- if (tahoma.getName().equals(tahoma.getFontName())) {
- canDisplayLocalizedText(tahoma, Locale.ENGLISH, true);
- canDisplayLocalizedText(tahoma, Locale.GERMAN, true);
- canDisplayLocalizedText(tahoma, Locale.FRENCH, true);
- canDisplayLocalizedText(tahoma, Locale.ITALIAN, true);
- canDisplayLocalizedText(tahoma, Locale.CHINESE, false);
- canDisplayLocalizedText(tahoma, Locale.SIMPLIFIED_CHINESE, false);
- canDisplayLocalizedText(tahoma, Locale.TRADITIONAL_CHINESE, false);
- canDisplayLocalizedText(tahoma, Locale.JAPANESE, false);
- canDisplayLocalizedText(tahoma, Locale.KOREAN, false);
- }
- Font msSansSerif = new Font("Microsoft Sans Serif", Font.PLAIN, 12);
- if (msSansSerif.getName().equals(msSansSerif.getFontName())) {
- canDisplayLocalizedText(msSansSerif, Locale.ENGLISH, true);
- canDisplayLocalizedText(msSansSerif, Locale.GERMAN, true);
- canDisplayLocalizedText(msSansSerif, Locale.FRENCH, true);
- canDisplayLocalizedText(msSansSerif, Locale.ITALIAN, true);
- canDisplayLocalizedText(msSansSerif, Locale.CHINESE, false);
- canDisplayLocalizedText(msSansSerif, Locale.SIMPLIFIED_CHINESE, false);
- canDisplayLocalizedText(msSansSerif, Locale.TRADITIONAL_CHINESE, false);
- canDisplayLocalizedText(msSansSerif, Locale.JAPANESE, false);
- canDisplayLocalizedText(msSansSerif, Locale.KOREAN, false);
- }
- }
-
-
- private static void canDisplayLocalizedText(Font font, Locale locale, boolean expectedResult) {
- boolean result = Boolean.TRUE.equals(Fonts.canDisplayLocalizedText(font, locale));
- assertEquals("Failed display test. Font=" + font + "; Locale=" + locale,
- expectedResult,
- result);
- }
-
-
-}
diff --git a/src/test/com/jgoodies/looks/tests/OptionsTest.java b/src/test/com/jgoodies/looks/tests/OptionsTest.java
deleted file mode 100644
index 1430bcd..0000000
--- a/src/test/com/jgoodies/looks/tests/OptionsTest.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (c) 2001-2012 JGoodies Karsten Lentzsch. All Rights Reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * o Redistributions of source code must retain the above copyright notice,
- * this list of conditions and the following disclaimer.
- *
- * o Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- *
- * o Neither the name of JGoodies Karsten Lentzsch nor the names of
- * its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
- * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-package com.jgoodies.looks.tests;
-
-import javax.swing.UIManager;
-
-import junit.framework.TestCase;
-
-import com.jgoodies.looks.LookUtils;
-import com.jgoodies.looks.Options;
-
-/**
- * A test case for class {@link Options}.
- *
- * @author Karsten Lentzsch
- * @version $Revision: 1.7 $
- */
-public final class OptionsTest extends TestCase {
-
-
- /**
- * Checks that tab icons can be enabled and disabled via the Options.
- */
- public static void testTabIconsEnablement() {
- Boolean systemDefault = LookUtils.getBooleanSystemProperty(
- Options.TAB_ICONS_ENABLED_KEY,
- "Test: tab icons");
-
- if (systemDefault != null) {
- assertEquals("Tab icon enablement honors system property.",
- systemDefault.booleanValue(),
- Options.isTabIconsEnabled());
- return;
- }
- UIManager.put(Options.TAB_ICONS_ENABLED_KEY, null);
- assertTrue("Tab icons are enabled by default.", Options.isTabIconsEnabled());
-
- Options.setTabIconsEnabled(true);
- assertTrue("Tab icons are enabled.", Options.isTabIconsEnabled());
-
- Options.setTabIconsEnabled(false);
- assertFalse("Tab icons are disabled.", Options.isTabIconsEnabled());
- }
-
-
-}
--
libjgoodies-looks-java packaging
More information about the pkg-java-commits
mailing list