QGIS API Documentation  2.99.0-Master (d55fa22)
qgscharacterselectdialog.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgscharacterselectdialog.h - single font character selector dialog
3 
4  ---------------------
5  begin : November 2012
6  copyright : (C) 2012 by Larry Shaffer
7  email : larrys at dakcarto dot com
8  ***************************************************************************
9  * *
10  * This program is free software; you can redistribute it and/or modify *
11  * it under the terms of the GNU General Public License as published by *
12  * the Free Software Foundation; either version 2 of the License, or *
13  * (at your option) any later version. *
14  * *
15  ***************************************************************************/
16 
17 #ifndef QGSCHARACTERSELECTDIALOG_H
18 #define QGSCHARACTERSELECTDIALOG_H
19 
20 #include <QDialog>
21 #include <QChar>
22 #include "qgsguiutils.h"
23 #include "ui_qgscharacterselectdialogbase.h"
24 #include "qgis_gui.h"
25 
26 class CharacterWidget;
27 
32 class GUI_EXPORT QgsCharacterSelectorDialog : public QDialog, private Ui::QgsCharacterSelectorBase
33 {
34  Q_OBJECT
35 
36  public:
37  QgsCharacterSelectorDialog( QWidget *parent = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
38 
39  public slots:
40  const QChar &selectCharacter( bool *gotChar, const QFont &font, const QString &style );
41 
42  private slots:
43  void setCharacter( QChar chr );
44 
45  protected:
46  QChar mChar;
47  CharacterWidget *mCharWidget = nullptr;
48 };
49 
50 #endif
A widget for displaying characters available in a preset font, and allowing users to select an indivi...
A dialog for selecting a single character from a single font.