mirror of
				https://github.com/subsurface/subsurface.git
				synced 2025-02-19 22:16:15 +00:00 
			
		
		
		
	The never ending, futile fight for whitespace consistency
I just need to write a tool that does this... Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
		
							parent
							
								
									7757363953
								
							
						
					
					
						commit
						115e5e5fbc
					
				
					 16 changed files with 116 additions and 130 deletions
				
			
		|  | @ -57,10 +57,9 @@ QWidget* TankInfoDelegate::createEditor(QWidget* parent, const QStyleOptionViewI | ||||||
| 	comboDelegate->setModel(model); | 	comboDelegate->setModel(model); | ||||||
| 	int i; | 	int i; | ||||||
| 	for (i = 0; i < model->rowCount(); i++) { | 	for (i = 0; i < model->rowCount(); i++) { | ||||||
| 		if (model->data(model->index(i,0), Qt::DisplayRole).toString() == data){ | 		if (model->data(model->index(i,0), Qt::DisplayRole).toString() == data) | ||||||
| 			break; | 			break; | ||||||
| 	} | 	} | ||||||
| 	} |  | ||||||
| 	if (i != model->rowCount()) | 	if (i != model->rowCount()) | ||||||
| 		comboDelegate->setCurrentIndex(i); | 		comboDelegate->setCurrentIndex(i); | ||||||
| 	return comboDelegate; | 	return comboDelegate; | ||||||
|  |  | ||||||
|  | @ -103,13 +103,10 @@ QVariant CylindersModel::data(const QModelIndex& index, int role) const | ||||||
| 			ret = QString("%1%").arg((cyl->gasmix.he.permille + 5) / 10); | 			ret = QString("%1%").arg((cyl->gasmix.he.permille + 5) / 10); | ||||||
| 			break; | 			break; | ||||||
| 		} | 		} | ||||||
| 	} | 	} else if (role == Qt::DecorationRole) { | ||||||
| 
 | 		if (index.column() == REMOVE) | ||||||
| 	else if (role == Qt::DecorationRole){ |  | ||||||
| 		if (index.column() == REMOVE){ |  | ||||||
| 			ret = QIcon(":trash"); | 			ret = QIcon(":trash"); | ||||||
| 	} | 	} | ||||||
| 	} |  | ||||||
| 
 | 
 | ||||||
| 	return ret; | 	return ret; | ||||||
| } | } | ||||||
|  | @ -312,13 +309,10 @@ QVariant WeightModel::data(const QModelIndex& index, int role) const | ||||||
| 			ret = get_weight_string(ws->weight, TRUE); | 			ret = get_weight_string(ws->weight, TRUE); | ||||||
| 			break; | 			break; | ||||||
| 		} | 		} | ||||||
| 	} | 	} else if (role == Qt::DecorationRole) { | ||||||
| 
 | 		if (index.column() == REMOVE) | ||||||
| 	else if (role == Qt::DecorationRole){ |  | ||||||
| 		if (index.column() == REMOVE){ |  | ||||||
| 			ret = QIcon(":trash"); | 			ret = QIcon(":trash"); | ||||||
| 	} | 	} | ||||||
| 	} |  | ||||||
| 	return ret; | 	return ret; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -438,8 +438,7 @@ void ProfileGraphicsView::plot_pp_gas_profile() | ||||||
| 				item->setPen(pen); | 				item->setPen(pen); | ||||||
| 				scene()->addItem(item); | 				scene()->addItem(item); | ||||||
| 				from = to; | 				from = to; | ||||||
| 			} | 			} else { | ||||||
| 			else{ |  | ||||||
| 				from = QPointF(SCALEGC(entry->sec, entry->pn2)); | 				from = QPointF(SCALEGC(entry->sec, entry->pn2)); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|  | @ -457,8 +456,7 @@ void ProfileGraphicsView::plot_pp_gas_profile() | ||||||
| 				item->setPen(pen); | 				item->setPen(pen); | ||||||
| 				scene()->addItem(item); | 				scene()->addItem(item); | ||||||
| 				from = to; | 				from = to; | ||||||
| 			} | 			} else { | ||||||
| 			else{ |  | ||||||
| 				from = QPointF(SCALEGC(entry->sec, entry->pn2)); | 				from = QPointF(SCALEGC(entry->sec, entry->pn2)); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|  | @ -479,8 +477,7 @@ void ProfileGraphicsView::plot_pp_gas_profile() | ||||||
| 				item->setPen(pen); | 				item->setPen(pen); | ||||||
| 				scene()->addItem(item); | 				scene()->addItem(item); | ||||||
| 				from = to; | 				from = to; | ||||||
| 			} | 			} else { | ||||||
| 			else{ |  | ||||||
| 				from = QPointF(SCALEGC(entry->sec, entry->phe)); | 				from = QPointF(SCALEGC(entry->sec, entry->phe)); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|  | @ -498,8 +495,7 @@ void ProfileGraphicsView::plot_pp_gas_profile() | ||||||
| 				item->setPen(pen); | 				item->setPen(pen); | ||||||
| 				scene()->addItem(item); | 				scene()->addItem(item); | ||||||
| 				from = to; | 				from = to; | ||||||
| 			} | 			} else { | ||||||
| 			else{ |  | ||||||
| 				from = QPointF(SCALEGC(entry->sec, entry->phe)); | 				from = QPointF(SCALEGC(entry->sec, entry->phe)); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|  | @ -518,8 +514,7 @@ void ProfileGraphicsView::plot_pp_gas_profile() | ||||||
| 				item->setPen(pen); | 				item->setPen(pen); | ||||||
| 				scene()->addItem(item); | 				scene()->addItem(item); | ||||||
| 				from = to; | 				from = to; | ||||||
| 			} | 			} else { | ||||||
| 			else{ |  | ||||||
| 				from = QPointF(SCALEGC(entry->sec, entry->po2)); | 				from = QPointF(SCALEGC(entry->sec, entry->po2)); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|  | @ -535,8 +530,7 @@ void ProfileGraphicsView::plot_pp_gas_profile() | ||||||
| 				item->setPen(QPen(c)); | 				item->setPen(QPen(c)); | ||||||
| 				scene()->addItem(item); | 				scene()->addItem(item); | ||||||
| 				from = to; | 				from = to; | ||||||
| 			} | 			} else { | ||||||
| 			else{ |  | ||||||
| 				from = QPointF(SCALEGC(entry->sec, entry->po2)); | 				from = QPointF(SCALEGC(entry->sec, entry->po2)); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|  | @ -1168,8 +1162,7 @@ void ProfileGraphicsView::plot_temperature_profile() | ||||||
| 			item->setPen(pen); | 			item->setPen(pen); | ||||||
| 			scene()->addItem(item); | 			scene()->addItem(item); | ||||||
| 			from = to; | 			from = to; | ||||||
| 		} | 		} else { | ||||||
| 		else{ |  | ||||||
| 			from = QPointF(SCALEGC(sec, mkelvin)); | 			from = QPointF(SCALEGC(sec, mkelvin)); | ||||||
| 		} | 		} | ||||||
| 		last = mkelvin; | 		last = mkelvin; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue