2018-05-09 11:05:39 -05:00
|
|
|
#pragma once
|
2018-04-30 18:21:34 -05:00
|
|
|
#include <cstddef>
|
|
|
|
|
|
|
|
#include "common/String.h"
|
2020-12-25 12:39:35 -06:00
|
|
|
|
|
|
|
#define FONT_H 12
|
2018-04-30 18:21:34 -05:00
|
|
|
|
|
|
|
class FontReader
|
|
|
|
{
|
2018-05-09 11:05:39 -05:00
|
|
|
unsigned char const *pointer;
|
2018-04-30 18:21:34 -05:00
|
|
|
int width;
|
|
|
|
int pixels;
|
|
|
|
int data;
|
|
|
|
|
2019-12-17 08:03:41 -06:00
|
|
|
FontReader(unsigned char const *_pointer);
|
|
|
|
static unsigned char const *lookupChar(String::value_type ch);
|
2018-04-30 21:57:03 -05:00
|
|
|
|
2018-04-30 18:21:34 -05:00
|
|
|
public:
|
2019-12-17 08:03:41 -06:00
|
|
|
FontReader(String::value_type ch);
|
|
|
|
int GetWidth() const;
|
|
|
|
int NextPixel();
|
2018-04-30 18:21:34 -05:00
|
|
|
};
|