summaryrefslogtreecommitdiffstats
path: root/editor/editor_help.cpp
diff options
context:
space:
mode:
authorYuri Sizov <yuris@humnom.net>2023-03-31 21:17:59 +0200
committerYuri Sizov <yuris@humnom.net>2023-03-31 21:39:02 +0200
commit1522762dc986c130ad63cbf854514d730788a4cf (patch)
tree81cbbbb7028bc95f828d78644b570e506736ece9 /editor/editor_help.cpp
parent9fae65404a223a86816685b0b4036a57b8f976b7 (diff)
downloadredot-engine-1522762dc986c130ad63cbf854514d730788a4cf.tar.gz
Make icons of scripted and custom classes fit the editor UI
Also: - Add an option to limit the icon size in PopupMenu. This is similar to how this works in Tree and TreeItem. - Add the same option to TabBar. - Add a theme constant for Tree, PopupMenu, Button, and TabBar to apply this limit on the control level. Co-authored-by: Daylily-Zeleen <daylily-zeleen@foxmail.com>
Diffstat (limited to 'editor/editor_help.cpp')
-rw-r--r--editor/editor_help.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/editor_help.cpp b/editor/editor_help.cpp
index af35bda47c..61dabb9541 100644
--- a/editor/editor_help.cpp
+++ b/editor/editor_help.cpp
@@ -668,7 +668,7 @@ void EditorHelp::_update_doc() {
String inherits = cd.inherits;
while (!inherits.is_empty()) {
- _add_type_icon(inherits, 0, "ArrowRight");
+ _add_type_icon(inherits, theme_cache.doc_font_size, "ArrowRight");
class_desc->add_text(non_breaking_space); // Otherwise icon borrows hyperlink from _add_type().
_add_type(inherits);
@@ -701,7 +701,7 @@ void EditorHelp::_update_doc() {
if (prev) {
class_desc->add_text(" , ");
}
- _add_type_icon(E.value.name, 0, "ArrowRight");
+ _add_type_icon(E.value.name, theme_cache.doc_font_size, "ArrowRight");
class_desc->add_text(non_breaking_space); // Otherwise icon borrows hyperlink from _add_type().
_add_type(E.value.name);
prev = true;