New to Telerik UI for WinForms? Start a free 30-day trial

Section

Class

A block-level flow content element used for grouping other Block elements.

Definition

Namespace:Telerik.WinForms.Documents.Model

Assembly:Telerik.WinControls.RichTextEditor.dll

Syntax:

C#
public class Section : BlockContainerBase, IDisposable, INotifyPropertyChanged, ICustomTypeDescriptor, IBlockContainer

Inheritance: objectDisposableObjectRadObjectDocumentElementBlockBlockContainerBaseSection...

Implements: IBlockContainerICustomTypeDescriptorIDisposableINotifyPropertyChanged

Inherited Members BlockContainerBase.BlocksDocumentElement.GetStyleProperty(IStylePropertyDefinition)DocumentElement.GetStyleProperty(string)DocumentElement.EnumerateChildrenOfType<T>()DocumentElement.GetParentOfType<T>()DocumentElement.CreateLayoutBox()DocumentElement.CopyPropertiesFrom(DocumentElement)DocumentElement.CopyPropertiesFromStyle(StyleDefinition)DocumentElement.ExtractStyleFromProperties()DocumentElement.ExtractStyleFromLocalProperties()DocumentElement.InvalidateAssociatedBoxesArrange()DocumentElement.InvalidateAssociatedBoxesMeasure()DocumentElement.InvalidateAssociatedBoxesLayout()DocumentElement.GetAssociatedLayoutBoxes()DocumentElement.GetRootDocument()DocumentElement.CreateDeepCopy()DocumentElement.CreateShallowCopy()DocumentElement.GetPropertyValueSource(IStylePropertyDefinition)DocumentElement.ClearValue(IStylePropertyDefinition)DocumentElement.OnRemoved()DocumentElement.OnStyleChanging()DocumentElement.OnStyleChanged()DocumentElement.OnStylePropertyChanged(StylePropertyChangeEventArgs)DocumentElement.OnParentChanging()DocumentElement.ChildIndexDocumentElement.HasStyleDocumentElement.StyleDocumentElement.StyleNameDocumentElement.TagDocumentElement.FirstLayoutBoxDocumentElement.IsFirstLayoutBoxInitializedDocumentElement.DocumentElementsDocumentElement.ParentDocumentElement.ChildrenDocumentElement.PreviousSiblingDocumentElement.NextSiblingDocumentElement.CursorDocumentElement.StyleChangingDocumentElement.StyleChangedDocumentElement.StylePropertyChangedDocumentElement.ParentChangingDocumentElement.ParentChangedDocumentElement.PropertyValueChangedRadObject.BindingContextPropertyRadObject.RadTypeRadObject.ReplaceDefaultDescriptors(PropertyDescriptorCollection)RadObject.DisposeManagedResources()RadObject.ClearPropertyStore()RadObject.SuspendPropertyNotifications()RadObject.ResumePropertyNotifications()RadObject.GetPropertyValue(RadProperty)RadObject.SetDefaultValueOverride(RadProperty, object)RadObject.GetValue(RadProperty)RadObject.SetValue(RadProperty, object)RadObject.ResetValue(RadProperty)RadObject.ResetLocalValue(RadProperty)RadObject.ResetValue(RadProperty, ValueResetFlags)RadObject.UpdateValue(RadProperty)RadObject.GetValueSource(RadProperty)RadObject.GetRegisteredRadProperty(string)RadObject.UpdateValueCore(RadPropertyValue)RadObject.SetValueCore(RadPropertyValue, object, object, ValueSource)RadObject.ResetValueCore(RadPropertyValue, ValueResetFlags)RadObject.GetDefaultValue(RadPropertyValue, object)RadObject.CoerceValue(RadPropertyValue, object)RadObject.ShouldSerializeProperty(RadProperty)RadObject.CanRaisePropertyChangeNotifications(RadPropertyValue)RadObject.BindProperty(RadProperty, RadObject, RadProperty, PropertyBindingOptions)RadObject.UnbindProperty(RadProperty)RadObject.AddStylePropertySetting(IPropertySetting)RadObject.GetInheritedValue(RadProperty)RadObject.OnPropertyChanging(RadPropertyChangingEventArgs)RadObject.OnPropertyChanged(RadPropertyChangedEventArgs)RadObject.OnNotifyPropertyChanged(string)RadObject.OnNotifyPropertyChanged(PropertyChangedEventArgs)RadObject.OnShouldSerializeProperty(ShouldSerializePropertyEventArgs)RadObject.IsPropertyCancelable(RadPropertyMetadata)RadObject.PropertyValuesRadObject.PropertyFilterRadObject.RadObjectTypeRadObject.BindingContextRadObject.PropertyChangedRadObject.RadPropertyChangedRadObject.RadPropertyChangingDisposableObject.GetBitState(long)DisposableObject.SetBitState(long, bool)DisposableObject.OnBitStateChanged(long, bool, bool)DisposableObject.Dispose()DisposableObject.Dispose(bool)DisposableObject.PerformDispose(bool)DisposableObject.DisposeUnmanagedResources()DisposableObject.BitStateDisposableObject.EventsDisposableObject.IsDisposingDisposableObject.IsDisposedDisposableObject.DisposedDisposableObject.Disposing...

Constructors

Initializes a new instance of the Section class.

C#
public Section()

Initializes a new instance of the Section class by copying the properties from another instance.

C#
public Section(Section originalSection)
Parameters:originalSectionSection

The original section.

Fields

Defines the layout-affecting style property that stores a section's text-column arrangement.

C#
public static readonly StylePropertyDefinition<SectionColumnCollection, SectionProperties> ColumnsProperty

Defines the layout-affecting style property for the first endnote reference number; unset section values inherit EndnotesFirstNumber.

C#
public static readonly StylePropertyDefinition<int?, SectionProperties> EndnotesFirstNumberProperty

Defines the layout-affecting style property for endnote reference markers; unset section values inherit EndnotesNumberingFormat.

C#
public static readonly StylePropertyDefinition<ListNumberingFormat?, SectionProperties> EndnotesNumberingFormatProperty

Defines the layout-affecting style property for endnote numbering restarts; unset section values inherit EndnotesNumberingRestartType.

C#
public static readonly StylePropertyDefinition<NumberingRestartType?, SectionProperties> EndnotesNumberingRestartTypeProperty

Defines the layout-affecting style property for the inset below footer content in a section.

C#
public static readonly StylePropertyDefinition<int?, SectionProperties> FooterBottomMarginProperty

Defines the layout-affecting style property for the first footnote reference number; unset section values inherit FootnotesFirstNumber.

C#
public static readonly StylePropertyDefinition<int?, SectionProperties> FootnotesFirstNumberProperty

Defines the layout-affecting style property for footnote reference markers; unset section values inherit FootnotesNumberingFormat.

C#
public static readonly StylePropertyDefinition<ListNumberingFormat?, SectionProperties> FootnotesNumberingFormatProperty

Defines the layout-affecting style property for footnote numbering restarts; unset section values inherit FootnotesNumberingRestartType.

C#
public static readonly StylePropertyDefinition<NumberingRestartType?, SectionProperties> FootnotesNumberingRestartTypeProperty

Defines the layout-affecting property that controls whether this section uses separate headers and footers on its first page.

C#
public static readonly StylePropertyDefinition<bool?, SectionProperties> HasDifferentFirstPageHeaderFooterProperty

Defines the layout-affecting style property for the inset above header content in a section.

C#
public static readonly StylePropertyDefinition<int?, SectionProperties> HeaderTopMarginProperty

Defines the layout-affecting style property for line-numbering settings in a section.

C#
public static readonly StylePropertyDefinition<LineNumbering, SectionProperties> LineNumberingProperty

Defines the layout-affecting style property for a section's page margins.

C#
public static readonly StylePropertyDefinition<Padding?, SectionProperties> PageMarginProperty

Defines the layout-affecting style property for a section's page orientation.

C#
public static readonly StylePropertyDefinition<PageOrientation?, SectionProperties> PageOrientationProperty

Defines the layout-affecting style property for a section's page dimensions.

C#
public static readonly StylePropertyDefinition<Size?, SectionProperties> PageSizeProperty

Defines the layout-affecting style property that records how the section starts relative to the preceding section.

C#
public static readonly StylePropertyDefinition<SectionBreakType?, SectionProperties> PreviousSectionBreakTypeProperty

Properties

Gets or sets the page margins after they have been mapped to the section's current PageOrientation. Use PageMargin for the stored margin values before orientation adjustment.

C#
public Padding ActualPageMargin { get; set; }

Gets or sets the text columns in the Section.

C#
public SectionColumnCollection Columns { get; set; }
Property Value:

The section columns.

Gets or sets the endnotes starting number.

C#
[XamlSerializable(1)]
public int EndnotesFirstNumber { get; set; }

Gets or sets the endnotes numbering format.

C#
[XamlSerializable(ListNumberingFormat.Decimal)]
public ListNumberingFormat EndnotesNumberingFormat { get; set; }

Gets or sets the type of the endnotes numbering restart.

C#
[XamlSerializable(NumberingRestartType.Continuous)]
public NumberingRestartType EndnotesNumberingRestartType { get; set; }

Gets or sets the page number that appears on the first page of the section.

C#
[XamlSerializable(null)]
public int? FirstPageNumber { get; set; }
Property Value:

The page number.

Gets or sets the footer bottom margin.

C#
[XamlSerializable(48)]
public int FooterBottomMargin { get; set; }
Property Value:

The footer bottom margin.

Gets or sets the footers.

C#
[XamlCompositePropertySerializable]
public Footers Footers { get; set; }
Property Value:

The footers.

Gets or sets the footnotes starting number.

C#
[XamlSerializable(1)]
public int FootnotesFirstNumber { get; set; }

Gets or sets the footnotes numbering format.

C#
[XamlSerializable(ListNumberingFormat.Decimal)]
public ListNumberingFormat FootnotesNumberingFormat { get; set; }

Gets or sets the type of the footnotes numbering restart.

C#
[XamlSerializable(NumberingRestartType.Continuous)]
public NumberingRestartType FootnotesNumberingRestartType { get; set; }

Gets or sets a value indicating whether first page header/footer is different.

C#
[XamlSerializable(false)]
public bool HasDifferentFirstPageHeaderFooter { get; set; }
Property Value:

true if first page header/footer is different; otherwise, false.

Gets or sets the headers.

C#
[XamlCompositePropertySerializable]
public Headers Headers { get; set; }
Property Value:

The headers.

Gets or sets the header top margin.

C#
[XamlSerializable(48)]
public int HeaderTopMargin { get; set; }
Property Value:

The header top margin.

Gets a value indicating whether the section is empty.

C#
public bool IsEmpty { get; }
Property Value:

true if the section is empty; otherwise, false.

Gets or sets the line numbering in the Section.

C#
public LineNumbering LineNumbering { get; set; }
Property Value:

The line numbering.

Gets the section number (starting from 1).

C#
public int Number { get; }

Gets or sets the section's page margins before orientation adjustment. If not overridden, the value resolves from SectionDefaultPageMargin. Use ActualPageMargin for margins mapped to the current orientation.

C#
[XamlSerializable]
public Padding PageMargin { get; set; }

Gets or sets the orientation used to lay out this section. It determines how page dimensions and margin sides are mapped; if not overridden, the value resolves from SectionDefaultPageOrientation.

C#
[XamlSerializable(PageOrientation.Portrait)]
public PageOrientation PageOrientation { get; set; }

Gets or sets the section's page dimensions before orientation adjustment. If not overridden, the value resolves from SectionDefaultPageSize.

C#
[XamlSerializable]
public Size PageSize { get; set; }

Gets or sets the break used to enter this section from the preceding section. The default is NextPage.

C#
[XamlSerializable]
public SectionBreakType PreviousSectionBreakType { get; set; }

Methods

Copies the properties from another document element to the current instance.

C#
protected override void CopyPropertiesFromOverride(DocumentElement fromElement)
Parameters:fromElementDocumentElement

The Section to copy the properties from.

Overrides: DocumentElement.CopyPropertiesFromOverride(DocumentElement)

Creates a SectionLayoutBox for the element.

C#
public override LayoutBox CreateLayoutBox(DocumentStructureCollection documentCollection)
Parameters:documentCollectionDocumentStructureCollection

The document collection.

Returns:

LayoutBox

The new SectionLayoutBox.

Overrides: DocumentElement.CreateLayoutBox(DocumentStructureCollection)

Creates a new Section instance.

C#
protected override DocumentElement CreateNewElementInstance()
Returns:

DocumentElement

The new instance.

Overrides: DocumentElement.CreateNewElementInstance()

Gets the footer by page number.

C#
public Footer GetFooterByPageNumber(int pageNumber)
Parameters:pageNumberint

The page number.

Returns:

Footer

Gets the footer by its type.

C#
public Footer GetFooterByType(HeaderFooterType footerType)
Parameters:footerTypeHeaderFooterType

Type of the footer.

Returns:

Footer

Gets the height of the footer for a page.

C#
public float GetFooterHeight(int pageNumber)
Parameters:pageNumberint

The page number.

Returns:

float

Gets the header by page number.

C#
public Header GetHeaderByPageNumber(int pageNumber)
Parameters:pageNumberint

The page number.

Returns:

Header

Gets the header by its type.

C#
public Header GetHeaderByType(HeaderFooterType headerType)
Parameters:headerTypeHeaderFooterType

Type of the header.

Returns:

Header

Gets the header/footer type by page number.

C#
public HeaderFooterType GetHeaderFooterTypeByPageNumber(int pageNumber)
Parameters:pageNumberint

The page number.

Returns:

HeaderFooterType

Gets the height of the header for a page.

C#
public float GetHeaderHeight(int pageNumber)
Parameters:pageNumberint

The page number.

Returns:

float

Determines whether a footer is linked to the previous section footer.

C#
public bool IsFooterLinkedToPrevious(HeaderFooterType headerFooterType)
Parameters:headerFooterTypeHeaderFooterType

Type of the footer.

Returns:

bool

true if the footer is linked to the previous section footer; otherwise, false.

Determines whether a header is linked to the previous section header.

C#
public bool IsHeaderLinkedToPrevious(HeaderFooterType headerFooterType)
Parameters:headerFooterTypeHeaderFooterType

Type of the header.

Returns:

bool

true if the header is linked to the previous section header; otherwise, false.

Links the footer of this section to the previous section footer.

C#
public void LinkFooterToPrevious(HeaderFooterType headerFooterType)
Parameters:headerFooterTypeHeaderFooterType

Type of the header or footer.

Links the header of this section to the previous section header.

C#
public void LinkHeaderToPrevious(HeaderFooterType headerFooterType)
Parameters:headerFooterTypeHeaderFooterType

Type of the header or footer.

Currently performs no work after a child document container changes.

C#
public void OnChildDocumentContainerChanged()

Currently performs no work before a child document container changes.

C#
public void OnChildDocumentContainerChanging()

Notifies the root document and section listeners after header/footer settings change.

C#
protected virtual void OnHeadersFootersChanged(EventArgs e)
Parameters:eEventArgs

Event data for the notification.

Refreshes header/footer document ownership and protection settings after the section is reparented.

C#
protected override void OnParentChanged()

Overrides: DocumentElement.OnParentChanged()

Sets the footer by page number.

C#
public void SetFooterByPageNumber(int pageNumber, Footer footer)
Parameters:pageNumberint

The page number.

footerFooter

The footer.

Sets a footer according to type.

C#
public void SetFooterByType(HeaderFooterType footerType, Footer footer)
Parameters:footerTypeHeaderFooterType

Type of the footer.

footerFooter

The footer.

Sets the header by page number.

C#
public void SetHeaderByPageNumber(int pageNumber, Header header)
Parameters:pageNumberint

The page number.

headerHeader

The header.

Sets a header according to type.

C#
public void SetHeaderByType(HeaderFooterType headerType, Header header)
Parameters:headerTypeHeaderFooterType

Type of the header.

headerHeader

The header.

Sets the main document. This method is used to link the headers and footers in a section with the main body document.

C#
public void SetMainDocument(RadDocument document)
Parameters:documentRadDocument

The document.

Removes the link between the footer of this section and the previous section footer.

C#
public void UnlinkFooterFromPrevious(HeaderFooterType headerFooterType)
Parameters:headerFooterTypeHeaderFooterType

Type of the header or footer.

Removes the link between the header of this section and the previous section header.

C#
public void UnlinkHeaderFromPrevious(HeaderFooterType headerFooterType)
Parameters:headerFooterTypeHeaderFooterType

Type of the header or footer.

In this article
DefinitionConstructorsSection()Section(Section)FieldsColumnsPropertyEndnotesFirstNumberPropertyEndnotesNumberingFormatPropertyEndnotesNumberingRestartTypePropertyFooterBottomMarginPropertyFootnotesFirstNumberPropertyFootnotesNumberingFormatPropertyFootnotesNumberingRestartTypePropertyHasDifferentFirstPageHeaderFooterPropertyHeaderTopMarginPropertyLineNumberingPropertyPageMarginPropertyPageOrientationPropertyPageSizePropertyPreviousSectionBreakTypePropertyPropertiesActualPageMarginColumnsEndnotesFirstNumberEndnotesNumberingFormatEndnotesNumberingRestartTypeFirstPageNumberFooterBottomMarginFootersFootnotesFirstNumberFootnotesNumberingFormatFootnotesNumberingRestartTypeHasDifferentFirstPageHeaderFooterHeadersHeaderTopMarginIsEmptyLineNumberingNumberPageMarginPageOrientationPageSizePreviousSectionBreakTypeMethodsCopyPropertiesFromOverride(DocumentElement)CreateLayoutBox(DocumentStructureCollection)CreateNewElementInstance()GetFooterByPageNumber(int)GetFooterByType(HeaderFooterType)GetFooterHeight(int)GetHeaderByPageNumber(int)GetHeaderByType(HeaderFooterType)GetHeaderFooterTypeByPageNumber(int)GetHeaderHeight(int)IsFooterLinkedToPrevious(HeaderFooterType)IsHeaderLinkedToPrevious(HeaderFooterType)LinkFooterToPrevious(HeaderFooterType)LinkHeaderToPrevious(HeaderFooterType)OnChildDocumentContainerChanged()OnChildDocumentContainerChanging()OnHeadersFootersChanged(EventArgs)OnParentChanged()SetFooterByPageNumber(int, Footer)SetFooterByType(HeaderFooterType, Footer)SetHeaderByPageNumber(int, Header)SetHeaderByType(HeaderFooterType, Header)SetMainDocument(RadDocument)UnlinkFooterFromPrevious(HeaderFooterType)UnlinkHeaderFromPrevious(HeaderFooterType)
Not finding the help you need?
Contact Support