Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / Designer / WebForms / System / Web / UI / Design / DesignerAutoFormat.cs / 1 / DesignerAutoFormat.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.Design { using System; using System.ComponentModel.Design; using System.Drawing; using System.Web.UI; using System.Web.UI.WebControls; using Control = System.Web.UI.Control; ///public abstract class DesignerAutoFormat { private string _name; private DesignerAutoFormatStyle _style; protected DesignerAutoFormat(string name) { if ((name == null) || (name.Length == 0)) { throw new ArgumentNullException("name"); } _name = name; } /// public string Name { get { return _name; } } public DesignerAutoFormatStyle Style { get { if (_style == null) { _style = new DesignerAutoFormatStyle(); } return _style; } } /// public abstract void Apply(Control control); public virtual Control GetPreviewControl(Control runtimeControl) { IDesignerHost host = (IDesignerHost)runtimeControl.Site.GetService(typeof(IDesignerHost)); ControlDesigner designer = host.GetDesigner(runtimeControl) as ControlDesigner; if (designer != null) { return designer.CreateClonedControl(host, true); } return null; } /// public override string ToString() { return Name; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- Identity.cs
- Cursor.cs
- Decorator.cs
- XhtmlBasicPanelAdapter.cs
- HtmlEmptyTagControlBuilder.cs
- LogicalCallContext.cs
- DictionarySectionHandler.cs
- InternalTypeHelper.cs
- ScriptingJsonSerializationSection.cs
- nulltextcontainer.cs
- XmlDataImplementation.cs
- BrowsableAttribute.cs
- Timer.cs
- GridViewUpdateEventArgs.cs
- DocumentEventArgs.cs
- SqlFactory.cs
- BlockingCollection.cs
- HttpCapabilitiesSectionHandler.cs
- StandardCommands.cs
- TreeNodeCollection.cs
- ManagedIStream.cs
- _SpnDictionary.cs
- WCFServiceClientProxyGenerator.cs
- SolidBrush.cs
- ClientUrlResolverWrapper.cs
- DayRenderEvent.cs
- XmlSchemaAny.cs
- AuthenticationModuleElementCollection.cs
- WebServiceData.cs
- StringReader.cs
- BitmapCodecInfo.cs
- TabControlEvent.cs
- HttpRequestBase.cs
- exports.cs
- ModelUIElement3D.cs
- EtwTrace.cs
- ComplusEndpointConfigContainer.cs
- PageThemeParser.cs
- TypeUnloadedException.cs
- PageCatalogPart.cs
- TypeDescriptor.cs
- CodeExporter.cs
- GeometryModel3D.cs
- FaultCode.cs
- DataGridViewAdvancedBorderStyle.cs
- ByeMessageApril2005.cs
- RepeaterCommandEventArgs.cs
- CodeSubDirectory.cs
- TypeSystem.cs
- ProcessHost.cs
- DesignBindingPropertyDescriptor.cs
- GlobalizationSection.cs
- InkCollectionBehavior.cs
- CustomSignedXml.cs
- FunctionDescription.cs
- StoryFragments.cs
- CachedPathData.cs
- WebServiceHandlerFactory.cs
- ViewManager.cs
- WizardSideBarListControlItemEventArgs.cs
- ChildDocumentBlock.cs
- IgnoreDataMemberAttribute.cs
- ManifestSignedXml.cs
- HexParser.cs
- ByteRangeDownloader.cs
- DataServiceHostWrapper.cs
- AuthenticationModulesSection.cs
- InfoCardConstants.cs
- ISessionStateStore.cs
- HttpCachePolicyElement.cs
- UpdateCompiler.cs
- AudioStateChangedEventArgs.cs
- ValidationErrorEventArgs.cs
- AdapterUtil.cs
- ExceptionRoutedEventArgs.cs
- TemplateBamlRecordReader.cs
- TextTrailingCharacterEllipsis.cs
- AutoGeneratedField.cs
- ResponseBodyWriter.cs
- TableCell.cs
- TitleStyle.cs
- SHA1CryptoServiceProvider.cs
- XmlDictionaryString.cs
- SetterBaseCollection.cs
- XhtmlConformanceSection.cs
- HttpFileCollection.cs
- SqlNodeAnnotation.cs
- PrintingPermission.cs
- WebConfigurationFileMap.cs
- SafeNativeMethods.cs
- MinMaxParagraphWidth.cs
- KeyFrames.cs
- AsyncOperation.cs
- ToolStripComboBox.cs
- XmlCharacterData.cs
- Hash.cs
- PathSegmentCollection.cs
- _NegotiateClient.cs
- NotifyIcon.cs
- StrongNameUtility.cs