Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qandroidplatformmenuitem.h
Go to the documentation of this file.
1// Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QANDROIDPLATFORMMENUITEM_H
5#define QANDROIDPLATFORMMENUITEM_H
6#include <qpa/qplatformmenu.h>
7
9
11
13{
14public:
16
17 void setText(const QString &text) override;
18 QString text() const;
19
20 void setIcon(const QIcon &icon) override;
21 QIcon icon() const;
22
23 void setMenu(QPlatformMenu *menu) override;
25
26 void setVisible(bool isVisible) override;
27 bool isVisible() const;
28
29 void setIsSeparator(bool isSeparator) override;
30 bool isSeparator() const;
31
32 void setFont(const QFont &font) override;
33
34 void setRole(MenuRole role) override;
35 MenuRole role() const;
36
37 void setCheckable(bool checkable) override;
38 bool isCheckable() const;
39
40 void setChecked(bool isChecked) override;
41 bool isChecked() const;
42
43 void setShortcut(const QKeySequence &shortcut) override;
44
45 void setEnabled(bool enabled) override;
46 bool isEnabled() const;
47
48 void setIconSize(int size) override;
49
50private:
51 QString m_text;
52 QIcon m_icon;
54 bool m_isVisible;
55 bool m_isSeparator;
56 MenuRole m_role;
57 bool m_isCheckable;
58 bool m_isChecked;
59 bool m_isEnabled;
60};
61
63
64#endif // QANDROIDPLATFORMMENUITEM_H
void setIsSeparator(bool isSeparator) override
void setShortcut(const QKeySequence &shortcut) override
void setIcon(const QIcon &icon) override
void setRole(MenuRole role) override
void setEnabled(bool enabled) override
void setFont(const QFont &font) override
QAndroidPlatformMenu * menu() const
void setCheckable(bool checkable) override
void setText(const QString &text) override
void setMenu(QPlatformMenu *menu) override
void setChecked(bool isChecked) override
void setIconSize(int size) override
void setVisible(bool isVisible) override
\reentrant
Definition qfont.h:22
The QIcon class provides scalable icons in different modes and states.
Definition qicon.h:20
The QKeySequence class encapsulates a key sequence as used by shortcuts.
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:129
Combined button and popup list for selecting options.
GLenum GLuint GLintptr GLsizeiptr size
[1]
GLenum GLenum GLsizei const GLuint GLboolean enabled