private static void SetShowInBalloons(string dataDir) { // ExStart:SetShowInBalloons Document doc = new Document(dataDir + "Revisions.docx"); // Get the RevisionOptions object that controls the appearance of revisions RevisionOptions revisionOptions = doc.LayoutOptions.RevisionOptions; // Show deletion revisions in balloon revisionOptions.ShowInBalloons = ShowInBalloons.FormatAndDelete; doc.Save(dataDir + "Revisions.ShowRevisionsInBalloons_out.pdf"); // ExEnd:SetShowInBalloons Console.WriteLine("\nFile saved at " + dataDir); }
public void RevisionOptions() { //ExStart //ExFor:ShowInBalloons //ExFor:RevisionOptions.ShowInBalloons //ExFor:RevisionOptions.CommentColor //ExFor:RevisionOptions.DeletedTextColor //ExFor:RevisionOptions.DeletedTextEffect //ExFor:RevisionOptions.InsertedTextEffect //ExFor:RevisionOptions.MovedFromTextColor //ExFor:RevisionOptions.MovedFromTextEffect //ExFor:RevisionOptions.MovedToTextColor //ExFor:RevisionOptions.MovedToTextEffect //ExFor:RevisionOptions.RevisedPropertiesColor //ExFor:RevisionOptions.RevisedPropertiesEffect //ExFor:RevisionOptions.RevisionBarsColor //ExFor:RevisionOptions.RevisionBarsWidth //ExFor:RevisionOptions.ShowOriginalRevision //ExFor:RevisionOptions.ShowRevisionMarks //ExFor:RevisionTextEffect //ExSummary:Shows how to edit appearance of revisions. Document doc = new Document(MyDir + "Revisions.docx"); // Get the RevisionOptions object that controls the appearance of revisions. RevisionOptions revisionOptions = doc.LayoutOptions.RevisionOptions; // Render insertion revisions in green and italic. revisionOptions.InsertedTextColor = RevisionColor.Green; revisionOptions.InsertedTextEffect = RevisionTextEffect.Italic; // Render deletion revisions in red and bold. revisionOptions.DeletedTextColor = RevisionColor.Red; revisionOptions.DeletedTextEffect = RevisionTextEffect.Bold; // In a movement revision, the same text will appear twice: // once at the departure point and once at the arrival destination. // Render the text at the moved-from revision yellow with a double strike through // and double-underlined blue at the moved-to revision. revisionOptions.MovedFromTextColor = RevisionColor.Yellow; revisionOptions.MovedFromTextEffect = RevisionTextEffect.DoubleStrikeThrough; revisionOptions.MovedToTextColor = RevisionColor.Blue; revisionOptions.MovedFromTextEffect = RevisionTextEffect.DoubleUnderline; // Render format revisions in dark red and bold. revisionOptions.RevisedPropertiesColor = RevisionColor.DarkRed; revisionOptions.RevisedPropertiesEffect = RevisionTextEffect.Bold; // Place a thick dark blue bar on the left side of the page next to lines affected by revisions. revisionOptions.RevisionBarsColor = RevisionColor.DarkBlue; revisionOptions.RevisionBarsWidth = 15.0f; // Show revision marks and original text. revisionOptions.ShowOriginalRevision = true; revisionOptions.ShowRevisionMarks = true; // Get movement, deletion, formatting revisions and comments to show up in green balloons // on the right side of the page. revisionOptions.ShowInBalloons = ShowInBalloons.Format; revisionOptions.CommentColor = RevisionColor.BrightGreen; // These features are only applicable to formats such as .pdf or .jpg. doc.Save(ArtifactsDir + "Revision.RevisionOptions.pdf"); //ExEnd }