I think that is normal.

Word will present you with a localized name for the "standard" word styles.

I myself modify the standard word styles in spanish in my reference doc (Título 1, Título 2, etc.) and it all works as expected with pandoc.

That's the reason why Word won't let you define a new "Title" style, because it is already there (only you see it with your localized name).

Best regards,
  Agustín.


On Thursday, May 23, 2019 at 5:03:14 PM UTC+2, Denis Maier wrote:
Hi,

I am trying to go from DOCX to Markdown. As reported here (https://groups.google.com/forum/#!searchin/pandoc-discuss/author$20title$20docx%7Csort:date/pandoc-discuss/R_o0pLxGOG0/8lzV-bKbCgAJ) I am having issues with Word styles, namely with the title style. As soon as I save my files, Word insists on changing the style name from "Title" to "Titel", and I cannot change it back which is really weird. (I cannot even create a new style with the name "Title" -- Word will rename this style to "Titel1".)

Anyway, I thought this might be a good job for a lua filter, but I am unable to code this myself. I have tried this, but it won't change the style.

```

function CorrectTitle(blk)

           local search = pandoc.Attr()

           local repl = pandoc.Attr()

           search.attributes["custom-style"] = "Titel"

           repl.attributes["custom-style"] = "Title"

           if (blk.t == "Div" and blk.attributes == search.attributes) then

                     return pandoc.Div({blk},repl)

           end

end


```

Any suggestions?

Best,
Denis


--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/3df97404-194e-4269-b0b5-8a6268e86e66%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.