#include <paragraphs_internal.h>
Definition at line 192 of file paragraphs_internal.h.
◆ ParagraphTheory()
◆ AddModel()
Definition at line 1225 of file paragraphs.cpp.
1225 {
1226 for (
int i = 0; i < models_->
size(); i++) {
1227 if ((*models_)[i]->Comparable(model))
1228 return (*models_)[i];
1229 }
1233 return m;
1234}
int push_back_new(const T &object)
◆ DiscardUnusedModels()
void tesseract::ParagraphTheory::DiscardUnusedModels |
( |
const SetOfModels & |
used_models | ) |
|
Definition at line 1236 of file paragraphs.cpp.
1236 {
1237 for (
int i = models_->
size() - 1; i >= 0; i--) {
1239 if (!used_models.contains(m) && models_we_added_.
contains(m)) {
1242 delete m;
1243 }
1244 }
1245}
int get_index(const T &object) const
bool contains(const T &object) const
◆ Fits()
Definition at line 1250 of file paragraphs.cpp.
1251 {
1252 for (
int m = 0; m < models_->
size(); m++) {
1256 return model;
1257 }
1258 return nullptr;
1259}
bool RowsFitModel(const GenericVector< RowScratchRegisters > *rows, int start, int end, const ParagraphModel *model)
tesseract::ParagraphJustification justification() const
◆ IndexOf()
int tesseract::ParagraphTheory::IndexOf |
( |
const ParagraphModel * |
model | ) |
const |
Definition at line 1269 of file paragraphs.cpp.
1269 {
1270 for (
int i = 0; i < models_->
size(); i++) {
1271 if ((*models_)[i] == model)
1272 return i;
1273 }
1274 return -1;
1275}
◆ models() [1/2]
◆ models() [2/2]
◆ NonCenteredModels()
void tesseract::ParagraphTheory::NonCenteredModels |
( |
SetOfModels * |
models | ) |
|
Definition at line 1261 of file paragraphs.cpp.
1261 {
1262 for (
int m = 0; m < models_->
size(); m++) {
1266 }
1267}
The documentation for this class was generated from the following files: