If there is several spaces between style definition and style name in RTF style table, the imported style name will have extra spaces in the beginning.
Word imports those normally.
Can you explain the steps for reproduce the problem?
Created attachment 103332 [details]
I can't reproduce the problem on LibO:
* Version: 188.8.131.52.alpha0+
* Build ID: 4ca819b204e6c93c4b4e20b191100aa248b8ff23
* TinderBox: Linux-rpm_deb-x86_64@46-TDF, Branch:master, Time: 2014-07-22_23:53:50
* OS: Ubuntu 14.04 x86_64
Can you provide a step by step procedure? Can you specify your system and your LibreOffice version?
Your attachment 103332 [details] has a "test" style with one blank space at the beginning but I can't create a second one with the same problem.
> has a "test" style with one blank space at the beginning
So you can reproduce it.
(In reply to comment #4)
> So you can reproduce it.
Opening your file I can see the test style with one blank space at the beginning but I can't create this kind of style.
I'm reverting status to NEEDINFO since we need exact step-by-step procedure to exactly reproduce your bug.
also give details about O/S and other stuff like asked by Marina
also tell if the issue was present or not in previous LibO release or if it's specific to 4.4.x master branch
Confirming as per Comment 3.
The bug is about opening RTF files, as evident per Comment 1.
This bug is not in OpenOffice.
Your attachment 103332 [details] has a buggy style name but I can create a new one style with the same behaviour.
Please, can you write a step by step procedure to create a new buggy style?
Which LibreOffice version are you using?
I'm testing on Ubuntu 14.04 x86_64 and I see your "test" style but I can't create a new one with blank space at the beginning.
Are you testing on Windows or Mac?
Are you dyslexic? Opening that files SHOULD NOT create a style name with spaces.
Whether you can or cannot create such a style is not related to this bug.
besides being rude with a lady, would you please reply to the simple question about you O/S that has been already asked to you 3 times?
this is the source code of your rtf file:
\viewkind4\uc1\pard\s0\slmult1\lang9\f0\fs22 Hello world!\par
Reading the code, it seems to be a "handmade" document.
In any case, LibreOffice add the extra blank space at the beginning of the style name.
I can't test with MS Office but AOO trims the extra blank spaces.
* AOO411m3(Build:9772) - Rev. 1611634
* 2014-07-18 15:06 - Linux x86_64
All the tested (LibO's) versions have the same behaviour (extra spaces not trimmed):
* Version: 184.108.40.206.alpha0+
* Build ID: 3fdd4f069d5436cf39708004af7fda8175fbc4c2
* TinderBox: Linux-rpm_deb-x86_64@46-TDF, Branch:master, Time: 2014-07-09_02:51:53
* Version: 220.127.116.11
* Build ID: 1c1366bba2ba2b554cd2ca4d87c06da81c05d24
* Version: 18.104.22.168
* Build ID: 40ff705089295be5be0aae9b15123f687c05b0a
* Version: 22.214.171.124
* Build ID: 61cb170a04bb1f12e77c884eab9192be736ec5f5
* Version: 126.96.36.199
* Build ID: 08ebe52789a201dd7d38ef653ef7a48925e7f9f7
According to my tests --> Version sets to 188.8.131.52
@Miklós: what's the right behaviour?
Word also strips the whitespace around the style name, so we should, too.
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":
fdo#79959 RTF import: trim whitespace around style names
The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
Affected users are encouraged to test the fix and report feedback.
Migrating Whiteboard tags to Keywords: (filter:rtf)