Changeset - r26590:2a2369793c9b
[Not reviewed]
master
0 2 0
Tyler Trahan - 19 months ago 2022-11-13 15:25:04
tyler@tylertrahan.com
Change: Add a Total caption to each category of the finance window
2 files changed with 7 insertions and 2 deletions:
0 comments (0 inline, 0 general)
src/company_gui.cpp
Show inline comments
 
@@ -186,8 +186,12 @@ static void DrawCategories(const Rect &r
 
		DrawCategory(r, y, _expenses_list_types[i]);
 
		y += _expenses_list_types[i].GetHeight();
 

	
 
		/* Advance y by the height of the total and associated total line */
 
		y += WidgetDimensions::scaled.vsep_normal + FONT_HEIGHT_NORMAL;
 
		/* Advance y by the height of the horizontal line between amounts and subtotal */
 
		y += WidgetDimensions::scaled.vsep_normal;
 

	
 
		/* Draw category total and advance y */
 
		DrawString(r.left, r.right, y, STR_FINANCES_TOTAL_CAPTION, TC_FROMSTRING, SA_RIGHT);
 
		y += FONT_HEIGHT_NORMAL;
 

	
 
		/* Advance y by a blockspace after this category block */
 
		y += WidgetDimensions::scaled.vsep_wide;
src/lang/english.txt
Show inline comments
 
@@ -3660,6 +3660,7 @@ STR_FINANCES_SECTION_SHIP_REVENUE       
 
STR_FINANCES_SECTION_LOAN_INTEREST                              :{GOLD}Loan Interest
 
STR_FINANCES_SECTION_OTHER                                      :{GOLD}Other
 

	
 
STR_FINANCES_TOTAL_CAPTION                                      :{WHITE}Total
 
STR_FINANCES_NEGATIVE_INCOME                                    :-{CURRENCY_LONG}
 
STR_FINANCES_ZERO_INCOME                                        :{CURRENCY_LONG}
 
STR_FINANCES_POSITIVE_INCOME                                    :+{CURRENCY_LONG}
0 comments (0 inline, 0 general)