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

toXlsx does not preserve the bold font in comments #76

Closed
stla opened this issue Jan 19, 2017 · 2 comments
Closed

toXlsx does not preserve the bold font in comments #76

stla opened this issue Jan 19, 2017 · 2 comments
Labels

Comments

@stla
Copy link
Contributor

stla commented Jan 19, 2017

Hello,

When I comment a cell in Excel, Excel automatically adds my name at the top of the comment, in bold font.

This is what I get in comment1.xml:

<commentList>
    <comment ref="A1" authorId="0">
        <text>
            <r>
                <rPr><b/><sz val="9"/><color indexed="81"/><rFont val="Tahoma"/><charset val="1"/></rPr>
                <t>Stéphane Laurent:</t>
            </r>
            <r>
                <rPr><sz val="9"/><color indexed="81"/><rFont val="Tahoma"/><charset val="1"/></rPr>
                <t xml:space="preserve">
                    hello</t>
            </r>
        </text>
    </comment>
</commentList>

When I read the xlsx file with toXlsx and when I rewrite it, without modifying anything, my name is not in bold font anymore.

This is the XlsxText I get when I read the file:

XlsxRichText
  [ RichTextRun
      { _richTextRunProperties =
          Just
            RunProperties
              { _runPropertiesBold = Nothing
              , _runPropertiesCharset = Just 1
              , _runPropertiesColor =
                  Just
                    Color
                      { _colorAutomatic = Nothing
                      , _colorARGB = Nothing
                      , _colorTheme = Nothing
                      , _colorTint = Nothing
                      }
              , _runPropertiesCondense = Nothing
              , _runPropertiesExtend = Nothing
              , _runPropertiesFontFamily = Nothing
              , _runPropertiesItalic = Nothing
              , _runPropertiesOutline = Nothing
              , _runPropertiesFont = Just "Tahoma"
              , _runPropertiesScheme = Nothing
              , _runPropertiesShadow = Nothing
              , _runPropertiesStrikeThrough = Nothing
              , _runPropertiesSize = Just 9.0
              , _runPropertiesUnderline = Nothing
              , _runPropertiesVertAlign = Nothing
              }
      , _richTextRunText = "St\233phane Laurent:"
      }
  , RichTextRun
      { _richTextRunProperties =
          Just
            RunProperties
              { _runPropertiesBold = Nothing
              , _runPropertiesCharset = Just 1
              , _runPropertiesColor =
                  Just
                    Color
                      { _colorAutomatic = Nothing
                      , _colorARGB = Nothing
                      , _colorTheme = Nothing
                      , _colorTint = Nothing
                      }
              , _runPropertiesCondense = Nothing
              , _runPropertiesExtend = Nothing
              , _runPropertiesFontFamily = Nothing
              , _runPropertiesItalic = Nothing
              , _runPropertiesOutline = Nothing
              , _runPropertiesFont = Just "Tahoma"
              , _runPropertiesScheme = Nothing
              , _runPropertiesShadow = Nothing
              , _runPropertiesStrikeThrough = Nothing
              , _runPropertiesSize = Just 9.0
              , _runPropertiesUnderline = Nothing
              , _runPropertiesVertAlign = Nothing
              }
      , _richTextRunText = "\r\nhello"
      }
  ]

I think that _runPropertiesBold should be Just True for the first line.

@qrilka
Copy link
Owner

qrilka commented Jan 19, 2017

Hi @stla that seems to be another place that needs to be fixed as a part of #69
I'll create a fix

@qrilka qrilka added the bug label Jan 19, 2017
@qrilka
Copy link
Owner

qrilka commented Jan 19, 2017

Closed by 83907df

@qrilka qrilka closed this as completed Jan 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants