Bug 3970 [preferences] UI needed to define the default line delimiters for new files (1GFIOAX)
When creating a new file we currently use the line delimiter returned form System.getProperties("line.delimiter"). But this is not whay a user always wants. Consider the following sceanrio: - Unix and Windows work station used to develop a Unix product / program. - the Windows work stations are used as X terminals and to run Eclipse (since PC are cheaper than Unix boxes). - even if the new file is created on Windows it should have Unix line delimiters since the end product is a Unix product. There should be a UI (Preference) to define the line delimiter for new files. Possible values are: - Dos / Windows - Mac - Unix - default platform line delimiter. The UI should be provided by the Workbench since all plugins should use the same line delimiter for new files. NOTES:
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/dialogs/IDEEditorsPreferencePage.java
*
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.ui.internal.ide.dialogs;
import java.util.Collections;
import java.util.List;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.jface.preference.FieldEditor;
import org.eclipse.jface.util.IPropertyChangeListener;
import org.eclipse.jface.util.PropertyChangeEvent;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Label;
import org.eclipse.ui.WorkbenchEncoding;
import org.eclipse.ui.dialogs.PreferenceLinkArea;
import org.eclipse.ui.ide.IDEEncoding;
import org.eclipse.ui.ide.dialogs.ResourceEncodingFieldEditor;
import org.eclipse.ui.internal.dialogs.EditorsPreferencePage;
import org.eclipse.ui.internal.ide.IDEWorkbenchMessages;
import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
/**
 * Extends the Editors preference page with IDE-specific settings.
 * 
 * Note: want IDE settings to appear in main Editors preference page (via
 * subclassing), however the superclass, EditorsPreferencePage, is internal
 */
public class IDEEditorsPreferencePage extends EditorsPreferencePage {