Exemple #1
0
        private static EsDocument GetDocument()
        {
            EsDocument pd = new EsDocument();

            pd.PageSize    = "A4";
            pd.PageMargins = new EsMargins()
            {
                Top = 20, Bottom = 20, Left = 20, Right = 20
            };
            EsSection s = new EsSection();

            pd.Sections.Add(s);
            s.Elements.Add(
                new EsImage()
            {
                Base64          = Convert.ToBase64String(ResourcesHelper.GetBin("Resources.Logo.png")),
                HorizontalAlign = EsHorizontalAlign.Center,
                Width           = 75
            }
                );
            s.Elements.Add(
                new EsText()
            {
                Content   = "Overview",
                FontName  = "Verdana",
                FontSize  = 20,
                TextAlign = EsTextAlign.Right
            }
                );
            s.Elements.Add(
                new EsText()
            {
                Content   = ResourcesHelper.GetText("Resources.Overview.txt"),
                FontSize  = 10,
                TextAlign = EsTextAlign.Justified
            }
                );
            return(pd);
        }
Exemple #2
0
 private static EsDocument GetFromJson()
 {
     return(EsGenerator.DeserializeDocument(ResourcesHelper.GetText("Resources.Model.json")));
 }