OfficeIMO

API Reference

Class

WordTableStyleDetails

Namespace OfficeIMO.Word
Assembly OfficeIMO.Word

Manages table style settings and borders.

Inheritance

  • Object
  • WordTableStyleDetails

Constructors

WordTableStyleDetails(OfficeIMO.Word.WordTable table) #

Constructor for Table Style Details

Parameters

table OfficeIMO.Word.WordTable required

Methods

public Void ApplyBordersToAllCells() #
Returns: Void

Apply the current table's border settings to all cells in the table

public ValueTuple<Nullable<BorderValues>, UInt32Value, String> GetBorderProperties(WordTableBorderSide side) #
Returns: ValueTuple<Nullable<BorderValues>, UInt32Value, String>

Gets border properties for the specified side

Parameters

side OfficeIMO.Word.WordTableBorderSide requiredposition: 0
The border side to get properties for

Returns

A tuple with style, size, and color

public Void SetBordersForAllSides(BorderValues style, UInt32Value size, Color color) #
Returns: Void

Creates and sets a TableBorders object with the specified border settings

Parameters

style DocumentFormat.OpenXml.Wordprocessing.BorderValues requiredposition: 0
Border style for all sides
size DocumentFormat.OpenXml.UInt32Value requiredposition: 1
Border size for all sides
color SixLabors.ImageSharp.Color requiredposition: 2
Border color for all sides
public Void SetBordersOutsideInside(BorderValues outsideStyle, UInt32Value outsideSize, Color outsideColor, BorderValues insideStyle, UInt32Value insideSize, Color insideColor) #
Returns: Void

Creates a TableBorders object with different settings for outside and inside borders

Parameters

outsideStyle DocumentFormat.OpenXml.Wordprocessing.BorderValues requiredposition: 0
Style for outside borders
outsideSize DocumentFormat.OpenXml.UInt32Value requiredposition: 1
Size for outside borders
outsideColor SixLabors.ImageSharp.Color requiredposition: 2
Color for outside borders
insideStyle DocumentFormat.OpenXml.Wordprocessing.BorderValues requiredposition: 3
Style for inside borders
insideSize DocumentFormat.OpenXml.UInt32Value requiredposition: 4
Size for inside borders
insideColor SixLabors.ImageSharp.Color requiredposition: 5
Color for inside borders
public Void SetCustomBorders(Nullable<BorderValues> topStyle = null, UInt32Value topSize = null, Nullable<Color> topColor = null, Nullable<BorderValues> bottomStyle = null, UInt32Value bottomSize = null, Nullable<Color> bottomColor = null, Nullable<BorderValues> leftStyle = null, UInt32Value leftSize = null, Nullable<Color> leftColor = null, Nullable<BorderValues> rightStyle = null, UInt32Value rightSize = null, Nullable<Color> rightColor = null, Nullable<BorderValues> insideHStyle = null, UInt32Value insideHSize = null, Nullable<Color> insideHColor = null, Nullable<BorderValues> insideVStyle = null, UInt32Value insideVSize = null, Nullable<Color> insideVColor = null) #
Returns: Void

Creates a TableBorders object with custom settings for each side

Parameters

topStyle System.Nullable{DocumentFormat.OpenXml.Wordprocessing.BorderValues} = null optionalposition: 0
topSize DocumentFormat.OpenXml.UInt32Value = null optionalposition: 1
topColor System.Nullable{SixLabors.ImageSharp.Color} = null optionalposition: 2
bottomStyle System.Nullable{DocumentFormat.OpenXml.Wordprocessing.BorderValues} = null optionalposition: 3
bottomSize DocumentFormat.OpenXml.UInt32Value = null optionalposition: 4
bottomColor System.Nullable{SixLabors.ImageSharp.Color} = null optionalposition: 5
leftStyle System.Nullable{DocumentFormat.OpenXml.Wordprocessing.BorderValues} = null optionalposition: 6
leftSize DocumentFormat.OpenXml.UInt32Value = null optionalposition: 7
leftColor System.Nullable{SixLabors.ImageSharp.Color} = null optionalposition: 8
rightStyle System.Nullable{DocumentFormat.OpenXml.Wordprocessing.BorderValues} = null optionalposition: 9
rightSize DocumentFormat.OpenXml.UInt32Value = null optionalposition: 10
rightColor System.Nullable{SixLabors.ImageSharp.Color} = null optionalposition: 11
insideHStyle System.Nullable{DocumentFormat.OpenXml.Wordprocessing.BorderValues} = null optionalposition: 12
insideHSize DocumentFormat.OpenXml.UInt32Value = null optionalposition: 13
insideHColor System.Nullable{SixLabors.ImageSharp.Color} = null optionalposition: 14
insideVStyle System.Nullable{DocumentFormat.OpenXml.Wordprocessing.BorderValues} = null optionalposition: 15
insideVSize DocumentFormat.OpenXml.UInt32Value = null optionalposition: 16
insideVColor System.Nullable{SixLabors.ImageSharp.Color} = null optionalposition: 17

Properties

public Nullable<Int16> MarginDefaultTopWidth { get; set; } #

Get or set the top margin in twips

public Nullable<Double> MarginDefaultTopCentimeters { get; set; } #

Get or set the top margin in centimeters

public Nullable<Int16> MarginDefaultBottomWidth { get; set; } #

Get or set the bottom margin in twips

public Nullable<Double> MarginDefaultBottomCentimeters { get; set; } #

Get or set the bottom margin in centimeters

public Nullable<Int16> MarginDefaultLeftWidth { get; set; } #

Get or set the left margin in twips

public Nullable<Double> MarginDefaultLeftCentimeters { get; set; } #

Get or set the left margin in centimeters

public Nullable<Int16> MarginDefaultRightWidth { get; set; } #

Get or set the right margin in twips

public Nullable<Double> MarginDefaultRightCentimeters { get; set; } #

Get or set the right margin in centimeters

public Nullable<Int16> CellSpacing { get; set; } #

Get or set the cell spacing in twips

public Nullable<Double> CellSpacingCentimeters { get; set; } #

Get or set the cell spacing in centimeters

public TableBorders TableBorders { get; set; } #

Get or set the table borders

public TableCellMarginDefault TableCellMarginDefault { get; set; } #

Get or set the table cell margin default