View Issue Details

IDProjectCategoryView StatusLast Update
0032409CommunityOCCT:Data Exchangepublic2021-07-28 12:03
Reporterlucas_morona_164500 Assigned Tobugmaster  
PrioritynormalSeveritymajor 
Status closedResolutionunable to reproduce 
PlatformWindowsOSWindows 
Product Version7.3.0 
Target Version7.6.0 
Summary0032409: Bug in OCC with german letter
DescriptionI have a bug in open cascade and i need create a bug in forum, the is open cascade do not import file with German letter "ä​"
Steps To Reproduceimport a file with German letter "ä​"
TagsNo tags attached.
Test case number

Attached Files

  • Schulungen&Präsentation1.dxf (138,916 bytes)

Relationships

has duplicate 0032410 closedbugmaster Community Bug in DXF import 
has duplicate 0032413 closedbugmaster Community Bug in DXF import 

Activities

lucas_morona_164500

2021-06-01 10:20

reporter  

Schulungen&Präsentation1.dxf (138,916 bytes)

kgv

2021-06-01 10:43

developer   ~0101535

Last edited: 2021-06-02 17:57

Dear lucas.

The file is opened fine in CAD Assistant based on OCCT 7.5.0.

Please share the code snippet used for loading the file (and preferably check on newer version of OCCT).

lucas_morona_164500

2021-06-11 17:00

reporter   ~0101788

The version of OCC is 7.3.0 not 7.5.0,

    Handle(TDocStd_Document) document;
    Handle(XCAFApp_Application) application = XCAFApp_Application::GetApplication();

    application->NewDocument(m_filePath.toLatin1().constData(), document);
    DXFCAFControl_Reader dxfReaderLayer;
    dxfReaderLayer.SetNameMode(true);
    dxfReaderLayer.ReadFile(static_cast<Standard_CString>(m_filePath.toLatin1().constData()));

    dxfReaderLayer.Transfer(document);
    TDF_Label rootLabel = document->Main();

    m_filePath is the path of file;

kgv

2021-06-11 17:09

developer   ~0101789

> dxfReaderLayer.ReadFile(static_cast<Standard_CString (m_filePath.toLatin1().constData()));

You are converting string into Latin code page which leads to data loss of non-Latin symbols.
Presuming that m_filePath is a QString, the conversion normally looks like this:

> TCollection_AsciiString aFilePathUtf8 (m_filePath.toUtf8().constData());
> dxfReaderLayer.ReadFile (aFilePathUtf8.ToCString());

lucas_morona_164500

2021-06-16 12:03

reporter   ~0101863

I tested is working thank you very much?

Issue History

Date Modified Username Field Change
2021-06-01 10:20 lucas_morona_164500 New Issue
2021-06-01 10:20 lucas_morona_164500 Assigned To => msv
2021-06-01 10:20 lucas_morona_164500 File Added: Schulungen&Präsentation1.dxf
2021-06-01 10:43 kgv Note Added: 0101535
2021-06-01 10:43 kgv Assigned To msv => lucas_morona_164500
2021-06-01 10:43 kgv Status new => feedback
2021-06-01 10:43 kgv Category OCCT:Modeling Algorithms => OCCT:Data Exchange
2021-06-01 10:44 kgv Resolution open => unable to reproduce
2021-06-01 10:44 kgv Target Version => 7.6.0
2021-06-01 15:07 kgv Relationship added has duplicate 0032410
2021-06-02 17:54 kgv Relationship added has duplicate 0032413
2021-06-02 17:57 kgv Note Edited: 0101535
2021-06-11 17:00 lucas_morona_164500 Note Added: 0101788
2021-06-11 17:09 kgv Note Added: 0101789
2021-06-16 12:03 lucas_morona_164500 Note Added: 0101863
2021-06-16 12:06 kgv Assigned To lucas_morona_164500 => bugmaster
2021-07-28 12:03 bugmaster Status feedback => closed