This service will be undergoing maintenance at 00:00 UTC, 2016-09-28. It is expected to last about 1 hours
Bug 215905 - Positioning of double quotes ("") around Hindi (& maybe other languages) characters is wrong (hi_IN)
Positioning of double quotes ("") around Hindi (& maybe other languages) char...
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: openoffice.org (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Caolan McNamara
: i18n
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-11-16 05:30 EST by Mayank Jain
Modified: 2007-11-30 17:11 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-05-09 07:27:09 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
Problem description and its counterpart in gedit (193.62 KB, image/png)
2006-11-16 05:30 EST, Mayank Jain
no flags Details
for needinfo (81.57 KB, image/png)
2006-11-16 07:45 EST, Mayank Jain
no flags Details

  None (edit)
Description Mayank Jain 2006-11-16 05:30:53 EST
Description of problem:
Positioning of double quotes ("") around Hindi characters is wrong (hi_IN).
Please check the screenshot. You'll see that in oo.o, the second quote gets
dislodged from the original height.

Version-Release number of selected component (if applicable):
openoffice.org-writer-2.0.4-5.6

How reproducible:
Always

Steps to Reproduce:
1. Open oowriter, select Lohit-hindi from fonts list & type "" (doublequotes)
2. Activate scim (hi-phonetic) & move the cursor back between the double quotes
3. type "k" (क) between those double quotes & watch the quotes move from their
position.
  
Actual results:
As in screenshot

Expected results:
"क"

Additional info:
Comment 1 Mayank Jain 2006-11-16 05:30:53 EST
Created attachment 141357 [details]
Problem description and its counterpart in gedit
Comment 2 Caolan McNamara 2006-11-16 06:51:08 EST
These are typographical quotes, not ascii quotes. To get ascii quotes, use
tools->autocorrect and disable custom quotes and type "" and stick the letter in
between. 

So we're looking at typographical (smart) quote marks here. So I suspect from
the screenshot in this case that the closing quote is in a different font that
the opening quote. This is a fairly complicated area. You have the ascii quote,
0x201C typographical quote open, and 0x201D typographical quote close. So the
various issues are 

a) what language will the quote be considered, probably depends somewhat on context
b) what font is used for the language that the quote is in
c) what unicode code point the quote may have been autocorrected into.

So, back with "replace quotes" mode enabled, if you select the first quote what
does the fontbox say the font is, and also for the second quote what does the
fontbox say. Then select the whole set of three characters and what is the CTL
font and the western font in format->character ?

And finally what was the locale that oowriter was launched in ? I suspect that
from the screenshot that the first quote is in Lohit Hindi and the last quote is
in DejaVu. And the question is if anything can/should actually be done about it.
Comment 3 Mayank Jain 2006-11-16 07:44:04 EST
(In reply to comment #2)

> So, back with "replace quotes" mode enabled, if you select the first quote what
> does the fontbox say the font is,

Lohit Hindi

 and also for the second quote what does the
> fontbox say. 

DejaVu LGC Sans

Then select the whole set of three characters and what is the CTL
> font and the western font in format->character ?

Please check the attached screenshot as I couldnt find anything like CTL in the
format->character dialog box.

> 
> And finally what was the locale that oowriter was launched in ?

en_US

 I suspect that
> from the screenshot that the first quote is in Lohit Hindi and the last quote is
> in DejaVu. And the question is if anything can/should actually be done about it.

A finding - If you look at the screenshot, you'll find that when I wrote a
series of combinations ("क"), the quotes were well aligned in the other two
characters.

Also, if I select (क) from any of the other two combinations (from the series
depicted in the screenshot), the fontbox says that its "DejaVu LGC Sans" font.
Comment 4 Mayank Jain 2006-11-16 07:45:27 EST
Created attachment 141364 [details]
for needinfo

Series of "क"
Comment 5 Caolan McNamara 2006-11-16 07:53:59 EST
tools->options->language settings->languages enable CTL and asian. You're not
seeing the full story when mixing CTL script and western script if the display
mode is just to show the western font settings (which is what happens when the
locale is en_US so as to not confuse westerners :-))
Comment 6 Mayank Jain 2006-11-16 07:59:59 EST
Okay, I enabled the CTL & asian check boxes, restarted oowriter, but i'm getting
the same results.
Comment 7 Caolan McNamara 2006-11-16 08:07:20 EST
yes, that won't change any behaviour except to show CTL/Asian info e.g. in
format->character. But now you should be able to report the results from
selecting the sequence of quote character quote and use format->character and
see the fonts being used for Western and CTL characters to see if the CTL font
is set to Deva Vu
Comment 8 Caolan McNamara 2007-05-09 07:27:09 EDT
Anyway, I know what the problem is, but there's nothing that can be done about it.

a) There is a font setting for CJK text, and one for CTL text and one for
western text. 
b) Some symbols like quotes are "weak characters" which can belong to more than
one script.
c) If the CTL font and the Western font do not match and a quote is used, then
the script of the preceding text is taken to determine what font to use for the
weak character

So if launched under en_US then the default script and font is the Western one,
so the first quote with no preceding text is put in the western font, typing a
hindi letter uses the CTL font, another quote is then appended. The preceding
character is CTL and so the next quote is taken from the CTL font, and so the
quotes don't match eachother.

If OOo is launched in a hi_IN locale then the fonts are all set to "Lohit Hindi"
and the problem of mismatching fonts used for the quotes doesn't arise as the
fonts match eachother for CTL and Western.

To really complicate the mix, there is a auto-correct substitution which occurs
to replace simple " quotes with their typographical start and end quotes for
western text. And that also considers the script in use as the indicator as to
whether to use a start or end quote as the replacement or if to do no
replacement at atll. This will default to the base locale language when it's the
first quote used and there's no hint available as to what script is in use, and
will swap to the other language when there is enough context. 

i.e. 
a) In a OOo launched in the hi_IN locale typing "ककककक" will give matching
quotes non-replaced, appending foo "english" will show typographical quotes
around the english text, but they will match. Adding कक"कक" will then revert to
non-typographic quotes, but they will match eachother because the script कक"कक"
will then revert to non-typographic quotes. And as the font is all Lohit Hindi
for western and CTL the same font is used for all text, even when in some
western-text influenced conditions typographical quotes have been substituted
during typing.

b) In a OOo launched in the en_US locale typing "ककककक" will give mismatching 
quotes because the first one was converted to a typographical quote from the
English font as text was assumed to be western by default, while the second one
will be an unconverted simple quote in Lohit Hindi as the influencing text is
CTL. Appending foo "english" will show typographical quotes around the english
text, but they will match. Adding कक"कक" will then revert to non-typographic
quotes, but they will match eachother because the script range can be considered
all CTL and the Lohit Hindi is used for the range.

Note You need to log in before you can comment on or make changes to this bug.