Interface IOfficeChartManualLayout
Represents the manual layout of the chart element.
Inherited Members
Namespace: Syncfusion.OfficeChart
Assembly: Syncfusion.OfficeChart.Base.dll
Syntax
public interface IOfficeChartManualLayout : IParentApplication
Properties
Height
Specifies the height (if Height Mode is Factor) or bottom (if Height Mode is edge) of the chart element as a fraction of the height of the chart.
Declaration
double Height { get; set; }
Property Value
Type |
---|
System.Double |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()
HeightMode
Specifies how to interpret the Height element for this manual layout.
Declaration
LayoutModes HeightMode { get; set; }
Property Value
Type |
---|
LayoutModes |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()
LayoutTarget
Specifies whether to layout only the plot area
Declaration
LayoutTargets LayoutTarget { get; set; }
Property Value
Type |
---|
LayoutTargets |
Left
Specifies the x location (left) of the chart element as a fraction of the width of the chart. If Left Mode is Factor, then the position is relative to the default position for the chart element.
Declaration
double Left { get; set; }
Property Value
Type |
---|
System.Double |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()
LeftMode
Specifies how to interpret the Left element for this manual layout
Declaration
LayoutModes LeftMode { get; set; }
Property Value
Type |
---|
LayoutModes |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()
Top
Specifies the top of the chart element as a fraction of the height of the chart. If Top Mode is Factor, then the position is relative to the default position for the chart element.
Declaration
double Top { get; set; }
Property Value
Type |
---|
System.Double |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()
TopMode
Specifies how to interpret the Top element for this manual layout.
Declaration
LayoutModes TopMode { get; set; }
Property Value
Type |
---|
LayoutModes |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()
Width
Specifies the width (if Width Mode is Factor) or right (if Width Mode is Edge) of the chart element as a fraction of the width of the chart.
Declaration
double Width { get; set; }
Property Value
Type |
---|
System.Double |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()
WidthMode
Specifies how to interpret the Width element for this manual layout.
Declaration
LayoutModes WidthMode { get; set; }
Property Value
Type |
---|
LayoutModes |
Examples
//Open a presentation
IPresentation presentation = Presentation.Open("Template.pptx");
//Get the chart from the first slide
IOfficeChart chart = presentation.Slides[0].Charts[0] as IOfficeChart;
//Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top;
//Get the legend layout
IOfficeChartLayout layout = chart.Legend.Layout;
//Get the manual layout
IOfficeChartManualLayout manualLayout = layout.ManualLayout;
//Modify the manual layout left position
manualLayout.Left = 100;
//Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor;
//Modify the manual layout top position
manualLayout.Top = 100;
//Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor;
//Modify the manual layout height
manualLayout.Height = 120;
//Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor;
//Modify the manual layout width
manualLayout.Width = 100;
//Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge;
//Save the presentation
presentation.Save("Output.pptx");
//Close the presentation
presentation.Close();
'Open a presentation
Dim presentation__1 As IPresentation = Presentation.Open("Template.pptx")
'Get the chart from the first slide
Dim chart As IOfficeChart = TryCast(presentation__1.Slides(0).Charts(0), IOfficeChart)
'Set the legend position
chart.Legend.Position = OfficeLegendPosition.Top
'Get the legend layout
Dim layout As IOfficeChartLayout = chart.Legend.Layout
'Get the manual layout
Dim manualLayout As IOfficeChartManualLayout = layout.ManualLayout
'Modify the manual layout left position
manualLayout.Left = 100
'Modify the manual layout left mode
manualLayout.LeftMode = LayoutModes.factor
'Modify the manual layout top position
manualLayout.Top = 100
'Modify the manual layout top mode
manualLayout.TopMode = LayoutModes.factor
'Modify the manual layout height
manualLayout.Height = 120
'Modify the manual layout height mode
manualLayout.HeightMode = LayoutModes.factor
'Modify the manual layout width
manualLayout.Width = 100
'Modify the manual layout width mode
manualLayout.WidthMode = LayoutModes.edge
'Save the presentation
presentation__1.Save("Output.pptx")
'Close the presentation
presentation__1.Close()