Peter Nelson 
							
						 
					 
					
						
						
							
						
						35ba49bfb4 
					 
					
						
						
							
							Change: Rename text colour NWidgetPart to SetTextStyle and add font size.  
						
						 
						
						... 
						
						
						
						This allows to set both text colour and size for any widget with default
drawing. 
						
						
					 
					
						2023-04-30 11:47:53 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						55d981aec3 
					 
					
						
						
							
							Add: Helper to update widget vertical size.  
						
						 
						
						... 
						
						
						
						This avoids directly setting min_y outside widget code. 
						
						
					 
					
						2023-04-25 13:27:22 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						d93f96a442 
					 
					
						
						
							
							Fix: Account for extra dropdown list padding.  
						
						 
						
						
						
						
					 
					
						2023-04-12 18:43:15 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								rubidium42 
							
						 
					 
					
						
						
							
						
						6ba55e663e 
					 
					
						
						
							
							Codechange: do not hide variables with other variables  
						
						 
						
						
						
						
					 
					
						2023-01-29 07:21:34 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Rubidium 
							
						 
					 
					
						
						
							
						
						f001e84e5e 
					 
					
						
						
							
							Codechange: use RAII to automatically restore _cur_dpi after use  
						
						 
						
						
						
						
					 
					
						2023-01-28 20:33:02 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								PeterN 
							
						 
					 
					
						
						
							
						
						c448eb04d8 
					 
					
						
						
							
							Fix   #10242 : Allow a space for text shadow when clipping WWT_EMPTY/WWT_TEXT. ( #10243 )  
						
						 
						
						
						
						
					 
					
						2022-12-15 23:21:10 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						9bf24ec56f 
					 
					
						
						
							
							Codechange: Reorder and properly declare DrawSpriteIgnorePadding().  
						
						 
						
						... 
						
						
						
						Parameters have been rearranged to be closer to those of the standard
DrawSprite() function, and PaletteID can now be set. 
						
						
					 
					
						2022-11-17 09:12:07 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						ecb5393c55 
					 
					
						
						
							
							Change: Standardize progress bar layout.  
						
						 
						
						... 
						
						
						
						Progress bars are drawn differently depending on when it was added, with
different layouts and sizes.
This change adds a standard padding size to use, and makes all progress
bars visually similar, with scaled padding. 
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						ed60c88b0a 
					 
					
						
						
							
							Change: Use power-of-2 scaling for some dimensions in GUI.  
						
						 
						
						... 
						
						
						
						These are related to drawing sprites that are normally drawn on the
landscape, and should therefore still follow power-of-2 scaling to fit
correctly. 
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						dd90d79e7b 
					 
					
						
						
							
							Add: Setting to toggle thin vs chunky (scaled) bevels.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						e554fd7808 
					 
					
						
						
							
							Change: Hide WidgetDrawDistances from general use.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						890b2666d3 
					 
					
						
						
							
							Change: Use scaled WidgetDimensions.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						23a8222200 
					 
					
						
						
							
							Change: Split vscroll and hscroll padding.  
						
						 
						
						... 
						
						
						
						Vertical and horizontal scrollbars are different sizes, this allows
different padding for each type. 
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						90ce704366 
					 
					
						
						
							
							Change: Use scaled WidgetDimensions for core widgets.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						0bb9a45785 
					 
					
						
						
							
							Change: Simplify drawing widget image buttons.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						d0add1e07f 
					 
					
						
						
							
							Change: Ignore offsets when drawing GUI sprite.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						b5693becdc 
					 
					
						
						
							
							Add: Define scaled WidgetDimensions.  
						
						 
						
						... 
						
						
						
						Includes RectPadding container. 
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						0108e9f387 
					 
					
						
						
							
							Change: Set up suggested widget padding for panel, frame and inset.  
						
						 
						
						... 
						
						
						
						Window handlers are free to ignore the suggested padding, however some
handlers have logic that assumes this information was already provided. 
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						68423c40c5 
					 
					
						
						
							
							Fix: Off-by-one in GetAlignedPosition().  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						dd9f6bc803 
					 
					
						
						
							
							Change: Use RectPadding Horizontal()/Vertical() helpers.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						04cbe57d2a 
					 
					
						
						
							
							Change: Use RectPadding for widget padding/uz_padding.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						f5f035a22b 
					 
					
						
						
							
							Codechange: Make use of Rect Width/Height helpers.  
						
						 
						
						
						
						
					 
					
						2022-11-12 18:28:39 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								PeterN 
							
						 
					 
					
						
						
							
						
						f24286a1ae 
					 
					
						
						
							
							Fix: Ensure 31-bit shifts are unsigned. ( #10128 )  
						
						 
						
						... 
						
						
						
						Shifting a signed 32-bit integer by 31 bits is undefined behaviour.
A few more than necessary are switched to unsigned for consistentency. 
						
						
					 
					
						2022-11-04 07:15:59 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						ba94efba87 
					 
					
						
						
							
							Change: Add flag to apply resize to largest resize step first.  
						
						 
						
						... 
						
						
						
						Resize step is normally allocated equally amongst all resizable widgets.
With this flag, we allocate as much as possible from the largest
resize step first. 
						
						
					 
					
						2022-10-16 14:56:34 +02:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						296af146fb 
					 
					
						
						
							
							Change: Default widget text colour to black.  
						
						 
						
						... 
						
						
						
						TC_FROMSTRING really means blue, and we almost never actually use
blue text. 
						
						
					 
					
						2022-10-16 14:24:51 +02:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Patric Stout 
							
						 
					 
					
						
						
							
						
						28e90769f7 
					 
					
						
						
							
							Codechange: use "[[maybe_unused]]" instead of a wide variety of other ways we had  
						
						 
						
						... 
						
						
						
						While at it, replace OTTD_ASSERT with WITH_ASSERT, as this
is always set if assert() is valid. No matter if NDEBUG is set
or not. 
						
						
					 
					
						2021-06-03 17:30:00 +02:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								PeterN 
							
						 
					 
					
						
						
							
						
						330a305c99 
					 
					
						
						
							
							Fix: Apply unscaled padding to Viewport inside WWT_INSET. ( #9219 )  
						
						 
						
						... 
						
						
						
						Since pixel dimensions in SetPadding() are scaled by GUI size, padding for inset viewports was excessive.
Instead, automatically apply padding for WWT_INSET at widget level. This applies to all widgets inside a WWT_INSET, which in all instances is a NWID_VIEWPORT. 
						
						
					 
					
						2021-05-08 21:01:16 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						d8e06e590a 
					 
					
						
						
							
							Codechange: Make GetCurrentRect() conform to usual Rect bounds, and reuse it.  
						
						 
						
						... 
						
						
						
						Similar code is already repeated in other locations. 
						
						
					 
					
						2021-05-08 09:53:55 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						52b16237ad 
					 
					
						
						
							
							Codechange: Don't update window contents if scrollbar position has not moved.  
						
						 
						
						
						
						
					 
					
						2021-05-08 09:52:54 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								PeterN 
							
						 
					 
					
						
						
							
						
						256dbee255 
					 
					
						
						
							
							Fix: Crash when extra viewport height is zero with sign in view. ( #9175 )  
						
						 
						
						... 
						
						
						
						If a viewport sign straddles the top of a viewport, a crash will occur if the viewport height is zero. This is resolved by simply not attempting to draw the viewport in this situation, consistent with other widgets. 
						
						
					 
					
						2021-05-02 10:21:27 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						4791ff2862 
					 
					
						
						
							
							Fix: Recalculate padding and minimum sizes when GUI or Font zoom is changed.  
						
						 
						
						
						
						
					 
					
						2021-04-30 17:08:15 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						6fe5353da2 
					 
					
						
						
							
							Cleanup: Set unchanging scrollbar properties in constructor.  
						
						 
						
						
						
						
					 
					
						2021-04-30 17:08:15 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						03a43b8247 
					 
					
						
						
							
							Cleanup: Call SetMinimalSize instead of setting min_y directly.  
						
						 
						
						
						
						
					 
					
						2021-04-30 17:08:15 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						f5569763c9 
					 
					
						
						
							
							Fix: Specify width when width is required instead of top.  
						
						 
						
						
						
						
					 
					
						2021-04-30 17:08:15 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						4c6cca459a 
					 
					
						
						
							
							Cleanup: Remove fairly redundant DrawDropdown() function.  
						
						 
						
						
						
						
					 
					
						2021-04-30 17:08:15 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						5153e1b6e3 
					 
					
						
						
							
							Cleanup: Horizontal widget size is commonly width rather than length.  
						
						 
						
						
						
						
					 
					
						2021-04-30 17:08:15 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						51b4bd6c38 
					 
					
						
						
							
							Codechange: Add widget text colour override property.  
						
						 
						
						
						
						
					 
					
						2021-04-22 16:42:04 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						636e37d183 
					 
					
						
						
							
							Codechange: Add internal widget alignment property, along with widget part.  
						
						 
						
						
						
						
					 
					
						2021-04-22 16:42:04 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Peter Nelson 
							
						 
					 
					
						
						
							
						
						2a0365b3d9 
					 
					
						
						
							
							Cleanup: Remove unnecessary parameter of GetScrolledRowFromWidget()  
						
						 
						
						... 
						
						
						
						Line height defaults to the resize height of the relevant widget, which is
set in all cases. Therefore it is not necessary to specify this value every time.
Additionally fixes scrolled padding for the framerate window. 
						
						
					 
					
						2021-04-21 23:12:10 +02:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Rubidium 
							
						 
					 
					
						
						
							
						
						bf4fe19a66 
					 
					
						
						
							
							Codechange: merge duplicated logic to scroll in lists by key into a single function  
						
						 
						
						
						
						
					 
					
						2021-04-21 21:12:08 +02:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Charles Pigott 
							
						 
					 
					
						
						
							
						
						dd798d688b 
					 
					
						
						
							
							Fix   #8919 : Release builds with asserts enabled ( #8925 )  
						
						 
						
						
						
						
					 
					
						2021-04-01 23:57:49 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Patric Stout 
							
						 
					 
					
						
						
							
						
						fece1c57ca 
					 
					
						
						
							
							Codechange: Suppress warnings when asserts are disabled ( #8917 )  
						
						 
						
						
						
						
					 
					
						2021-04-01 11:16:19 +02:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Tyler Trahan 
							
						 
					 
					
						
						
							
						
						de891238d6 
					 
					
						
						
							
							Change: Recolour graph windows to brown ( #8700 )  
						
						 
						
						
						
						
					 
					
						2021-03-11 15:30:29 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								PeterN 
							
						 
					 
					
						
						
							
						
						9fdc881005 
					 
					
						
						
							
							Fix: Scale PIP-padding the same as regular padding. ( #8829 )  
						
						 
						
						
						
						
					 
					
						2021-03-09 10:43:04 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Patric Stout 
							
						 
					 
					
						
						
							
						
						af22a4f2cd 
					 
					
						
						
							
							Add: show in the tooltip of disabled toolbar buttons why they are disabled  
						
						 
						
						
						
						
					 
					
						2021-01-08 16:43:51 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								Charles Pigott 
							
						 
					 
					
						
						
							
						
						9b800a96ed 
					 
					
						
						
							
							Codechange: Remove min/max functions in favour of STL variants ( #8502 )  
						
						 
						
						
						
						
					 
					
						2021-01-08 11:16:18 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								TechGeekNZ 
							
						 
					 
					
						
						
							
						
						a10013dd00 
					 
					
						
						
							
							Codechange: Spell 'Viewport' consistently  
						
						 
						
						... 
						
						
						
						Some places in the codebase misspell 'Viewport' as 'ViewPort' or 'view_port'.
This patch makes everything consistent. 
						
						
					 
					
						2020-07-27 17:31:29 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								TechGeekNZ 
							
						 
					 
					
						
						
							
						
						8652a4db76 
					 
					
						
						
							
							Cleanup: Give SetDirtyBlocks a more descriptive name.  
						
						 
						
						
						
						
					 
					
						2020-06-09 13:15:47 +01:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								S. D. Cloudt 
							
						 
					 
					
						
						
							
						
						13cc8a0cee 
					 
					
						
						
							
							Cleanup: Removed SVN  headers  
						
						 
						
						
						
						
					 
					
						2019-11-10 17:59:20 +00:00  
					
					
						 
						
						
							
							
							 
							
							
							
							
							 
						
					 
				 
			
				
					
						
							
							
								 
								glx 
							
						 
					 
					
						
						
							
						
						1f418555a1 
					 
					
						
						
							
							Fix   #7742 ,  66dd7c3: widget position can be negative  
						
						 
						
						
						
						
					 
					
						2019-09-17 20:11:34 +02:00