8000 Fix UIMessageBox title (#2582) · pythonarcade/arcade@2501fcf · GitHub
Skip to content

Commit 2501fcf

Browse files
authored
Fix UIMessageBox title (#2582)
- Add title as argument in docstring - Use the title argument as the title UILabel's text instead of 10437 always setting it to "Message"
1 parent 21fe980 commit 2501fcf

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

arcade/gui/constructs.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ def on_action(event: UIOnActionEvent):
2929
width: Width of the message box
3030
height: Height of the message box
3131
message_text: Text to show as message to the user
32+
title: Title of the message box, displayed on the top
3233
buttons: List of strings, which are shown as buttons
3334
3435
"""
@@ -68,7 +69,7 @@ def __init__(
6869
if title:
6970
title_label = frame.add(
7071
child=UILabel(
71-
text="Message",
72+
text=title,
7273
font_size=16,
7374
size_hint=(1, 0),
7475
align="center",

0 commit comments

Comments
 (0)
0