LayoutTargetType

ChartPlotArea.LayoutTargetType 属性

如果绘图区的布局是手动定义的,则此属性指定是按内部(不包括轴和轴标签)还是按外部(包括轴和轴标签)布局绘图区。可读写 LayoutTargetType

public LayoutTargetType LayoutTargetType { get; set; }

示例

using (Presentation presentation = new Presentation())

    ISlide slide = presentation.Slides[0];
    IChart chart = slide.Shapes.AddChart(ChartType.ClusteredColumn, 20, 100, 600, 400);

    chart.PlotArea.AsILayoutable.X = 0.2f;
    chart.PlotArea.AsILayoutable.Y = 0.2f;
    chart.PlotArea.AsILayoutable.Width = 0.7f;
    chart.PlotArea.AsILayoutable.Height = 0.7f;

    chart.PlotArea.LayoutTargetType = LayoutTargetType.Inner;
    ...

另见