protected override void Load(ICSharpCode.SharpDevelop.Project.MSBuildBasedProject project, string configuration, string platform) { base.Load(project, configuration, platform); if (formattingPolicy != null) { formattingPolicy.OptionsContainer.PropertyChanged -= ContainerPropertyChanged; } formattingPolicy = AlFormattingPolicies.Instance.GetProjectOptions(project); formattingEditor.OptionsContainer = formattingPolicy.OptionsContainer; formattingEditor.AllowPresets = true; formattingEditor.OverrideGlobalIndentation = true; formattingPolicy.OptionsContainer.PropertyChanged += ContainerPropertyChanged; }
public AlFormattingOptionPanel(AlFormattingPolicy persistenceHelper, bool allowPresets, bool overrideGlobalIndentation) { if (persistenceHelper == null) { throw new ArgumentNullException("persistenceHelper"); } this.formattingPolicy = persistenceHelper; this.isDirty = false; InitializeComponent(); formattingEditor.AllowPresets = allowPresets; formattingEditor.OverrideGlobalIndentation = overrideGlobalIndentation; }