Vitruvian Penguin
knoppix

[knoppix:1936] Re: ファイル公開再開

Date: Tue, 12 Aug 2003 20:22:17 +0900
User-agent: KMail/1.5.2
Daisuke@JKUGです。
#パッチは添付できないらしいので、本文に引用します。

2003年 7月 14日 月曜日 21:38、Daisuke Kameda さんは書きました:
> >  こちらで構築した KNOPPIXでは、動作がおかしくなるよりも、
> > 重くなる方がまだ良いだろうと考えて、"Over the Spot"にして
> > います。
>
> このjmode+Anthyの環境ですが、Anthyの開発者である田畑さんの
> ご協力により、ある程度原因をしぼれてはいます。ただ、私個人は
> いろいろやらなければいけないことがあるので、いつごろになるか
> 断言することはできません。

この件ですが、結局ハッキリとしたことは分からず、どの時点での変更なのかだけを
特定した時点で、Trolltechに報告したところ、修正パッチを送ってもらいましたので、
先ほどKdeveloperに報告したものを転送しておきます。
#jmode-0.6.7で対応済みらしいですが。

あと、どうでもいいかもしれませんが、これOver The Spotの間違いでした。
>> > QtのXIMの"On the Spot"*だけ*を直した本人なので、一応コメントします。


----------  転送メッセージ  ----------

Subject: [Kdeveloper:02853] Fwd: Re: [Issue N28110] Operation of Qt is slow 
when XIM server called jmode is used
Date: 2003年 8月 12日 火曜日 15:32
From: Daisuke Kameda <kaminmat@xxxxxxxxxxxx>
To: Kdeveloper@xxxxxxxxx

Daisukeです。

Qt3.0.6以降において、入力スタイルにOver The Spotを選択してある状態で
XIMサーバにjmode(URL:http://sourceforge.jp/projects/anthy/)
を使った場合に動作が遅くなる問題をTrolltechに報告したところ、
パッチを送ってもらったので、転送いたします。

もともと添付されていたのは3.2.0用のパッチでしたが、
このメールには、Qt3.1.2用とQt3.2.0用の両方を添付してあります。

-------------------------------------------------------

Subject: Re: [Issue N28110] Operation of Qt is slow when XIM server called
jmode is used
Date: 2003年 8月 11日 月曜日 22:40
From: qt-bugs@xxxxxxxxxxxxx
To: Daisuke Kameda <kaminmat@xxxxxxxxxxxx>
Cc: daisuke@xxxxxxxxx, qt-bugs@xxxxxxxxxxxxx

On Sunday, 03. Aug 2003 15:58 Daisuke Kameda wrote:
> > I noticed that operation of Qt application became slow, when a
> > popular XIM server "jmode" was used. This phenomenon occur in
> > version 3.0.6 or later, and, in before 3.0.5, no problem.
> >
> > Between 3.0.5 and 3.0.6, there is some difference in a QInputContext
> > class. However, since this phenomenon was not occurred even if it
> > applied the diff to 3.0.5, I think that the cause is in places other
> > than a QInputContext class. But, if the execution of XSetICValues is
> > commented out, operation does not become heavy when inputting
> > Japanese. Moreover, such a phenomenon is not occurred in gtk
> > application.
>
> This phenomenon is occurred in "Over The Spot" mode, not "On The
> Spot". I'm Sorry to have forgotten to write important information.

You are indeed correct.  Apparently some of the changes made for the
3.0.6 release were not completely correct.  I have attached a patch for
you to try, which should fix the performance problem.

Could you give this patch a try and see if it works for you as well?
The patch is against a clean Qt 3.2.0 tree.

Thanks :)

> --
> Daisuke Kameda <kaminmat@xxxxxxxxxxxx>

--
Bradley T Hughes
Trolltech AS, Waldemar Thranes gt. 98, N-0175 Oslo, Norway

-------------------------------------------------------

--
Daisuke Kameda <kaminmat@xxxxxxxxxxxx>

-------------------------------------------------------


----------  qt-x11-free-3.1.2-fix-jmode_performance  ----------
diff -ur qt-x11-free-3.1.2.orig/src/kernel/qinputcontext_x11.cpp 
qt-x11-free-3.1.2/src/kernel/qinputcontext_x11.cpp
--- qt-x11-free-3.1.2.orig/src/kernel/qinputcontext_x11.cpp     2003-02-24 
17:30:17.000000000 +0900
+++ qt-x11-free-3.1.2/src/kernel/qinputcontext_x11.cpp  2003-08-11 
23:11:41.000000000 +0900
@@ -418,7 +418,6 @@
        XVaNestedList preedit_attr =
            XVaCreateNestedList(0,
                                XNSpotLocation, &point,
-                               XNFontSet, fontset,
                                (char *) 0);
        XSetICValues((XIC) ic, XNPreeditAttributes, preedit_attr, (char *) 0);
        XFree(preedit_attr);
@@ -439,7 +438,6 @@

        XVaNestedList preedit_attr = XVaCreateNestedList(0,
                                                         XNArea, &rect,
-                                                        XNFontSet, fontset,
                                                         (char *) 0);
        XSetICValues((XIC) ic, XNPreeditAttributes, preedit_attr, (char *) 0);
        XFree(preedit_attr);
@@ -481,10 +479,15 @@
 void QInputContext::setXFontSet(const QFont &f)
 {
 #if !defined(QT_NO_XIM)
-    if ( font == f ) // nothing to do
-       return;
+    if (font == f) return; // nothing to do
+    font = f;

-    fontset = getFontSet( f );
+    XFontSet fs = getFontSet(font);
+    if (fontset == fs) return; // nothing to do
+
+    XVaNestedList preedit_attr = XVaCreateNestedList(0, XNFontSet, fontset, 
(char *) 0);
+    XSetICValues((XIC) ic, XNPreeditAttributes, preedit_attr, (char *) 0);
+    XFree(preedit_attr);
 #else
     Q_UNUSED( f );
 #endif
-------------------------------------------------------

----------  qt-x11-free-3.2.0-fix-jmode_performance  ----------
diff -ur qt-x11-free-3.2.0.orig/src/kernel/qinputcontext_x11.cpp 
qt-x11-free-3.2.0/src/kernel/qinputcontext_x11.cpp
--- qt-x11-free-3.2.0.orig/src/kernel/qinputcontext_x11.cpp     2003-07-18 
22:20:58.000000000 +0900
+++ qt-x11-free-3.2.0/src/kernel/qinputcontext_x11.cpp  2003-08-12 
15:23:31.000000000 +0900
@@ -453,7 +453,6 @@
        XVaNestedList preedit_attr =
            XVaCreateNestedList(0,
                                XNSpotLocation, &point,
-                               XNFontSet, fontset,
                                (char *) 0);
        XSetICValues((XIC) ic, XNPreeditAttributes, preedit_attr, (char *) 0);
        XFree(preedit_attr);
@@ -474,7 +473,6 @@

        XVaNestedList preedit_attr = XVaCreateNestedList(0,
                                                         XNArea, &rect,
-                                                        XNFontSet, fontset,
                                                         (char *) 0);
        XSetICValues((XIC) ic, XNPreeditAttributes, preedit_attr, (char *) 0);
        XFree(preedit_attr);
@@ -516,10 +514,15 @@
 void QInputContext::setXFontSet(const QFont &f)
 {
 #if !defined(QT_NO_XIM)
-    if ( font == f ) // nothing to do
-       return;
+    if (font == f) return; // nothing to do
+    font = f;

-    fontset = getFontSet( f );
+    XFontSet fs = getFontSet(font);
+    if (fontset == fs) return; // nothing to do
+
+    XVaNestedList preedit_attr = XVaCreateNestedList(0, XNFontSet, fontset, 
(char *) 0);
+    XSetICValues((XIC) ic, XNPreeditAttributes, preedit_attr, (char *) 0);
+    XFree(preedit_attr);
 #else
     Q_UNUSED( f );
 #endif
-------------------------------------------------------


-- 
Daisuke Kameda <kaminmat@xxxxxxxxxxxx>
<Prev in Thread] Current Thread [Next in Thread>
  • [knoppix:1936] Re: ファイル公開再開, Daisuke Kameda <=