OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
Slic3r::Emboss::FontFile Struct Reference

keep information from file about font (store file data itself) More...

#include </home/runner/work/OrcaSlicer/OrcaSlicer/src/libslic3r/Emboss.hpp>

Collaboration diagram for Slic3r::Emboss::FontFile:

Classes

struct  Info

Public Member Functions

 FontFile (std::unique_ptr< std::vector< unsigned char > > data, std::vector< Info > &&infos)
bool operator== (const FontFile &other) const

Public Attributes

std::unique_ptr< std::vector< unsigned char > > data
std::vector< Info > infos

Detailed Description

keep information from file about font (store file data itself)

  • cache data readed from buffer

Class Documentation

◆ Slic3r::Emboss::FontFile::Info

struct Slic3r::Emboss::FontFile::Info
Class Members
int ascent
int descent
int linegap
int unit_per_em

Constructor & Destructor Documentation

◆ FontFile()

Slic3r::Emboss::FontFile::FontFile ( std::unique_ptr< std::vector< unsigned char > > data,
std::vector< Info > && infos )
inline
91 : data(std::move(data)), infos(std::move(infos))
92 {
93 assert(this->data != nullptr);
94 assert(!this->data->empty());
95 }
std::vector< Info > infos
Definition Emboss.hpp:87
std::unique_ptr< std::vector< unsigned char > > data
Definition Emboss.hpp:76

References data, and infos.

Referenced by operator==().

Here is the caller graph for this function:

Member Function Documentation

◆ operator==()

bool Slic3r::Emboss::FontFile::operator== ( const FontFile & other) const
inline
97 {
98 if (data->size() != other.data->size())
99 return false;
100 //if(*data != *other.data) return false;
101 for (size_t i = 0; i < infos.size(); i++)
102 if (infos[i].ascent != other.infos[i].ascent ||
103 infos[i].descent == other.infos[i].descent ||
104 infos[i].linegap == other.infos[i].linegap)
105 return false;
106 return true;
107 }

References FontFile(), data, and infos.

Here is the call graph for this function:

Member Data Documentation

◆ data

◆ infos


The documentation for this struct was generated from the following file:
  • /home/runner/work/OrcaSlicer/OrcaSlicer/src/libslic3r/Emboss.hpp