Package org.eclipse.core.runtime.preferences

Examples of org.eclipse.core.runtime.preferences.IPreferencesService


      fContentAssistant
          .setContextInformationPopupOrientation(IContentAssistant.CONTEXT_INFO_ABOVE);
      fContentAssistant
          .setInformationControlCreator(getInformationControlCreator(sourceViewer));

      IPreferencesService preferencesService = Platform
          .getPreferencesService();
      fContentAssistant.enableAutoActivation(preferencesService
          .getBoolean(PHPCorePlugin.ID,
              PHPCoreConstants.CODEASSIST_AUTOACTIVATION, false,
              null));
      fContentAssistant.setAutoActivationDelay(preferencesService.getInt(
          PHPCorePlugin.ID,
          PHPCoreConstants.CODEASSIST_AUTOACTIVATION_DELAY, 0, null));
      fContentAssistant.enableAutoInsert(preferencesService.getBoolean(
          PHPCorePlugin.ID, PHPCoreConstants.CODEASSIST_AUTOINSERT,
          false, null));

      addContentAssistProcessors(sourceViewer);
    }
View Full Code Here


      }
    }

    // reset auto activation delay based on pdt's setting,because it was
    // changed by wtp
    IPreferencesService preferencesService = Platform
        .getPreferencesService();
    int fAutoActivationDelay = preferencesService.getInt(PHPCorePlugin.ID,
        PHPCoreConstants.CODEASSIST_AUTOACTIVATION_DELAY, 200, null);

    fContentAssistant.setAutoActivationDelay(fAutoActivationDelay);
  }
View Full Code Here

        String strColor = AnsiConsoleActivator.getDefault().getPreferenceStore().getString(id);
        return colorFromStringRgb(strColor);
    }

    public static Color getDebugConsoleBgColor() {
        IPreferencesService ps = Platform.getPreferencesService();
        String value = ps.getString(DEBUG_CONSOLE_PLUGIN_ID, "org.eclipse.debug.ui.consoleBackground",
                DEBUG_CONSOLE_FALLBACK_BKCOLOR, null);
        return colorFromStringRgb(value);
    }
View Full Code Here

                DEBUG_CONSOLE_FALLBACK_BKCOLOR, null);
        return colorFromStringRgb(value);
    }

    public static Color getDebugConsoleFgColor() {
        IPreferencesService ps = Platform.getPreferencesService();
        String value = ps.getString(DEBUG_CONSOLE_PLUGIN_ID, "org.eclipse.debug.ui.outColor",
                DEBUG_CONSOLE_FALLBACK_FGCOLOR, null);
        return colorFromStringRgb(value);
    }
View Full Code Here

            .endsWith(IncludeStatementStrategy.FOLDER_SEPARATOR)) {
      // workaround for:
      // https://bugs.eclipse.org/bugs/show_bug.cgi?id=269634
      activateCodeAssist = true;
    } else {
      IPreferencesService preferencesService = Platform
          .getPreferencesService();
      boolean enableAutoactivation = preferencesService.getBoolean(
          PHPCorePlugin.ID,
          PHPCoreConstants.CODEASSIST_AUTOACTIVATION, false, null);
      if (enableAutoactivation) {
        char lastChar = replacementString.charAt(replacementString
            .length() - 1);
View Full Code Here

            PHPStructuredTextViewerConfiguration configuration = (PHPStructuredTextViewerConfiguration) getSourceViewerConfiguration();
            if (configuration != null) {
              StructuredContentAssistant contentAssistant = (StructuredContentAssistant) configuration
                  .getPHPContentAssistant(sourceViewer);

              IPreferencesService preferencesService = Platform
                  .getPreferencesService();
              contentAssistant
                  .enableAutoActivation(preferencesService
                      .getBoolean(
                          PHPCorePlugin.ID,
                          PHPCoreConstants.CODEASSIST_AUTOACTIVATION,
                          false, null));
              contentAssistant
                  .setAutoActivationDelay(preferencesService
                      .getInt(PHPCorePlugin.ID,
                          PHPCoreConstants.CODEASSIST_AUTOACTIVATION_DELAY,
                          0, null));
              contentAssistant
                  .enableAutoInsert(preferencesService
                      .getBoolean(
                          PHPCorePlugin.ID,
                          PHPCoreConstants.CODEASSIST_AUTOINSERT,
                          false, null));
            }
View Full Code Here

   *         TimeoutException in JDI calls. NOTE: This is not in compliance
   *         with the Sun's JDI.
   */
  public int getGlobalRequestTimeout() {
    try {
      IPreferencesService srvc = Platform.getPreferencesService();
      if(srvc != null) {
        return Platform.getPreferencesService().getInt(
            JDIDebugModel.getPluginIdentifier(),
            JDIDebugModel.PREF_REQUEST_TIMEOUT,
            JDIDebugModel.DEF_REQUEST_TIMEOUT,
View Full Code Here

   *            Path to the database files
   * @return
   */
  private String getConnectionString(IPath dbPath) {

    IPreferencesService preferencesService = Platform
        .getPreferencesService();

    StringBuilder buf = new StringBuilder("jdbc:h2:").append(dbPath.append(
        DB_NAME).toOSString());

    buf.append(";UNDO_LOG=0");
    buf.append(";LOCK_MODE=").append(
        preferencesService.getInt(SymfonyIndex.PLUGIN_ID,
            SymfonyIndexPreferences.DB_LOCK_MODE, 0, null));

    buf.append(";CACHE_TYPE=").append(
        preferencesService.getString(SymfonyIndex.PLUGIN_ID,
            SymfonyIndexPreferences.DB_CACHE_TYPE, null, null));

    buf.append(";CACHE_SIZE=").append(
        preferencesService.getInt(SymfonyIndex.PLUGIN_ID,
            SymfonyIndexPreferences.DB_CACHE_SIZE, 0, null));

    return buf.toString();
  }
View Full Code Here

      e.printStackTrace();
    }
  }

  private static File getFolderFromPreferences() {
    IPreferencesService service = Platform.getPreferencesService();
    Preferences node = service.getRootNode().node(ConfigurationScope.SCOPE).node(CoreActivator.PLUGIN_ID);
    if(node!=null) {
      String folderPath = node.get(DesignerCoreConstants.CONFIG_FOLDER_PREFERENCE, null);
      if(folderPath!=null) {
        File file = new File(folderPath);
        if(file!=null && file.isDirectory()) {
View Full Code Here

    }
    return null;
  }

  public static void saveFolderToPreferences(String folderPath) {
    IPreferencesService service = Platform.getPreferencesService();
    Preferences node = service.getRootNode().node(ConfigurationScope.SCOPE).node(CoreActivator.PLUGIN_ID);
    try {
      if(node!=null) {
        node.put(DesignerCoreConstants.CONFIG_FOLDER_PREFERENCE, folderPath);
        node.flush();
        return;
View Full Code Here

TOP

Related Classes of org.eclipse.core.runtime.preferences.IPreferencesService

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.