mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 21:32:44 +00:00 
			
		
		
		
	 eb610b309e
			
		
	
	
		eb610b309e
		
	
	
	
	
		
			
			I found myself having to cast to GWidget* all the time when writing some generic debugging code that just wanted to dump widget info.
		
			
				
	
	
		
			21 lines
		
	
	
	
		
			413 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
	
		
			413 B
		
	
	
	
		
			C++
		
	
	
	
	
	
| #pragma once
 | |
| 
 | |
| #include <LibGUI/GWidget.h>
 | |
| 
 | |
| class GLabel;
 | |
| 
 | |
| class GStatusBar : public GWidget {
 | |
| public:
 | |
|     explicit GStatusBar(GWidget* parent);
 | |
|     virtual ~GStatusBar() override;
 | |
| 
 | |
|     String text() const;
 | |
|     void set_text(String&&);
 | |
| 
 | |
|     virtual const char* class_name() const override { return "GStatusBar"; }
 | |
| 
 | |
| private:
 | |
|     virtual void paint_event(GPaintEvent&) override;
 | |
| 
 | |
|     GLabel* m_label { nullptr };
 | |
| };
 |