You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Increase the padding of the Title: plotModel.TitlePadding = 20;
Add a custom text annotation under the title, with position relative to PlotAndAxisArea.
public class CustomTextAnnotation : Annotation
{
public CustomTextAnnotation()
{ }
public string Text { get; set; }
public double X { get; set; }
public double Y { get; set; }
public override void Render(IRenderContext rc)
{
base.Render(rc);
double pX = PlotModel.PlotAndAxisArea.Left + X;
double pY = PlotModel.PlotAndAxisArea.Top + Y;
rc.DrawMultilineText(new ScreenPoint(pX, pY), Text, TextColor, Font, FontSize, FontWeight);
}
}
plotModel.Annotations.Add(new CustomTextAnnotation()
{
Text = YAxisTitle,
X = 0,
Y = -16,
Font = "Whatever you like",
FontSize = 12,
TextColor = OxyColors.Black
});
Activity
datafj commentedon Feb 14, 2021
Here is my temporary solution for this issue:
plotModel.TitlePadding = 20;VisualMelon commentedon Feb 14, 2021
Linking #1640 where I'm working on a more general solution