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
- ClientTargetSection.cs
- DbProviderFactories.cs
- HtmlTableCell.cs
- BufferedWebEventProvider.cs
- FtpWebResponse.cs
- XmlMembersMapping.cs
- QueryCreatedEventArgs.cs
- AsmxEndpointPickerExtension.cs
- ExpressionLink.cs
- DnsPermission.cs
- InheritablePropertyChangeInfo.cs
- TreeNodeEventArgs.cs
- AutoResizedEvent.cs
- DirectoryNotFoundException.cs
- Trace.cs
- DecimalAnimationUsingKeyFrames.cs
- DNS.cs
- MultiSelectRootGridEntry.cs
- Aggregates.cs
- _ScatterGatherBuffers.cs
- NameTable.cs
- WSSecurityOneDotOneSendSecurityHeader.cs
- NativeMethods.cs
- ExpandSegmentCollection.cs
- Paragraph.cs
- PageOutputQuality.cs
- PopupRoot.cs
- FileInfo.cs
- XamlWriter.cs
- TreeViewEvent.cs
- GC.cs
- StatusBarItemAutomationPeer.cs
- DrawListViewItemEventArgs.cs
- UriParserTemplates.cs
- SerializableAttribute.cs
- ChangeTracker.cs
- BrowsableAttribute.cs
- Encoder.cs
- ApplicationDirectory.cs
- SyndicationElementExtension.cs
- FtpWebResponse.cs
- EnumerableRowCollection.cs
- InvalidDataException.cs
- HtmlMeta.cs
- ColorPalette.cs
- TemplateControl.cs
- BindingContext.cs
- ModelFunctionTypeElement.cs
- ValidationErrorCollection.cs
- ContravarianceAdapter.cs
- NotifyIcon.cs
- PersistChildrenAttribute.cs
- PathFigure.cs
- WinCategoryAttribute.cs
- ConsoleCancelEventArgs.cs
- WebEventTraceProvider.cs
- AutomationPatternInfo.cs
- SqlGatherConsumedAliases.cs
- LinqDataView.cs
- StructuredProperty.cs
- PaperSize.cs
- Select.cs
- __ComObject.cs
- FontStyles.cs
- XsltQilFactory.cs
- LoginCancelEventArgs.cs
- BinaryFormatterWriter.cs
- IsolatedStorageFile.cs
- ConditionCollection.cs
- CodeRegionDirective.cs
- Margins.cs
- ImportCatalogPart.cs
- DrawingCollection.cs
- SqlClientPermission.cs
- _AutoWebProxyScriptWrapper.cs
- AsyncStreamReader.cs
- StatusBarDrawItemEvent.cs
- DataTable.cs
- DataListItemEventArgs.cs
- TransformPattern.cs
- CodeCommentStatement.cs
- Sql8ConformanceChecker.cs
- IsolatedStorage.cs
- ToolTip.cs
- Color.cs
- SID.cs
- DateTimeSerializationSection.cs
- WebCategoryAttribute.cs
- ColorTransform.cs
- CodeSubDirectoriesCollection.cs
- DatagridviewDisplayedBandsData.cs
- ClassicBorderDecorator.cs
- ContainerControl.cs
- OrderedDictionaryStateHelper.cs
- WinFormsSpinner.cs
- DetailsViewUpdateEventArgs.cs
- Utils.cs
- FixedTextBuilder.cs
- SpanIndex.cs
- ColorMap.cs