Problem with unicode in menu after switching language

Here's the place for discussion related to coding in FreeCAD, C++ or Python. Design, interfaces and structures.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
User avatar
Roy_043
Veteran
Posts: 8450
Joined: Thu Dec 27, 2018 12:28 pm

Problem with unicode in menu after switching language

Post by Roy_043 »

I want to change "Bezier tools" to "Bézier tools" (with accent aigu) in a Draft menu. This works fine. But after changing the GUI language the e with accent aigu gets mangled.

Test:
  • Switch to the Draft WB.
  • Run this code:

    Code: Select all

    wb = Gui.activeWorkbench()
    wb.appendMenu(["Drafting 2", "Bézier tools"], "Draft_BezCurve")
  • Switch to another WB and then back to the Draft WB.
  • Test the "Drafting 2" menu: the e with accent aigu looks fine.
  • Change the GUI language.
  • Again test the "Drafting 2" menu: the e with accent aigu is mangled. See image.
  • Note that it does not matter what the initial GUI language is.
Is this a bug? Or do I need to use a particular encoding?
Attachments
problem-unicode-in-menu.png
problem-unicode-in-menu.png (3 KiB) Viewed 1808 times
Post Reply