[prev in list] [next in list] [prev in thread] [next in thread] 

List:       koffice-devel
Subject:    Re: kotext formatting and bidi
From:       Krister Wicksell Eriksson <krister.wicksell () spray ! se>
Date:       2002-03-06 16:50:22
[Download RAW message or body]

On Wednesday 06 March 2002 13.48, David Faure wrote:
> On Tuesday 05 March 2002 16:43, Krister Wicksell Eriksson wrote:
> > Hi
> >
> > I am playing with the formatting chars when in bidi mode. Have reversed
> > the new line char and tab char when in right to left mode. Have attached
> > a patch that do this so you can try. Comments?
>
> No time for testing, but thanks for taking care of this.
>
> > Tabs in right to left mode don't seems to work so well or is it just my
> > fonts?
>
> Hmm, I admit I never tested this. KoTextParag::nextTab() looks from left
> to right - doesn't the initial QTextParag::nextTab() do the same?

Yes, but it's not so complex.
The tabs in the ruler are placed from left to right and nextTab() read them 
this way. So the first tab in right to left text i the left most tab in the 
ruler. Working on a fix for this.

>
> > A other thing. I have found a lot of functions that returns the character
> > width. Which one should be used when?
> > For example when calculating the char width in KoTextFormatter::format
> > the function KoTextFormat::charWidth is used, but KoTextParag::nextTab
> > uses KoTextString::width. This results in formatting errors when using
> > right tabs.
>
> I introduced charWidth to implement the current WYSIWYG solution, that's
> the one you should probably use.
>
> That WYSIWYG solution is: layout units are high-resolution (*20), but font
> metrics are calculated from the 100%-zoom-level font (e.g. 12pt for a 12pt
> font) and _then_ multiplied by 20, instead of using a 240pt font for that
> as we did before. KoTextFormat::charWidth() implements that.

ok

>
> I'm updating kword/DESIGN ;)

-- 
krister.wicksell@spray.se
http://hem.spray.se/krister.wicksell/
_______________________________________________
koffice-devel mailing list
koffice-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/koffice-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic