Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: compatible office2016 #1083

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

fix: compatible office2016 #1083

wants to merge 1 commit into from

Conversation

xtgdgwg
Copy link

@xtgdgwg xtgdgwg commented Mar 21, 2022

Office2016 and 2019 error

<a:p>
    <a:pPr algn="l" marL="115570" indent="-115570">
        <a:lnSpc>
            <a:spcPts val="1600"/>
        </a:lnSpc>
        <a:buSzPct val="100000"/>
        <a:buChar char="&#x2022;"/>
    </a:pPr>
    <a:pPr algn="l">
        <a:lnSpc>
            <a:spcPts val="1400"/>
        </a:lnSpc>
    </a:pPr>
    <a:r>
        <a:rPr lang="en-US" sz="1000" dirty="0">
            <a:solidFill>
                <a:srgbClr val="14161A"/>
            </a:solidFill>
            <a:latin typeface="微软雅黑" pitchFamily="34" charset="0"/>
            <a:ea typeface="微软雅黑" pitchFamily="34" charset="-122"/>
            <a:cs typeface="微软雅黑" pitchFamily="34" charset="-120"/>
        </a:rPr>
        <a:t>基于“人机共智”的安全运营服务,围绕业务的“</a:t>
    </a:r>
    <a:pPr algn="l" marL="115570" indent="-115570">
        <a:lnSpc>
            <a:spcPts val="1600"/>
        </a:lnSpc>
        <a:buSzPct val="100000"/>
        <a:buChar char="&#x2022;"/>
    </a:pPr>
    <a:pPr algn="l">
        <a:lnSpc>
            <a:spcPts val="1400"/>
        </a:lnSpc>
    </a:pPr>
    <a:r>
        <a:rPr lang="en-US" sz="1000" b="1" dirty="0">
            <a:solidFill>
                <a:srgbClr val="14161A"/>
            </a:solidFill>
            <a:latin typeface="微软雅黑" pitchFamily="34" charset="0"/>
            <a:ea typeface="微软雅黑" pitchFamily="34" charset="-122"/>
            <a:cs typeface="微软雅黑" pitchFamily="34" charset="-120"/>
        </a:rPr>
        <a:t>资产、漏洞、威胁、事件</a:t>
    </a:r>
    <a:pPr algn="l" marL="115570" indent="-115570">
        <a:lnSpc>
            <a:spcPts val="1600"/>
        </a:lnSpc>
        <a:buSzPct val="100000"/>
        <a:buChar char="&#x2022;"/>
    </a:pPr>
    <a:pPr algn="l">
        <a:lnSpc>
            <a:spcPts val="1400"/>
        </a:lnSpc>
    </a:pPr>
    <a:r>
        <a:rPr lang="en-US" sz="1000" dirty="0">
            <a:solidFill>
                <a:srgbClr val="14161A"/>
            </a:solidFill>
            <a:latin typeface="微软雅黑" pitchFamily="34" charset="0"/>
            <a:ea typeface="微软雅黑" pitchFamily="34" charset="-122"/>
            <a:cs typeface="微软雅黑" pitchFamily="34" charset="-120"/>
        </a:rPr>
        <a:t>”四个核心要素,提供</a:t>
    </a:r>
    <a:pPr algn="l" marL="115570" indent="-115570">
        <a:lnSpc>
            <a:spcPts val="1600"/>
        </a:lnSpc>
        <a:buSzPct val="100000"/>
        <a:buChar char="&#x2022;"/>
    </a:pPr>
    <a:pPr algn="l">
        <a:lnSpc>
            <a:spcPts val="1400"/>
        </a:lnSpc>
    </a:pPr>
    <a:r>
        <a:rPr lang="en-US" sz="1000" b="1" dirty="0">
            <a:solidFill>
                <a:srgbClr val="14161A"/>
            </a:solidFill>
            <a:latin typeface="微软雅黑" pitchFamily="34" charset="0"/>
            <a:ea typeface="微软雅黑" pitchFamily="34" charset="-122"/>
            <a:cs typeface="微软雅黑" pitchFamily="34" charset="-120"/>
        </a:rPr>
        <a:t>风险可知、风险可控、风险可管</a:t>
    </a:r>
    <a:pPr algn="l">
        <a:lnSpc>
            <a:spcPts val="1400"/>
        </a:lnSpc>
    </a:pPr>
    <a:r>
        <a:rPr lang="en-US" sz="1000" dirty="0">
            <a:solidFill>
                <a:srgbClr val="14161A"/>
            </a:solidFill>
            <a:latin typeface="微软雅黑" pitchFamily="34" charset="0"/>
            <a:ea typeface="微软雅黑" pitchFamily="34" charset="-122"/>
            <a:cs typeface="微软雅黑" pitchFamily="34" charset="-120"/>
        </a:rPr>
        <a:t>。</a:t>
    </a:r>
    <a:endParaRPr lang="en-US" sz="800" dirty="0"/>
</a:p>

to change to this format :

<a:p>
  <a:pPr marL="115570" indent="-115570" algn="l">
      <a:lnSpc>
          <a:spcPts val="1600"/>
      </a:lnSpc>
      <a:buSzPct val="100000"/>
      <a:buChar char=""/>
  </a:pPr>
  <a:r>
      <a:rPr lang="en-US" sz="1000" dirty="0">
          <a:solidFill>
              <a:srgbClr val="14161A"/>
          </a:solidFill>
          <a:latin typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:ea typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:cs typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-120"/>
      </a:rPr>
      <a:t>基于“人机共智”的安全运营服务,围绕业务的“</a:t>
  </a:r>
  <a:r>
      <a:rPr lang="en-US" sz="1000" b="1" dirty="0">
          <a:solidFill>
              <a:srgbClr val="14161A"/>
          </a:solidFill>
          <a:latin typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:ea typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:cs typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-120"/>
      </a:rPr>
      <a:t>资产、漏洞、威胁、事件</a:t>
  </a:r>
  <a:r>
      <a:rPr lang="en-US" sz="1000" dirty="0">
          <a:solidFill>
              <a:srgbClr val="14161A"/>
          </a:solidFill>
          <a:latin typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:ea typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:cs typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-120"/>
      </a:rPr>
      <a:t>”四个核心要素,提供</a:t>
  </a:r>
  <a:r>
      <a:rPr lang="en-US" sz="1000" dirty="0">
          <a:solidFill>
              <a:srgbClr val="14161A"/>
          </a:solidFill>
          <a:latin typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:ea typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-122"/>
          <a:cs typeface="微软雅黑" panose="020B0503020204020204" pitchFamily="34" charset="-120"/>
      </a:rPr>
      <a:t>。</a:t>
  </a:r>
  <a:endParaRPr lang="en-US" sz="800" dirty="0"/>
</a:p>

Can this be modified?

@gitbrent
Copy link
Owner

I'd like to know what the issue being fixed here consists of.

Is it your observation that not having <a:pPr> tags after each <a:r> makes the presentation incompatible with older versions of PowerPoint?

Diff:
Screen Shot 2022-03-27 at 13 17 57

@xtgdgwg
Copy link
Author

xtgdgwg commented Mar 28, 2022

I am in the 2016 version,
<a:Ppr> can only appear in the first place in <a:P>,
If it appears between <a:r>, an error will be reported
@gitbrent

@xtgdgwg
Copy link
Author

xtgdgwg commented Mar 29, 2022

this compatibility issue
can you solve it here

@reviewher
Copy link

p (of type CT_P) has the following schema:

<xsd:complexType name="CT_P">
  <xsd:sequence>
    <xsd:element name="pPr" type="CT_PPr" minOccurs="0"/>
    <xsd:group ref="EG_PContent" minOccurs="0" maxOccurs="unbounded"/>
  </xsd:sequence>
  <xsd:attribute name="rsidRPr" type="ST_LongHexNumber"/>
  <xsd:attribute name="rsidR" type="ST_LongHexNumber"/>
  <xsd:attribute name="rsidDel" type="ST_LongHexNumber"/>
  <xsd:attribute name="rsidP" type="ST_LongHexNumber"/>
  <xsd:attribute name="rsidRDefault" type="ST_LongHexNumber"/>
</xsd:complexType>

If you follow the chain, EG_PContent includes: fldSimple hyperlink subDoc customXml smartTag sdt dir bdo r proofErr permStart permEnd ins del moveFrom moveTo ... but not pPr.

At the very least, pPr elements after the first r element violate the schema definition.

@gitbrent
Copy link
Owner

gitbrent commented May 2, 2022

Does anyone have sample code that generates the XML output shown at the top?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants