Questions tagged [perltk]

Perl's Tk module provides a complete interface to Tk, a GUI toolkit, while providing an object oriented interface to Perl code.

Tk is a graphical user interface toolkit for Perl.

95 questions
0
votes
2 answers

How do I clear a Frame's value in Perl/Tk?

In Perl/Tk I have designed one interface in that I have one frame. That frame has an Entry and Text box. When I am clicking the button those Entry and Text value has to clear in the Frame. I know that I can access each object then I can clear…
Pavunkumar
  • 5,147
  • 14
  • 43
  • 69
0
votes
2 answers

Unable to print arguments in perl tk callback

When submit button is clicked, a callback function should be called. printing all arguments passed during callback doesn't work. But it enters callback function. How can I access passed variables so that I can insert into table. sub registerStu { …
Sam
  • 335
  • 1
  • 6
  • 13
0
votes
1 answer

How to do map path to completion in Perl/Tk

The linux system in my server comes with Perl v5.14.1, and it seems like this version of Perl do not support Tk-PathEntry widget (pls refer to : https://code.activestate.com/ppm/Tk-PathEntry/). May I know is there any alternate way that I can do so…
Grace
  • 440
  • 3
  • 6
  • 21
0
votes
1 answer

How do I clear the text within an entry or text widget when I mouse click on that entry/text in Perl/Tk

Can someone shed some lights on with my problem as title? I have both text and entry widgets within the form I created, but somehow I wish if I could do something such as for some of the text and entry widgets, I'll place the "" wording in it and…
Grace
  • 440
  • 3
  • 6
  • 21
0
votes
1 answer

perl how to print to a perl/tk listbox

how to i send print output to a perl/tk list box, there can be unlimited lines of print. i know how to create the list box but don't now how to call the listbox and print to it. this is the code that produces the print line by line. [code] …
user3360439
  • 359
  • 1
  • 4
  • 13
0
votes
1 answer

Multi Line input using Perl/Tk

I was trying GUI in Perl using Perl/Tk. I couldn't find a way to take multi line text input from the user using any widget. For single line "Entry" can be used but I could find nothing for multi line input. Is there any way?
chappa
  • 95
  • 1
  • 2
  • 12
0
votes
2 answers

Checkbutton in perl Tk is selecting all options

I'm creating a list of checkbuttons in perl tk using a loop. $i=1; $n=5; @x=1; while($i <= $n){ $mw->Checkbutton(->text=>$i,-variable=>\$ckval,->command=>sub{ if($ckval){print $i} })->pack; $i=$i+@x; …
g3nair
  • 137
  • 5
0
votes
1 answer

Line number and column number in Text Widget

Is there some method which tells you the line number and column number of a Text widget in Perl/Tk?
Liam Willis
  • 661
  • 6
  • 17
0
votes
1 answer

Deselect text programmatically

I am using a Text widget. I have over-ridden the right click to display a popup menu in my Perl/Tk GUI. But whenever I right click at any position, the text from the earlier cursor location till the location where I have right clicked gets…
Liam Willis
  • 661
  • 6
  • 17
0
votes
2 answers

Multiple undo/redo in Scrolled widged

I know that I can implement multiple undo using the TextUndo widget. But that doesn't do the redo function. How can I implement both multiple undo and multiple redo?
Liam Willis
  • 661
  • 6
  • 17
0
votes
1 answer

Check if Text widget has been modified

I have a Button and a Text Widget. When a user click the Button, I want to know if the text in the Text Widget has been modified since the last time the user clicked the Button. How do I check this?
Liam Willis
  • 661
  • 6
  • 17
0
votes
3 answers

Stop after first find within two knowns, print, then continue searching file in perl

I am writing in Perl and would like assistance. I am trying to write a program to find "Bobby" and print the line of text with "display". I have already written the program and have it working except one little flaw. If "Bobby" is present multiple…
Spartakus
  • 69
  • 1
  • 10
0
votes
1 answer

Perl tk - tab between entry widgets

I have a very simple GUI which interacts with postgresql database. The mainframe is split into 4 quadrants with each quadrant having 4 Entry Widgets. Here is an example code of one quadrant my $f_blue = $bottom_half->Frame(-bg=>'BLUE')->…
moadeep
  • 3,988
  • 10
  • 45
  • 72
0
votes
1 answer

Reading a unix command output with Perl

I need to run a command with variables inside of the command. I need to capture the output and save it in either one line varible or an array, it doesn't matter. It's going to be pasted into a textbox in Tk anyways. I've tried: my @array =…
Jesse Hernandez
  • 307
  • 2
  • 15
0
votes
1 answer

Perl Tk error "Invalid value for shared scalar"

I got problem with scalars in my program. I got code like this: use threads; use threads::shared; use Tk; $mw = new MainWindow; my $label = undef; share($label) my $ok = undef; share($ok) HERE IS BUTTON WITH OPTION -command =>…
Kamil Hajduk
  • 51
  • 1
  • 6