in reply to Tk Entry & Right Single Quote

You're using a non-ASCII character in the code. You should tell Perl about the encoding:
use utf8;

Also, you're printing the character to STDERR. Either set the binmode of STDERR to understand UTF-8, or encode the character.

binmode STDERR, ':encoding(UTF-8)'; # or use Encode qw{ encode }; say STDERR encode('UTF-8', "Messaging: $msg");

If you're on MSWin (guessing from words like Outlook and Notepad), you might need to switch the terminal's codepage to UTF-8. I don't have such a machine handy, so you'll have to Google that yourself.

map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]

Replies are listed 'Best First'.
Re^2: Tk Entry & Right Single Quote
by Marshall (Canon) on Apr 13, 2024 at 02:09 UTC
    I did test on my Win10 machine, here is how to change the code page in a command window:
    C:...Documents\PerlProjects\Monks>chcp 65001 Active code page: 65001
    With that and the above suggestions, and making sure my editor saved the program text as UTF-8 instead of ASCII, I got the correct display from STDERR in the command window. I did not get the message box to display properly from the program variable but did get cut-n-paste Chinese characters into the Tk window to show up correctly in the message box.
Re^2: Tk Entry & Right Single Quote
by cmv (Chaplain) on Apr 13, 2024 at 22:39 UTC
    ++choroba

    You hit it on the head. The use utf8; did the trick, and everything worked as expected.

    I am running on MacOSX, so the terminal output was correct for me, but now I know how to fix that when needed.

    I clearly need to learn more about Perl's Unicode handling.

    Many thanks!