Issue 30149 - Wrong location of images in imported Hebrew file
Summary: Wrong location of images in imported Hebrew file
Alias: None
Product: Internationalization
Classification: Code
Component: BiDi (show other issues)
Version: OOo 2.4.0
Hardware: PC All
: P3 Trivial with 12 votes (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
Keywords: ms_interoperability
: 25255 28653 28659 (view as issue list)
Depends on:
Blocks: 29117
  Show dependency tree
Reported: 2004-06-13 12:08 UTC by sforbes
Modified: 2017-05-20 11:13 UTC (History)
6 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---

the problem file (57.50 KB, application/msword)
2004-06-13 12:08 UTC, sforbes
no flags Details
Contains picture, centered (1.14 MB, application/msword)
2005-04-26 08:09 UTC, alan
no flags Details
Screen shot of the file as it appears in OOo (69.22 KB, image/jpeg)
2005-04-26 08:12 UTC, alan
no flags Details
Screen shot of the file as it appears in Word (94.16 KB, image/jpeg)
2005-04-26 08:13 UTC, alan
no flags Details
Proposed patch (802 bytes, patch)
2005-04-26 08:15 UTC, alan
no flags Details | Diff
another WW8 document in RTL with horizontal positions in LTR mode (54.00 KB, application/msword)
2005-04-28 09:08 UTC, Oliver-Rainer Wittmann
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description sforbes 2004-06-13 12:08:02 UTC
MSWord 2003 file with two images- When opened in OOo 680m38, the images move
into a wrong location:
* The top image moves from the far right to the left, and is incurrectly halfway
* the buttom image move from being aligned with the left part of the trext, to
the edge of the page.
Comment 1 sforbes 2004-06-13 12:08:38 UTC
Created attachment 15858 [details]
the problem file
Comment 2 Dieter.Loeschky 2004-07-05 11:24:06 UTC
DL->MRU: Could you please handle this?
Comment 3 michael.ruess 2004-07-09 13:59:35 UTC
MRU->AMA: Word does not change the directions for positioning when in RTL
context. OO Writer does. So in my eyes, there are two possibilities to fix the
problem of frame/graphic position in CTL Word doc's.
1. the import must recalculate the position dependent on the width/margins of
the page text area or
2. A kind of compatibility flag will be introduced for this.
Comment 4 michael.ruess 2004-07-09 14:44:28 UTC
*** Issue 28653 has been marked as a duplicate of this issue. ***
Comment 5 michael.ruess 2004-07-09 14:56:53 UTC
*** Issue 28659 has been marked as a duplicate of this issue. ***
Comment 6 michael.ruess 2004-07-09 16:05:20 UTC
*** Issue 25255 has been marked as a duplicate of this issue. ***
Comment 7 Unknown 2004-07-21 20:56:00 UTC
Please add keywords: ms_interoperability
Comment 8 soto 2004-08-19 14:39:32 UTC
My name is Oleg Reebakov. I work for Tk Open Systems company in Jerusalem. We
delop the Hebrew versions.
I have started to investigate this Issue. I have few directions so I am planning
to fix this issue unless I hear from you otherwise.
Comment 9 alan 2005-04-26 08:05:41 UTC
ayaniger -> ama:

The file originally attached to this issue has been imported correctly for some
time now, however placement of images in RTL documents is still not always correct.

Example: when importing the attached Word document (picture_RTL.doc) with an
image centered in an RTL paragraph, the picture appears at the right edge
instead of in the center. This does not happen if the direction is changed to LTR.

I was able to fix the placement by applying the attached patch
(ww8par6.cxx.diff) to my m86 development environment under Linux RH9. The file
being patched, sw/source/filter/ww8/ww8par6.cxx has not changed from m86 to m97.

Could you review the patch?
Comment 10 alan 2005-04-26 08:09:31 UTC
Created attachment 25466 [details]
Contains picture, centered
Comment 11 alan 2005-04-26 08:12:19 UTC
Created attachment 25467 [details]
Screen shot of the file as it appears in OOo
Comment 12 alan 2005-04-26 08:13:59 UTC
Created attachment 25468 [details]
Screen shot of the file as it appears in Word
Comment 13 alan 2005-04-26 08:15:57 UTC
Created attachment 25469 [details]
Proposed patch
Comment 14 alan 2005-04-26 08:35:20 UTC
Note: the OOo screenshot is from m95.
Comment 15 Oliver-Rainer Wittmann 2005-04-28 09:04:31 UTC
Thx for your contribution to OOo.
I've reviewed your patch. As I see you only disabled the introduced conversion
of Microsoft Word RTL horizontal position into the Writer RTL horizontal
position. This conversion is done in the assumption that the Microsoft Word RTL
horizontal position is given in LTR mode. This is true for the given document
<2724401.doc> and the document <109311-Contemporary Letter_MS Word.doc>. For
these documents the conversion is needed, otherwise the horizontal object
positions will be wrong.
Thus, there must be a difference between these documents and the document you
had attached. Probably its the Microsoft Word version, which created the
documents. With which version do you created your document? I' ll will try to
find out with which version the other documents are created.

If we have find out the difference, we have to adjust your patch and only
suppress the conversion of the horizontal position under the found out
Comment 16 Oliver-Rainer Wittmann 2005-04-28 09:08:14 UTC
Created attachment 25595 [details]
another WW8 document in RTL with horizontal positions in LTR mode
Comment 17 alan 2005-05-03 11:20:57 UTC
ayaniger -> od:

The document I attached, picture_RTL.doc, was created by removing lots of other
stuff form a different Word document, then saving in Word 2000. I don't know
which version of Word was used to create the original uncut document. (I got the
same behavior, when I saved under Word 2002 instead of Word 2000.) 

However, when I tried to created a new document, with a different picture, I
couldn't reproduce the problem, either in Word 2000 or Word 2002. The pictures
were imported correctly. Is there something unusual about the picture in
picture_RTL.doc that I'm missing?

Or is it because of the version of Word used to create the original uncut document?
Comment 18 Oliver-Rainer Wittmann 2005-05-23 09:32:57 UTC

Sorry for answering soo late, but I was busy.

Thank you for checking new Microsoft Word 2000 and 2002 documents. I checked a
new Microsoft Word 2003 document and everything is fine. Means the introduce
position conversion has to be performed to get the correct positions in the
Writer. I also changed the given document <picture_RTL.doc> with Microsoft Word
2003 - I've set another horizontal position at the picture. Also, for this
resulting document the position conversion has to be performed.
Thus, a deeper look into the document <picture_RTL.doc> is needed. I'll have to
investigate the single property modifiers given in the document - probably one
of them states that the object positions are given in RTL. Probably your
suggestion is correct and there is something special at the picture.

My current planning and workload reveals that this investigation has to wait at
least 4-5 weeks. Probably you can have a deeper look into the file format.
Comment 19 kaplanlior 2008-04-09 12:46:22 UTC
I can confirm the problem still exits with 2.4.0 on Debian. Please update
the version info and re-terget.
Comment 20 alan 2008-11-30 19:24:29 UTC
Import of the bugdoc submitted by sforbes has been fixed by the patch to issue
96267. The import of picture_RTL.doc is still a problem, though there might be
something unusual about this picture as od suggested.
Comment 21 Marcus 2017-05-20 11:13:53 UTC
Reset assigne to the default "".