Now Spire.Doc support using uninstalled font when converting Doc to PDF to diversity text content. In this article, we'll talk about how to realize this function:

Step 1: Download a font uninstalled in system.

How to use uninstalled font when converting Doc to PDF via Spire.Doc

Step 2: Create a new blank Word document.

Document document = new Document();

Step 3: Add a section and create a new paragraph.

Section section = document.AddSection();
Paragraph paragraph = section.Paragraphs.Count > 0 ? section.Paragraphs[0] : section.AddParagraph();

Step 4: Append text for a txtRange.

TextRange txtRange = paragraph.AppendText(text);

Step 5: Create an example for class ToPdfParameterList named to pdf, and create a new PrivateFontPathlist for property PrivateFontPaths, instantiate one PrivateFontPath with name and path of downloaded font.

ToPdfParameterList toPdf = new ToPdfParameterList()
{
    PrivateFontPaths = new List()
        {
          new PrivateFontPath("DeeDeeFlowers",@"D:\DeeDeeFlowers.ttf")
        }
};

Step 6: Set the new font for the txtaRange.

txtRange.CharacterFormat.FontName = "DeeDeeFlowers";

Step 7: Convert the Doc to PDF.

document.SaveToFile("result.pdf", toPdf);

Step 8: Review converted PDF files.

System.Diagnostics.Process.Start("result.pdf");

Result screenshot:

How to use uninstalled font when converting Doc to PDF via Spire.Doc

Full Code Below:

Document document = new Document();
           
//Add the first secition
Section section = document.AddSection();
//Create a new paragraph and get the first paragraph
Paragraph paragraph
    = section.Paragraphs.Count > 0 ? section.Paragraphs[0] : section.AddParagraph();

//Append Text
String text
    = "This paragraph is demo of text font and color. "
    + "The font name of this paragraph is Tahoma. "
    + "The font size of this paragraph is 20. "
    + "The under line style of this paragraph is DotDot. "
    + "The color of this paragraph is Blue. ";
 TextRange txtRange = paragraph.AppendText(text);

//Import the font
 ToPdfParameterList toPdf = new ToPdfParameterList()
 {
     PrivateFontPaths = new List<PrivateFontPath>()
         {
          new PrivateFontPath("DeeDeeFlowers",@"D:\DeeDeeFlowers.ttf")
         }
};
//Make use of the font.
txtRange.CharacterFormat.FontName = "DeeDeeFlowers";

document.SaveToFile("result.pdf", toPdf);

System.Diagnostics.Process.Start("result.pdf");

To use different versions of PowerPoint document easier, Spire.Presentation enables to convert PowerPoint Presentation 97 – 2003 to PowerPoint Presentation 2007, 2010. Spire.Presentation supports to convert PPT to PPTX, from version 2.2.17, now it starts to load .pps format document and save to .ppsx format document in C#. This article will show you how to convert PPS to PPTX in C#.

Step 1: Create a presentation document.

Presentation presentation = new Presentation();

Step 2: Load the PPS file from disk.

presentation.LoadFromFile("sample.pps");

Step 3: Save the PPS document to PPTX file format.

presentation.SaveToFile("ToPPTX.pptx", FileFormat.Pptx2010);

Step 4: Launch and view the resulted PPTX file.

System.Diagnostics.Process.Start("ToPPTX.pptx");

Full codes:

C#
using Spire.Presentation;
namespace PPStoPPTX
{
    class Program
    {
        static void Main(string[] args)
        {
            Presentation presentation = new Presentation();

            //load the PPS file from disk
            presentation.LoadFromFile("sample.pps");

            //save the PPS document to PPTX file format
            presentation.SaveToFile("ToPPTX.pptx", FileFormat.Pptx2010);
            System.Diagnostics.Process.Start("ToPPTX.pptx");
        }
    }
}
VB.NET
Imports Spire.Presentation
Namespace PPStoPPTX
	Class Program
		Private Shared Sub Main(args As String())
			Dim presentation As New Presentation()

			'load the PPS file from disk
			presentation.LoadFromFile("sample.pps")

			'save the PPS document to PPTX file format
			presentation.SaveToFile("ToPPTX.pptx", FileFormat.Pptx2010)
			System.Diagnostics.Process.Start("ToPPTX.pptx")
		End Sub
	End Class
End Namespace

The result PPTX document:

How to convert PPS document to PPTX in C#

Outline and effects for shapes can make the presentation of your PowerPoint files more attractive. This article talks about how to set the outline and effects for shapes via Spire.Presentation.

Step 1: Create a PowerPoint document.

Presentation ppt = new Presentation();

Step 2: Get the first slide

ISlide slide = ppt.Slides[0];

Step 3: Draw Rectangle shape on slide[0] with methord AppendShape();

IAutoShape shape = slide.Shapes.AppendShape(ShapeType.Rectangle, new RectangleF(50, 100, 100, 50));

Step 4: Set outline color as red.

//Outline color
shape.ShapeStyle.LineColor.Color = Color.Red;

Step 5: Add shadow effect and set parameters for it.

//Effect
PresetShadow shadow = new PresetShadow();
shadow.Preset = PresetShadowValue.FrontRightPerspective;
shadow.Distance = 10.0;
shadow.Direction = 225.0f;
shape.EffectDag.PresetShadowEffect = shadow;

Step 6: Change a Ellipse to add yellow outline with a glow effect:

Change step 4 and 5 as Code:

shape = slide.Shapes.AppendShape(ShapeType.Ellipse, new RectangleF(200, 100, 100, 100));
//Outline color
shape.ShapeStyle.LineColor.Color = Color.Yellow;
//Effect
GlowEffect glow = new GlowEffect();
glow.ColorFormat.Color = Color.Purple;
glow.Radius = 20.0;
shape.EffectDag.GlowEffect = glow;

Step 7: Save and review.

ppt.SaveToFile("Result.pptx", FileFormat.Pptx2010);
System.Diagnostics.Process.Start("Sample.PPTx");

Here is the screen shot:

Set the outline and effects for shapes in PowerPoint files via Spire.Presentation

page 249