Revision: 7307
Author: nogu.dev
Date: Fri Sep 16 03:38:27 2011
Log: * qt4/pref/customwidgets.cpp
- (TableEditForm::TableEditForm): Adjust horizontal header size.
- (TableEditForm::setTable): Make row height of table narrower.
http://code.google.com/p/uim/source/detail?r=7307
Modified:
/trunk/qt4/pref/customwidgets.cpp
=======================================
--- /trunk/qt4/pref/customwidgets.cpp Fri Sep 16 03:38:18 2011
+++ /trunk/qt4/pref/customwidgets.cpp Fri Sep 16 03:38:27 2011
@@ -1281,6 +1281,9 @@
m_table = new QTableWidget;
m_table->setSelectionMode( QAbstractItemView::SingleSelection );
m_table->verticalHeader()->setVisible( false );
+ QHeaderView *header = m_table->horizontalHeader();
+ header->setResizeMode( QHeaderView::ResizeToContents );
+ header->setStretchLastSection( true );
connect( m_table, SIGNAL( itemSelectionChanged() ),
this, SLOT( slotItemSelectionChanged() ) );
@@ -1360,6 +1363,8 @@
item->setFlags( Qt::NoItemFlags );
m_table->setItem( row, column, item );
}
+ m_table->setRowHeight( row,
+ QFontMetrics( m_table->font() ).height() + 2 );
}
m_customTable = custom_table;
}