Discussion:
[ruby-list:49771] TkDND での日本語名の扱い
Umino
2014-03-06 03:50:47 UTC
Permalink
Umino $B$H?=$7$^$9(B

$B<B$O0JA0$K(B OKWave$B$KEj9F$7$?FbMF$G$9$,!"(B
$B2sEzL5$7$G4|***@Z$l$K$J$C$F$7$^$$$^$7$?!#(B

Ruby 2.0.0p353 (2013-11-22) [i386-mingw32]
__ENCODING__ Windows-31J
TkDND 2.6
$B>e5-$N4D6-$K$F(B
TkDND$B$G<u$1<h$k(B,$BF|K\8l%U%!%$%kL>$,J8;z2=$1$7$F$7$^$$$^$9!#(B

$BNc$($P(B
txt = TkText.new(nil){
dnd_bindtarget('text/uri-list','<Drop>','%D'){|d|
p d
insert('end',d[0])
insert('end',"\n")
}
}
txt.pack

$B$H$7$F!"(B
"c:/usr/dev/$B$"(B" $B$H$$$&L>A0$N%U%!%$%k$r%I%m%C%W$9$k$H(B

["C:/usr/dev/\xC3\x83\xC2\xA3\xC3\x82\xC2\x81\xC3\x82\xC2\x82"]
$B$b$A$m$s!"(BTkText$B$G$bJ8;z2=$1$7$F$7$^$$$^$9!#(B

$BAG$N(BTcl/Tk $B$GF1$8$h$&$K9T$C$?>l9g$OJ8;z2=$1$J$/<B9T(B
$B=PMh$k$N$G!"(BRuby$BB&%(%s%3(B-$B%G%#%s%0$N07$$$G2?$H$+$J$kLdBj$+$H$O(B
$B;W$C$F$$$^$9$,!"(Bnkf$B$G(B '-W','-W16' $BEy;n$7$F$bBP1~$G$-$:(B
$B$=$3$+$i9T$-5M$C$F$$$^$9!#(B

$B$I$J$?$+!"JQ49J}K!(B $B$465<xD:$1$J$$$G$7$g$&$+!#(B
$B59$7$/$*4j$$$7$^$9!#(B
Nobuyoshi Nakada
2014-03-06 05:53:08 UTC
Permalink
Post by Umino
"c:/usr/dev/$B$"(B" $B$H$$$&L>A0$N%U%!%$%k$r%I%m%C%W$9$k$H(B
["C:/usr/dev/\xC3\x83\xC2\xA3\xC3\x82\xC2\x81\xC3\x82\xC2\x82"]
$B$b$A$m$s!"(BTkText$B$G$bJ8;z2=$1$7$F$7$^$$$^$9!#(B
$ ruby -e 'p ARGV[0].encode("iso-8859-1", "utf-8").encode("iso-8859-1", "utf-8")' $'\xC3\x83\xC2\xA3\xC3\x82\xC2\x81\xC3\x82\xC2\x82'
"\xE3\x81\x82"

$B$H$$$&$3$H$G!"(BUTF-8$BJ8;zNs$K(BISO-8859-1(Latin-1)$B"*(BUTF-8$B$NJQ49$rFsEY7+$jJV$7$F$$$k$_$?$$$G$9$M!#(B
Umino
2014-03-06 14:56:47 UTC
Permalink
Nakada $B$5$s(B
$BM-Fq$&8f:B$$$^$9!#(B
Post by Nobuyoshi Nakada
$ ruby -e 'p ARGV[0].encode("iso-8859-1", "utf-8").encode("iso-8859-1", "utf-8")' $'\xC3\x83\xC2\xA3\xC3\x82\xC2\x81\xC3\x82\xC2\x82'
"\xE3\x81\x82"
$B$H$$$&$3$H$G!"(BUTF-8$BJ8;zNs$K(BISO-8859-1(Latin-1)$B"*(BUTF-8$B$NJQ49$rFsEY7+$jJV$7$F$$$k$_$?$$$G$9$M!#(B
u8str = d[0].encode("iso-8859-1","utf-8").encode("iso-8859-1","utf-8")
$B8e$O(B
u8str.encode('cp932','utf-8') $B$b$7$/$O(B NKF.nkf('-Ws', u8str)
$B$G8+;v$KF|K\8l%Q%9$rI=<(=PMh$^$7$?!#(B

$BJ8;z%3!<%I$K4X$7$F>e<j$/@0M}=PMh$F$*$i$:!"$b$C$Q$i(BNKF$B$@$h$j$G$7$?$N$G(B
$BJ#?t2s$NJQ49$,$5$l$F$$$k$J$IA[A|$b=PMh$^$;$s$G$7$?!#(B
#$B2?8N!"(B2$B2sJQ49$,9T$o$l$k$N$+$OJ,$+$j$^$;$s$,!&!&!&!&(B

$BK\Ev$K=u$+$j$^$7$?!#(B
Hidetoshi NAGAI
2014-03-07 01:20:50 UTC
Permalink
$B1J0f(B@$BCNG=!%6e9)Bg$G$9!%(B

From: Umino <jam280400-/E1597aS9LR3+***@public.gmane.org>
Subject: [ruby-list:49775] Re: TkDND $B$G$NF|K\8lL>$N07$$(B
Date: Thu, 6 Mar 2014 23:56:47 +0900 (JST)
Post by Umino
$BJ#?t2s$NJQ49$,$5$l$F$$$k$J$IA[A|$b=PMh$^$;$s$G$7$?!#(B
#$B2?8N!"(B2$B2sJQ49$,9T$o$l$k$N$+$OJ,$+$j$^$;$s$,!&!&!&!&(B
$B$4$a$s$J$5$$!%(BRuby/Tk $B$N%P%0$G$7$g$&$M!%(B

# $B2DG=$G$"$l$P!$(BOKWave $B$H$+$G$O$J$/!$(Bruby-list ML $B$d(B ruby-dev ML $B$H$+$G(B
# $BLd$$9g$o$;$dJs9p$r$7$F$$$?$@$1$^$9$H=u$+$j$^$9!%(B

Ruby 1.9 $B0J9_$O(B Ruby $B>e$N(B encoding $B$H(B Tcl/Tk $B>e$N(B encoding $B$H$N(B
$B#2$D$N(B encoding $B$r07$o$M$P$J$i$J$/$J$C$?$?$a!$(B
$BH=CG$d=hM}$r8m$k$H$3$&$7$?2a>jJQ49$J$I$,@8$8$F$7$^$$$^$9!%(B
$BBg6Z$G$OLdBj$,=P$J$$$h$&$K$7$F$$$k$D$b$j$G$9$,!$(B
($BFC$K(B I/O $BMm$_$NItJ,$G$O(B) $B=hM}8m$j$,$^$@;D$C$F$$$?$h$&$G$9!%(B
$B%P%0=$@5$O$-$A$s$H$9$k$D$b$j$G$9$,!$(B
$BL\A0$O1~5^=hCV$GBP1~$7$F$*$$$F$$$?$@$1$^$9$H9,$$$G$9!%(B

$B$h$m$7$/$*4j$$CW$7$^$9!%(B
--
$B1J0f(B $B=(Mx(B (nagai-iKxUiVHJP4pSXnIrXG/***@public.gmane.org)
$B6e=#9)6HBg3XBg3X1!>pJs9)3X8&5f1!CNG=>pJs9)3X8&5f7OCNG=>pJs%a%G%#%"ItLg=u65(B
Umino
2014-03-08 02:28:54 UTC
Permalink
$B1J0fMM(B
$BM-Fq$&8f:B$$$^$9!#(B

$B$$$/$D$+$N(B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$+(B or $B$9$Y$-$+$rCN$C$F$$$k$N$O%W%m%0%i%^$G$"$k$3$H(B
$B$H$$$&$h$&$J$3$H$+$i!$<u$1<h$C$?$^$^$K0z$-EO$9$N$,$$$$$@$m$&$H$$$&H=CG$G$9!%(B

$BDL>o$O(B encoding $B$***@_Dj$5$l$F$$$J$$(B (ASCII-8BIT $B$K$J$C$F$$$k(B) $B$N$G!$(B
force_encoding $B$r$+$1$?$j!$(BTkComm.simplelist $B$G%j%9%H$H$7$FJ,2r$7$?$j$O!$(B
$B%W%m%0%i%^$,I,MW$K1~$8$F9T$&$H$$$&$N$,0lHV3N<B$@$H;W$$$^$9!%(B

$B$H$$$&$o$1$G!$0J2<$N%Q%C%A$N$h$&$JJQ99$G$O$$$+$,$G$7$g$&$+!%(B

======================================================================
--- tkdnd.rb.orig 2013-11-27 06:19:58.369532997 +0900
+++ tkdnd.rb 2014-10-25 00:19:07.151774217 +0900
@@ -11,7 +11,7 @@
# call setup script
require 'tkextlib/tkDND/setup.rb'

-TkPackage.require('tkdnd')
+TkPackage.require('tkdnd', '1.0')

module Tk
module TkDND
@@ -35,7 +35,7 @@
[ ?b, ?L, :codes ],
[ ?c, ?s, :code ],
[ ?d, ?l, :descriptions ],
- [ ?D, ?l, :data ],
+ [ ?D, ?s, :data ],
[ ?L, ?l, :source_types ],
[ ?m, ?l, :modifiers ],
[ ?t, ?l, :types ],
@@ -158,7 +158,7 @@
cmd = Proc.new
end

- args = [None] if args.empty
+ args = [TkComm::None] if args.empty?

tk_call('dnd', 'bindsource', @path, type, cmd, *args)
self
======================================================================

From: Hidetoshi NAGAI <***@ai.kyutech.ac.jp>
Subject: [ruby-list:49776] Re: TkDND $B$G$NF|K\8lL>$N07$$(B
Date: Fri, 07 Mar 2014 10:20:50 +0900 (JST)
Post by Hidetoshi NAGAI
Subject: [ruby-list:49775] Re: TkDND $B$G$NF|K\8lL>$N07$$(B
Date: Thu, 6 Mar 2014 23:56:47 +0900 (JST)
Post by Umino
$BJ#?t2s$NJQ49$,$5$l$F$$$k$J$IA[A|$b=PMh$^$;$s$G$7$?!#(B
#$B2?8N!"(B2$B2sJQ49$,9T$o$l$k$N$+$OJ,$+$j$^$;$s$,!&!&!&!&(B
$B$4$a$s$J$5$$!%(BRuby/Tk $B$N%P%0$G$7$g$&$M!%(B
# $B2DG=$G$"$l$P!$(BOKWave $B$H$+$G$O$J$/!$(Bruby-list ML $B$d(B ruby-dev ML $B$H$+$G(B
Ruby 1.9 $B0J9_$O(B Ruby $B>e$N(B encoding $B$H(B Tcl/Tk $B>e$N(B encoding $B$H$N(B
$B#2$D$N(B encoding $B$r07$o$M$P$J$i$J$/$J$C$?$?$a!$(B
$BBg6Z$G$OLdBj$,=P$J$$$h$&$K$7$F$$$k$D$b$j$G$9$,!$(B
$B$h$m$7$/$*4j$$CW$7$^$9!%(B
--
$B1J0f(B $B=(Mx(B (***@ai.kyutech.ac.jp)
$B6e=#9)6HBg3XBg3X1!>pJs9)3X8&5f1!CNG=>pJs9)3X8&5f7OCNG=>pJs%a%G%#%"ItLg=u65(B
Loading...