mirror of
https://github.com/sqlitebrowser/sqlitebrowser.git
synced 2026-01-20 11:00:44 -06:00
Show more information on the fields of a table in the DB Structure view
In the Database Structure tab of the main window and the DB Schema pane, show more information in the field nodes of the tree view. This commit puts the field definition in the Schema column which has been unsused until now. It also changes the icon of the field row when the field is a primary key. This hopefully makes the Schema view a bit more useful, especially in the pane.
This commit is contained in:
@@ -175,7 +175,11 @@ void DbStructureModel::reloadData(DBBrowserDB* db)
|
||||
fldItem->setText(0, (*it).table.fields().at(i)->name());
|
||||
fldItem->setText(1, "field");
|
||||
fldItem->setText(2, (*it).table.fields().at(i)->type());
|
||||
fldItem->setIcon(0, QIcon(":/icons/field"));
|
||||
fldItem->setText(3, (*it).table.fields().at(i)->toString(" ", " "));
|
||||
if((*it).table.fields().at(i)->primaryKey())
|
||||
fldItem->setIcon(0, QIcon(":/icons/field_key"));
|
||||
else
|
||||
fldItem->setIcon(0, QIcon(":/icons/field"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user