All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
underlin.h
Go to the documentation of this file.
1 /**********************************************************************
2  * File: underlin.h (Formerly undrline.h)
3  * Description: Code to chop blobs apart from underlines.
4  * Author: Ray Smith
5  * Created: Mon Aug 8 11:14:00 BST 1994
6  *
7  * (C) Copyright 1994, Hewlett-Packard Ltd.
8  ** Licensed under the Apache License, Version 2.0 (the "License");
9  ** you may not use this file except in compliance with the License.
10  ** You may obtain a copy of the License at
11  ** http://www.apache.org/licenses/LICENSE-2.0
12  ** Unless required by applicable law or agreed to in writing, software
13  ** distributed under the License is distributed on an "AS IS" BASIS,
14  ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  ** See the License for the specific language governing permissions and
16  ** limitations under the License.
17  *
18  **********************************************************************/
19 
20 #ifndef UNDERLIN_H
21 #define UNDERLIN_H
22 
23 #include "fpchop.h"
24 
26 "Fraction of x to ignore");
28 "Chop underlines & put back");
29 void restore_underlined_blobs( //get chop points
30  TO_BLOCK *block //block to do
31  );
32 TO_ROW *most_overlapping_row( //find best row
33  TO_ROW_LIST *rows, //list of rows
34  BLOBNBOX *blob //blob to place
35  );
36 void find_underlined_blobs( //get chop points
37  BLOBNBOX *u_line, //underlined unit
38  QSPLINE *baseline, //actual baseline
39  float xheight, //height of line
40  float baseline_offset, //amount to shrinke it
41  ICOORDELT_LIST *chop_cells //places to chop
42  );
43 void vertical_cunderline_projection( //project outlines
44  C_OUTLINE *outline, //outline to project
45  QSPLINE *baseline, //actual baseline
46  float xheight, //height of line
47  float baseline_offset, //amount to shrinke it
48  STATS *lower_proj, //below baseline
49  STATS *middle_proj, //centre region
50  STATS *upper_proj //top region
51  );
52 #endif
TO_ROW * most_overlapping_row(TO_ROW_LIST *rows, BLOBNBOX *blob)
Definition: underlin.cpp:116
void find_underlined_blobs(BLOBNBOX *u_line, QSPLINE *baseline, float xheight, float baseline_offset, ICOORDELT_LIST *chop_cells)
Definition: underlin.cpp:173
Definition: statistc.h:33
double textord_underline_offset
Definition: underlin.cpp:28
#define double_VAR_H(name, val, comment)
Definition: params.h:274
void vertical_cunderline_projection(C_OUTLINE *outline, QSPLINE *baseline, float xheight, float baseline_offset, STATS *lower_proj, STATS *middle_proj, STATS *upper_proj)
Definition: underlin.cpp:218
#define FALSE
Definition: capi.h:29
void restore_underlined_blobs(TO_BLOCK *block)
Definition: underlin.cpp:38
bool textord_restore_underlines
Definition: underlin.cpp:30
#define BOOL_VAR_H(name, val, comment)
Definition: params.h:268