Fp editor export writes files with no newlines or indentation, normal save is not affected
Description
When using the export function in the footprint editor, the resulting files have incorrect formatting. All newlines and tabs are replaced by a single space. It seems to be folding all whitespace together.
Saving instead of exporting works as expected.
Confirmed with 9.0.2 on Windows 10 and on Linux with Flatpak (below)
Example exported file: PowerPAK_SO-8L_Single.kicad_mod
Example saved file: PowerPAK_SO-8L_Single.kicad_mod
Steps to reproduce
- Open any fp in the fp editor
- File -> Export -> Footprint and select a location
- Compare the resulting file to the original file you opened
KiCad Version
Application: KiCad Footprint Editor x86_64 on x86_64
Version: 9.0.2, release build
Libraries:
wxWidgets 3.2.8
FreeType 2.13.3
HarfBuzz 9.0.0
FontConfig 2.15.0
Platform: Freedesktop SDK 24.08 (Flatpak runtime), 64 bit, Little endian, wxGTK, X11, KDE, x11
OpenGL: AMD, AMD Radeon Graphics (radeonsi, rembrandt, LLVM 19.1.7, DRM 3.57, 6.8.0-60-generic), 4.6 (Compatibility Profile) Mesa 25.0.5 (git-a89e404408)
wxWidgets: 3.2.8 (wchar_t,wx containers) GTK+ 3.24
Boost: 1.88.0
OCC: 7.9.0
Curl: 8.13.0
ngspice: 44.2
Compiler: GCC 14.2.0 with C++ ABI 1019
KICAD_IPC_API=ON
Locale:
Lang: en_US
Enc: UTF-8
Num: 1.234,5
Encoded кΩ丈: D0BACEA9E4B888 (sys), D0BACEA9E4B888 (utf8)
Edited by kliment