EditorItem::EditorItem(EditorItem *parent, EditorItem *after, const QString &text) : KListViewItem(parent, after, text) { d = new EditorItemPrivate(); d->property = 0; d->editor = 0; setMultiLinesEnabled(true); }
TOCItem( KListViewItem *parent, TOCItem *after, const QDomElement & e ) : KListViewItem( parent, after, e.tagName() ), m_element( e ) { #ifdef TOC_ENABLE_PAGE_COLUMN if ( e.hasAttribute( "Page" ) ) setText( 1, e.attribute( "Page" ) ); #endif setMultiLinesEnabled(true); }
PropertyEditorItem::PropertyEditorItem(KListView *par, const QString &text) : KListViewItem(par, text, "") { m_property = 0; setSelectable(false); setOpen(true); //3 rows per item is enough? setMultiLinesEnabled( true ); setHeight(static_cast<PropertyEditor*>(par)->baseRowHeight()*3); }
//BEGIN Class PropertyEditorItem PropertyEditorItem::PropertyEditorItem( PropertyEditorItem * par, Property * property ) : KListViewItem( par, property->editorCaption(), property->displayString() ) { setExpandable( false ); m_property=property; connect( m_property, SIGNAL(valueChanged( QVariant, QVariant )), this, SLOT(propertyValueChanged()) ); updateValue(); //3 rows per item is enough? setMultiLinesEnabled( true ); setHeight(static_cast<PropertyEditor*>(listView())->baseRowHeight()*3); }
ErrorItem::ErrorItem( QListView *parent, QListViewItem *after, const QString &message, int line, const QString &locationString, QObject *locationObject ) : QListViewItem( parent, after ) { setMultiLinesEnabled( TRUE ); QString m( message ); type = m.startsWith( "Warning: " ) ? Warning : Error; m = m.mid( m.find( ':' ) + 1 ); setText( 0, type == Error ? "Error" : "Warning" ); setText( 1, m ); setText( 2, QString::number( line ) ); setText( 3, locationString ); object = locationObject; read = !after; if ( !after ) { parent->setSelected( this, TRUE ); parent->setCurrentItem( this ); } }
void SafeListViewEntry::setSelected(bool yes) { setMultiLinesEnabled(yes); Q3ListViewItem::setSelected(yes); setup(); }