blob: 59de414c0600ebdf68e291b5308d7249f16788e3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
|
#pragma once
#include <QtGui/QFont>
#include <QtWidgets/QWidget>
#include "uicontext.h"
/*!
@addtogroup FontSettings
\ingroup uiapi
@{
*/
enum AntialiasingStyle
{
SubpixelAntialiasing,
GrayscaleAntialiasing,
SubpixelAntialiasingUnlessHighDPI,
NoAntialiasing
};
//! Returns the default font size for the current platform.
int BINARYNINJAUIAPI getDefaultFontSize();
//! Returns the default application font name.
std::string BINARYNINJAUIAPI getDefaultApplicationFontName();
//! Returns the default application font, ignoring user settings.
QFont BINARYNINJAUIAPI getDefaultApplicationFont();
//! Returns the currently configured application font (or the default, if it doesn't exist).
QFont BINARYNINJAUIAPI getApplicationFont(QWidget* widget);
/*!
* Sets the currently configured application font.
*
* @param font The font to use. Passing nullptr will reset the application font to the user's configured default.
*/
void BINARYNINJAUIAPI setApplicationFont(const QFont* font);
//! Returns the default monospaced font name.
std::string BINARYNINJAUIAPI getDefaultMonospaceFontName();
//! Returns the default monospaced font, ignoring user settings.
QFont BINARYNINJAUIAPI getDefaultMonospaceFont();
//! Returns the currently configured monospaced font (or the default, if it doesn't exist).
QFont BINARYNINJAUIAPI getMonospaceFont(QWidget* widget);
/*!
* Sets the currently configured monospaced font.
*
* @param font The font to use. Passing nullptr will reset the monospaced font to the user's configured default.
*/
void BINARYNINJAUIAPI setMonospaceFont(const QFont* font);
//! Returns the default emoji font name.
std::string BINARYNINJAUIAPI getDefaultEmojiFontName();
//! Returns the default emoji font, ignoring user settings.
QFont BINARYNINJAUIAPI getDefaultEmojiFont();
//! Returns the currently configured emoji font (or the default, if it doesn't exist).
QFont BINARYNINJAUIAPI getEmojiFont(QWidget* widget);
/*!
* Sets the currently configured emoji font.
*
* @param font The font to use. Passing nullptr will reset the emoji font to the user's configured default.
*/
void BINARYNINJAUIAPI setEmojiFont(const QFont* font);
int BINARYNINJAUIAPI getDefaultExtraFontSpacing();
int BINARYNINJAUIAPI getExtraFontSpacing();
void BINARYNINJAUIAPI setExtraFontSpacing(int spacing);
int BINARYNINJAUIAPI getFontVerticalOffset();
bool BINARYNINJAUIAPI allowBoldFonts();
void BINARYNINJAUIAPI setAllowBoldFonts(bool allow);
AntialiasingStyle BINARYNINJAUIAPI getAntialiasingStyle();
void BINARYNINJAUIAPI setAntialiasingStyle(AntialiasingStyle style);
void BINARYNINJAUIAPI adjustFontForAntialiasingSettings(QFont& font, QWidget* widget);
int BINARYNINJAUIAPI getFontWidthAndAdjustSpacing(QFont& font);
/*!
@}
*/
|