Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / WinForms / Managed / System / WinForms / FlowLayoutSettings.cs / 1305376 / FlowLayoutSettings.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;
///
[DefaultProperty("FlowDirection")]
public class FlowLayoutSettings : LayoutSettings {
internal FlowLayoutSettings(IArrangedElement owner) : base(owner) {}
///
public override LayoutEngine LayoutEngine {
get { return FlowLayout.Instance; }
}
///
[SRDescription(SR.FlowPanelFlowDirectionDescr)]
[DefaultValue(FlowDirection.LeftToRight)]
[SRCategory(SR.CatLayout)]
public FlowDirection FlowDirection {
get { return FlowLayout.GetFlowDirection(Owner); }
set {
FlowLayout.SetFlowDirection(Owner, value);
Debug.Assert(FlowDirection == value, "FlowDirection should be the same as we set it");
}
}
///
[SRDescription(SR.FlowPanelWrapContentsDescr)]
[DefaultValue(true)]
[SRCategory(SR.CatLayout)]
public bool WrapContents {
get { return FlowLayout.GetWrapContents(Owner); }
set {
FlowLayout.SetWrapContents(Owner, value);
Debug.Assert(WrapContents == value, "WrapContents should be the same as we set it");
}
}
public void SetFlowBreak(object child, bool value) {
IArrangedElement element = FlowLayout.Instance.CastToArrangedElement(child);
if (GetFlowBreak(child) != value) {
CommonProperties.SetFlowBreak(element, value);
}
}
public bool GetFlowBreak(object child) {
IArrangedElement element = FlowLayout.Instance.CastToArrangedElement(child);
return CommonProperties.GetFlowBreak(element);
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- SafeHandles.cs
- DataGridView.cs
- SafeNativeMethods.cs
- SessionPageStatePersister.cs
- PeerCollaborationPermission.cs
- RelationalExpressions.cs
- FixedPosition.cs
- Menu.cs
- __Filters.cs
- SmtpReplyReader.cs
- Group.cs
- AdRotator.cs
- Options.cs
- InputProviderSite.cs
- ComboBoxItem.cs
- ReferentialConstraintRoleElement.cs
- TextTreeTextElementNode.cs
- CustomError.cs
- Membership.cs
- OleDbInfoMessageEvent.cs
- RichTextBoxAutomationPeer.cs
- HyperLink.cs
- ContainerCodeDomSerializer.cs
- CustomCategoryAttribute.cs
- XmlSchemaExporter.cs
- RawContentTypeMapper.cs
- PeerApplicationLaunchInfo.cs
- XmlILAnnotation.cs
- ToolStripPanel.cs
- RoutedEventHandlerInfo.cs
- ToolStripPanelRow.cs
- DayRenderEvent.cs
- NavigatorInput.cs
- MemberDomainMap.cs
- TerminateDesigner.cs
- DoubleStorage.cs
- TcpChannelListener.cs
- RectConverter.cs
- SectionInput.cs
- UrlMappingCollection.cs
- SHA512.cs
- NonParentingControl.cs
- CipherData.cs
- CodeDOMUtility.cs
- PerformanceCounterPermissionEntry.cs
- BitmapEffectDrawing.cs
- DataViewSettingCollection.cs
- RegistryPermission.cs
- ObjectItemCachedAssemblyLoader.cs
- ListBox.cs
- OleDbRowUpdatingEvent.cs
- ParenthesizePropertyNameAttribute.cs
- HostedTransportConfigurationManager.cs
- PersonalizableAttribute.cs
- RectangleGeometry.cs
- FixedFindEngine.cs
- AutomationElementIdentifiers.cs
- Button.cs
- PointAnimationUsingPath.cs
- SqlMethodTransformer.cs
- LowerCaseStringConverter.cs
- BinaryWriter.cs
- AlternateViewCollection.cs
- PriorityBindingExpression.cs
- _ListenerResponseStream.cs
- TrackingValidationObjectDictionary.cs
- KnownTypeAttribute.cs
- ConfigurationSectionGroup.cs
- DiscoveryRequestHandler.cs
- MaskedTextProvider.cs
- ExceptionUtil.cs
- ToolStripItemTextRenderEventArgs.cs
- SizeFConverter.cs
- DataGridViewCellStyle.cs
- WebPartCatalogAddVerb.cs
- Stack.cs
- TemplateBindingExpression.cs
- sqlnorm.cs
- BufferModeSettings.cs
- SByteConverter.cs
- NameValueFileSectionHandler.cs
- LeafCellTreeNode.cs
- RsaSecurityKey.cs
- ApplicationServicesHostFactory.cs
- DataObjectMethodAttribute.cs
- TextEffect.cs
- ClientFormsIdentity.cs
- DataControlPagerLinkButton.cs
- DocumentViewerAutomationPeer.cs
- PageTextBox.cs
- VBIdentifierTrimConverter.cs
- ObjectFullSpanRewriter.cs
- SocketAddress.cs
- GroupBox.cs
- columnmapkeybuilder.cs
- ValidatedControlConverter.cs
- EntityDataSourceValidationException.cs
- ApplicationTrust.cs
- OracleConnectionStringBuilder.cs
- XmlEnumAttribute.cs