During layout analysis, blocks with handwritten and handprinted texts can be found and marked for recognition with the handwritten text type. To detect and recognize handwritten or handprinted text, set the DetectHandwritten property of the PageAnalysisParams property to TRUE. Set the SpeedQualityMode property to SQM_Accurate, because handwriting can only be detected in accurate analysis mode.Handwritten and handprinted text type are specified by the same TextTypeEnum::TT_Handwritten constant. The text blocks will be created with the TextTypes property of the ITextBlock::RecognizerParams object set to TT_Handwritten.During recognition, the text will be recognized as handwritten if the recognition language supports handwritten text, or as handprinted if it only supports handprinted text.
C# code
// Global ABBYY FineReader Engine objectFREngine.IEngine engine;...// Open an image file...FREngine.IFRDocument frdoc;// Create DocumentProcessingParams and set parametersFREngine.IDocumentProcessingParams processingParams = engine.CreateDocumentProcessingParams();processingParams.PageProcessingParams.PageAnalysisParams.SpeedQualityMode = SQM_Accurate;processingParams.PageProcessingParams.PageAnalysisParams.DetectHandwritten = true;// Set the text types to recognize both regular text and handwritingprocessingParams.PageProcessingParams.RecognizerParams.TextTypes = TT_Normal | TT_Handwritten;// Use the parameters for processingfrDoc.Process( processingParams );...
[Optional] Handprinted letters can often be enclosed in a frame, box, etc. In this case, set up the type of marking around the letters in the FieldMarkingType property of the RecognizerParams object. If each letter is written in a separate cell, use the CellsCount property to set up the number of character cells in the recognized block.
C# code
// Global ABBYY FineReader Engine objectFREngine.IEngine engine;...// Open an image file...// Obtain the Layout object from the pageFREngine.ILayout layout = frPage.Layout;// Set block regionFREngine.IRegion region = engine.CreateRegion();region.AddRect( 491, 314, 2268, 404 );// Create a new blockFREngine.IBlock newBlock = layout.Blocks.AddNew( FREngine.BlockTypeEnum.BT_Text, region, 0 );FREngine.ITextBlock textBlock = newBlock.GetAsTextBlock();// Specify the text typetextBlock.RecognizerParams.TextTypes = (int)FREngine.TextTypeEnum.TT_Handwritten;// Specify the type of marking around the letterstextBlock.RecognizerParams.FieldMarkingType = FREngine.FieldMarkingTypeEnum.FMT_SimpleText;// Recognition and export...