in reply to Re^2: Tk : Entry widget-Strange behaviour with decimals
in thread Tk : Entry widget-Strange behaviour with decimals

Very interesting indeed.
Especially since it seems to be happening primarly with certain combinations of Perl and Tk versions.
Funny to see that my initial suspicion was right, the entry()'d value is somehow converted to an integer.
Concerning you other remark about versions, i looked it up, and i'll just put it ahead of my code from now on, starting each new program with:

# Windows 7/64-bit
# Perl 5.26.1.1 for MSWin32-x64-multithread
# Tk 804.034

So i won't forget to mention those anymore, and it's a good reminder for myself too.
If you have any more remarks or advice on my little program, i'd be glad to hear it.
J.

  • Comment on Re^3: Tk : Entry widget-Strange behaviour with decimals

Replies are listed 'Best First'.
Re^4: Tk : Entry widget-Strange behaviour with decimals
by poj (Abbot) on Jan 07, 2018 at 16:49 UTC
    or advice on my little program, i'd be glad to hear it.

    Since you asked, rather than using a lot of similar variable names like $row0, $row1 ,$row2 etc consider using an array. For example

    my @col = (40,$center-35,$center+30,$breed-40); my @row = (20,40,60,80,90,110);

    a few more changes (mainly style) here

    poj

      Wow!
      You really gave me something to study here.
      I started Perl just 8 days ago, and I did my last programming some 20 years ago.
      I see you are using things that i didn't know existed, or what they really do, like \%.
      Since i already know what my program is suppoded to do, i can now trace the use of those things.
      Your comment does indeed help me on my way, and will probably be keeping me busy for a number of days.
      Thanks.