summaryrefslogtreecommitdiffstats
path: root/ext/tk
Commit message (Collapse)AuthorAgeFilesLines
* * ext/tk/lib/tk.rb: use Encoding.find("locale") instaed ofnagai2009-01-121-2/+3
| | | | | | | Encoding.locale_charmap git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@21472 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb: rescue abnormal Encoding.locale_charmap value.nagai2009-01-091-2/+2
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@21406 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c: fix wrong flag value.nagai2008-12-221-3/+4
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20913 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb: temporary patch for trouble on TkAqua (> Tk8.4.9).nagai2008-12-212-35/+48
| | | | | | | | * ext/tk/sample/demos-jp/widget: set encoding to a demo-code string to avoid garbled text on the Code Window. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20903 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk/menu.rb: TkOptionMenubutton.new fails to treat nagai2008-12-031-2/+2
| | | | | | | 'parent' and 'variable' options on a Hash argument. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20476 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb: bug fix. use ::RubyVM instead of ::VM [ruby-list:45676]nagai2008-12-032-3/+3
| | | | | | | * ext/tk/tcltklib.c: update RELEASE_DATE git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20475 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c (ip_ruby_cmd, ip_invoke_with_position): mustnobu2008-12-031-11/+9
| | | | | | | not access internal union directly. [ruby-list:45670] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20460 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/blt/tabset.rb, ext/tk/lib/tkextlib/blt/tabnotebook.rb: nagai2008-11-244-18/+183
| | | | | | | | fix many bugs. Now, those work properly. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20349 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/version.rb, ext/tk/ChangeLog.tkextlib: update.nagai2008-11-222-1/+6
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20303 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/blt.rb, ext/tk/lib/tkextlib/blt/vector.rb: nagai2008-11-222-8/+8
| | | | | | | fix NameError bug. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@20299 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb: support Encoding.default_internal.nagai2008-10-195-66/+147
| | | | | | | | * ext/tk/tcltklib.c: ditto. * ext/tk/extconf.rb: improve the strategy for searching Tcl/Tk headers. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@19852 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * include/ruby/ruby.h: embeds the elements of an array into itsyugui2008-10-091-6/+3
| | | | | | | | | | | | | | | | | | struct RArray for # of elements <= 3. * array.c: ditto. * gc.c (gc_mark_children): following the change of struct RArray. * ext/tk/tcltklib.c (ip_ruby_cmp): ditto. * parse.y (coverage): ditto. * proc.c (curry): ditto. * .gdbinit: ditto. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@19723 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * dln.c: Ruby no longer supports Windows CE.yugui2008-10-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * eval.c: ditto. * include/ruby/defines.h: ditto. * include/ruby/win32.h: ditto. * ruby.c: ditto. * strftime.c: ditto. * win32/Makefile.sub: ditto. * win32/win32.c: ditto. * ext/tk/extconf.rb: ditto. * lib/fileutils.rb: ditto. * test/fileutils/test_fileutils.rb: ditto. * wince/*: removed. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@19681 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * dln.c: Ruby no longer supports MacOS 9 or before.yugui2008-10-042-40/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * eval.c: ditto. * eval_intern.h: ditto. * ext/extmk.rb: ditto. * ext/tk/sample/tkextlib/treectrl/demo.rb: ditto. * ext/tk/stubs.c: ditto. * file.c: ditto. * hash.c: ditto. * include/ruby/defines.h: ditto. * ruby.c: ditto. * signal.c: ditto. * vm_core.h: ditto. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@19680 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * thread.c (rb_thread_check_trap_pending): added for compatibility.ko12008-09-042-75/+36
| | | | | | | | | * ext/tk/tcltklib.c, ext/tk/tkutil/tkutil.c: remove ruby/signal.h dependency. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@19128 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/{stubs,tcltklib}.c, ext/tk/tkutil/tkutil.c: fix warningsnobu2008-07-234-44/+49
| | | | | | | about constness and signedness. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@18188 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/{,tkutil/}extconf.rb: ruby/ruby.h no longer needs to benobu2008-07-154-9/+8
| | | | | | | | | checked. * ext/tk/{tcltklib.c,tkutil/tkutil.c}: check macros for each headers. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@18079 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/extconf.rb, ext/tk/tcltklib.c, ext/tk/tkutil/tkutil.c: Doknu2008-07-153-5/+3
| | | | | | | | | not test ruby/ruby.h, which makes OS X's gcc pick the wrong header file from Ruby.framework. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@18076 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/tile/treeview.rb: cannot configure tags.nagai2008-06-191-9/+10
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17423 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/multi-tk.rb: cannot access class variable from singleton method.nagai2008-06-171-3/+4
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17389 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/sample/demos-jp/toolber.rb, ext/tk/sample/demos-en/toolber.rb:nagai2008-06-162-2/+2
| | | | | | | fail to back a tear-off marker when reattach the toolbar. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17369 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c: SEGV when exit.nagai2008-06-163-9/+23
| | | | | | | | | * ext/tk/lib/tk.rb: add a check for safety to Tk.exit. * ext/tk/sample/irbtkw.rbw: freezes when receives SIGINT. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17368 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c: [trial patch] On some environments, it givesnagai2008-06-123-6/+12
| | | | | | | | better responce about callbacks across threads. But on the other environments, it has no effect. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17115 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk: check proper conditions. [ruby-dev:35047]nobu2008-06-115-283/+104
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17099 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c: SEGV when tcltk-stubs is enabled.nagai2008-06-10219-1265/+6983
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ext/tk/tcltklib.c: avoid error on a shared object. * ext/tk/extconf.rb: support --with-tcltkversion * ext/tk/README.tcltklib: add document about --with-tcltkversion * ext/tk/lib/tk.rb, ext/tk/lib/multi-tk.rb, ext/tk/lib/remote-tk.rb: not work on $SAFE==4 * ext/tk/lib/multi-tk.rb: Object#methods returns Symbols on Ruby1.9. * ext/tk/lib/tk/timer.rb: add TkTimer#at_end(proc) to register the procedure which called at end of the timer. * ext/tk/lib/tk.rb, ext/tk/lib/tk/itemfont.rb, ext/tk/lib/font.rb: support __IGNORE_UNKNOWN_CONFIGURE_OPTION__ about font options. * ext/tk/lib/*: treat __IGNORE_UNKNOWN_CONFIGURE_OPTION__ * ext/tk/lib/tkextlib/iwidgets/scrolledcanvas.rb, ext/tk/lib/tkextlib/iwidgets/scrolledlistbox.rb, ext/tk/lib/tkextlib/iwidgets/scrolledtext.rb: bug fix. * ext/tk/lib/tk/text.rb: typo. call a wrong method. * ext/tk/lib/tk/itemconfig.rb: ditto. * ext/tk/lib/tk.rb, ext/tk/lib/tk/itemconfig.rb, ext/tk/lib/tk/canvas.rb: support alias names of option keys. * ext/tk/lib/tk/grid.rb: lack of module-method definitions. * ext/tk/lib/tk/pack.rb, ext/tk/lib/tk/grid.rb: increase supported parameter patterns of configure method. * ext/tk/lib/tk.rb: add TkWindow#grid_anchor, grid_column, grid_row. * ext/tk/lib/tk/wm.rb: methods of Tk::Wm_for_General module cannot pass the given block to methods of Tk::Wm module. * ext/tk/lib/tk/wm.rb: Wm#overrideredirect overwrites arguemnt to an invalid value. * ext/tk/lib/tk.rb: fix memory (object) leak bug. * ext/tk/tcltklib.c, ext/tk/tkutil/tkutil.c: fix memory leak. * ext/tk/sample/demos-jp/aniwave.rb, ext/tk/sample/demos-en/aniwave.rb: bug fix. * ext/tk/lib/tkextlib/blt/component.rb, ext/tk/lib/tkextlib/tile/tentry.rb, ext/tk/lib/tkextlib/tile/treeview.rb: ditto. * ext/tk/lib/tkextlib/tile/tpaned.rb: improve TPaned#add. * ext/tk/sample/demos-jp/widget, ext/tk/sample/demos-en/widget, ext/tk/sample/demos-jp/style.rb, ext/tk/sample/demos-en/style.rb, ext/tk/sample/demos-jp/bind.rb, ext/tk/sample/demos-en/bind.rb: bug fix. * ext/tk/sample/ttk_wrapper.rb: ditto. * ext/tk/sample/ttk_wrapper.rb: support "if __FILE__ == $0" idiom. * ext/tk/sample/tktextio.rb: add binding for 'Ctrl-u' at console mode. * ext/tk/lib/tkextlib/tile.rb, ext/tk/lib/tkextlib/tile/style.rb, ext/tk/sample/ttk_wrapper.rb: improve treating and control themes. add Tk::Tile.themes and Tk::Tile.set_theme(theme). * ext/tk/lib/tkextlib/tile.rb: lack of autoload definitions. * ext/tk/lib/tkextlib/tile/tnotebook.rb: cannot use kanji (not UTF-8) characters for headings. * ext/tk/lib/tkextlib/tkDND/shape.rb: wrong package name. * ext/tk/tkutil/tkutil.c: improve handling callback-subst-keys. Now, support longnam-keys (e.g. '%CTT' on tkdnd-2.0; however, still not support tkdnd-2.0 on tkextlib), and symbols of parameters (e.g. :widget=>'%W', :keycode=>'%k', '%x'=>:x, '%X'=>:root_x, and so on; those are attributes of event object). It means that Ruby/Tk accepts not only "widget.bind(ev, '%W', '%k', ...){|w, k, ...| ... }", but also "widget.bind(ev, :widget, :keycode, ...){|w, k, ...| ... }". It is potentially incompatible, when user passes symbols to the arguments of the callback block (the block receives the symbols as strings). I think that is very rare case (probably, used by Ruby/Tk experts only). When causes such trouble, please give strings instead of such symbol parameters (e.g. call Symbol#to_s method). * ext/tk/lib/tk/event.rb, ext/tk/lib/tk/validation.rb, ext/tk/lib/tkextlib/blt/treeview.rb, ext/tk/lib/tkextlib/winico/winico.rb: ditto. * ext/tk/tkutil/tkutil.c: strings are available on subst_tables on TkUtil::CallbackSubst class (it is useful on Ruby 1.9). * ext/tk/lib/tk/spinbox.rb, ext/tk/lib/tkextlib/iwidgets/hierarchy.rb, ext/tk/lib/tkextlib/iwidgets/spinner.rb, ext/tk/lib/tkextlib/iwidgets/entryfield.rb, ext/tk/lib/tkextlib/iwidgets/calendar.rb, ext/tk/lib/tkextlib/blt/dragdrop.rb, ext/tk/lib/tkextlib/tkDND/tkdnd.rb, ext/tk/lib/tkextlib/treectrl/tktreectrl.rb, ext/tk/lib/tkextlib/tktable/tktable.rb: disable code piece became unnecessary by reason of the changes of ext/tk/tkutil/tkutil.c. * ext/tk/lib/tk.rb, ext/tk/lib/multi-tk.rb: change strategy to define the constant WITH_ENCODING. * ext/tk/lib/tk.rb: fix bug on Tk::Encoding.tk_encoding_names. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@17083 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* revert git backfire in r15860; sorrymatz2008-03-304-8/+98
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15861 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * proc.c (proc_dup): should copy is_lambda attribute as well.matz2008-03-304-98/+8
| | | | | | [ruby-talk:296244] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15860 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/sample/ttk_wrapper.rb: minor bug fix.nagai2008-03-291-1/+1
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15850 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/*: full update Ruby/Tk to support Ruby(1.9|1.8) and Tc/Tk8.5.nagai2008-03-29120-2194/+7771
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ext/tk/lib/tkextlib/tile.rb: [incompatible] remove TileWidgets' instate/state/identify method to avoid the conflict with standard widget options. Those methods are renamed to ttk_instate/ttk_state/ ttk_identify (tile_instate/tile_state/tile_identify are available too). Although I don't recommend, if you realy need old methods, please define "Tk::USE_OBSOLETE_TILE_STATE_METHOD = true" before "require 'tkextlib/tile'". * ext/tk/lib/tkextlib/tile.rb: "Tk::Tile::__Import_Tile_Widgets__!" is obsolete. It outputs warning. To control default widget set, use "Tk.default_widget_set = :Ttk". * ext/tk/lib/tk.rb: __IGNORE_UNKNOWN_CONFIGURE_OPTION__ method and __set_IGNORE_UNKNOWN_CONFIGURE_OPTION__!(mode) method are defind as module methods of TkConfigMethod. It may help users to wrap old Ruby/Tk scripts (use standard widgets) to force to use Ttk widgets. Ttk widgets don't have some options of standard widgets which are control the view of widgets. When set ignore-mode true, configure method tries to ignoure such unknown options with no exception. Of course, it may raise other troubles on the GUI design. So, those are a little danger methods. * ext/tk/lib/tk/itemconfig.rb: __IGNORE_UNKNOWN_CONFIGURE_OPTION__ method and __set_IGNORE_UNKNOWN_CONFIGURE_OPTION__!(mode) method are defind as module methods of TkItemConfigMethod as the same purpose as TkConfigMethod's ones. * ext/tk/sample/ttk_wrapper.rb: A new example. This is a tool for wrapping old Ruby/Tk scripts (which use standard widgets) to use Ttk (Tile) widgets as default. * ext/tk/sample/tkextlib/tile/demo.rb: use ttk_instate/ttk_state method instead of instate/state method. * ext/tk/lib/tk/root, ext/tk/lib/tk/namespace.rb, ext/tk/lib/tk/text.rb, ext/tk/lib/tkextlib/*: some 'instance_eval's are replaced to "instance_exec(self)". * ext/tk/lib/tk/event.rb: bug fix on KEY_TBL and PROC_TBL (?x is not a character code on Ruby1.9). * ext/tk/lib/tk/variable.rb: support new style of operation argument on Tcl/Tk's 'trace' command for variables. * ext/tk/sample/demos-jp/widget, ext/tk/sample/demos-en/widget: bug fix * ext/tk/sammple/demos-jp/textpeer.rb, ext/tk/sammple/demos-en/textpeer.rb: new widget demo. * ext/tk/tcltklib.c: decrase SEGV troubles (probably) * ext/tk/lib/tk.rb: remove Thread.critical access if Ruby1.9 * ext/tk/lib/tk/multi-tk.rb: support Ruby1.9 (probably) * ext/tk/lib/tkextlib/tile.rb: add method to define Tcl/Tk command to make Tcl/Tk theme sources (based on different version of Tile extension) available. (Tk::Tile::__define_LoadImages_proc_for_comaptibility__) * ext/tk/lib/tk.rb, ext/tk/lib/tk/wm.rb: support dockable frames (Tcl/Tk8.5 feature). 'wm' command can treat many kinds of widgets as toplevel widgets. * ext/tk/lib/tkextlib/tile/style.rb: ditto. (Tk::Tile::Style.__define_wrapper_proc_for_compatibility__) * ext/tk/lib/tk/font.rb: add actual_hash and metrics_hash to get properties as a hash. metrics_hash method returns a boolean value for 'fixed' option. But metrics method returns numeric value (0 or 1) for 'fixed' option, because of backward compatibility. * ext/tk/lib/tk/timer.rb: somtimes fail to set callback procedure. * ext/tk/lib/tk.rb: add Tk.sleep and Tk.wakeup method. Tk.sleep doesn't block the eventloop. It will be better to use the method in event callbacks. * ext/tk/sample/tksleep_sample.rb: sample script about Tk.sleep. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15848 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb: forgot to update RELEASE_DATEnagai2008-02-286-27/+42
| | | | | | | | | | | | | | | * ext/tk/lib/tk.rb, ext/tk/lib/tk/text.rb, ext/tk/lib/tkextlib/iwidgets/scrolledtext.rb: remove adhoc check of Ruby's features (use existence of some classes instead of comparing with RUBY_VERSION) * ext/tk/lib/tk/root.rb, ext/tk/lib/tk/autoload.rb: make TkRoot (Tk::Root) unswitchable * ext/tk/lib/multi-tk.rb: partial bug fix (still not work!!) git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15634 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb, ext/tk/lib/*: make default widget set nagai2008-02-2787-463/+821
| | | | | | | | | | | | | | | | | | | | | | | | switchable between Tk (standard Tcl/Tk widget set) and Ttk (Tile). Initial default widget set is Tk. Now, toplevel widget classes are removed and defined as aliases. For example, "TkButton" is an alias of the "Tk::Button" class. Those aliases are replaced when switching default widget set. "Tk.default_widget_set=" is the method for switching default widget set. "Tk.default_widget_set = :Ttk" defines Ttk (Tile) widget set as default. It means that "TkButton" denotes "Tk::Tile::Button" class. And then, "TkButton.new" creates a Tk::Tile::Button widget. Of course, you can back to use standard Tk widgets as the default widget set by calling "Tk.default_widget_set = :Tk", whenever you want. Based on thie feature, you can use Ttk widget styling engine on your old Ruby/Tk application without modifying its source, if you don'tuse widget options unsupported on Ttk widgets (At first, call "Tk.default_widget_set = :Ttk", and next load and run your application). This is one step for supporting Tcl/Tk8.5 features. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@15618 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * $Date$ keyword removed to avoid inclusion of locale dependentakr2008-01-067-7/+0
| | | | | | | string. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14912 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * include/ruby/ruby.h, thread.c: rename is_ruby_native_thread() toko12007-12-251-8/+8
| | | | | | | | | ruby_native_thread_p(). * ext/tk/tcltklib.c: apply it. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14680 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/sample/tkextlib/vu/canvSticker2.rb,usa2007-12-213-14/+14
| | | | | | | | ext/tk/sample/demos-{en,jp}/bind.rb: fix typo. [ruby-dev:32668] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14436 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Ruby/Tk :: provisional support on Ruby-VM and Tcl/Tk8.5.nagai2007-12-2145-325/+1185
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14426 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * regerror.c, string.c, io.c, lib/getoptlong.rb, lib/net/imap.rb,akr2007-12-212-2/+2
| | | | | | | | | | | compile.c, sprintf.c, parse.y, ext/win32ole/win32ole.c, ext/tk/sample/demos-en/entry3.rb, ext/tk/lib/tcltk.rb, ext/openssl/ossl_bn.c, numeric.c, vm.c, benchmark/bm_so_meteor_contest.rb, bignum.c, ruby.c: don't "illegal" for non law violation context. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14377 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * encoding.c (rb_enc_mbclen): make it never fail.akr2007-12-081-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (rb_enc_nth): don't check the return value of rb_enc_mbclen. (rb_enc_strlen): ditto. (rb_enc_precise_mbclen): return needmore(1) if e <= p. (rb_enc_get_ascii): new function for extracting ASCII character. * include/ruby/encoding.h (rb_enc_get_ascii): declared. * include/ruby/regex.h (ismbchar): removed. * re.c (rb_reg_expr_str): use rb_enc_get_ascii. (unescape_escaped_nonascii): use rb_enc_precise_mbclen to determine the termination of escaped non-ASCII character. (unescape_nonascii): use rb_enc_precise_mbclen. (rb_reg_quote): use rb_enc_get_ascii. (rb_reg_regsub): use rb_enc_get_ascii. * string.c (rb_str_reverse) don't check the return value of rb_enc_mbclen. (rb_str_split_m): don't call rb_enc_mbclen with e <= p. * parse.y (is_identchar): use ISASCII. (parser_ismbchar): removed. (parser_precise_mbclen): new macro. (parser_isascii): new macro. (parser_tokadd_mbchar): use parser_precise_mbclen to check invalid character precisely. (parser_tokadd_string): use parser_isascii. (parser_yylex): ditto. (is_special_global_name): don't call is_identchar with e <= p. (rb_enc_symname_p): ditto. [ruby-dev:32455] * ext/tk/sample/tkextlib/vu/canvSticker2.rb: remove coding cookie because the encoding is not UTF-8. [ruby-dev:32475] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14131 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* forgot to modify akr2007-08-291-7/+7
| | | | | | | | | ext/json/ext/parser/parser.rl and ext/tk/tkutil/tkutil.c. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@13312 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * encoding.c: provide basic features for M17N.matz2007-08-2560-0/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * parse.y: encoding aware parsing. * parse.y (pragma_encoding): encoding specification pragma. * parse.y (rb_intern3): encoding specified symbols. * string.c (rb_str_length): length based on characters. for older behavior, bytesize method added. * string.c (rb_str_index_m): index based on characters. rindex as well. * string.c (succ_char): encoding aware succeeding string. * string.c (rb_str_reverse): reverse based on characters. * string.c (rb_str_inspect): encoding aware string description. * string.c (rb_str_upcase_bang): encoding aware case conversion. downcase, capitalize, swapcase as well. * string.c (rb_str_tr_bang): tr based on characters. delete, squeeze, tr_s, count as well. * string.c (rb_str_split_m): split based on characters. * string.c (rb_str_each_line): encoding aware each_line. * string.c (rb_str_each_char): added. iteration based on characters. * string.c (rb_str_strip_bang): encoding aware whitespace stripping. lstrip, rstrip as well. * string.c (rb_str_justify): encoding aware justifying (ljust, rjust, center). * string.c (str_encoding): get encoding attribute from a string. * re.c (rb_reg_initialize): encoding aware regular expression * sprintf.c (rb_str_format): formatting (i.e. length count) based on characters. * io.c (rb_io_getc): getc to return one-character string. for older behavior, getbyte method added. * ext/stringio/stringio.c (strio_getc): ditto. * io.c (rb_io_ungetc): allow pushing arbitrary string at the current reading point. * ext/stringio/stringio.c (strio_ungetc): ditto. * ext/strscan/strscan.c: encoding support. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@13261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c (Init_tcltklib): use rb_set_end_proc().nobu2007-08-181-5/+2
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@13105 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * file.c (rb_file_s_rename): deleted code to get rid of a bug ofnobu2007-07-221-2/+2
| | | | | | | | | | | | | | | | | | | | | | | old Cygwin. * file.c (rb_file_truncate): added prototype of GetLastError() on cygwin. [ruby-dev:31239] * include/ruby/intern.h (is_ruby_native_thread): prototype. * missing/strftime.c (strftime): fix printf format and actual arguments. * ext/Win32API/Win32API.c (Win32API_initialize): ditto. * ext/tk/tcltklib.c (ip_finalize): ditto. * ext/win32ole/win32ole.c (lcid_installed): ditto. * ext/socket/getnameinfo.c: include stdio.h always. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@12836 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * include/ruby: moved public headers.nobu2007-06-105-9/+10
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@12501 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/tcllib/tablelist.rb: fix typo.nagai2007-05-254-3/+12
| | | | | | | | * ext/tk/lib/tkextlib/tile/dialog.rb: forget to give an argument. * ext/tk/lib/tkextlib/version.rb: update RELEASE_DATE. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@12388 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/sample/irbtkw.rbw: fails to exit process.nagai2007-03-061-1/+6
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@12002 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb: fix typo (TkConfigMethod::__confinfo_cmd, nagai2007-02-091-2/+2
| | | | | | | __conv_keyonly_opts). git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11680 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/sample/images/teapot.ppm: fix the broken file. [ruby-dev:30226]nagai2007-01-311-37/+12
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11600 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/sample/tktextio.rb: 'hist_size' option causes error.nagai2007-01-291-1/+1
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11591 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk.rb (TkConfigMethod#__confinfo_cmd,__conv_keyonly_optkeys): nagai2007-01-2610-17/+32
| | | | | | | | | | | | | | | | | | | make them private [ruby-dev:30074]. * ext/tk/lib/tk/txtwin_abst.rb: fix typo [ruby-dev:30073]. * ext/tk/lib/tk/canvas.rb (TkCanvas#scan_dragto): lack of an argument. * ext/tk/lib/tk/canvas.rb: clarify the including module name [ruby-dev:30080]. * ext/tk/lib/tk/scrollable.rb: change primary name of modules [ruby-dev:30080]. * ext/tk/lib/tkextlib/iwidgets/checkbox.rb: wrong number of arguments [ruby-Bugs-7776]. * ext/tk/lib/tkextlib/iwidgets/radiobox.rb: ditto. * ext/tk/lib/tkextlib/blt/tile/checkbutton.rb: change primary name of class [ruby-dev:30080]. * ext/tk/lib/tkextlib/blt/tile/radiobutton.rb: ditto. * ext/tk/ChangeLog.tkextlib: update. * ext/tk/lib/tkextlib/version.rb: update. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11577 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c : fix to compile on YARVko12006-12-311-40/+40
| | | | | | | | | ruby_errinfo -> rb_errinfo(), ruby_safe_level -> rb_safe_level(). git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/tcltklib.c: shouldn't run the killed thread at callback.nagai2006-12-011-13/+28
| | | | | | | [ruby-talk: 227408] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e