if(ip.X + sWidth > doc.PageSize.Width&& i < images.Count()-1)
{
ip.X = margin;
ip.Y += sHeight;
if(ip.Y + sHeight > doc.PageSize.Height)
{
g = doc.NewPage().Graphics;
ip.Y = margin;
}
}
}
// Done:
doc.Save(stream);
// Dispose images after saving the PDF:
images.ForEach(t_ => t_.Item2.Dispose());
return doc.Pages.Count;
}
publicstaticList<string[]>GetSampleParamsList()
{
// Strings are name, description, info, rest are arbitrary strings:
returnnewList<string[]>()
{
newstring[]{"@b-svg/Font Awesome - brands","Render Font Awesome SVG glyphs from the \"svgs/brands\" directory",
"This sample renders the SVG icons included in the \"svgs/brands/\" directory of the Font Awesome \"Free for Web\" download, sorted by file name.",
"brands"},
newstring[]{"@b-svg/Font Awesome - regular","Render Font Awesome SVG glyphs from the \"svgs/regular\" directory",
"This sample renders the SVG icons included in the \"svgs/regular/\" directory of the Font Awesome \"Free for Web\" download, sorted by file name.",
"regular"},
newstring[]{"@b-svg/Font Awesome - solid","Render Font Awesome SVG glyphs from the \"svgs/solid\" directory",
"This sample renders the SVG icons included in the \"svgs/solid/\" directory of the Font Awesome \"Free for Web\" download, sorted by file name.",
"solid"},
newstring[]{"@b-svg/Font Awesome - colorize","Render Font Awesome SVG glyphs using random order and colors",
"This sample renders the SVG icons included in the \"svgs/\" directory of the Font Awesome \"Free for Web\" download, randomizing the order of the icons and their colors.",