Tesseract  3.02
tesseract-ocr/ccstruct/werd.cpp File Reference
#include "mfcpch.h"
#include "blckerr.h"
#include "helpers.h"
#include "linlsq.h"
#include "werd.h"

Go to the source code of this file.

Defines

#define FIRST_COLOUR   ScrollView::RED
#define LAST_COLOUR   ScrollView::AQUAMARINE
#define CHILD_COLOUR   ScrollView::BROWN

Functions

int word_comparator (const void *word1p, const void *word2p)

Variables

const ERRCODE CANT_SCALE_EDGESTEPS = "Attempted to scale an edgestep format word"

Define Documentation

#define CHILD_COLOUR   ScrollView::BROWN

Definition at line 28 of file werd.cpp.

#define FIRST_COLOUR   ScrollView::RED

Definition at line 26 of file werd.cpp.

#define LAST_COLOUR   ScrollView::AQUAMARINE

Definition at line 27 of file werd.cpp.


Function Documentation

int word_comparator ( const void *  word1p,
const void *  word2p 
)

word_comparator()

word comparator used to sort a word list so that words are in increasing order of left edge.

Definition at line 381 of file werd.cpp.

                                                            {
  WERD *word1 = *(WERD **)word1p;
  WERD *word2 = *(WERD **)word2p;
  return word1->bounding_box().left() - word2->bounding_box().left();
}

Variable Documentation

const ERRCODE CANT_SCALE_EDGESTEPS = "Attempted to scale an edgestep format word"

Definition at line 30 of file werd.cpp.