/usr/share/freepwing/fpwfullchar is in freepwing 1.5-1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 | #! /usr/bin/perl
# -*- Perl -*-
# Copyright (c) 2000 Motoyuki Kasahara
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
require 5.005;
use English;
use FreePWING::FullUserChar;
use FreePWING::FPWUtils::FPWUtils;
use Getopt::Long;
#
# ¥³¥Þ¥ó¥É¹Ô¤ò²òÀϤ¹¤ë¡£
#
if (!GetOptions('workdir=s' => \$work_directory)) {
exit 1;
}
#
# fpwutils ¤ò½é´ü²½¤¹¤ë¡£
#
initialize_fpwutils();
#
# ¤³¤ì¤«¤é½ÐÎϤ¹¤ë¥Õ¥¡¥¤¥ë¤¬¤¹¤Ç¤Ë¤¢¤ì¤Ð¡¢ºï½ü¤¹¤ë¡£
#
unlink($full_char_name_file_name);
unlink($full_char_bitmap_16_file_name);
unlink($full_char_bitmap_24_file_name);
unlink($full_char_bitmap_30_file_name);
unlink($full_char_bitmap_48_file_name);
$full = FreePWING::FullUserChar->new();
foreach $file_name (@ARGV) {
#
# ³°»ú¤ÎÄêµÁ¥Õ¥¡¥¤¥ë¤ò³«¤¯¡£
#
$handle = FileHandle->new();
if (!$handle->open($file_name, 'r')) {
die "$PROGRAM_NAME: failed to open the file, $ERRNO: $file_name\n";
}
for (;;) {
#
# °ì¹ÔÆɤ߹þ¤à¡£
#
$line = $handle->getline();
if (!defined($line)) {
last;
}
$line =~ s/\r?\n?$//;
#
# ¶õ¹Ô¤È¥³¥á¥ó¥È¹Ô (`#' ¤¬ÀèƬ¤ËÍè¤Æ¤¤¤ë¹Ô) ¤Ï̵»ë¤¹¤ë¡£
#
next if ($line =~ /^\#/ || $line =~ /^$/);
#
# Æɤ߹þ¤ó¤À¹Ô¤ò°ú¿ô¤Ëʬ²ò¤¹¤ë¡£
# ºÇÄã 2 ¸Ä (̾Á°¤È 16¥É¥Ã¤È³°»ú) ¤Ê¤¤¤È¥¨¥é¡¼¡£
#
@line_arguments = split(/[ \t]+/, $line);
if (@line_arguments <= 1) {
die "$PROGRAM_NAME: malformed line, at line $NR in $file_name\n";
}
#
# ºÇ½é¤Î³°»ú¥¨¥ó¥È¥ê¤¬Í褿»þÅÀ¤Ç¡¢³°»ú¤ÎÀ¸À®Â¦¥Õ¥¡¥¤¥ë¤ò³«¤¯¡£
#
if ($full->character_count() == 0) {
#
# À¸À®Â¦¥Õ¥¡¥¤¥ë¤ò³«¤¯¡£
#
@full_char_bitmap_file_names = ();
push(@full_char_bitmap_file_names, $full_char_bitmap_16_file_name)
if (2 <= @line_arguments);
push(@full_char_bitmap_file_names, $full_char_bitmap_24_file_name)
if (3 <= @line_arguments);
push(@full_char_bitmap_file_names, $full_char_bitmap_30_file_name)
if (4 <= @line_arguments);
push(@full_char_bitmap_file_names, $full_char_bitmap_48_file_name)
if (5 <= @line_arguments);
if (!$full->open($full_char_name_file_name,
@full_char_bitmap_file_names)) {
die "$PROGRAM_NAME: " . $full->error_message() . "\n";
}
}
#
# Æɤ߹þ¤ó¤À¹Ô¤Ëµ¤µ¤ì¤¿³°»ú¤òÄɲ乤롣
#
if (!$full->add_character(@line_arguments)) {
die "$PROGRAM_NAME: " . $full->error_message() . "\n";
}
}
#
# ³°»ú¤ÎÄêµÁ¤òµ½Ò¤·¤¿¥Õ¥¡¥¤¥ë¤ò³«¤¯¡£
#
$handle->close();
}
#
# ³°»ú¤ÎÀ¸À®Â¦¥Õ¥¡¥¤¥ë¤òÊĤ¸¤ë¡£
#
if (!$full->close()) {
die "$PROGRAM_NAME: " . $full->error_message() . "\n";
}
#
# fpwutils ¤Î¸å»ÏËö¤ò¤¹¤ë¡£
#
finalize_fpwutils();
exit 0;
|