public override void Render(AbstractRendererBase rendererBase, PonyTextContext textContext) { AbstractProcessor abstractProcessor = null; if (CustomProperty.HasProperty(AbstractProcessor.RENDER_PROCESSOR_PROPERTY)) { var processor = CustomProperty.GetProperty(AbstractProcessor.RENDER_PROCESSOR_PROPERTY) as string; abstractProcessor = textContext.ProcessorFactory.GetRenderProcessor(processor); abstractProcessor.PreRendering(textContext, rendererBase, this); } rendererBase.RenderText(Content, CustomProperty); abstractProcessor?.PostRendering(textContext, rendererBase, this); }
public override void Render(AbstractRendererBase rendererBase, PonyTextContext textContext) { rendererBase.StartParagraphRendering(CustomProperty); AbstractProcessor abstractProcessor = null; if (CustomProperty.HasProperty(AbstractProcessor.RENDER_PROCESSOR_PROPERTY)) { var processor = CustomProperty.GetProperty(AbstractProcessor.RENDER_PROCESSOR_PROPERTY) as string; abstractProcessor = textContext.ProcessorFactory.GetRenderProcessor(processor); abstractProcessor.PreRendering(textContext, rendererBase, this); } foreach (var text in texts) { text.Render(rendererBase, textContext); } abstractProcessor?.PostRendering(textContext, rendererBase, this); rendererBase.EndParagraphRendering(); }