18 #ifndef Q_TEXT_ORIENTATION_WIDGET_H 19 #define Q_TEXT_ORIENTATION_WIDGET_H bool textDisplayed() const
double squares_interval_
Interval between commonly used angles (represented by squares), in degrees.
double highlight_angle_
Specific angle to be highlighted.
QString getMostUsableStringForRadius(const qreal &)
void paintEvent(QPaintEvent *) override
QStringList usableTexts() const
double current_orientation_
current angle
void setOrientation(const double &)
bool display_text_
Whether to display an example text.
void setUsableTexts(const QStringList &)
void mouseReleaseEvent(QMouseEvent *) override
QHash< QString, qreal > text_size_hash_
Associate available example texts with their length (in pixels)
~QTextOrientationWidget() override
bool read_only_
Whether this widget is read only.
void generateTextSizeHash()
double orientation() const
void setDisplayText(bool)
void setFont(const QFont &)
void mouseMoveEvent(QMouseEvent *) override
int heightForWidth(int) const override
bool positionIsASquare(const QPointF &, double *=nullptr)
QSize sizeHint() const override
bool must_highlight_angle_
Whether to highlight a specific angle.
QTextOrientationWidget(QWidget *=nullptr)
QTextOrientationWidget & operator=(const QTextOrientationWidget &)
void orientationChanged(double)
QFont text_font_
Font used to render the example text.