Package javax.help

Examples of javax.help.HelpSet


    try {
       
      ClassLoader cl = HelpDialog.class.getClassLoader();
            java.net.URL hsURL = javax.help.HelpSet.findHelpSet(cl, "jHelpSet.hs");
           
            HelpSet hs = new HelpSet(cl, hsURL);
            hs.setTitle(DcResources.getText("lblHelp"));
           
            DefaultHelpBroker hb = new DefaultHelpBroker();
            hb.setHelpSet(hs);
            hb.setActivationWindow(window);
            hb.setCurrentID(helpIndex);
View Full Code Here


      GUIUtils.defaultInitialization(locale);

      InternationalizationManager.addLanguageFile("resources/builder/builder");
      ImageIconFactory.addSearchPath("resources/builder/icons");
      Widget.setHelpSet(
        new HelpSet(
          cl,
          HelpSet.findHelpSet(cl, "resources/builder/help/builder." + locale.toString() + ".hs")));
      new Builder();
    } catch (Exception e) {
      new MessageDialog(e);
View Full Code Here

    public void showHelpTopic(String topic) {
        // TODO: use the "topic" argument to pick an initial page
        try {
            URL url = HelpSet.findHelpSet(null, "LightZone.hs");
            HelpSet help = new HelpSet(null, url);
            String title = help.getTitle();
            JHelp jhelp = new JHelp(help);
            help.setHomeID("index");
            try {
                jhelp.setCurrentID(topic);
            }
            catch (Throwable t) {
                jhelp.setCurrentID("index");
View Full Code Here

   */
  final void initHelpMenu() {
    try {
      ClassLoader cl = MenuBarBuilderImpl.class.getClassLoader();
      URL url = HelpSet.findHelpSet(cl, HELPSET_NAME);
      mainHS = new HelpSet(cl, url);
    } catch (Exception ee) {
      System.out.println("Help Set " + HELPSET_NAME + " not found");
      return;
    } catch (ExceptionInInitializerError ex) {
      System.err.println("initialization error:");
View Full Code Here

           
            return eRetVal;
        }

        private HelpBroker _getHelpBroker( MainJFrame pMainJFrame_ ) {
            HelpSet pHelpSet = null;
            String  sHSFile  = pMainJFrame_.getInit()
                                           .getHelpBrokerURL();
            try {
                URL urlHelpSet = new URL( sHSFile );
                Util.debug( this, "_getHelpBroker(..).urlHelpSet: " +
                            urlHelpSet );
                pHelpSet = new HelpSet( null, urlHelpSet );
               
                /*sHSFile = pMainJFrame_.getClass().getName();
                int lastDot = sHSFile.lastIndexOf( '.' );
                if ( lastDot == -1 ) {
                    sHSFile = "/doc";
                } else {
                    sHSFile = "/"
                               + sHSFile.substring( 0, lastDot )
                                        .replace( '.', '/' );
                }
                sHSFile += pMainJFrame_.getInit()
                                       .getApplicationName()
                                       .toLower()
                           + ".hs";
                pHelpSet = HelpSet.findHelpSet( null, sHSFile );*/
            } catch( Exception pException ) {
                Util.printlnErr( "HelpSet " + sHSFile +
                                 " not found!" );
            }
            HelpBroker pHelpBroker = pHelpSet.createHelpBroker();
           
            return pHelpBroker;
        }
View Full Code Here

      return;


  if (ConsoleHelp.helpLoaded())  {
            HelpBroker hb = ConsoleHelp.hb[ConsoleHelp.CONSOLE_HELP];
            HelpSet hs = ConsoleHelp.hs[ConsoleHelp.CONSOLE_HELP];
            helpButton.addActionListener(ConsoleHelp.hl[ConsoleHelp.CONSOLE_HELP]);
            // go to a specific area of overview.
            hb.enableHelp(helpButton, helpId, hs);

      helpButton.setEnabled(true);
View Full Code Here

      try {
          URL hsURL = HelpSet.findHelpSet(null, fileName);
    if (hsURL == null)  {
        return;
    }
          hs[i] = new HelpSet(null, hsURL);
          hb[i] = hs[i].createHelpBroker();
          hl[i] = new CSH.DisplayHelpFromSource(hb[i]);

      } catch (Exception e) {
    System.err.println("HelpSet " + fileName + " not found.");
View Full Code Here

  overviewItem = new JMenuItem(acr.getString(acr.I_OVERVIEW));
  overviewItem.setText(acr.getString(acr.I_MENU_OVERVIEW));
  helpMenu.add(overviewItem);
  if (ConsoleHelp.helpLoaded())  {
      HelpBroker hb = ConsoleHelp.hb[ConsoleHelp.CONSOLE_HELP];
      HelpSet hs = ConsoleHelp.hs[ConsoleHelp.CONSOLE_HELP];
      overviewItem.addActionListener(ConsoleHelp.hl[ConsoleHelp.CONSOLE_HELP]);
      // go to a specific area of overview.
      hb.enableHelp(overviewItem, ConsoleHelpID.INTRO, hs);
  } else {
      overviewItem.setEnabled(false);
View Full Code Here

           }

           GfrCSH._LOGGER_.info("hbrCur.getCurrentView()=" + hbrCur.getCurrentView());


          HelpSet hstCur = hbrCur.getHelpSet();

          if (hstCur == null)
          {
              GfrCSH._LOGGER_.severe("nil hstCur");
              return false;
          }

          ArrayList<Component> altCur = GfrCSH._MAP_HPR2ALT_CMP_SET_ID.get(hbrCur);

          if (altCur == null)
          {
              GfrCSH._LOGGER_.severe("nil altCur");
              return false;
          }

          for (int i=0; i<altCur.size(); i++)
          {
              Component cmpCur = (Component) altCur.get(i);

              if (cmpCur == null)
              {
                  GfrCSH._LOGGER_.severe("nil cmpCur");
                  return false;
              }

              String strIDCur = CSH.getHelpIDString(cmpCur);

              if (strIDCur == null)
              {
                  GfrCSH._LOGGER_.severe("nil strIDCur");
                  return false;
              }

              if (! hstCur.getCombinedMap().isValidID(strIDCur, hstCur))
            {
                blnGotNoValidId = true;
                GfrCSH._LOGGER_.severe("not isValidID strIDCur=" + strIDCur +", ignoring");
                  // continuing in order to get all invalid Ids
            }
View Full Code Here

     *                       localisation extensions.)
     */

    public static HelpSet getHelpSet(String newHelpSetName, ClassLoader loader)
    {
        HelpSet newHelpSet = null;
        try
        {
            URL url = HelpSet.findHelpSet(loader, newHelpSetName);
            if (url != null)
                newHelpSet = new HelpSet(loader, url);
        }
        catch (NoClassDefFoundError ec)
        {
            log.log(Level.WARNING, "Help Broker initialization error: couldn't find help set ", ec);
        }
View Full Code Here

TOP

Related Classes of javax.help.HelpSet

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.