mirror of
				https://github.com/ciphervance/supercell-wx.git
				synced 2025-10-31 04:30:05 +00:00 
			
		
		
		
	Create accessor functions for placefile fonts
This commit is contained in:
		
							parent
							
								
									783e8f3490
								
							
						
					
					
						commit
						4ee7731023
					
				
					 2 changed files with 19 additions and 0 deletions
				
			
		|  | @ -84,6 +84,22 @@ std::vector<std::shared_ptr<Placefile::DrawItem>> Placefile::GetDrawItems() | |||
|    return p->drawItems_; | ||||
| } | ||||
| 
 | ||||
| std::unordered_map<std::size_t, std::shared_ptr<Placefile::Font>> | ||||
| Placefile::fonts() | ||||
| { | ||||
|    return p->fonts_; | ||||
| } | ||||
| 
 | ||||
| std::shared_ptr<Placefile::Font> Placefile::font(std::size_t i) | ||||
| { | ||||
|    auto it = p->fonts_.find(i); | ||||
|    if (it != p->fonts_.cend()) | ||||
|    { | ||||
|       return it->second; | ||||
|    } | ||||
|    return nullptr; | ||||
| } | ||||
| 
 | ||||
| std::shared_ptr<Placefile> Placefile::Load(const std::string& filename) | ||||
| { | ||||
|    logger_->debug("Loading placefile: {}", filename); | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Dan Paulat
						Dan Paulat