Removing legacy build scripts. build.xml scripts are generated by pde-build, and...
[phpeclipse.git] / archive / net.sourceforge.phpeclipse.jtidy / src / net / sourceforge / phpdt / tidy / preferences / JTidyGeneralPreferences.java
1 package net.sourceforge.phpdt.tidy.preferences;
2
3 import net.sourceforge.phpdt.tidy.JtidyPlugin;
4
5 import org.eclipse.jface.preference.BooleanFieldEditor;
6 import org.eclipse.jface.preference.FieldEditorPreferencePage;
7 import org.eclipse.jface.preference.FileFieldEditor;
8 import org.eclipse.jface.preference.IPreferenceStore;
9 import org.eclipse.ui.IWorkbench;
10 import org.eclipse.ui.IWorkbenchPreferencePage;
11
12 /**
13  * A preference page for a simple HTML editor.
14  */
15 public class JTidyGeneralPreferences extends FieldEditorPreferencePage implements IWorkbenchPreferencePage, IPreferenceConstants {
16
17   public JTidyGeneralPreferences() {
18     super(FieldEditorPreferencePage.GRID);
19
20     // Set the preference store for the preference page.
21     IPreferenceStore store = JtidyPlugin.getDefault().getPreferenceStore();
22     setPreferenceStore(store);
23   }
24
25   /**
26    * @see org.eclipse.jface.preference.
27    * FieldEditorPreferencePage#createFieldEditors()
28    */
29   protected void createFieldEditors() {
30     FileFieldEditor tidyConf = new FileFieldEditor(GENERAL_CONFIG_FILE, "Config file", true, getFieldEditorParent());
31     addField(tidyConf);
32     BooleanFieldEditor useConfigFile =
33       new BooleanFieldEditor(GENERAL_USE_CONFIG_FILE, "Use configurtion file", getFieldEditorParent());
34     addField(useConfigFile);
35     // 
36     
37     BooleanFieldEditor tidyMark =
38       new BooleanFieldEditor(GENERAL_TIDY_MARK, "Set Tidy signature in header", getFieldEditorParent());
39     addField(tidyMark);
40     
41     BooleanFieldEditor showWarning =
42       new BooleanFieldEditor(GENERAL_SHOW_WARNINGS, "Show warnings", getFieldEditorParent());
43     addField(showWarning);
44
45     BooleanFieldEditor quiet =
46       new BooleanFieldEditor(GENERAL_QUIET, "Quiet output", getFieldEditorParent());
47     addField(quiet);
48
49     BooleanFieldEditor emacs =
50       new BooleanFieldEditor(GENERAL_EMACS, "Emacs error reporting style", getFieldEditorParent());
51     addField(emacs);
52     
53     BooleanFieldEditor keepFileTimes =
54       new BooleanFieldEditor(GENERAL_KEEP_FILE_TIMES, "Keep last modified time", getFieldEditorParent());
55     addField(keepFileTimes);
56   }
57
58   /**
59    * @see IWorkbenchPreferencePage#init
60    */
61   public void init(IWorkbench workbench) {
62   }
63 }