| Server IP : 170.10.161.225 / Your IP : 216.73.216.78 Web Server : Apache System : Linux vps103298.mylogin.co 4.18.0-513.11.1.el8_9.x86_64 #1 SMP Wed Jan 17 02:00:40 EST 2024 x86_64 User : calvet ( 273824) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : ON Directory : /lib64/perl5/vendor_perl/Prima/examples/ |
Upload File : |
=pod
=head1 NAME
examples/ps_setup.pl - A prima PostScript printer output setup program.
=head1 FEATURES
Prints a PS document after setup dialog is finished.
Whereas Prima::PS modules can be used on any platform,
they serve as an only remedy on *nix systems when printing
via Prima is desired. The Prima::PS interface can load user
preferences from $HOME/.prima/printer file. This file is
maintained by the PostScript output setup dialog.
=cut
use strict;
use warnings;
use Prima;
use Prima::PS::Printer;
use Prima::Application;
use Prima::StdBitmap;
if (!@ARGV || $ARGV[0] !~ /^\-(ps|pdf)$/) {
print "Please run with either -ps or -pdf\n";
exit(1);
}
$::application-> icon( Prima::StdBitmap::icon(0));
my $class = ($ARGV[0] eq '-ps') ?
'Prima::PS::Printer' :
'Prima::PS::PDF::Printer';
my $x = $class-> new;
$x-> setup_dialog;
$x-> begin_doc;
$x-> color(cl::Green);
$x-> text_out( "hello!", 100, 100);
$x-> end_doc;
1;