MauiKit Image Tools
7#include "image2text_export.h"
8#include <QQmlParserStatus>
15class OCRLanguageModel;
22 Q_PROPERTY(QString filePath READ filePath WRITE setFilePath NOTIFY filePathChanged)
23 Q_PROPERTY(QRect area READ area WRITE setArea NOTIFY areaChanged)
27 Q_PROPERTY(
bool autoRead READ autoRead WRITE setAutoRead NOTIFY autoReadChanged)
29 Q_PROPERTY(TextBoxes wordBoxes READ wordBoxes NOTIFY wordBoxesChanged)
30 Q_PROPERTY(TextBoxes paragraphBoxes READ paragraphBoxes NOTIFY paragraphBoxesChanged)
31 Q_PROPERTY(TextBoxes lineBoxes READ lineBoxes NOTIFY lineBoxesChanged)
33 Q_PROPERTY(BoxesType boxesType READ boxesType WRITE setBoxesType NOTIFY boxesTypeChanged)
44 Q_DECLARE_FLAGS(BoxesType, BoxType)
48 explicit OCS(QObject *parent =
nullptr);
51 QString filePath()
const;
53 bool autoRead()
const;
54 TextBoxes wordBoxes()
const;
55 TextBoxes paragraphBoxes()
const;
56 TextBoxes lineBoxes()
const;
57 OCS::BoxesType boxesType();
73 void setFilePath(QString filePath);
74 void setArea(QRect area);
75 void setAutoRead(
bool value);
76 void setBoxesType(OCS::BoxesType types);
79 tesseract::TessBaseAPI *m_tesseract;
80 OCRLanguageModel *m_languages;
84 bool m_autoRead =
false;
86 TextBoxes m_wordBoxes;
87 TextBoxes m_paragraphBoxes;
88 TextBoxes m_lineBoxes;
90 BoxesType m_boxesTypes;
93 void filePathChanged(QString filePath);
94 void areaChanged(QRect area);
95 void autoReadChanged();
96 void textReady(QString text);
97 void wordBoxesChanged();
98 void lineBoxesChanged();
99 void paragraphBoxesChanged();
100 void boxesTypeChanged();
102Q_DECLARE_OPERATORS_FOR_FLAGS(OCS::BoxesType)
virtual void classBegin()=0
virtual void componentComplete()=0
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Mar 7 2025 11:56:33 by
doxygen 1.13.2 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.