okular/generators/dvi/glyph.h
Albert Astals Cid 19d98d6a74 Run clang-format
find . \( -name "*.cpp" -or -name "*.h"  -or -name "*.c"  -or -name "*.cc" \) -exec clang-format -i {} \;

If you reached this file doing a git blame, please see README.clang-format (added 2 commits in the future of this one)
2020-07-11 09:17:33 +02:00

48 lines
842 B
C++

// -*- Mode: C++; c-basic-offset: 2; indent-tabs-mode: nil; c-brace-offset: 0; -*-
#ifndef _GLYPH_H
#define _GLYPH_H
#include <QColor>
#include <QImage>
struct bitmap {
bitmap();
~bitmap();
bitmap(const bitmap &) = delete;
bitmap &operator=(const bitmap &) = delete;
// width and height in pixels
quint16 w, h;
// scan-line width in bytes
quint16 bytes_wide;
// pointer to the bits
char *bits;
};
class glyph
{
public:
glyph();
~glyph();
// address of bitmap in font file
long addr;
QColor color;
// DVI units to move reference point
qint32 dvi_advance_in_units_of_design_size_by_2e20;
// x and y offset in pixels
short x, y;
QImage shrunkenCharacter;
// x and y offset in pixels (shrunken bitmap)
short x2, y2;
};
#endif // ifndef _GLYPH_H