[uim-commit] r524 - trunk/qt

kzk at freedesktop.org kzk at freedesktop.org
Fri Feb 4 20:37:38 PST 2005


Author: kzk
Date: 2005-02-04 20:37:36 -0800 (Fri, 04 Feb 2005)
New Revision: 524

Modified:
   trunk/qt/candwin-qt.cpp
   trunk/qt/pref-customwidgets.cpp
   trunk/qt/pref-qt.cpp
   trunk/qt/qtgettext.h
   trunk/qt/switcher-qt.cpp
Log:
* qt/candiw-qt.cpp
  - (CandidateWindow::CandidateWindow): use QApplication::exit instead of exit
* qt/pref-qt.cpp
  - (UimPrefDialog::UimPrefDialog): use QApplication::exit instead of exit

* qt/pref-customwidgets.cpp
  - (CustomOrderedLitEdit::updateText): quote each item of list and put space
     after separator(comma) to make easy to recognize.
  - (CustomKeyEdit::updateText): Ditto
  - layout enhancement

* qt/qtgettext.h
  - add copyright

* qt/switcher-qt.cpp
  - eye candy enchancement


Modified: trunk/qt/candwin-qt.cpp
===================================================================
--- trunk/qt/candwin-qt.cpp	2005-02-05 04:01:47 UTC (rev 523)
+++ trunk/qt/candwin-qt.cpp	2005-02-05 04:37:36 UTC (rev 524)
@@ -41,7 +41,6 @@
 
 #include <locale.h>
 #include <stdio.h>
-#include <stdlib.h>
 #include <string.h>
 #include <unistd.h>
 
@@ -253,7 +252,7 @@
     if ( n == 0 )
     {
         close( fd );
-        exit( -1 );
+        QApplication::exit( -1 );
     }
     if ( n == -1 )
         return ;

Modified: trunk/qt/pref-customwidgets.cpp
===================================================================
--- trunk/qt/pref-customwidgets.cpp	2005-02-05 04:01:47 UTC (rev 523)
+++ trunk/qt/pref-customwidgets.cpp	2005-02-05 04:37:36 UTC (rev 524)
@@ -497,7 +497,7 @@
              item = m_custom->value->as_olist[++i] )
         {
             if( i != 0 )
-                str.append(",");
+                str.append(", ");
             str.append( _FU8(item->label) );
         }
     }
@@ -610,7 +610,7 @@
              key = m_custom->value->as_key[++i])
         {
             if( i != 0 )
-                str.append(",");
+                str.append(", ");
             str.append( key->literal );
         }
     } else {

Modified: trunk/qt/pref-qt.cpp
===================================================================
--- trunk/qt/pref-qt.cpp	2005-02-05 04:01:47 UTC (rev 523)
+++ trunk/qt/pref-qt.cpp	2005-02-05 04:37:36 UTC (rev 524)
@@ -55,11 +55,8 @@
 #include <qobjectlist.h>
 
 #include "uim/config.h"
-
 #include "qtgettext.h"
 
-#include <unistd.h>
-#include <stdlib.h>
 #include <locale.h>
 
 #define _FU8(String) QString::fromUtf8(String)
@@ -74,7 +71,7 @@
     } else {
       qDebug("uim_custom_enable() failed.");
       uim_quit();
-      exit(-1);
+      QApplication::exit( -1 );
     }
 }
 
@@ -111,6 +108,7 @@
     QWidget *buttonHWidget = new QWidget( leftSideWidget );
     m_groupWidgetStack = new QWidgetStack( leftSideWidget );
     QHBoxLayout *buttonHLayout = new QHBoxLayout( buttonHWidget );
+    buttonHLayout->setMargin( 6 );
     buttonHLayout->setSpacing( 6 );
     QPushButton *defaultButton = new QPushButton( _("Defaults"), buttonHWidget );
     QObject::connect( defaultButton, SIGNAL(clicked()),
@@ -280,6 +278,7 @@
 void GroupPageWidget::setupWidgets( const char *group_name )
 {
     QVBoxLayout *vLayout = new QVBoxLayout( this );
+    vLayout->setMargin( 6 );
     vLayout->setSpacing( 3 );
     
     struct uim_custom_group *group = uim_custom_group_get( group_name );

Modified: trunk/qt/qtgettext.h
===================================================================
--- trunk/qt/qtgettext.h	2005-02-05 04:01:47 UTC (rev 523)
+++ trunk/qt/qtgettext.h	2005-02-05 04:37:36 UTC (rev 524)
@@ -1,3 +1,35 @@
+/*
+
+ Copyright (c) 2003,2004,2005 uim Project http://uim.freedesktop.org/
+
+ All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions
+ are met:
+
+ 1. Redistributions of source code must retain the above copyright
+    notice, this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright
+    notice, this list of conditions and the following disclaimer in the
+    documentation and/or other materials provided with the distribution.
+ 3. Neither the name of authors nor the names of its contributors
+    may be used to endorse or promote products derived from this software
+    without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ SUCH DAMAGE.
+
+*/
 #ifndef _QT_GETTEXT_H_
 #define _QT_GETTEXT_H_
 

Modified: trunk/qt/switcher-qt.cpp
===================================================================
--- trunk/qt/switcher-qt.cpp	2005-02-05 04:01:47 UTC (rev 523)
+++ trunk/qt/switcher-qt.cpp	2005-02-05 04:37:36 UTC (rev 524)
@@ -95,6 +95,7 @@
     /* im list view */
     listview = new QListView( this );
     listview->setSelectionMode( QListView::Single );
+    listview->setAllColumnsShowFocus( true );
     listview->addColumn( _( "InputMethodName" ) );
     listview->addColumn( _( "Language" ) );
     listview->addColumn( _( "Description" ) );



More information about the Uim-commit mailing list