MsgBox(3pm)
π¬ NAME π¬
okay bestie, gather round, because this is Tk::MsgBox β she creates and manipulates a message dialog. that's it, that's the whole job, and she does it flawlessly π
β¨ SYNOPSIS β¨
use Tk::MsgBox
...
$d = $top->MsgBox(-title => "Title", -type => "okcancel");
...
$button = $d->Show;
likeβ¦ look at her. three lines and a dream π«Ά
π DESCRIPTION π
MsgBox is a simple dialog with predefined buttons. no cap, that's literally the entire concept β she pops up, she's cute, she has buttons you already chose from a list. main character energy in a popup window π¦
πΈ OPTIONS πΈ
here are all the options MsgBox recognizes, and yes we're going through every single one because that's what she deserves:
-iconβ pick the icon for yourMsgBox. valid values areerror,info,question, orwarning. choose wisely, it's giving vibe check π-typeβ sets the type of theMsgBox. valid values areabortretryignore,ok,okcancel,retrycancel,yesno, oryesnocancel. this is the one that decides which buttons show up, so it's highkey important π₯-defaultβ the default button, aka the one that gets the spotlight. this has to be one ofabort,retry,ignore,ok,cancel,yes, ornoβ and which ones are even allowed depends on the-typeyou picked earlier. no mixing and matching, bestie π-detailβ the text for the detail region of theMsgBox.-messageβ the message text of theMsgBox. this is the moment she speaks β¨-titleβ the title of theMsgBox. her name tag, basically π
π METHODS π
MsgBox supports only one method as of now β one method, zero filler, iconic behavior:
Show()
Displays the MsgBox until the user invokes one of the buttons. Returns the name of the button invoked. so you call her, she shows up, the user clicks something, and she hands you back the button name like a little gift π
π AUTHOR π
Translated from Tcl/Tk by Slaven Rezic srezic@cpan.org
This code is distributed under the same terms as Perl.
π SEE ALSO π
Tk::messageBox, Tk::DialogBox, Tk::Dialog.
that's the whole page bestie, go forth and pop up dialogs responsibly π this was MsgBox from the perl v5.40.1 docs, dated 2025-04-13, filed under User Contributed Perl Documentation β and yes she ate, periodt π
πΈ
π¦ where this page comes from
- debian trixie: perl-tk 1:804.036+dfsg1-5
- ubuntu questing: perl-tk 1:804.036+dfsg1-5
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms