[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdelibs/kdeui/tests
From: David Faure <faure () kde ! org>
Date: 2004-02-28 17:52:00
Message-ID: 20040228175200.AEBF8995B () office ! kde ! org
[Download RAW message or body]
CVS commit by faure:
tests, $Id$ removed, copyright
M +13 -1 klistviewtest.cpp 1.3
M +0 -1 ktabctltest.cpp 1.10
M +28 -1 kwordwraptest.cpp 1.2
--- kdelibs/kdeui/tests/klistviewtest.cpp #1.2:1.3
@@ -10,4 +10,8 @@ int main( int argc, char **argv )
KDialogBase dialog;
KListView *view = new KListView( dialog.makeVBoxMainWidget() );
+ view->setSelectionModeExt( KListView::FileManager );
+ view->setDragEnabled( true );
+ view->setItemsMovable( false );
+ view->setAcceptDrops( true );
view->addColumn("Column 1");
view->addColumn("Column 2");
@@ -15,4 +19,12 @@ int main( int argc, char **argv )
new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
+ new QListViewItem( view, "Item 1");
new QListViewItem( view, "Item 2", "Some more", "Hi Mom :)" );
--- kdelibs/kdeui/tests/ktabctltest.cpp #1.9:1.10
@@ -1,4 +1,3 @@
/*
- * $Id$
*
*/
--- kdelibs/kdeui/tests/kwordwraptest.cpp #1.1:1.2
@@ -1,2 +1,20 @@
+/*
+ * Copyright (C) 2003 David Faure <faure@kde.org>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License version 2 as published by the Free Software Foundation;
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public License
+ * along with this library; see the file COPYING.LIB. If not, write to
+ * the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
#include <kapplication.h>
#include <kdebug.h>
@@ -6,5 +24,5 @@
int main(int argc, char *argv[])
{
- KApplication app(argc, argv, "KProgressTest");
+ KApplication app(argc, argv, "KWordWrapTest");
QFont font( "helvetica", 12 ); // let's hope we all have the same...
@@ -14,3 +32,12 @@ int main(int argc, char *argv[])
KWordWrap* ww = KWordWrap::formatText( fm, r, 0, str );
kdDebug() << str << " => " << ww->truncatedString() << endl;
+ delete ww;
+
+ str = "</p></p></p></p>";
+ for ( ; r.width() > 0 ; r.setWidth( r.width()-10 ) )
+ {
+ ww = KWordWrap::formatText( fm, r, 0, str );
+ kdDebug() << str << " => " << ww->truncatedString() << endl;
+ delete ww;
+ }
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic