Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: perl TK Gui rendering in windows remote desktop

by XiaoShizihou (Initiate)
on Oct 18, 2012 at 19:46 UTC ( #999807=note: print w/ replies, xml ) Need Help??


in reply to perl TK Gui rendering in windows remote desktop

this is seen on Win7 and WinXP. If the GUI is started locally, then mstsc does not render the GUI completely. If the GUI is started via mstsc, then locally the GUI is not rendered.

#!/usr/local/bin/perl -w #use 5.10.0; use Tk; use strict; use warnings; use Tk::NoteBook; use Data::Dumper; # -------------------------------------------------------------------- +---------- #<+MAIN part of the program +> # -------------------------------------------------------------------- +---------- my $mw = MainWindow->new; $mw->title('MSTSC test $Rev:$'); $mw->bind( '<Key-F5>', sub { $mw->update; } ); $mw->bind( '<Escape>', sub { exit; } ); $mw->bind( '<Alt-x>', sub { exit;} ); $mw->bind( '<Alt-X>', sub { exit;} ); my $menubar = $mw->Frame()->pack( -side => 'top', -anchor => 'w', ); $menubar->Button( -text => "Exit", -command => sub { exit; } )->pack( +-side => 'right' ); $menubar->Button( -text => "Exit", -command => sub { exit; } )->pack( +-side => 'right' ); $menubar->Button( -text => "Exit", -command => sub { exit; } )->pack( +-side => 'right' ); $menubar->Button( -text => "Exit", -command => sub { exit; } )->pack( +-side => 'right' ); my $npage = $mw->NoteBook(); #->pack; # create the Main window to hold start/status buttons my $start_page = $npage->add( 'start', -label => "Start", ); my %widget_obj; my $label = "ZZ"; $widget_obj{output_tab_wid} = $npage->add( $label, -label => "$label", + ); $widget_obj{output_tab_wid}->Label( -text => "Input Window" )->pack( - +side => 'top', -anchor => 'n' ); $widget_obj{intext_wid} = $widget_obj{output_tab_wid}->Scrolled("Text" +)->pack( -side => 'top', -fill => 'both', -expand => 1, ); my $drive_frame = $start_page->Frame( -relief => 'groove', -borderwidth => 2, -label => "Special Button" )->pack( -side => 'left', -fill => 'y' ); $start_page->pack(-anchor => 'n' , -side => 'left', ); $widget_obj{'button_wid'} = $drive_frame->Button( -state => 'disabled', -text => $label, -relief => 'flat', -borderwidth => 4, -width => 15, -height => 15, -highlightthickness => 0, )->pack( -anchor => 'w' , -side => 'left', ); $npage->pack(); $mw->update; # $mw->focusmodel("active"); MainLoop; exit 0;


Comment on Re: perl TK Gui rendering in windows remote desktop
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://999807]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (8)
As of 2014-07-12 20:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (241 votes), past polls