public void Tables() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2002); Assert.AreEqual(false, compatibilityOptions.AdjustLineHeightInTable); Assert.AreEqual(false, compatibilityOptions.AlignTablesRowByRow); Assert.AreEqual(true, compatibilityOptions.AllowSpaceOfSameStyleInTable); Assert.AreEqual(true, compatibilityOptions.DoNotAutofitConstrainedTables); Assert.AreEqual(true, compatibilityOptions.DoNotBreakConstrainedForcedTable); Assert.AreEqual(false, compatibilityOptions.DoNotBreakWrappedTables); Assert.AreEqual(false, compatibilityOptions.DoNotSnapToGridInCell); Assert.AreEqual(false, compatibilityOptions.DoNotUseHTMLParagraphAutoSpacing); Assert.AreEqual(true, compatibilityOptions.DoNotVertAlignCellWithSp); Assert.AreEqual(false, compatibilityOptions.ForgetLastTabAlignment); Assert.AreEqual(true, compatibilityOptions.GrowAutofit); Assert.AreEqual(false, compatibilityOptions.LayoutRawTableWidth); Assert.AreEqual(false, compatibilityOptions.LayoutTableRowsApart); Assert.AreEqual(false, compatibilityOptions.NoColumnBalance); Assert.AreEqual(false, compatibilityOptions.OverrideTableStyleFontSizeAndJustification); Assert.AreEqual(false, compatibilityOptions.UseSingleBorderforContiguousCells); Assert.AreEqual(true, compatibilityOptions.UseWord2002TableStyleRules); Assert.AreEqual(false, compatibilityOptions.UseWord2010TableStyleRules); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.Tables.docx"); }
public void Spacing() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.AutoSpaceLikeWord95); Assert.AreEqual(true, compatibilityOptions.DisplayHangulFixedWidth); Assert.AreEqual(false, compatibilityOptions.NoExtraLineSpacing); Assert.AreEqual(false, compatibilityOptions.NoLeading); Assert.AreEqual(false, compatibilityOptions.NoSpaceRaiseLower); Assert.AreEqual(false, compatibilityOptions.SpaceForUL); Assert.AreEqual(false, compatibilityOptions.SpacingInWholePoints); Assert.AreEqual(false, compatibilityOptions.SuppressBottomSpacing); Assert.AreEqual(false, compatibilityOptions.SuppressSpBfAfterPgBrk); Assert.AreEqual(false, compatibilityOptions.SuppressSpacingAtTopOfPage); Assert.AreEqual(false, compatibilityOptions.SuppressTopSpacing); Assert.AreEqual(false, compatibilityOptions.UlTrailSpace); // In the output document, these settings can be accessed in Microsoft Word via // File -> Options -> Advanced -> Compatibility options for... doc.Save(ArtifactsDir + "CompatibilityOptions.Spacing.docx"); }
public void Misc() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.BalanceSingleByteDoubleByteWidth); Assert.AreEqual(false, compatibilityOptions.ConvMailMergeEsc); Assert.AreEqual(false, compatibilityOptions.DoNotExpandShiftReturn); Assert.AreEqual(false, compatibilityOptions.DoNotLeaveBackslashAlone); Assert.AreEqual(false, compatibilityOptions.DoNotSuppressParagraphBorders); Assert.AreEqual(true, compatibilityOptions.DoNotUseIndentAsNumberingTabStop); Assert.AreEqual(false, compatibilityOptions.PrintBodyTextBeforeHeader); Assert.AreEqual(false, compatibilityOptions.PrintColBlack); Assert.AreEqual(true, compatibilityOptions.SelectFldWithFirstOrLastChar); Assert.AreEqual(false, compatibilityOptions.SubFontBySize); Assert.AreEqual(false, compatibilityOptions.SwapBordersFacingPgs); Assert.AreEqual(false, compatibilityOptions.TransparentMetafiles); Assert.AreEqual(true, compatibilityOptions.UseAnsiKerningPairs); Assert.AreEqual(false, compatibilityOptions.UseFELayout); Assert.AreEqual(false, compatibilityOptions.UsePrinterMetrics); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.Misc.docx"); }
public void List() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(true, compatibilityOptions.UnderlineTabInNumList); Assert.AreEqual(true, compatibilityOptions.UseNormalStyleForList); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.List.docx"); }
public void List() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(true, compatibilityOptions.UnderlineTabInNumList); Assert.AreEqual(true, compatibilityOptions.UseNormalStyleForList); // In the output document, these settings can be accessed in Microsoft Word via // File -> Options -> Advanced -> Compatibility options for... doc.Save(ArtifactsDir + "CompatibilityOptions.List.docx"); }
public void Alignment() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(true, compatibilityOptions.CachedColBalance); Assert.AreEqual(true, compatibilityOptions.DoNotVertAlignInTxbx); Assert.AreEqual(true, compatibilityOptions.DoNotWrapTextWithPunct); Assert.AreEqual(false, compatibilityOptions.NoTabHangInd); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.Alignment.docx"); }
public void Legacy() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.FootnoteLayoutLikeWW8); Assert.AreEqual(false, compatibilityOptions.LineWrapLikeWord6); Assert.AreEqual(false, compatibilityOptions.MWSmallCaps); Assert.AreEqual(false, compatibilityOptions.ShapeLayoutLikeWW8); Assert.AreEqual(false, compatibilityOptions.UICompat97To2003); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.Legacy.docx"); }
public void WordPerfect() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.SuppressTopSpacingWP); Assert.AreEqual(false, compatibilityOptions.TruncateFontHeightsLikeWP6); Assert.AreEqual(false, compatibilityOptions.WPJustification); Assert.AreEqual(false, compatibilityOptions.WPSpaceWidth); Assert.AreEqual(false, compatibilityOptions.WrapTrailSpaces); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.WordPerfect.docx"); }
public void Alignment() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(true, compatibilityOptions.CachedColBalance); Assert.AreEqual(true, compatibilityOptions.DoNotVertAlignInTxbx); Assert.AreEqual(true, compatibilityOptions.DoNotWrapTextWithPunct); Assert.AreEqual(false, compatibilityOptions.NoTabHangInd); // In the output document, these settings can be accessed in Microsoft Word via // File -> Options -> Advanced -> Compatibility options for... doc.Save(ArtifactsDir + "CompatibilityOptions.Alignment.docx"); }
public void Breaks() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.ApplyBreakingRules); Assert.AreEqual(true, compatibilityOptions.DoNotUseEastAsianBreakRules); Assert.AreEqual(false, compatibilityOptions.ShowBreaksInFrames); Assert.AreEqual(true, compatibilityOptions.SplitPgBreakAndParaMark); Assert.AreEqual(true, compatibilityOptions.UseAltKinsokuLineBreakRules); Assert.AreEqual(false, compatibilityOptions.UseWord97LineBreakRules); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.Breaks.docx"); }
public void Legacy() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.FootnoteLayoutLikeWW8); Assert.AreEqual(false, compatibilityOptions.LineWrapLikeWord6); Assert.AreEqual(false, compatibilityOptions.MWSmallCaps); Assert.AreEqual(false, compatibilityOptions.ShapeLayoutLikeWW8); Assert.AreEqual(false, compatibilityOptions.UICompat97To2003); // In the output document, these settings can be accessed in Microsoft Word via // File -> Options -> Advanced -> Compatibility options for... doc.Save(ArtifactsDir + "CompatibilityOptions.Legacy.docx"); }
public void WordPerfect() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.SuppressTopSpacingWP); Assert.AreEqual(false, compatibilityOptions.TruncateFontHeightsLikeWP6); Assert.AreEqual(false, compatibilityOptions.WPJustification); Assert.AreEqual(false, compatibilityOptions.WPSpaceWidth); Assert.AreEqual(false, compatibilityOptions.WrapTrailSpaces); // In the output document, these settings can be accessed in Microsoft Word via // File -> Options -> Advanced -> Compatibility options for... doc.Save(ArtifactsDir + "CompatibilityOptions.WordPerfect.docx"); }
public void Breaks() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.ApplyBreakingRules); Assert.AreEqual(true, compatibilityOptions.DoNotUseEastAsianBreakRules); Assert.AreEqual(false, compatibilityOptions.ShowBreaksInFrames); Assert.AreEqual(true, compatibilityOptions.SplitPgBreakAndParaMark); Assert.AreEqual(true, compatibilityOptions.UseAltKinsokuLineBreakRules); Assert.AreEqual(false, compatibilityOptions.UseWord97LineBreakRules); // In the output document, these settings can be accessed in Microsoft Word via // File -> Options -> Advanced -> Compatibility options for... doc.Save(ArtifactsDir + "CompatibilityOptions.Breaks.docx"); }
public void Spacing() { Document doc = new Document(); CompatibilityOptions compatibilityOptions = doc.CompatibilityOptions; compatibilityOptions.OptimizeFor(MsWordVersion.Word2000); Assert.AreEqual(false, compatibilityOptions.AutoSpaceLikeWord95); Assert.AreEqual(true, compatibilityOptions.DisplayHangulFixedWidth); Assert.AreEqual(false, compatibilityOptions.NoExtraLineSpacing); Assert.AreEqual(false, compatibilityOptions.NoLeading); Assert.AreEqual(false, compatibilityOptions.NoSpaceRaiseLower); Assert.AreEqual(false, compatibilityOptions.SpaceForUL); Assert.AreEqual(false, compatibilityOptions.SpacingInWholePoints); Assert.AreEqual(false, compatibilityOptions.SuppressBottomSpacing); Assert.AreEqual(false, compatibilityOptions.SuppressSpBfAfterPgBrk); Assert.AreEqual(false, compatibilityOptions.SuppressSpacingAtTopOfPage); Assert.AreEqual(false, compatibilityOptions.SuppressTopSpacing); Assert.AreEqual(false, compatibilityOptions.UlTrailSpace); // These options will become available in File > Options > Advanced > Compatibility Options in the output document doc.Save(ArtifactsDir + "CompatibilityOptions.Spacing.docx"); }