Package javax.swing

Examples of javax.swing.LookAndFeel


        assertTrue(createAudioAction instanceof BasicLookAndFeel.AudioAction);
        assertTrue(lf.createAudioAction("CheckBoxMenuItem.commandSound") instanceof BasicLookAndFeel.AudioAction);
    }

    private LookAndFeel lookAndFeelInstance() {
        return new LookAndFeel() {
            @Override
            public String getDescription() {
                return null;
            }
View Full Code Here


        }
      }
    }
  }
  public static void playSound(JComponent c, Object actionKey) {
    LookAndFeel laf = UIManager.getLookAndFeel();
    if (laf instanceof Win32LookAndFeel) {
      Object[] audioStrings = (Object[])UIManager.get("AuditoryCues.playList");
      if (audioStrings != null){
        for (int i = 0; i < audioStrings.length; i++) {
          if (actionKey.equals(audioStrings[i])){
View Full Code Here

        return UIManager.getLookAndFeel().getID().equals("Aqua");
    }


    static void ensureValidCache() {
        LookAndFeel currentLookAndFeel = UIManager.getLookAndFeel();
        if (currentLookAndFeel != cachedLookAndFeel) {
            clearLookAndFeelBasedCaches();
            cachedLookAndFeel = currentLookAndFeel;
        }
    }
View Full Code Here

        }
      }
    }
  }
  public static void playSound(JComponent c, Object actionKey) {
    LookAndFeel laf = UIManager.getLookAndFeel();
    if (laf instanceof Win32LookAndFeel) {
      Object[] audioStrings = (Object[])UIManager.get("AuditoryCues.playList");
      if (audioStrings != null){
        for (int i = 0; i < audioStrings.length; i++) {
          if (actionKey.equals(audioStrings[i])){
View Full Code Here

        return UIManager.getLookAndFeel().getID().equals("Aqua");
    }


    static void ensureValidCache() {
        LookAndFeel currentLookAndFeel = UIManager.getLookAndFeel();
        if (currentLookAndFeel != cachedLookAndFeel) {
            clearLookAndFeelBasedCaches();
            cachedLookAndFeel = currentLookAndFeel;
        }
    }
View Full Code Here

        }
      }
    }
  }
  public static void playSound(JComponent c, Object actionKey) {
    LookAndFeel laf = UIManager.getLookAndFeel();
    if (laf instanceof Win32LookAndFeel) {
      Object[] audioStrings = (Object[])UIManager.get("AuditoryCues.playList");
      if (audioStrings != null){
        for (int i = 0; i < audioStrings.length; i++) {
          if (actionKey.equals(audioStrings[i])){
View Full Code Here

    SwingUtilities.invokeLater(new Runnable() {

      @Override
      public void run() {
        try {
          LookAndFeel laf = LookAndFeels.LOOK_AND_FEELS
              .get(PropertiesManager.getProperty("laf"));
          LOGGER.debug("Using look and feel " + laf);
          UIManager.setLookAndFeel(laf);
        } catch (UnsupportedLookAndFeelException e) {
          LOGGER.exception("Error setting look and feel", e);
View Full Code Here

   *
   * @throws ClassNotFoundException
   *             If the class could not be found.
   */
  public static void loadLookAndFeel() throws ClassNotFoundException {
    LookAndFeel laf = UIManager.getLookAndFeel();
    if (laf == null) {
      return; // never null
    }
    ClassLoader cl = laf.getClass().getClassLoader();
    if (cl == null) {
      return; // null for system class loader (?)
    }

    // Does not work: cl.getClass().equals(JarClassLoader.class)
View Full Code Here

   * /015374.html
   *
   * @throws ClassNotFoundException If the class could not be found.
   */
  public static void loadLookAndFeel() throws ClassNotFoundException {
    LookAndFeel laf = UIManager.getLookAndFeel();
    if (laf == null) {
      return; // never null
    }
    ClassLoader cl = laf.getClass().getClassLoader();
    if (cl == null) {
      return; // null for system class loader (?)
    }

    // Does not work: cl.getClass().equals(JarClassLoader.class)
View Full Code Here

          // JNLP sandbox
        }

        try {
          if (!hasLafSpecified) {
            LookAndFeel laf = new SubstanceGeminiLookAndFeel();
            UIManager.setLookAndFeel(laf);
          }
        } catch (Exception e) {
          e.printStackTrace();
        }
View Full Code Here

TOP

Related Classes of javax.swing.LookAndFeel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.