[前][次][番号順一覧][スレッド一覧]

ruby-changes:28859

From: nobu <ko1@a...>
Date: Fri, 24 May 2013 15:54:36 +0900 (JST)
Subject: [ruby-changes:28859] nobu:r40911 (trunk): io/console: rdoc

nobu	2013-05-24 15:54:25 +0900 (Fri, 24 May 2013)

  New Revision: 40911

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=40911

  Log:
    io/console: rdoc
    
    * ext/io/console/console.c (io_getch): add rdoc.
    
    * ext/io/console/lib/console/size.rb (IO.console_size): ditto.

  Modified files:
    trunk/ext/io/console/console.c
    trunk/ext/io/console/lib/console/size.rb

Index: ext/io/console/console.c
===================================================================
--- ext/io/console/console.c	(revision 40910)
+++ ext/io/console/console.c	(revision 40911)
@@ -768,6 +768,12 @@ console_dev(VALUE klass) https://github.com/ruby/ruby/blob/trunk/ext/io/console/console.c#L768
     return con;
 }
 
+/*
+ * call-seq:
+ *   io.getch(min: nil, time: nil)       -> char
+ *
+ * See IO#getch.
+ */
 static VALUE
 io_getch(int argc, VALUE *argv, VALUE io)
 {
Index: ext/io/console/lib/console/size.rb
===================================================================
--- ext/io/console/lib/console/size.rb	(revision 40910)
+++ ext/io/console/lib/console/size.rb	(revision 40911)
@@ -1,3 +1,4 @@ https://github.com/ruby/ruby/blob/trunk/ext/io/console/lib/console/size.rb#L1
+# fallback to console window size
 def IO.default_console_size
   [
     ENV["LINES"].to_i.nonzero? || 25,
@@ -12,6 +13,7 @@ rescue LoadError https://github.com/ruby/ruby/blob/trunk/ext/io/console/lib/console/size.rb#L13
     alias console_size default_console_size
   end
 else
+  # returns console window size
   def IO.console_size
     console.winsize
   rescue NoMethodError

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]