| 247 | }; |
| 248 | |
| 249 | class Font { |
| 250 | protected: |
| 251 | FontID fid; |
| 252 | #if PLAT_WX |
| 253 | int ascent; |
| 254 | #endif |
| 255 | // Private so Font objects can not be copied |
| 256 | Font(const Font &); |
| 257 | Font &operator=(const Font &); |
| 258 | public: |
| 259 | Font(); |
| 260 | virtual ~Font(); |
| 261 | |
| 262 | virtual void Create(const FontParameters &fp); |
| 263 | virtual void Release(); |
| 264 | |
| 265 | FontID GetID() { return fid; } |
| 266 | // Alias another font - caller guarantees not to Release |
| 267 | void SetID(FontID fid_) { fid = fid_; } |
| 268 | #if PLAT_WX |
| 269 | void SetAscent(int ascent_) { ascent = ascent_; } |
| 270 | #endif |
| 271 | friend class Surface; |
| 272 | friend class SurfaceImpl; |
| 273 | }; |
| 274 | |
| 275 | /** |
| 276 | * A surface abstracts a place to draw. |
nothing calls this directly
no outgoing calls
no test coverage detected