mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 16:18:42 +00:00
Use CascadingResizeSections in RideNavigator
Makes resizing columns smoother and more intuitive.
This commit is contained in:
@@ -64,6 +64,7 @@ RideNavigator::RideNavigator(MainWindow *parent) : main(parent), active(false),
|
||||
tableView->expandAll();
|
||||
//XXXtableView->horizontalScrollBar()->setDisabled(true);
|
||||
//XXXtableView->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
|
||||
tableView->header()->setCascadingSectionResizes(true); // easier to resize this way
|
||||
tableView->setContextMenuPolicy(Qt::CustomContextMenu);
|
||||
tableView->header()->setStretchLastSection(false);
|
||||
tableView->header()->setMinimumSectionSize(20);
|
||||
@@ -837,7 +838,7 @@ void NavigatorCellDelegate::paint(QPainter *painter, const QStyleOptionViewItem
|
||||
//painter->drawLine(0,myOption.rect.y()+myOption.rect.height()-1,0,myOption.rect.y()+myOption.rect.height()-1);
|
||||
painter->drawLine(0,myOption.rect.y()+myOption.rect.height(),0,myOption.rect.y()+myOption.rect.height());
|
||||
//painter->drawLine(rideNavigator->pwidth,myOption.rect.y(),rideNavigator->pwidth, myOption.rect.y()+myOption.rect.height()-1);
|
||||
painter->drawLine(rideNavigator->pwidth,myOption.rect.y(),rideNavigator->pwidth, myOption.rect.y()+myOption.rect.height());
|
||||
//painter->drawLine(rideNavigator->pwidth,myOption.rect.y(),rideNavigator->pwidth, myOption.rect.y()+myOption.rect.height());
|
||||
myOption.rect.setHeight(18); //added
|
||||
myOption.font.setWeight(QFont::Bold);
|
||||
drawDisplay(painter, myOption, myOption.rect, value);
|
||||
|
||||
Reference in New Issue
Block a user