public override void Render (TileRenderContext ctx) { if (head_template == null) { head_template = new Template ("template-head.html"); PopulateTemplate (head_template); } ctx.Write (head_template.ToString ()); RenderTiles (ctx); if (foot_template == null) { foot_template = new Template ("template-foot.html"); PopulateTemplate (foot_template); } ctx.Write (foot_template.ToString ()); }
private void RenderStyles (TileRenderContext ctx) { if (style_attributes == null) ScanAssembly (Assembly.GetExecutingAssembly ()); if (style_templates == null) { GetFontSettings (); style_templates = new ArrayList (); foreach (TileStyleAttribute attr in style_attributes) { Template t = new Template (attr.Resource); t["FontFamily"] = preferred_font_family; t["FontSize"] = preferred_font_size.ToString (); style_templates.Add (t); } } foreach (Template t in style_templates) { ctx.Write (t.ToString ()); } }
private void PopulateTemplate (Template t) { }