OCRTest/src/main/java/edu/sfsu/cs/orange/ocr/CaptureActivity.java
void handleOcrContinuousDecode(OcrResultFailure obj) {
    lastResult = null;
    viewfinderView.removeResultText();

    // Reset the text in the recognized text box.
    statusViewTop.setText("");

    if (CONTINUOUS_DISPLAY_METADATA) {
      // Color text delimited by '-' as red.
      statusViewBottom.setTextSize(14);
      CharSequence cs = setSpanBetweenTokens(
              "OCR: " + sourceLanguageReadable + " - OCR failed - Time required: " + obj.getTimeRequired() + " ms",
              new ForegroundColorSpan(0xFFFF0000));
      statusViewBottom.setText(cs);
    }
  }
/**
   * Version of handleOcrContinuousDecode for failed OCR requests. Displays a failure message.
   *
   * @param obj Metadata for the failed OCR request.
   */
Version of handleOcrContinuousDecode for failed OCR requests. Displays a failure message.

@param obj Metadata for the failed OCR request.
Version of handleOcrContinuousDecode for failed OCR requests . Displays a failure message . @param obj Metadata for the failed OCR request .
void handleOcrContinuousDecode(OcrResultFailure obj) {
    lastResult = null;
    viewfinderView.removeResultText();
    statusViewTop.setText("");
    if (CONTINUOUS_DISPLAY_METADATA) {
      statusViewBottom.setTextSize(14);
      CharSequence cs = setSpanBetweenTokens(
              "OCR: " + sourceLanguageReadable + " - OCR failed - Time required: " + obj.getTimeRequired() + " ms",
              new ForegroundColorSpan(0xFFFF0000));
      statusViewBottom.setText(cs);
    }
  }
void handleOcrContinuousDecode ( OcrResultFailure obj ) { lastResult = null ; viewfinderView . removeResultText ( ) ; statusViewTop . setText ( "" ) ; if ( CONTINUOUS_DISPLAY_METADATA ) { statusViewBottom . setTextSize ( 14 ) ; CharSequence cs = setSpanBetweenTokens ( "OCR: " + sourceLanguageReadable + " - OCR failed - Time required: " + obj . getTimeRequired ( ) + " ms" , new ForegroundColorSpan ( 0xFFFF0000 ) ) ; statusViewBottom . setText ( cs ) ; } }
Version of handleOcrContinuousDecode for failed OCR requests.
Version of handleOcrContinuousDecode for failed OCR requests .
// Reset the text in the recognized text box.
 // Color text delimited by '-' as red.
