彩票走势图

【更新】Aspose.Words 2月新版v19.2发布 | 附下载

原创|产品更新|编辑:黄竹雯|2019-02-11 09:54:31.000|阅读 293 次

概述:Word功能开发控件Aspose.Words for .Net更新至19.2。

# 慧都年终大促·界面/图表报表/文档/IDE等千款热门软控件火热促销中 >>

Aspose.Words无需Microsoft Word 也可在任何平台上满足Word文档的一切操作需求。2019年2月Aspose.Words发布v19.2,以下是v19.2更新说明:

Aspose.Words 19.2试用版下载

核心 概述 类别
WORDSNET-14532 改进字体替换API 新增功能
WORDSNET-16111 LINQ报告中的错误处理 新增功能
WORDSNET-15203 当LINQ报告语法不正确时,添加更多有用的异常消息 新增功能
WORDSNET-17047 ActiveX控件渲染//保存为PDF时,单选按钮呈锯齿状 增强
WORDSNET-17725 从HTML导入后,Border的宽度为零 增强
WORDSNET-11331 从DOCX转换为DOC/PDF出现空行 增强
WORDSNET-17405 文本将呈现到下一页 增强
WORDSNET-14851 PDF中的布局与WORD文档中的布局不同 增强
WORDSNET-15008 表格内容与页脚重叠,不会转到PDF格式的下一页 增强
WORDSNET-16413 内容控件在输出PDF中显示在下一个 增强
WORDSNET-17532 单元格中断包含在下一页 增强
WORDSNET-13756 为ReportingEngine.BuildReport抛出有意义的异常 增强
WORDSNET-17950 从Aspose.Words.Tests中提取常用测试代码 增强
WORDSNET-17809 ReportingEngine.buildReport抛出java.lang.IllegalStateException 增强
WORDSNET-17404 内容将下推到输出PDF中的下一页 增强
WORDSNET-18018 DOC / X到PDF - 消耗大量内存并占用太多时间 性能
WORDSNET-17911 加载大ODT文件会占用太多时间 性能
... ... ...

公共API和向后不兼容的更改


这里列出了Aspose.Words 19.2中引入的公共API更改。它不仅包括新的和过时的公共方法,还包括对Aspose.Words中幕后行为的任何变化的描述,这可能会影响现有代码。引入的任何行为都可以被可能修改现有行为,这一点尤为重要,并在此处进行了说明。

调整当保存为PDF时,图像处理问题的警告信息

WORDSNET-17338已经被解决

以前有一个通用警告文本“不支持的图像格式”。现在有一个针对OutOfMemoryException的特定警告,文本“没有足够的内存来加载图像”。以及带有文字的通用警告“无法处理图像。可能不支持的图像格式”。


字体替换过程和公共API的更改

WORDSNET-14532现已解决:

字体提取和替换机制已更改

以前的字体提取过程是:

  1. 确切的字体名称匹配
  2. 从文档中嵌入字体数据
  3. 为字体名称指定的字体替换
  4. FontInfo中的AltName(如果有)和AltName的替代
  5. 如果存在FontInfo并且设置了EnableFontSubstitution,则替换字体
  6. DefaultFontName和DefaultFontName的替代
  7. 可用字体来源的任何字体
  8. “Fanwood”字体嵌入到汇编中

现在字体提取过程是:

  1. 确切的字体名称匹配
  2. 从文档中嵌入字体数据
  3. FontInfo的AltName(如果有的话)
  4. 字体替换规则
    • fontconfig替换
    • 表替换字体名称和alt名称
    • 字体信息替换
    • 默认字体替换
  5. 可用字体来源的任何字体
  6. “Fanwood”字体嵌入到汇编中

为字体替换设置添加了新的公共API。与字体替换相关的之前的API方法/属性已过时

public class FontSettings
{
    /// 
    /// Settings related to font substitution mechanism.
    /// 
    public FontSubstitutionSettings SubstitutionSettings
    { get; }
      
    [Obsolete("This property is obsolete. Please use SubstitutionSettings.DefaultFontSubstitution instead.")]
    public string DefaultFontName
    { get; set; }
          
    [Obsolete("This property is obsolete. Please use SubstitutionSettings.FontInfoSubstitution instead.")]
    public bool EnableFontSubstitution
    { get; set; }
  
    [Obsolete("This method is obsolete. Please use SubstitutionSettings.TableSubstitution instead.")]
    public string[] GetFontSubstitutes(string originalFontName);
          
    [Obsolete("This method is obsolete. Please use SubstitutionSettings.TableSubstitution instead.")]
    public void SetFontSubstitutes(string originalFontName, params string[] substituteFontNames);
          
    [Obsolete("This method is obsolete. Please use SubstitutionSettings.TableSubstitution instead.")]
    public void AddFontSubstitutes(string originalFontName, params string[] substituteFontNames);
}
  
/// 
/// Specifies font substitution mechanism settings.
/// 
/// 
/// 
/// Font substitution process consists of several rules which are checked one by one in specific order.
/// If the first rule can't resolve the font then second rule is checked and so on.
/// The order of the rules is following:
/// 1. Font config substitution rule (disabled by default)
/// 2. Table substitution rule (enabled by default)
/// 3. Font info substitution rule (enabled by default)
/// 4. Default font rule (enabled by default)
/// 
/// 
/// Note that font info substitution rule will always resolve the font if  is available
/// and will override the default font rule. If you want to use the default font rule then you should disable the
/// font info substitution rule. 
/// 
/// 
/// Note that font config substitution rule will resolve the font in most cases and thus overrides all other rules. 
/// 
/// 
public class FontSubstitutionSettings
{        
    /// 
    /// Settings related to table substitution rule.
    /// 
    public TableSubstitutionRule TableSubstitution
    { get; }
  
    /// 
    /// Settings related to font info substitution rule.
    /// 
    public FontInfoSubstitutionRule FontInfoSubstitution
    { get; }
  
    /// 
    /// Settings related to default font substitution rule.
    /// 
    public DefaultFontSubstitutionRule DefaultFontSubstitution
    { get; }
  
    /// 
    /// Settings related to font config substitution rule.
    /// 
    public FontConfigSubstitutionRule FontConfigSubstitution
    { get; }
}
  
/// 
/// This is an abstract base class for the font substitution rule.
/// 
public abstract class FontSubstitutionRule
{
    /// 
    /// Specifies whether the rule is enabled or not.
    /// 
    public bool Enabled
    { get; set; }
}
  
/// 
/// Font config substitution rule.
/// 
/// 
/// 
/// This rule uses fontconfig utility on Linux (and other Unix-like) platforms to get the substitution
/// if the original font is not available.
/// 
/// 
/// If fontconfig utility is not available then this rule will be ignored.
/// 
/// 
public class FontConfigSubstitutionRule : FontSubstitutionRule
{
    /// 
    /// Check if fontconfig utility is available or not.
    /// 
    public bool IsFontConfigAvailable();
  
    /// 
    /// Resets the cache of fontconfig calling results.
    /// 
    public void ResetCache();
}
  
/// 
/// Table font substitution rule.
/// 
/// 
/// This rule defines the list of substitute font names to be used if the original font is not available.
/// Substitutes will be checked for the font name and the  (if any).
/// 
public class TableSubstitutionRule : FontSubstitutionRule
{      
    /// 
    /// Loads table substitution settings from XML file.
    /// 
    /// Input file name.
    public void Load(string fileName);
  
    /// 
    /// Loads table substitution settings from XML stream.
    /// 
    /// Input stream.
    public void Load(Stream stream);
  
    /// 
    /// Loads predefined table substitution settings for Windows platform.
    /// 
    public void LoadWindowsSettings();
          
    /// 
    /// Loads predefined table substitution settings for Linux platform.
    /// 
    public void LoadLinuxSettings();
  
    /// 
    /// Saves the current table substitution settings to file.
    /// 
    /// Output file name.
    public void Save(string fileName);
          
    /// 
    /// Saves the current table substitution settings to stream.
    /// 
    /// Output stream.
    public void Save(Stream outputStream);
  
    /// 
    /// Returns array containing substitute font names for the specified original font name.
    /// 
    /// Original font name.
    /// List of alternative font names.
    public IEnumerable GetSubstitutes(string originalFontName);
        
    /// 
    /// Override substitute font names for given original font name.
    /// 
    /// Original font name.
    /// List of alternative font names.
    public void SetSubstitutes(string originalFontName, IEnumerable substituteFontNames);
  
    /// 
    /// Override substitute font names for given original font name.
    /// 
    /// Original font name.
    /// List of alternative font names.
    public void SetSubstitutes(string originalFontName, params string[] substituteFontNames);
          
    /// 
    /// Adds substitute font names for given original font name.
    /// 
    /// Original font name.
    /// List of alternative font names.
    public void AddSubstitutes(string originalFontName, IEnumerable substituteFontNames);
  
    /// 
    /// Adds substitute font names for given original font name.
    /// 
    /// Original font name.
    /// List of alternative font names.
    public void AddSubstitutes(string originalFontName, params string[] substituteFontNames);
}
  
/// 
/// Font info substitution rule.
/// 
/// 
/// According to this rule Aspose.Words evaluates all the related fields in  (Panose, Sig etc) for
/// the missing font and finds the closest match among the available font sources. If  is not
/// available for the missing font then nothing will be done.
/// 
public class FontInfoSubstitutionRule : FontSubstitutionRule
{ }
  
/// 
/// Default font substitution rule.
/// 
/// 
/// This rule defines single default font name to be used for substitution if the original font is not available.
/// 
public class DefaultFontSubstitutionRule : FontSubstitutionRule
{
    /// 
    /// Gets or sets the default font name.
    /// 
    /// 
    /// The default value is 'Times New Roman'.
    /// 
    public string DefaultFontName
    { get; set; }
}

删除了不推荐使用的公共属性TxtSaveOptions.ExportHeadersFooters

问题:WORDSNET-17560

删除已弃用的公共属性TxtSaveOptions.ExportHeadersFooters:

// Specifies whether to output headers and footers when exporting in plain text format.
// Default value is true.
public bool ExportHeadersFooters

请改用TxtSaveOptions.ExportHeadersFootersMode属性。

想要购买正版授权,或者获取更多Aspsoe.words相关信息的朋友可以点击" "~

标签:文档管理OfficeAspose.words文档处理

本站文章除注明转载外,均为本站原创或翻译。欢迎任何形式的转载,但请务必注明出处、不得修改原文相关链接,如果存在内容上的异议请邮件反馈至chenjj@pclwef.cn

文章转载自:慧都网

为你推荐

  • 推荐视频
  • 推荐活动
  • 推荐产品
  • 推荐文章
  • 慧都慧问
扫码咨询


添加微信 立即咨询

电话咨询

客服热线
023-68661681

TOP