Is there a way to draw a line over a label? Mine keeps disappearing. I cannot seem to get the DC lines thing to work, even without a label...

Steve

<code>
use strict;
use Win32::GUI;
our $mw = Win32::GUI::Window->new(
   -name        => "MainWindow",
   -title      => "Line Layer Test",
   -size       => [400,400],
   -resizable  => 0,
   -maximizebox => 0,
   );
# my $font=Win32::GUI::Font->new(
#     -name   => 'Arial',
#     -width => 40,
#     -height => 60,
#     -bold => 1
#     );
#$mw->AddLabel(-pos => [60,100],-text => "HELLO",-font => $font);

my $DC = $mw->GetDC();
my $P = Win32::GUI::Pen->new(
   -color => [ 0,0,0 ],
   -width => 3,
   );
my $oldP = $DC->SelectObject($P);
$DC->BeginPath();
$DC->MoveTo(50, 100);
$DC->LineTo(200, 100);
$DC->EndPath();
$DC->StrokePath();
$DC->SelectObject($oldP);
$mw->Show();
Win32::GUI::Dialog();
exit;
</code>


Reply via email to