home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.madoka.org
/
2014.12.ftp.madoka.org.tar
/
ftp.madoka.org
/
pub
/
plum
/
2.x
/
plum2_32_1.lzh
/
module
/
client
/
kanji.plm
Wrap
Text File
|
1999-02-20
|
2KB
|
96 lines
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"><!-- $_ if 0; # -*- perl -*-
# $Id: kanji.plm,v 2.5 1998/12/20 02:28:21 hasegawa Exp $
# copyright (c)1997-1998 Yoshinori Hasegawa <hasegawa@madoka.org>
package client_kanji;
$_ = 'client_kanji';
sub client_read {
local($clientno, $line) = @_;
foreach $kanji (&'property($'userno[$clientno], 'input')) {
foreach $code (split(/\,/, "\L$kanji\E")) {
if ($code eq 'euc') {
$line = &'euc_jis($line);
} elsif ($code eq 'jis') {
$line = &'jis_jis($line);
} elsif ($code eq 'sjis') {
$line = &'sjis_jis($line);
}
}
}
return $line;
}
sub client_write {
local($clientno, $line) = @_;
local($kanji, $code);
$kanji = &'property($'userno[$clientno], 'output');
if ($kanji) {
$code = (split(/\,/, "\L$kanji\E"))[0];
if ($kanji eq 'euc') {
$line = &'jis_euc($line);
} elsif ($kanji eq 'jis') {
$line = &'jis_jis($line);
} elsif ($kanji eq 'sjis') {
$line = &'jis_sjis($line);
}
}
return $line;
}
__END__
--><HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-2022-JP">
<LINK REV="made" HREF="mailto:hasegawa@madoka.org">
<TITLE>client/kanji.plm</TITLE></HEAD><BODY>
$B%*%s%i%$%s%I%-%e%a%s%H(B
<HR><H3>$BL>A0(B</H3>
client/kanji.plm - $B%/%i%$%"%s%H$H$NF~=PNO$G4A;z%3!<%I$rJQ49$9$k(B
<HR><H3>$B@bL@(B</H3>
$B%/%i%$%"%s%H$+$i(Bjis$B0J30$GF~NO$5$l$?4A;z%3!<%I$r(Bjis$B$KJQ49$7$^$9!#(B
$B$^$?%/%i%$%"%s%H$KBP$7$F=PNO$9$k4A;z%3!<%I$r;XDj$7$?$b$N$K$7$^$9!#(B
<HR><H3>$B%W%m%Q%F%#(B</H3>
<DL>
<DT> client.kanji.input* ({jis|euc|sjis})
</DT>
<DD> $B%/%i%$%"%s%H$+$i$NF~NO$,;XDj$7$?4A;z%3!<%I$N$b$N$G$"$l$P!"(B
$B$=$l$r(Bjis$B$KJQ49$7$^$9!#(Beuc$B$H(Bsjis$B$OF1;~$K;XDj$G$-$^$;$s!#(B
</DD>
<DT> client.kanji.output {jis|euc|sjis}
</DT>
<DD> $B%/%i%$%"%s%H$K=PNO$9$k4A;z%3!<%I$r;XDj$7$?$b$N$K$7$^$9!#(B
</DD>
</DL>
<HR><H3>$B@_DjNc(B</H3>
<PRE>
+ client/kanji.plm
client.kanji.input: euc
</PRE>
$B%/%i%$%"%s%H$+$i$NF~NO$,(Beuc$B$@$C$?$H$-$K!"$=$l$r(Bjis$B$KJQ49$7$^$9!#(B
<PRE>
+ client/kanji.plm
client.kanji.input: sjis,jis
client.kanji.output: sjis
</PRE>
$B%/%i%$%"%s%H$+$i$NF~NO$,(Bsjis$B$@$C$?$H$-$K!"$=$l$r(Bjis$B$KJQ49$7$^$9!#(B
$B$^$?%/%i%$%"%s%H$KBP$9$k=PNO$r(Bsjis$B$K$7$^$9!#(B
</BODY></HTML>