Bug 210098 - Kword can't open files (doc, rtf, etc...)
Summary: Kword can't open files (doc, rtf, etc...)
Status: RESOLVED FIXED
Alias: None
Product: kde-windows
Classification: Miscellaneous
Component: network and files (show other bugs)
Version: unspecified
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: KDE-Windows
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-10-10 19:16 UTC by jfaryeeman
Modified: 2012-03-09 12:56 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description jfaryeeman 2009-10-10 19:16:54 UTC
Version:           2.1 beta 3 (using KDE 4.3.1)
OS:                MS Windows
Installed from:    MS Windows

Kword on Windows can't open files.

How To Reproduce
----------------

Run Kword
Choose "Open Document"
Browse to the file you want; In my case several files in rtf, doc, odt. It seems not to support opening HTML files!?
Try to open them, fail and get this message:

"Could not read the beginning of the file"

The second time you try to open a file you don't even get that error message; nothing happens then

Expected behavior
-----------------

Kword should open the file. In case of error it should provide better information.

PS: You should consider add support for more files, at least for opening. For those that you can't or won't, you should then add a converter application allowing batch conversion to odt. Example: user tries to open docx, wpd, application detects this, informs the user and then  provides a conversion system to odt.
Comment 1 Thomas Zander 2009-10-12 12:43:36 UTC
Could a kde-windows guy maybe verify this bug?  I have the suspicion this is a packaging or Windows specific issue.
Comment 2 Jarosław Staniek 2009-10-12 14:22:42 UTC
Hi,
I confirm exactly this error message. The problem is in KoFilter or
even in KZip.
I've been trying to debug this, but no results yet.
Comment 3 Jarosław Staniek 2009-10-12 14:34:47 UTC
BTW, the created temporary odf file has 0 size.
Comment 4 Cyrille Berger 2009-10-13 17:43:14 UTC
Sounds like a duplicate of bug:209652 . Someone mentioned on IRC that saving from Krita to .png/.jpeg produces a .kra file instead. I am suspecting that kdelibs doesn't return the correct mimetype (I don't think there is anything os-specific in KoFilter that would justify the behaviour), so when opening .doc/.rtf in kword (or .png/.jpeg in krita), KoFilterChain think the file is a .odt (or .kra) file and that would explain the failure.
Comment 5 Sebastian Sauer 2012-03-01 03:40:47 UTC
The debug-out from comment 5 at bug #291374 says;

[8732] words(8732) bool __thiscall DocxImport::acceptsSourceMimeType(const class QByteArray &) const: Entering DOCX Import filter: from  "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
[8732] words(8732) bool __thiscall DocxImport::acceptsDestinationMimeType(const class QByteArray &) const: Entering DOCX Import filter: to  "application/vnd.oasis.opendocument.text"

what means the mimetypes are proper detected. I do think too that it's a bug in KZip. Probably similar to what was fixed with commit 9f9e302d0b8b in kzip.
Comment 6 Halla Rempt 2012-03-09 12:56:11 UTC
Fixed in bf47fed5ead06f2128abf042897f86bab39cf333