|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.alee.utils.ProprietaryUtils
public final class ProprietaryUtils
This utility class operates only with proprietary API calls. Their usage is inevitable, otherwise i would have replaced them with something else.
Field Summary | |
---|---|
static int |
HEAVY_WEIGHT_POPUP
|
static int |
LIGHT_WEIGHT_POPUP
Key used to indicate a light weight popup should be used. |
static int |
MEDIUM_WEIGHT_POPUP
Key used to indicate a medium weight Popup should be used. |
Constructor Summary | |
---|---|
ProprietaryUtils()
|
Method Summary | |
---|---|
static javax.swing.Popup |
createHeavyweightPopup(java.awt.Component invoker,
java.awt.Component content,
int x,
int y)
Returns heavyweight popup instance. |
static float |
getWindowOpacity(java.awt.Window window)
Returns window opacity. |
static boolean |
isAllowLinuxTransparency()
Returns whether per-pixel transparent windows usage is allowed on Linux systems or not. |
static boolean |
isWindowOpaque(java.awt.Window window)
Returns whether window is opaque or not. |
static boolean |
isWindowTransparencyAllowed()
Returns whether window transparency is supported on current OS or not. |
static void |
setAllowLinuxTransparency(boolean allow)
Sets whether per-pixel transparent windows usage is allowed on Linux systems or not. |
protected static void |
setupOpacityBackgroundColor(boolean opaque,
java.awt.Component component)
Changes component background color to match opacity. |
static void |
setupUIDefaults(javax.swing.UIDefaults table)
Installs some proprietary L&F defaults for proper text rendering. |
static void |
setWindowOpacity(java.awt.Window window,
float opacity)
Sets window opacity if that option is supported by the underlying system. |
static void |
setWindowOpaque(java.awt.Window window,
boolean opaque)
Sets window opaque if that option is supported by the underlying system. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int LIGHT_WEIGHT_POPUP
public static final int MEDIUM_WEIGHT_POPUP
public static final int HEAVY_WEIGHT_POPUP
Constructor Detail |
---|
public ProprietaryUtils()
Method Detail |
---|
public static boolean isAllowLinuxTransparency()
public static void setAllowLinuxTransparency(boolean allow)
allow
- whether per-pixel transparent windows usage is allowed on Linux systems or notpublic static void setupUIDefaults(javax.swing.UIDefaults table)
table.put ( sun.swing.SwingUtilities2.AA_TEXT_PROPERTY_KEY, sun.swing.SwingUtilities2.AATextInfo.getAATextInfo ( true ) );
but it doesn't directly use any proprietary API.
table
- defaults tablepublic static boolean isWindowTransparencyAllowed()
public static void setWindowOpaque(java.awt.Window window, boolean opaque)
window
- window to processopaque
- whether should make window opaque or notprotected static void setupOpacityBackgroundColor(boolean opaque, java.awt.Component component) throws java.lang.NoSuchMethodException, java.lang.reflect.InvocationTargetException, java.lang.IllegalAccessException
opaque
- whether component should should be opaque or notcomponent
- component to process
java.lang.NoSuchMethodException
java.lang.reflect.InvocationTargetException
java.lang.IllegalAccessException
public static boolean isWindowOpaque(java.awt.Window window)
window
- window to process
public static void setWindowOpacity(java.awt.Window window, float opacity)
window
- window to processopacity
- new window opacitypublic static float getWindowOpacity(java.awt.Window window)
window
- window to process
public static javax.swing.Popup createHeavyweightPopup(java.awt.Component invoker, java.awt.Component content, int x, int y)
invoker
- invoker componentcontent
- popup contentx
- popup initial location X coordinatey
- popup initial location Y coordinate
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |