Excel.Interfaces.ShapeFontUpdateData interface

一个用于更新 ShapeFont 对象上的数据的接口, 可用于 "shapeFont (An interface for updating data on the ShapeFont object, for use in "shapeFont.set({ ... })".

属性

bold

表示字体的加粗状态。Represents the bold status of font. 如果 TextRange 包含粗体和非粗体文本片段,则返回 null。Returns null the TextRange includes both bold and non-bold text fragments.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

color

文本颜色的 HTML 颜色代码表示形式 (例如, "#FF0000" 代表红色)。The HTML color code representation of the text color (e.g. "#FF0000" represents red). 如果 TextRange 包含具有不同颜色的文本片段,则返回 null。Returns null if the TextRange includes text fragments with different colors.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

italic

表示字体的斜体状态。Represents the italic status of font. 如果 TextRange 包含斜体和非斜体文本片段,则返回 null。Returns null if the TextRange includes both italic and non-italic text fragments.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

name

表示字体名称(例如“Calibri”)。Represents font name (e.g. "Calibri"). 如果文本是复杂脚本或东亚语言,则这是相应的字体名称,否则是拉丁字体名称。If the text is Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

size

表示以磅为单位的字体大小(例如 11)。Represents font size in points (e.g. 11). 如果 TextRange 包含具有不同字体大小的文本片段,则返回 null。Returns null if the TextRange includes text fragments with different font sizes.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

underline

应用于字体的下划线类型。Type of underline applied to the font. 如果 TextRange 包含具有不同下划线样式的文本片段,则返回 null。Returns null if the TextRange includes text fragments with different underline styles. 有关详细信息,请参阅 Excel.ShapeFontUnderlineStyle。See Excel.ShapeFontUnderlineStyle for details.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

属性详细信息

bold

表示字体的加粗状态。Represents the bold status of font. 如果 TextRange 包含粗体和非粗体文本片段,则返回 null。Returns null the TextRange includes both bold and non-bold text fragments.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

bold?: boolean;

属性值

boolean

color

文本颜色的 HTML 颜色代码表示形式 (例如, "#FF0000" 代表红色)。The HTML color code representation of the text color (e.g. "#FF0000" represents red). 如果 TextRange 包含具有不同颜色的文本片段,则返回 null。Returns null if the TextRange includes text fragments with different colors.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

color?: string;

属性值

string

italic

表示字体的斜体状态。Represents the italic status of font. 如果 TextRange 包含斜体和非斜体文本片段,则返回 null。Returns null if the TextRange includes both italic and non-italic text fragments.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

italic?: boolean;

属性值

boolean

name

表示字体名称(例如“Calibri”)。Represents font name (e.g. "Calibri"). 如果文本是复杂脚本或东亚语言,则这是相应的字体名称,否则是拉丁字体名称。If the text is Complex Script or East Asian language, this is the corresponding font name; otherwise it is the Latin font name.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

name?: string;

属性值

string

size

表示以磅为单位的字体大小(例如 11)。Represents font size in points (e.g. 11). 如果 TextRange 包含具有不同字体大小的文本片段,则返回 null。Returns null if the TextRange includes text fragments with different font sizes.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

size?: number;

属性值

number

underline

应用于字体的下划线类型。Type of underline applied to the font. 如果 TextRange 包含具有不同下划线样式的文本片段,则返回 null。Returns null if the TextRange includes text fragments with different underline styles. 有关详细信息,请参阅 Excel.ShapeFontUnderlineStyle。See Excel.ShapeFontUnderlineStyle for details.

[API 集: ExcelApi 1.9][ API set: ExcelApi 1.9 ]

underline?: Excel.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble";

属性值

Excel.ShapeFontUnderlineStyle | "None" | "Single" | "Double" | "Heavy" | "Dotted" | "DottedHeavy" | "Dash" | "DashHeavy" | "DashLong" | "DashLongHeavy" | "DotDash" | "DotDashHeavy" | "DotDotDash" | "DotDotDashHeavy" | "Wavy" | "WavyHeavy" | "WavyDouble"