[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

[MacPerl] Some lines of code --or a GUI-Module for non-GUI purpose



Just wanted to share some code with all of you.
This little script tells you which fonts are installed
in your system folder. (It is a 'clone' of the Technote 
"TE04 - Font Names" code, where you can read more about
it)

Andreas Marcel


#!perl -w
use Mac::Menus;

$fontmenu = NewMenu (200, "xyz"); 
AppendResMenu ($fontmenu,'FONT');
$items = CountMItems ($fontmenu)	;

for ($i=1; $i<=$items; $i++){
 push (@fonts,GetMenuItemText ($fontmenu, $i));
}
DisposeMenu ($fontmenu);

print "@fonts\n";
#-----------------------------




***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch