Added style support for noProof option.
Useful for blocks of source code, and possibly other things that cause the grammar and spelling checkers to go nuts. Example usage: run: { font:"Consolas", color: "0000AA", break:1, noProof:true, }, Also added section to .gitignore to exclude Mac .DS_Store files. These are useless on anything other than a Mac.
This commit is contained in:
committed by
Dolan Miu
parent
b1513d4ce9
commit
df619ffe49
3
.gitignore
vendored
3
.gitignore
vendored
@ -59,3 +59,6 @@ My Document.docx
|
||||
|
||||
# Temporary folder
|
||||
tmp
|
||||
|
||||
# Exclude Mac .DS_Store files
|
||||
.DS_Store
|
||||
|
@ -1,3 +1,4 @@
|
||||
// https://www.ecma-international.org/wp-content/uploads/ECMA-376-1_5th_edition_december_2016.zip page 297, section 17.3.2.21
|
||||
import { BorderElement, IBorderOptions } from "@file/border";
|
||||
import { IShadingAttributesProperties, Shading } from "@file/shading";
|
||||
import { ChangeAttributes, IChangedAttributesProperties } from "@file/track-revision/track-revision";
|
||||
@ -34,6 +35,7 @@ export enum TextEffect {
|
||||
}
|
||||
|
||||
export interface IRunStylePropertiesOptions {
|
||||
readonly noProof?: boolean;
|
||||
readonly bold?: boolean;
|
||||
readonly boldComplexScript?: boolean;
|
||||
readonly italics?: boolean;
|
||||
@ -131,7 +133,9 @@ export class RunProperties extends IgnoreIfEmptyXmlComponent {
|
||||
if (!options) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (options.noProof !== undefined) {
|
||||
this.push(new OnOffElement("w:noProof", options.noProof));
|
||||
}
|
||||
if (options.bold !== undefined) {
|
||||
this.push(new OnOffElement("w:b", options.bold));
|
||||
}
|
||||
|
Reference in New Issue
Block a user