mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 01:52:43 +00:00 
			
		
		
		
	 62974160da
			
		
	
	
		62974160da
		
	
	
	
	
		
			
			This function should return the automatic height of the formatting context's root box. Until now, we've been relying on some magical handshakes between parent and child context, when negotiating the height of child context root boxes. This is a step towards something more reasonable.
		
			
				
	
	
		
			27 lines
		
	
	
	
		
			662 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			27 lines
		
	
	
	
		
			662 B
		
	
	
	
		
			C++
		
	
	
	
	
	
| /*
 | |
|  * Copyright (c) 2022, Martin Falisse <mfalisse@outlook.com>
 | |
|  *
 | |
|  * SPDX-License-Identifier: BSD-2-Clause
 | |
|  */
 | |
| 
 | |
| #pragma once
 | |
| 
 | |
| #include <LibWeb/Layout/BlockFormattingContext.h>
 | |
| #include <LibWeb/Layout/Box.h>
 | |
| #include <LibWeb/Layout/FormattingContext.h>
 | |
| 
 | |
| namespace Web::Layout {
 | |
| 
 | |
| class GridFormattingContext final : public BlockFormattingContext {
 | |
| public:
 | |
|     explicit GridFormattingContext(LayoutState&, BlockContainer const&, FormattingContext* parent);
 | |
|     ~GridFormattingContext();
 | |
| 
 | |
|     virtual void run(Box const&, LayoutMode) override;
 | |
|     virtual float automatic_content_height() const override;
 | |
| 
 | |
| private:
 | |
|     float m_automatic_content_height { 0 };
 | |
| };
 | |
| 
 | |
| }
 |