Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / WinForms / Managed / System / WinForms / FlowLayoutPanel.cs / 1 / FlowLayoutPanel.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms { using System; using System.ComponentModel; using System.Diagnostics; using System.Drawing; using System.Windows.Forms.Layout; using System.Runtime.InteropServices; ///[ComVisible(true)] [ClassInterface(ClassInterfaceType.AutoDispatch)] [ProvideProperty("FlowBreak", typeof(Control))] [DefaultProperty("FlowDirection")] [Designer("System.Windows.Forms.Design.FlowLayoutPanelDesigner, " + AssemblyRef.SystemDesign)] [Docking(DockingBehavior.Ask)] [SRDescription(SR.DescriptionFlowLayoutPanel)] public class FlowLayoutPanel : Panel, IExtenderProvider { private FlowLayoutSettings _flowLayoutSettings; /// public FlowLayoutPanel() { _flowLayoutSettings = FlowLayout.CreateSettings(this); } /// public override LayoutEngine LayoutEngine { get { return FlowLayout.Instance; } } /// [SRDescription(SR.FlowPanelFlowDirectionDescr)] [DefaultValue(FlowDirection.LeftToRight)] [SRCategory(SR.CatLayout)] [Localizable(true)] public FlowDirection FlowDirection { get { return _flowLayoutSettings.FlowDirection; } set { _flowLayoutSettings.FlowDirection = value; Debug.Assert(FlowDirection == value, "FlowDirection should be the same as we set it"); } } /// [SRDescription(SR.FlowPanelWrapContentsDescr)] [DefaultValue(true)] [SRCategory(SR.CatLayout)] [Localizable(true)] public bool WrapContents { get { return _flowLayoutSettings.WrapContents; } set { _flowLayoutSettings.WrapContents = value; Debug.Assert(WrapContents == value, "WrapContents should be the same as we set it"); } } #region Provided properties /// /// bool IExtenderProvider.CanExtend(object obj) { Control control = obj as Control; return control != null && control.Parent == this; } [DefaultValue(false)] [DisplayName("FlowBreak")] public bool GetFlowBreak(Control control) { return _flowLayoutSettings.GetFlowBreak(control); } [DisplayName("FlowBreak")] public void SetFlowBreak(Control control, bool value) { _flowLayoutSettings.SetFlowBreak(control, value); } #endregion } } // 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
- ServiceEndpointCollection.cs
- InteropExecutor.cs
- GroupQuery.cs
- ProgressBarRenderer.cs
- CompilationPass2Task.cs
- UserControl.cs
- AlphabeticalEnumConverter.cs
- DynamicActivityTypeDescriptor.cs
- Latin1Encoding.cs
- MasterPageBuildProvider.cs
- IdentityManager.cs
- PeerNameRegistration.cs
- InternalRelationshipCollection.cs
- recordstatefactory.cs
- IsolatedStorageFileStream.cs
- AnyAllSearchOperator.cs
- SimpleBitVector32.cs
- SoapReflectionImporter.cs
- BroadcastEventHelper.cs
- EventsTab.cs
- SqlWebEventProvider.cs
- DependencyPropertyHelper.cs
- Script.cs
- DragStartedEventArgs.cs
- PersonalizationDictionary.cs
- ScopeCollection.cs
- LineUtil.cs
- TableItemProviderWrapper.cs
- BitmapEffectInputData.cs
- DecimalKeyFrameCollection.cs
- Int64AnimationUsingKeyFrames.cs
- MarkupObject.cs
- SchemaObjectWriter.cs
- DataServiceKeyAttribute.cs
- StringArrayConverter.cs
- JoinElimination.cs
- IriParsingElement.cs
- COAUTHIDENTITY.cs
- Operator.cs
- DesignerActionPropertyItem.cs
- CompositionTarget.cs
- SoapMessage.cs
- DataControlCommands.cs
- SpeechSynthesizer.cs
- NumericUpDownAccelerationCollection.cs
- PageAction.cs
- HttpHandlersSection.cs
- LocatorPart.cs
- PropertyToken.cs
- PageAsyncTask.cs
- DBDataPermissionAttribute.cs
- WindowsSolidBrush.cs
- EntityPropertyMappingAttribute.cs
- CapiNative.cs
- ProfileSettingsCollection.cs
- HostingEnvironmentException.cs
- CodeCompileUnit.cs
- WindowsIdentity.cs
- HtmlImageAdapter.cs
- EncryptedData.cs
- DataServiceRequestException.cs
- SQLMembershipProvider.cs
- PrintDialogException.cs
- MarkupExtensionParser.cs
- NumericUpDownAccelerationCollection.cs
- DiscoveryClientDocuments.cs
- CodeChecksumPragma.cs
- EventListenerClientSide.cs
- GeometryCombineModeValidation.cs
- AxisAngleRotation3D.cs
- SerialPinChanges.cs
- X509CertificateValidationMode.cs
- DataGridViewCellStyleChangedEventArgs.cs
- OleDbCommandBuilder.cs
- TypeListConverter.cs
- Helpers.cs
- SiteMapSection.cs
- QueryTreeBuilder.cs
- Matrix3DStack.cs
- ScriptResourceAttribute.cs
- DrawingBrush.cs
- LayoutExceptionEventArgs.cs
- SectionXmlInfo.cs
- MaskedTextBoxTextEditor.cs
- SiteMembershipCondition.cs
- NavigationPropertyEmitter.cs
- WebRequestModuleElementCollection.cs
- WorkflowMarkupSerializationManager.cs
- ErrorHandlingReceiver.cs
- StateBag.cs
- BasicKeyConstraint.cs
- TCPClient.cs
- FontCacheLogic.cs
- TrustManagerPromptUI.cs
- WCFServiceClientProxyGenerator.cs
- ContentPropertyAttribute.cs
- ConstraintConverter.cs
- Itemizer.cs
- StylusPointPropertyUnit.cs
- DataMember.cs