From 4ea281c750c5afcc68f2832bb42d98a1cbce6735 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Ka=CC=88fer?= Date: Wed, 16 Jul 2014 18:53:56 -0700 Subject: rename llmr => mbgl --- include/llmr/text/glyph.hpp | 61 --------------------------------------------- 1 file changed, 61 deletions(-) delete mode 100644 include/llmr/text/glyph.hpp (limited to 'include/llmr/text/glyph.hpp') diff --git a/include/llmr/text/glyph.hpp b/include/llmr/text/glyph.hpp deleted file mode 100644 index 99c8964701..0000000000 --- a/include/llmr/text/glyph.hpp +++ /dev/null @@ -1,61 +0,0 @@ -#ifndef LLMR_TEXT_GLYPH -#define LLMR_TEXT_GLYPH - -#include - -#include -#include -#include - -namespace llmr { - -typedef std::pair GlyphRange; - -// Note: this only works for the BMP -GlyphRange getGlyphRange(char32_t glyph); - -struct GlyphMetrics { - operator bool() const { - return width == 0 && height == 0 && advance == 0; - } - - // Glyph metrics. - uint32_t width = 0; - uint32_t height = 0; - int32_t left = 0; - int32_t top = 0; - uint32_t advance = 0; - -}; - -struct Glyph { - inline explicit Glyph() : rect(0, 0, 0, 0), metrics() {} - inline explicit Glyph(const Rect &rect, - const GlyphMetrics &metrics) - : rect(rect), metrics(metrics) {} - - operator bool() const { - return !metrics && !rect; - } - - const Rect rect; - const GlyphMetrics metrics; -}; - -typedef std::map GlyphPositions; - -class GlyphPlacement { -public: - inline explicit GlyphPlacement(uint32_t face, uint32_t glyph, uint32_t x, uint32_t y) - : face(face), glyph(glyph), x(x), y(y) {} - - uint32_t face = 0; - uint32_t glyph = 0; - int32_t x = 0; - int32_t y = 0; -}; - -typedef std::vector Shaping; -} - -#endif -- cgit v1.2.1