in reply to Re^3: How to perform a subroutine run in cpan Tk::ExecuteCommand module
in thread How to perform a subroutine run in cpan Tk::ExecuteCommand module

Hi Zentara, I have one extra question regarding the text widget gui, is that possible to change the vertical scrollbar to the right hand side instead of current position on the left sided.

  • Comment on Re^4: How to perform a subroutine run in cpan Tk::ExecuteCommand module

Replies are listed 'Best First'.
Re^5: How to perform a subroutine run in cpan Tk::ExecuteCommand module
by zentara (Cardinal) on Jun 27, 2014 at 10:37 UTC
    You probably will have to dig into the "advertised widgets" of Tk::ExecuteCommand, find the scrolled frame, then issue a configure command to it. -scrollbars => 'osoe'

    This code change does it:

    # read perldoc Tk::ExecuteCommand for the Adverised Widget section my $ROText = $ec->Subwidget('text'); print "$ROText\n"; $ROText->configure(-scrollbars => 'osoe');

    I'm not really a human, but I play one on earth.
    Old Perl Programmer Haiku ................... flash japh
      Thanks Zentara, I changed to 'se' and it works as what I wanted. I read through the Tk::RoText manual but seems don't have the cmd "$ROText->configure(-scrollbars => 'osoe');" you posted, and I never know the configure command can be used for -scrollbar if you never tell. Thanks a lot!
        I never know the configure command can be used for -scrollbar if you never tell.

        It helps to read Mastering Perl/Tk, and always remember Google is your friend when search for code. For example, googling for perl tk text scrollbar position would give you an answer also.


        I'm not really a human, but I play one on earth.
        Old Perl Programmer Haiku ................... flash japh
      Hi Zentara, I tried up vote your answer, not sure if that works at your end. This is my first time voting on PerlMOnks, let me know if that doesn't works. Thank you.