pcbnew: import files with case sensitive of extensions

Bug #1720542 reported by Eldar Khayrullin
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
KiCad
Fix Released
Low
Wayne Stambaugh

Bug Description

Affected formats:
- brd (Eagle)
- pcb (PCad)
- ses (Spectra)
- dxf
and kicad formats (kicad_pcb, brd).
It is need to add like (*.dxf;*.DXF) for each.

Application: pcbnew
Version: no-vcs-found-d00fc99~60~ubuntu17.04.1, release build
Libraries:
    wxWidgets 3.0.2
    libcurl/7.52.1 OpenSSL/1.0.2g zlib/1.2.11 libidn2/0.16 libpsl/0.17.0 (+libidn2/0.16) librtmp/2.3
Platform: Linux 4.10.0-35-generic x86_64, 64 bit, Little endian, wxGTK
Build Info:
    wxWidgets: 3.0.2 (wchar_t,wx containers,compatible with 2.8) GTK+ 2.24
    Boost: 1.62.0
    Curl: 7.52.1
    Compiler: GCC 6.3.0 with C++ ABI 1010

Build settings:
    USE_WX_GRAPHICS_CONTEXT=OFF
    USE_WX_OVERLAY=OFF
    KICAD_SCRIPTING=ON
    KICAD_SCRIPTING_MODULES=ON
    KICAD_SCRIPTING_WXPYTHON=ON
    KICAD_SCRIPTING_ACTION_MENU=ON
    BUILD_GITHUB_PLUGIN=ON
    KICAD_USE_OCE=ON
    KICAD_SPICE=ON

Tags: import pcbnew
Revision history for this message
Wayne Stambaugh (stambaughw) wrote :

Are you saying that when the file extensions are upper case that they cannot be selected with the file dialog? If so, what happens when the file extension is mixed case? I'm at work and do not have access to a linux box at the moment and want to be sure that adding the upper case variant to the file dialog wild card is as complete solution.

Revision history for this message
Wayne Stambaugh (stambaughw) wrote :

I answered my own questions and the solution is going to be ugly. Apparently OSX and windows will show any combination of cases with a wildcard like *.dxf. GTK will not but it does support regex so a wild card *.[dD][xX][fF] will do the trick. Unfortunately, this does not work under msw and presumably osx which means we will have to create wildcards with ugly #if defined( GTK )/#else/#endif wrappers. This applies to all wildcards in KiCad not just the ones mentioned in this bug report.

Here is more information:
https://groups.google.com/forum/#!topic/wx-users/hMuDo51ZN4Q

Revision history for this message
Eldar Khayrullin (eldar) wrote :

I think we should use more common cases, like .dxf and .DXF than don't use nothing.
I don't think that programs generate extension like .Dxf or .dXf - that do only man.

Revision history for this message
Eldar Khayrullin (eldar) wrote :

It is problem that some Windows programs save files in upper register (like .DXF) even if one selects lower register (like .dxf) in save dialog (maybe for compatibility with some filesystems)

Revision history for this message
Eldar Khayrullin (eldar) wrote :

Now Kicad support this extension schem in dialog `Select 3D model` in Footprint Properties.

Changed in kicad:
status: New → In Progress
importance: Undecided → Low
assignee: nobody → Wayne Stambaugh (stambaughw)
Revision history for this message
KiCad Janitor (kicad-janitor) wrote :

Fixed in revision 652b969193614727fc9e3de61d7c66aa1f89c089
https://git.launchpad.net/kicad/patch/?id=652b969193614727fc9e3de61d7c66aa1f89c089

Changed in kicad:
status: In Progress → Fix Committed
Changed in kicad:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.