From 941a0eaab8d7ee229302ba2aa5b6e437162819bb Mon Sep 17 00:00:00 2001 From: Steve Genoud Date: Wed, 27 Nov 2019 15:23:58 +0100 Subject: [PATCH] Text in slides does not override the bullet master Otherwise it overrides it by default --- src/gen-objects.ts | 5 +++++ src/gen-xml.ts | 6 ++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/gen-objects.ts b/src/gen-objects.ts index 72f8779f0..b65610939 100644 --- a/src/gen-objects.ts +++ b/src/gen-objects.ts @@ -820,6 +820,11 @@ export function addTextDefinition(target: ISlide, text: string | IText[], opts: opt.color = opt.color || target.color || DEF_FONT_COLOR // Set color (options > inherit from Slide > default to black) } + // A.2: Placeholder should inherit their bullets or override them, so don't default them + if (!opt.placeholder || isPlaceholder) { + opt.bullet = opt.bullet || false + } + // B if (opt.shape && opt.shape.name === 'line') { opt.line = opt.line || '333333' diff --git a/src/gen-xml.ts b/src/gen-xml.ts index ba911a650..587db0aeb 100644 --- a/src/gen-xml.ts +++ b/src/gen-xml.ts @@ -911,8 +911,10 @@ function genXmlParagraphProperties(textObj: ISlideObject | IText, isDefault: boo bulletLvl0Margin + '"' strXmlBullet = '' - } else { - strXmlBullet = '' + } else if ( textObj.options.bullet === false ){ + // We only add this when the user explicitely asks for no bullet. + // Otherwise it can override the master defaults + strXmlBullet = ''; } // B: Close Paragraph-Properties