From ajksharma at myrealbox.com Wed Oct 2 02:06:46 2002 From: ajksharma at myrealbox.com (ajay sharma) Date: Tue, 1 Oct 2002 22:36:46 +0530 Subject: [Apollo-talk] Patch for ADOStoredProc References: <20020926174140.963E.CQK01016@nifty.ne.jp> <000f01c266da$f8ac72b0$530510ac@mainserver> Message-ID: <001001c2696c$eedfe430$530510ac@mainserver> Hi, The AdoStoredproc patch is working. Thanks take_tk. Does someone have a script that I can use as an example? Regards Ajay Sharma From ggb03124 at nifty.ne.jp Wed Oct 2 13:12:01 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Wed, 02 Oct 2002 13:12:01 +0900 Subject: [Apollo-talk] Patch for ADOStoredProc In-Reply-To: <001001c2696c$eedfe430$530510ac@mainserver> References: <000f01c266da$f8ac72b0$530510ac@mainserver> <001001c2696c$eedfe430$530510ac@mainserver> Message-ID: <20021002105847.CC7B.GGB03124@nifty.ne.jp> Hi! Ajay. This is take_tk Re: [Apollo-talk] Patch for ADOStoredProc "ajay sharma" wrote: : Does someone have a script that I can use as an example? Some additional patches as follows are needed.. ADOConnection is somewhat differ (*) from this. I have no environment for test ADO now. So, please for few dates/weeks. (*) ADOStoredProc has not "exec_proc" nor ParamByName( #[] methods). So, must use #active=true and #parameters. #parameters ( Parameters class) is not implemented yet. So, I'll ask Moriq for it. ---- sample for StoredProc Using SQLConnection ---- require "phi" require "rdb" require "g:/apollo/kumalaw/kumalaw_db" con = DB_v19.db # please create your SQLConnection puts con ## # stored = RDB::SQLStoredProc.new stored.sql_connection = con #p stored # #puts stored.methods.sort ##stored_proc_name ##stored_proc_name= ##params ##params= ##puts con.procedure_names ##GET_EMP_PROJ ##ADD_EMP_PROJ ##SUB_TOT_BUDGET ##DELETE_EMPLOYEE ##DEPT_BUDGET ##ORG_CHART ##MAIL_LABEL ##SHIP_ORDER ##SHOW_LANGS ##ALL_LANGS ##MYPROCEDURE ##GET_ITEM_ID stored.stored_proc_name = "GET_EMP_PROJ" ## -- contents of Stored Procedure "GET_EMP_PROJ" ## ##CREATE PROCEDURE GET_EMP_PROJ ( ## EMP_NO SMALLINT ##) RETURNS ( ## PROJ_ID CHAR(5) ##) AS ##BEGIN ## FOR SELECT proj_id ## FROM employee_project ## WHERE emp_no = :emp_no ## INTO :proj_id ## DO ## SUSPEND; ##END RDB::Param.new( stored , RDB::PT_INPUT ) RDB::Param.new( stored , RDB::PT_OUTPUT ) #stored.params.clear #undefined method `clear' for # (NameError) stored.params[0].name = 'EMP_NO' stored.params[1].name = 'PROJ_ID' stored.params['EMP_NO'] = 52 stored.exec_proc p stored.params['PROJ_ID'] #=> MKTPR # ok! p "------" query = con.new_query('select * from employee_project') query.display =begin FROM Delphi HELP var P1, P2: TParam; begin ... with StoredProc1 do begin StoredProcName := 'GET_EMP_PROJ'; Params.Clear; P1 := TParam.Create(Params, ptInput); P2 := TParam.Create(Params, ptOutput); try Params[0].Name := 'EMP_NO'; Params[1].Name := 'PROJ_ID'; ParamByname('EMP_NO').AsSmallInt := 52; ExecProc; Edit1.Text := ParamByname('PROJ_ID').AsString; finally P1.Free; P2.Free; end; end; ... end; =end ---- Patch: ---- C:/Program Files/Apollo/src/ext/rdb/uSQLStoredProc.pas ---- uses SqlExpr, uDefUtils, Pythia, uRDB, uDataSet, uParam; //++ //// function SQLStoredProc_exec_proc(This: Tvalue): Tvalue; cdecl; var real: TSQLStoredProc; begin real := ap_data_get_struct(This); result := ap_Integer(real.ExecProc); end; function SQLStoredProc_get_params(This: Tvalue): Tvalue; cdecl; var real: TSQLStoredProc; begin real := ap_data_get_struct(This); result := ap_iParams(real.Params, This); end; procedure Init_SQLStoredProc; begin cSQLStoredProc := DefinePersistentClass(mRDB, TSQLStoredProc, ap_cObject, nil); DefineSingletonMethod(cSQLStoredProc, 'new', SQLStoredProc_new); //++ rb_define_method(cSQLStoredProc, 'exec_proc', @SQLStoredProc_exec_proc, 0); DefineAttrGet(cSQLStoredProc, 'params', SQLStoredProc_get_params); end; end. ---- take_tk = kumagai hidetake From ajksharma at myrealbox.com Fri Oct 4 15:24:33 2002 From: ajksharma at myrealbox.com (ajay sharma) Date: Fri, 4 Oct 2002 11:54:33 +0530 Subject: [Apollo-talk] Calling another form from mainform References: <000f01c266da$f8ac72b0$530510ac@mainserver> <001001c2696c$eedfe430$530510ac@mainserver> <20021002105847.CC7B.GGB03124@nifty.ne.jp> Message-ID: <002901c26b6e$b6438c90$530510ac@mainserver> Hi, I am stuck on this. I have a 'MainForm' which calls a 'LookupForm' to get some value. For example the mainform has a 'Edit' field and a button. Clicking this button calls another form, which has some value in a edit field. Now when I press a button on this form, this form will close and I will get this value in the edit field on the mainform. < require 'phi' include Phi form = Form.new btn = Button.new form txt = Edit.new form btn.top=100 btn.left=100 txt.top=25 txt.left=25 btn.caption = 'GetValue' def btn.on_click lookupform = Form.new lookupform.width=150 lookupform.height=100 btn1 = Button.new lookupform txt = Edit.new lookupform txt.text="676" btn1.top=35 btn1.caption = 'SendValue' if lookupform.showmodal=mr_ok then mainform.txt=lookupform.txt end form.show Phi.mainloop > So in short, I want to create child/lookup forms/dialogs and get values from them based on the user input/selection. Wonder if anybody has any examples which shows how do this properly? In the btn.on_click event in the above example, how can I access the 'Parent form'? I can only access if I declare the form object as @@form = Form.new Is this the correct way? I hope I have explained it clearly. Regards Ajay From ggb03124 at nifty.ne.jp Fri Oct 4 16:47:19 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Fri, 04 Oct 2002 16:47:19 +0900 Subject: [Apollo-talk] Calling another form from mainform In-Reply-To: <002901c26b6e$b6438c90$530510ac@mainserver> References: <20021002105847.CC7B.GGB03124@nifty.ne.jp> <002901c26b6e$b6438c90$530510ac@mainserver> Message-ID: <20021004163548.9267.GGB03124@nifty.ne.jp> Hi [Apollo-talk] Calling another form from mainform "ajay sharma" wrote: Try this please. ---- require 'phi' include Phi form = Form.new :mainform, "manform" btn = Button.new form btn.top=100 btn.left=100 #-- txt_local .. local variable #-- txt_prop .. property name of the form # # local variable cannot access fron inside the definition of method. txt_local = Edit.new form, :txt_prop ## <= form.txt_prop txt_local.top=25 txt_local.left=25 btn.caption = 'GetValue' def btn.on_click lookupform = Form.new lookupform.width=150 lookupform.height=100 btn1 = Button.new lookupform btn1.top=35 btn1.caption = 'SendValue' txt_local = Edit.new lookupform, :txt_prop txt_local.text="676" #-- set modal result of the button btn1.modal_result = Phi::MR_OK if lookupform.show_modal == Phi::MR_OK # -- self.parent # self is this button object. # self.parent is button's parent and is the mainform. # "form" is a local variable outside the difinition. # so, cannot refer the object by the name "form". self.parent.txt_prop.text = lookupform.txt_prop.text end end form.show Phi.mainloop ---- You can write "$form.txt_prop.text = lookupform .." if a global variable "$form" is made instead of local variable "form". But I do not recommend such use of global variable. take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Fri Oct 4 17:02:12 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Fri, 04 Oct 2002 17:02:12 +0900 Subject: [Apollo-talk] Calling another form from mainform In-Reply-To: <002901c26b6e$b6438c90$530510ac@mainserver> References: <20021002105847.CC7B.GGB03124@nifty.ne.jp> <002901c26b6e$b6438c90$530510ac@mainserver> Message-ID: <20021004165204.926A.GGB03124@nifty.ne.jp> Another solution; ---- require 'phi' include Phi form = Form.new btn = Button.new form btn.top=100 btn.left=100 txt_main = Edit.new form txt_main.top=25 txt_main.left=25 btn.caption = 'GetValue' ##def btn.on_click btn.on_click = proc{ lookupform = Form.new lookupform.width=150 lookupform.height=100 btn1 = Button.new lookupform txt_lookup = Edit.new lookupform txt_lookup.text="676" btn1.top=35 btn1.caption = 'SendValue' btn1.modal_result = Phi::MR_OK if lookupform.show_modal == Phi::MR_OK #-- according to the scope rule of blocks, # local variables outside the block can be refered. txt_main.text = txt_lookup.text end } ##end form.show Phi.mainloop ---- Take_tk = KUMAGAI Hidetake From ggb03124 at nifty.ne.jp Fri Oct 4 17:27:08 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Fri, 04 Oct 2002 17:27:08 +0900 Subject: [Apollo-talk] Calling another form from mainform In-Reply-To: <002901c26b6e$b6438c90$530510ac@mainserver> References: <002901c26b6e$b6438c90$530510ac@mainserver> Message-ID: <20021004171240.926D.GGB03124@nifty.ne.jp> Third reply.. (^^; > In the btn.on_click event in the above example, how can I access the 'Parent > form'? When you want to know "Parent", Object#methods is convinient. ---- def btn.on_click p self puts self.methods.select{|n| /parent/i =~ n }.sort #=> # #=> parent #=> parent= #=> parent_bi_di_mode #=> parent_bi_di_mode= #=> parent_bi_di_mode? #=> parent_font #=> parent_font= #=> parent_font? #=> parent_form .. <= what ? #=> parent_show_hint #=> parent_show_hint= #=> parent_show_hint? lookupform = Form.new ---- Take_tk = KUMAGAI Hidetake From ajksharma at myrealbox.com Fri Oct 4 18:34:03 2002 From: ajksharma at myrealbox.com (ajay sharma) Date: Fri, 4 Oct 2002 15:04:03 +0530 Subject: [Apollo-talk] Calling another form from mainform References: <002901c26b6e$b6438c90$530510ac@mainserver> <20021004171240.926D.GGB03124@nifty.ne.jp> Message-ID: <001201c26b89$2f1d0dc0$530510ac@mainserver> Hi Take_tk, That was very quick. Thanks for your replies. Regards Ajay From ajksharma at myrealbox.com Wed Oct 9 02:47:23 2002 From: ajksharma at myrealbox.com (ajay sharma) Date: Tue, 8 Oct 2002 23:17:23 +0530 Subject: [Apollo-talk] Apollo with Kylix? References: <000f01c266da$f8ac72b0$530510ac@mainserver> <001001c2696c$eedfe430$530510ac@mainserver> <20021002105847.CC7B.GGB03124@nifty.ne.jp> Message-ID: <000c01c26ef2$c3fc0650$530510ac@mainserver> Hi All, Does Apollo work in Kylix? I have installed kylix already. In windows we use the mswin32-ruby16.dll for Apollo, What is the equivalent in Linux? Regards ajay sharma From moriq.kazuhiro at nifty.ne.jp Wed Oct 9 07:53:05 2002 From: moriq.kazuhiro at nifty.ne.jp (Kazuhiro Yoshida) Date: Wed, 09 Oct 2002 07:53:05 +0900 Subject: [Apollo-talk] Apollo with Kylix? In-Reply-To: <000c01c26ef2$c3fc0650$530510ac@mainserver> References: <000c01c26ef2$c3fc0650$530510ac@mainserver> Message-ID: <200210082253.AA01716@thany.nifty.com> Hi, "ajay sharma" wrote: > Hi All, > Does Apollo work in Kylix? I have installed kylix already. I could have compiled. When performing the sample, there were some which do not work. > In windows we use the mswin32-ruby16.dll for Apollo, > What is the equivalent in Linux? libruby.so $ ./configure --enable-shared $ make $ make test $ su # make install # vi /etc/ld.so.conf append -- /usr/local/lib /usr/kylix/bin -- # ldconfig -v $ ruby -v $ export LD_LIBRARY_PATH=/usr/kylix/bin:/usr/local/apollo/bin $ export RUBYLIB=/usr/local/apollo/bin $ ruby_ap -v $ ruby_ap foo.rb ---- YOSHIDA Kazuhiro moriq at moriq.com http://www.moriq.com/ From ggb03124 at nifty.ne.jp Wed Oct 9 11:23:04 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Wed, 09 Oct 2002 11:23:04 +0900 Subject: [Apollo-talk] ap-list digest Message-ID: <20021009111004.9266.GGB03124@nifty.ne.jp> Hi!, This is take_tk Someone may post some English translation of Apollo Mailing List writen in Japanese. There are four mailing list in Japanese. Please ask for translation, if you are interested in some posting in them. (1) ap-list .. for apollo users http://www.freeml.com/ctrl/html/MessageListForm/ap-list at freeml.com (2) ap-ext .. samples of extensions of apollo. http://www.freeml.com/ctrl/html/MessageListForm/ap-ext at freeml.com (3) ap-doc .. for apollo documentation. http://www.freeml.com/ctrl/html/MessageListForm/ap-doc at freeml.com (4) ap-dev .. for apollo developpers. http://www.freeml.com/ctrl/html/MessageListForm/ap-dev at freeml.com take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Wed Oct 9 19:19:56 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Wed, 09 Oct 2002 19:19:56 +0900 Subject: [Apollo-talk:20] Re: [Apollo-talk] ap-list digest In-Reply-To: <20021009111004.9266.GGB03124@nifty.ne.jp> References: <20021009111004.9266.GGB03124@nifty.ne.jp> Message-ID: <20021009183920.926B.GGB03124@nifty.ne.jp> [ap-list:2927] ap-635 Sun, 06 Oct 2002 Kazuhiro Yoshida ap-635 was released. http://www.moriq.com/apollo/archive/ap-635_vcl60.zip http://homepage1.nifty.com/moriq/ap-635_bde60.msi http://homepage1.nifty.com/moriq/bdemerge.ini -- Exerb can convert Apollo scripts to exe files. Exerb http://exerb.sourceforge.jp/ Following command line makes "foo.1.exe" from "foo.1.rb". "bin/foo.1.rbc" is the definition file of "bin/foo.1.rb". D:\exerb\bin>ruby exerb.rb d:\apollo\bin\foo.1.rbc Thanks Mr. Yuya .. [ruby-list:36101] -- Win.* Sys.* => Phi.* Win and Sys modules are dropped and merged to Phi module. Inserting following line to old script assures compatibility. Win = Sys = Phi unless defined? Win # [ap-dev:0798] -- config.rb "config.rb" modifies Delphi resource description in apollo source files (esp. *.dof and *.cfg). Before run the script, you must edit "config_opt.rb" for your environment. -- for Linux (1) Get Kylix3 Open Edition http://www.borland.com/kylix/open/index.html (2) Make Ruby-1.6 with --enable-shared option (3) Set LD_LIBRARY_PATH, RUBYLIB (4) Open Kylix2Pro.bpg, and configure directory options (5) may create ruby_ap, phi.so, dialogs.so Wanted, Debug Soldiers who do not be afraid "core dump" "tmp/cutcr.rb" removes "\r" from source files. Recommended. -- [ap-dev:0714] IO hook is moved from Phi::Application to Phi::IO which is a instance of Phi::IOHook. [ap-dev:0715] TreeNode# expanded first_child last_child next next_child next_sibling next_visible prev prev_child prev_sibling prev_visible [ap-dev:0772] [Apollo-talk] SQLStoredProc#exec_proc SQLStoredProc#params ADOStoredProc#exec_proc ADOStoredProc#parameters -- DefinePersistentClass OutputPersistentClass Checks whether the object in third parameter is a Phi::Persistent -- + class TreeView ; include Phi::ItemsEnumerable ; end def define_child_attr(this) - define_method(this.name){ this } + define_method(Phi.downcase(this.name)){ this } + module ControlContainer + def control_attr_flatten + class Form ; include Phi::ControlContainer ; end + # ap-dev:0748 + def right=(v) + def bottom=(v) +# ap-dev:0750 +module Phi + class DateTime + + alias :succ :inc_day + + alias :begin_of_day :start_of_day + alias :begin_of_month :start_of_month + alias :begin_of_year :start_of_year [ap-dev:0721] InterBase#counter "dummy_for_counter" table was removed. "rdb$database" table is used. [Delphi:69987] [ap-dev:0728] Editor.url_chars ---- take_tk = kumagai hidetake From repeater at lucentprimate.cjb.net Sun Oct 20 09:24:24 2002 From: repeater at lucentprimate.cjb.net (repeater) Date: Sun, 20 Oct 2002 02:24:24 +0200 Subject: [Apollo-talk:21] apollo problems Message-ID: greetings it is good thing to see an english list for apollo ! i'm facing some problens though, i hope some of you can help 1.) the latest version (ap-635_vcl60.zip) does not operate on my computer. when executing apollo.exe i get: " No such file to load -- rbconfig (LoadError) c:/ruby/apollo/bin/phi.rb:6:in `require' c:/ruby/apollo/bin/phi.rb:6 C:/ruby/apollo/bin/custom.rb:8:in `require' C:/ruby/apollo/bin/custom.rb:8 " it cannot find the include dir i think. this is probably related to some new kind of basic directory setup that i'm missing. (the previous distribution i have used (ap-632_vcl60.zip), is currently working) 2.) is it possible to use ruby 1.7 with apollo ? i've tried and failed (it looks for that mswin32-ruby16.dll file, now named mswin32-ruby17.dll. the directories containing "1.6" also changed name, it seems) 3.) in the development of a project, i've found the following features of delphi missing in apollo: Popupmenu popup_component popup_point MenuItem clear (can be faked with while loop and delete(), but slower i think) Shape on_mouse_down on_mouse_move on_mouse_up i've circumvented all of the above with rather clumsy code, but is there a reason for their exclusion ? thank you for this list regards Peter From ggb03124 at nifty.ne.jp Sun Oct 20 10:25:46 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Sun, 20 Oct 2002 10:25:46 +0900 Subject: [Apollo-talk:22] No such file to load -- rbconfig <= apollo problems In-Reply-To: References: Message-ID: <20021020093744.C417.GGB03124@nifty.ne.jp> Hi! "repeater" . This is take_tk in [Apollo-talk:21] apollo problems "repeater" wrote: : 1.) the latest version (ap-635_vcl60.zip) does not operate on my computer. : when executing apollo.exe i get: : " : No such file to load -- rbconfig (LoadError) : c:/ruby/apollo/bin/phi.rb:6:in `require' (1) Please show me the result of "dir /s c:\rbconfig.rb". My result is as follows; ---- C:\Program Files\Apollo\lib\ruby\1.6\i586-mswin32>dir /s c:\rbconfig.rb c:\Program Files\Apollo\lib\ruby\1.6\i586-mswin32 # <== OK 2002/03/01 23:30 3,558 rbconfig.rb c:\Program Files\Ruby\lib\ruby\1.6\i586-mswin32 2002/03/02 01:23 3,559 rbconfig.rb C:\Program Files\Apollo\lib\ruby\1.6\i586-mswin32> ---- (2) and the result of "puts $:" after editing phi.rb as follows; ---- #!/usr/bin/env ruby $:.push File.expand_path(File.join(File.dirname(__FILE__), '../lib')) $:.push File.expand_path(File.dirname(__FILE__)) # v: comment out unless "require 'win32.rb'". #require 'rbconfig' #if /win32/ =~ Config::CONFIG['arch'] require 'win32.rb' #else # require 'linux.rb' #end puts $: ---- My result is as follows; ---- c:/program files/apollo/bin C:/Program Files/Apollo/lib/ruby/site_ruby/1.6 C:/Program Files/Apollo/lib/ruby/site_ruby/1.6/i586-mswin32 # <= OK C:/Program Files/Apollo/lib/ruby/site_ruby C:/Program Files/Apollo/lib/ruby/1.6 C:/Program Files/Apollo/lib/ruby/1.6/i586-mswin32 . C:/Program Files/Apollo/bin c:/program files/apollo/lib c:/program files/apollo/bin Apollo console with Phi library version 0.635_vcl60 Phi::PLATFORM=WIN32, Phi::COMPOLIB=VCL control_tree.rb shows controls of Apollo.exe itself. -- Phi::SCREEN .... ---- take_tk = kumagai hidetake From repeater at lucentprimate.cjb.net Sun Oct 20 19:25:59 2002 From: repeater at lucentprimate.cjb.net (repeater) Date: Sun, 20 Oct 2002 12:25:59 +0200 Subject: [Apollo-talk:23] Re: No such file to load -- rbconfig <= apollo problems In-Reply-To: <20021020093744.C417.GGB03124@nifty.ne.jp> Message-ID: > Hi! "repeater" . This is take_tk > hello take_tk > in [Apollo-talk:21] apollo problems > "repeater" wrote: > : 1.) the latest version (ap-635_vcl60.zip) does not operate on > my computer. > : when executing apollo.exe i get: > : " > : No such file to load -- rbconfig (LoadError) > : c:/ruby/apollo/bin/phi.rb:6:in `require' > > (1) Please show me the result of "dir /s c:\rbconfig.rb". > My result is as follows; > > ---- > C:\Program Files\Apollo\lib\ruby\1.6\i586-mswin32>dir /s c:\rbconfig.rb > > c:\Program Files\Apollo\lib\ruby\1.6\i586-mswin32 # <== OK > 2002/03/01 23:30 3,558 rbconfig.rb > > c:\Program Files\Ruby\lib\ruby\1.6\i586-mswin32 > 2002/03/02 01:23 3,559 rbconfig.rb > > C:\Program Files\Apollo\lib\ruby\1.6\i586-mswin32> > ---- so apollo apparently require its own version of ruby. what is the reason behind this ? strange, my previous version i have worked with used my normal ruby distribution (well apparently, i've installed it manually). i would prefer this. anyway, i've downloaded ap-635_bde60.msi, and it is now working. thanks for the help regards Peter From ggb03124 at nifty.ne.jp Sun Oct 20 22:28:30 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Sun, 20 Oct 2002 22:28:30 +0900 Subject: [Apollo-talk:24] Re: No such file to load -- rbconfig <= apollo problems In-Reply-To: References: <20021020093744.C417.GGB03124@nifty.ne.jp> Message-ID: <20021020214833.C6AF.GGB03124@nifty.ne.jp> Hi! This is take_tk on [Apollo-talk:23] Re: No such file to load -- rbconfig "repeater" wrote: : so apollo apparently require its own version of ruby. I don't think so. My apollo.exe can run under the ruby.dll of other distribution, when I invalidated the ruby.dll in apollo/bin directory. * c:/program file/ruby is for ActiveScriptRuby with Ruby1.6.2, and PATH env has its directory. and there is "c:\Program Files\Ruby\lib\ruby\1.6\i586-mswin32\rbconfig.rb" (1) invalidate ruby.dll in apollo/bin -- C:\Program Files\Apollo\bin>dir *.dll 2001/07/13 06:00 105,472 dbexpdb2.dll 2002/02/22 14:02 119,296 dbexpint.dll 2001/07/13 06:00 91,136 dbexpmys.dll 2002/03/18 06:02 92,160 dbexpmysql.dll 2002/03/18 06:02 165,376 dbexpora.dll 2002/03/18 06:02 293,888 midas.dll 2002/04/01 11:42 990,506 mswin32-ruby16.dll C:\Program Files\Apollo\bin>ren mswin32-ruby16.dll mswin32-ruby16.dll_ C:\Program Files\Apollo\bin>dir *.dll 2001/07/13 06:00 105,472 dbexpdb2.dll 2002/02/22 14:02 119,296 dbexpint.dll 2001/07/13 06:00 91,136 dbexpmys.dll 2002/03/18 06:02 92,160 dbexpmysql.dll 2002/03/18 06:02 165,376 dbexpora.dll 2002/03/18 06:02 293,888 midas.dll 2002/04/01 11:42 990,506 mswin32-ruby16.dll_ <= invalidated! -- (2) apollo.exe shows its $:, which shows "c:/program files/ruby" instead of "c:/program files/apollo" -- c:/program files/apollo/bin C:/Program Files/Ruby/lib/ruby/site_ruby/1.6 C:/Program Files/Ruby/lib/ruby/site_ruby/1.6/i586-mswin32 C:/Program Files/Ruby/lib/ruby/site_ruby C:/Program Files/Ruby/lib/ruby/1.6 C:/Program Files/Ruby/lib/ruby/1.6/i586-mswin32 . C:/Program Files/Apollo/bin c:/program files/apollo/lib c:/program files/apollo/bin -- I think trouble in using the ruby.dll of other distribution occurs from the reason of Environment Variable "PATH" of windows. : strange, my previous version i have worked with used my normal ruby : distribution (well apparently, i've installed it manually). i would prefer : this. I also think it is strange. Please tell me how to change ruby.dll(s) to use. Or, please try to invalidate ruby.dll in apollo/bin. Hmm.. Is there "c:\Ruby\lib\ruby\1.6\i586-mswin32\rbconfig.rb" ? take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Sun Oct 20 22:52:48 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Sun, 20 Oct 2002 22:52:48 +0900 Subject: [Apollo-talk:25] Re: apollo problems In-Reply-To: References: Message-ID: <20021020223248.C6B2.GGB03124@nifty.ne.jp> Hi! in [Apollo-talk:21] apollo problems "repeater" wrote: : 2.) is it possible to use ruby 1.7 with apollo ? i've tried and failed (it : looks for that mswin32-ruby16.dll file, now named : mswin32-ruby17.dll. the directories containing "1.6" also changed name, it : seems) Mr. moriq announced that apollo has been able to use "mswin32-ruby17.dll" in "[ap-dev:0783] ap-635d Thu, 03 Oct 2002 19:50:53 +0900" The announce is before the announce of "[ap-list:2927] ap-635 Sun, 06 Oct 2002 03:17:56 +0900" http://www.moriq.com/apollo/archive/ap-635_vcl60.zip http://homepage1.nifty.com/moriq/ap-635_bde60.msi So, I think ap-635_xxx can use ruby 1.7. But I did not try yet. : 3.) in the development of a project, i've found the following features of : delphi missing in apollo: : Popupmenu : popup_component : popup_point : MenuItem : clear (can be faked with while loop and delete(), but : slower i think) : Shape : on_mouse_down : on_mouse_move : on_mouse_up Popupmenu#popup_component and Popupmenu#popup_point seem "not yet" I wonder MenuItem#clear seems to have some problem, at least in my script. But I did not investigate it precisely. -- require "phi" puts Phi::VERSION #=> 0.635_vcl60 puts Phi::MenuItem.instance_methods.select{|n| /^cl/=~n}.sort #=> clear #=> click puts Phi::PopupMenu.instance_methods.select{|n| /^p/ =~ n}.sort #=> parent #=> parent_bi_di_mode #=> parent_bi_di_mode= #=> parent_bi_di_mode? #=> popup puts Phi::Shape.instance_methods.select{|n| /^on_m/ =~ n}.sort #=> on_mouse_down #=> on_mouse_down= #=> on_mouse_move #=> on_mouse_move= #=> on_mouse_up #=> on_mouse_up= -- : i've circumvented all of the above with rather clumsy code, but is there a : reason for their exclusion ? There may be no reason of exclusion, other than "not yet". take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Mon Oct 21 10:29:43 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Mon, 21 Oct 2002 10:29:43 +0900 Subject: [Apollo-talk:26] Re: apollo problems In-Reply-To: References: Message-ID: <20021021102000.977B.GGB03124@nifty.ne.jp> This is tale_tk in [Apollo-talk:21] apollo problems "repeater" wrote: > 2.) is it possible to use ruby 1.7 with apollo ? i've tried and failed (it > looks for that mswin32-ruby16.dll file, now named > mswin32-ruby17.dll. the directories containing "1.6" also changed name, it > seems) Moriq's patches from [ap-dev:0816] http://www.freeml.com/message/ap-dev at freeml.com/0000816 > 2.) is it possible to use ruby 1.7 with apollo ? -- $(APOLLO)/src/ruby/type.pas: -- const RubyDLL = {$IFDEF LINUX} 'libruby.so' {$ENDIF} {$IFDEF MSWINDOWS} 'mswin32-ruby16.dll' //'msvcrt-ruby17.dll' {$ENDIF} ; -- > Popupmenu > popup_component > popup_point -- uMenu.pas: - uIntern, uHandle, uAlloc, uProp, uPhi, + uIntern, uHandle, uAlloc, uProp, uPhi, uPoint, function PopupMenu_get_popup_point(This: Tvalue): Tvalue; cdecl; var real: TPopupMenu; begin real := ap_data_get_struct(This); result := ap_iPoint(real.PopupPoint, This); end; function PopupMenu_get_popup_component(This: Tvalue): Tvalue; cdecl; var real: TPopupMenu; Component: TComponent; begin real := ap_data_get_struct(This); Component := real.PopupComponent; if Component = nil then result := Qnil else result := Component.tag ; end; function PopupMenu_set_popup_component(This, v: Tvalue): Tvalue; cdecl; var real: TPopupMenu; Component: TComponent; begin real := ap_data_get_struct(This); ap_data_get_object(v, TComponent, Component); real.PopupComponent := Component; result := v; end; DefineAttrGet(cPopupMenu, 'popup_point', PopupMenu_get_popup_point); DefineAttrGet(cPopupMenu, 'popup_component', PopupMenu_get_popup_component); DefineAttrSet(cPopupMenu, 'popup_component', PopupMenu_set_popup_component); -- > MenuItem > clear MenuItem_clear is already implemented. Can not you use it? > Shape > on_mouse_down > on_mouse_move > on_mouse_up Shape#event_handle is missing! uShape.pas: - uDefUtils, uIntern, uAlloc, uProp, uSizeConstraints, + uDefUtils, uIntern, uHandle, uAlloc, uProp, uSizeConstraints, function Shape_event_handle(This, name: Tvalue): Tvalue; cdecl; begin EventHandle(This, name, [Handle]); result := Qnil; end; rb_define_method(cShape, 'event_handle', @Shape_event_handle, 1); ---- Take_tk = KUMAGAI Hidetake From repeater at lucentprimate.cjb.net Mon Oct 21 22:52:33 2002 From: repeater at lucentprimate.cjb.net (repeater) Date: Mon, 21 Oct 2002 15:52:33 +0200 Subject: [Apollo-talk:27] Re: No such file to load -- rbconfig <= apollo problems In-Reply-To: <20021020214833.C6AF.GGB03124@nifty.ne.jp> Message-ID: hello > on [Apollo-talk:23] Re: No such file to load -- rbconfig > "repeater" wrote: > > : so apollo apparently require its own version of ruby. > > I don't think so. My apollo.exe can run under the ruby.dll of other > distribution, when I invalidated the ruby.dll in apollo/bin directory. that is good to hear > > * c:/program file/ruby is for ActiveScriptRuby with Ruby1.6.2, and > PATH env has its directory. and there is > "c:\Program Files\Ruby\lib\ruby\1.6\i586-mswin32\rbconfig.rb" > > (1) invalidate ruby.dll in apollo/bin > -- > C:\Program Files\Apollo\bin>dir *.dll > 2001/07/13 06:00 105,472 dbexpdb2.dll > 2002/02/22 14:02 119,296 dbexpint.dll > 2001/07/13 06:00 91,136 dbexpmys.dll > 2002/03/18 06:02 92,160 dbexpmysql.dll > 2002/03/18 06:02 165,376 dbexpora.dll > 2002/03/18 06:02 293,888 midas.dll > 2002/04/01 11:42 990,506 mswin32-ruby16.dll > > C:\Program Files\Apollo\bin>ren mswin32-ruby16.dll mswin32-ruby16.dll_ > > C:\Program Files\Apollo\bin>dir *.dll > 2001/07/13 06:00 105,472 dbexpdb2.dll > 2002/02/22 14:02 119,296 dbexpint.dll > 2001/07/13 06:00 91,136 dbexpmys.dll > 2002/03/18 06:02 92,160 dbexpmysql.dll > 2002/03/18 06:02 165,376 dbexpora.dll > 2002/03/18 06:02 293,888 midas.dll > 2002/04/01 11:42 990,506 mswin32-ruby16.dll_ <= invalidated! > -- i did this, and it crashes with an access violation in mswin32-ruby16.dll (i thus assume it finds the dll, since there remains only one other such file on my computer) i have this situation: in directory "old_apollo" -> run AppPath.exe, run Apollo.exe, old apollo works in directory "apollo" (new version) -> run AppPath.exe, run Apollo.exe, new apollo crashes so as i consider it, one of the following: 1.) i am using an incompatible version of ruby currently ruby 1.6.6, perhaps it needs ruby 1.6.7 ? i am using the pragmatic programmer distribution 2.) there is some directory setup that i'm missing (but unlikely) does this have something to do with set_path_for_ruby.rb ? what does this do btw ? > > (2) apollo.exe shows its $:, which shows "c:/program files/ruby" instead > of "c:/program files/apollo" > > -- > c:/program files/apollo/bin > C:/Program Files/Ruby/lib/ruby/site_ruby/1.6 > C:/Program Files/Ruby/lib/ruby/site_ruby/1.6/i586-mswin32 > C:/Program Files/Ruby/lib/ruby/site_ruby > C:/Program Files/Ruby/lib/ruby/1.6 > C:/Program Files/Ruby/lib/ruby/1.6/i586-mswin32 > . > C:/Program Files/Apollo/bin > c:/program files/apollo/lib > c:/program files/apollo/bin i do not see this, because it crashes > -- > > I think trouble in using the ruby.dll of other distribution occurs > from the reason of Environment Variable "PATH" of windows. my path variable is set, i've been using old version successfully for ages > > : strange, my previous version i have worked with used my normal ruby > : distribution (well apparently, i've installed it manually). i > would prefer > : this. > > I also think it is strange. Please tell me how to change ruby.dll(s) > to use. > > Or, please try to invalidate ruby.dll in apollo/bin. > > Hmm.. Is there "c:\Ruby\lib\ruby\1.6\i586-mswin32\rbconfig.rb" ? i guess my problem with rbconfig is solved: it found the mswin32-ruby16.dll in the apollo directory, and searched for the ruby libs there and did not find it. with the ruby libs placed in apollo lib dir, everything works fine. regards Peter From ggb03124 at nifty.ne.jp Tue Oct 22 01:01:07 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Tue, 22 Oct 2002 01:01:07 +0900 Subject: [Apollo-talk:28] Re: No such file to load -- rbconfig <= apollo problems In-Reply-To: References: <20021020214833.C6AF.GGB03124@nifty.ne.jp> Message-ID: <20021021235953.CBB4.GGB03124@nifty.ne.jp> Hi! [Apollo-talk:27] Re: No such file to load -- rbconfig <= apollo problems "repeater" wrote: : > Hmm.. Is there "c:\Ruby\lib\ruby\1.6\i586-mswin32\rbconfig.rb" ? : : i guess my problem with rbconfig is solved: : it found the mswin32-ruby16.dll in the apollo directory, and searched for : the ruby libs there and did not find it. with the ruby libs placed in apollo : lib dir, everything works fine. I see. The easiest solution is.. C:/Program Files/Apollo/bin/phi.rb ---- #require 'rbconfig' #if /win32/ =~ Config::CONFIG['arch'] # require 'win32.rb' #else # require 'linux.rb' #end # || # vv require 'win32.rb' ---- take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Thu Oct 24 01:15:18 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Thu, 24 Oct 2002 01:15:18 +0900 Subject: [Apollo-talk:29] Late assignment of Delphi event handlers Message-ID: <20021024003201.D25E.GGB03124@nifty.ne.jp> Hi! This is take_tk. FROM [ap-dev:0479] ap-633b Late assignment of Delphi event handlers Fri, 10 May 2002 In order to improve execution speed, Apollo-633b or later version adopted a "late assignment of Delphi event handlers". * In current version, the structure is implemented in "C:/Program Files/Apollo/bin/phi.rb" as follows; -- module Phi EventHandle = {} class Persistent private def singleton_method_added(id) p [:s, id] if $DEBUG return unless self.respond_to? :event_handle case id.to_s when /^on_/, /^after_/, /^before_/ self.event_handle id end end def Persistent.method_added(id) p [:m, id] if $DEBUG case id.to_s when /^on_/, /^after_/, /^before_/ if EventHandle[self].nil? EventHandle[self] = [] end EventHandle[self].push id end end ... def initialize(*args) super(*args) if EventHandle[type] EventHandle[type].each do|id| begin event_handle id rescue DelphiError # end end end end end end ---- This means, when "initialize" method is defined in a inherited class, if it does not carry out "super", Persistent#initialize is no longer called. Therefore, event handlers are no longer initialized. Mr. "repeater" reported following phenomenon; In the following program, on_click handler is not work, if "super" is comment-outed in the definition of "initialize" method. -- #! ruby -Ks require "phi" class MyPanel < Phi::Panel def on_click p "MyPanel#on_click" end def initialize( *args ) #super( *args ) #<= uncomment this to make test work. why ? end end form = Phi::Form.new MyPanel.new form form.show Phi.mainloop -- How to succeed is under examination even if there is no continuation of "super". --- I don't know whether this relates, but Mr. Sakurai reported that Ruby version 1.6.6 does not work well but 1.6.7 or more well. [ap-dev:0491] take_tk = kumagai hidetake From ajksharma at myrealbox.com Thu Oct 24 02:29:41 2002 From: ajksharma at myrealbox.com (ajay sharma) Date: Wed, 23 Oct 2002 22:59:41 +0530 Subject: [Apollo-talk:30] Re: Late assignment of Delphi event handlers References: <20021024003201.D25E.GGB03124@nifty.ne.jp> Message-ID: <007a01c27ab9$c71dc2b0$5b0610ac@mainserver> HI Take_tk, Thanks for your efforts! Regards ajay sharma <----- Original Message ----- Hi! This is take_tk. FROM [ap-dev:0479] ap-633b Late assignment of Delphi event handlers Fri, 10 May 2002 In order to improve execution speed, Apollo-633b or later version adopted a "late assignment of Delphi event handlers". * In current version, the structure is implemented in "C:/Program Files/Apollo/bin/phi.rb" as follows; -- > From ggb03124 at nifty.ne.jp Sun Oct 27 17:02:54 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Sun, 27 Oct 2002 17:02:54 +0900 Subject: [Apollo-talk:31] Config.bat <== building apollo and something weird In-Reply-To: References: Message-ID: <20021027170232.45AB.GGB03124@nifty.ne.jp> Hi! This is take_tk's very relayed reply on "building apollo and something weird" "repeater" wrote: : just a few misc notes: : 1) i've run the config.bat system, but there is a few places with output : directory "d:\apollo" remaining that i had to change manually. I see such phenomenon. The "config.bat" runs according to "$(Apollo)/bin/conf_opt.rb". The contents thereof by default is as follows; -- DELPHI_VERSION = 6 DELPHI_EDITION = 'ent' DIR_PAIR_LIST = [ ['C:\DelphiX\Source', 'D:\DelphiX\Source'], ['C:\Program Files\Borland\Delphi6\Lib', 'D:\usr\lib\delphi'], ['C:\Program Files\Borland\Delphi6', 'D:\Borland\Delphi6'], ['C:\Program Files\apollo', 'D:\apollo'], ] -- DELPHI_EDITION must be 'ent' / 'pro' or 'per' which shows Delphi version you use. The right sides of DIR_PAIR_LIST are your directory which you use. If your Apollo is installed in "c:\apollo", you must rewrite last line of DIR_PAIR_LIST from 'D:\apollo' to 'c:\apollo'. ['C:\Program Files\apollo', 'c:\apollo'], If your apollo is installed in "c:\program files\apollo" or your Delphi is installed 'C:\Program Files\Borland\Delphi6', I recommend to comment out the lines which you do not want to change. like this; -- DELPHI_VERSION = 6 DELPHI_EDITION = 'pro' # <= My Delphi is version 6 professional DIR_PAIR_LIST = [ # ['C:\DelphiX\Source', 'D:\DelphiX\Source'], # ['C:\Program Files\Borland\Delphi6\Lib', 'D:\usr\lib\delphi'], # ['C:\Program Files\Borland\Delphi6', 'D:\Borland\Delphi6'], # ['C:\Program Files\apollo', 'D:\apollo'], ] -- The left sides are directories distributed. The right sides are user's directories. I feel "D:\apollo" is the Moriq's directory. take_tk = kumagai hidetake From ajksharma at myrealbox.com Mon Oct 28 12:14:29 2002 From: ajksharma at myrealbox.com (ajay sharma) Date: Mon, 28 Oct 2002 08:44:29 +0530 Subject: [Apollo-talk:32] Installing ruby pakages in Apollo. References: <20021027170232.45AB.GGB03124@nifty.ne.jp> Message-ID: <008e01c27e31$79747dd0$5b0610ac@mainserver> Hi all, While using the "orignal" ruby installation we use , "ruby install.rb". If I want to install ruby packages like 'Rexml', 'yaml' etc to work in apollo , what are the steps. I have not installed the "orignal" ruby installation, just apollo. Now in my apollo/bin directory I have the following executables, Apollo.exe, Apollo_q.exe, ruby_ap.exe, ruby_aw.exe. Which executable should I use to install packages? I hope my question is clear. Regards ajay sharma From ggb03124 at nifty.ne.jp Mon Oct 28 13:58:45 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Mon, 28 Oct 2002 13:58:45 +0900 Subject: [Apollo-talk:33] Re: Installing ruby pakages in Apollo. In-Reply-To: <008e01c27e31$79747dd0$5b0610ac@mainserver> References: <20021027170232.45AB.GGB03124@nifty.ne.jp> <008e01c27e31$79747dd0$5b0610ac@mainserver> Message-ID: <20021028134907.9291.GGB03124@nifty.ne.jp> [Apollo-talk:32] Installing ruby packages in Apollo. "ajay sharma" wrote: > Hi all, > While using the "orignal" ruby installation we use , "ruby install.rb". > If I want to install ruby packages like 'Rexml', 'yaml' etc to work in > apollo , what are the steps. > I have not installed the "orignal" ruby installation, just apollo. > > Now in my apollo/bin directory I have the following executables, > Apollo.exe, Apollo_q.exe, ruby_ap.exe, ruby_aw.exe. > Which executable should I use to install packages? > I hope my question is clear. I tried to run "G:/DOWNLOAD/rexml_2.5.2/rexml/bin/install.rb" by apollo.exe. Then I got following messages in the apollo-console. And I confirmed many files and directory were created under the directory "C:/Program Files/Apollo/lib/ruby/site_ruby/1.6/rexml/" Isn't this what you want? -- Installing in C:/Program Files/Apollo/lib/ruby/site_ruby/1.6 rexml/xmltokens.rb -> C:/Program Files/Apollo/lib/ruby/site_ruby/1.6/rexml/xmltokens.rb chmod 0644 C:/Program Files/Apollo/lib/ruby/site_ruby/1.6/rexml/xmltokens.rb .... rexml/encodings/UTF-16.rb -> C:/Program Files/Apollo/lib/ruby/site_ruby/1.6/rexml/encodings/UTF-16.rb chmod 0644 C:/Program Files/Apollo/lib/ruby/site_ruby/1.6/rexml/encodings/UTF-16.rb -- take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Mon Oct 28 14:02:16 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Mon, 28 Oct 2002 14:02:16 +0900 Subject: [Apollo-talk:34] Re: Config.bat <== building apollo and something weird In-Reply-To: <20021027170232.45AB.GGB03124@nifty.ne.jp> References: <20021027170232.45AB.GGB03124@nifty.ne.jp> Message-ID: <20021028140021.9294.GGB03124@nifty.ne.jp> > Hi! This is take_tk's very relayed reply ^^^^^^^ delayed Take_tk = KUMAGAI Hidetake From repeater at lucentprimate.cjb.net Mon Oct 28 23:54:41 2002 From: repeater at lucentprimate.cjb.net (repeater) Date: Mon, 28 Oct 2002 16:54:41 +0200 Subject: [Apollo-talk:35] Re: Late assignment of Delphi event handlers In-Reply-To: <20021024003201.D25E.GGB03124@nifty.ne.jp> Message-ID: <..> > -- > #! ruby -Ks > require "phi" > > class MyPanel < Phi::Panel > def on_click > p "MyPanel#on_click" > end > def initialize( *args ) > #super( *args ) #<= uncomment this to make test work. why ? > end > end > > form = Phi::Form.new > MyPanel.new form > > form.show > Phi.mainloop > -- > > How to succeed is under examination even if there is no continuation of > "super". > if i gather correctly, the new behaviour is intended for performance reasons, and that is fine. but could you supply a solution to make the following work ? -- require 'phi' class MyPanel < Phi::Panel def on_click p "MyPanel#on_click" end def initialize( *args ) super( *args ) #added end end class SuperMyPanel < MyPanel def initialize( *args ) super( *args ) end end form = Phi::Form.new SuperMyPanel.new form form.show Phi.mainloop -- SuperMyPanel should inherit MyPanel's events thanks regards re~ From repeater at lucentprimate.cjb.net Wed Oct 30 08:13:14 2002 From: repeater at lucentprimate.cjb.net (repeater) Date: Wed, 30 Oct 2002 01:13:14 +0200 Subject: [Apollo-talk:36] division by zero bug? In-Reply-To: Message-ID: -- require 'phi' form = Phi::Form.new # <= comment out to make this working puts(3/2.0) Phi.mainloop -- err msg: 3: in `to_s': Floating point division by zero (EZeroDivide) it seems that to_s is overriden with a different, incomplete version. is this a bug ? i hate bugs... if this is the case, the developers should really consider creating a comprehensive test system. i have never used it, but perhaps utilising rubicon [http://www.pragmaticprogrammer.com/ruby/downloads/rubicon.html] in some way or another. regards re~ From ggb03124 at nifty.ne.jp Wed Oct 30 23:18:01 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Wed, 30 Oct 2002 23:18:01 +0900 Subject: [Apollo-talk:37] Re: division by zero bug? In-Reply-To: References: Message-ID: <20021030223838.CB28.GGB03124@nifty.ne.jp> Hi! "repeater" This is take_tk [Apollo-talk:36] division by zero bug? "repeater" wrote: : -- : require 'phi' : form = Phi::Form.new # <= comment out to make this working : puts(3/2.0) : Phi.mainloop : -- : : err msg: : 3: in `to_s': Floating point division by zero (EZeroDivide) My apollo did not show such error. Do you used Ruby 1.7.2? -- But I experienced such error twice. (1) [ap-list:1091] Cause: Ruby's floating point to string converter function used zero-division exception. But Delphi's error handler of floating point was differ from Ruby's one. So, we inserted following code. asm FInit; end; (2) [ap-list:2373] Cause: Compiler options for making ruby.dll were not correct. take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Wed Oct 30 23:53:11 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Wed, 30 Oct 2002 23:53:11 +0900 Subject: [Apollo-talk:38] Re: Late assignment of Delphi event handlers In-Reply-To: References: <20021024003201.D25E.GGB03124@nifty.ne.jp> Message-ID: <20021030235230.CB2D.GGB03124@nifty.ne.jp> Hi! This is take_tk [Apollo-talk:35] Re: Late assignment of Delphi event handlers "repeater" wrote: Short solution is add "self.on_click = nil" in MyPanel#initialize which teaches to apollo that on_click event is defined in this class. : -- : require 'phi' : class MyPanel < Phi::Panel : def on_click : p "MyPanel#on_click" : end : def initialize( *args ) : super( *args ) #added self.on_click = nil #++ to teach on_click is defined to apollo : end : end : : class SuperMyPanel < MyPanel : def initialize( *args ) : super( *args ) : end : end : : form = Phi::Form.new : SuperMyPanel.new form : form.show : Phi.mainloop : -- ---- I'm now discussing with Mr. moriq how to realise the inheritance system of modified event handlers in apollo. Basically to say, event handlers are not member of classes in Delphi. ie. TForm1.Button1Click is not member of TButton. So, inheritance system of event handler is not exist. But, in Delphi style, such modification of event handling is realized by overriding the "event handler caller" function. Such as TControl.Click. Under the circumstances, how to realize it in Apollo.. take_tk = kumagai hidetake From ggb03124 at nifty.ne.jp Thu Oct 31 00:01:00 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Thu, 31 Oct 2002 00:01:00 +0900 Subject: [Apollo-talk:39] Troubles caused by Japanese character-code Message-ID: <20021030235408.CB2F.GGB03124@nifty.ne.jp> Hi! This is take_tk. I hope that someone (^^) will teach us concrete file name and line number where Japanese character-code or message causes trouble. take_tk = kumagai hidetake From repeater at lucentprimate.cjb.net Thu Oct 31 03:28:17 2002 From: repeater at lucentprimate.cjb.net (repeater) Date: Wed, 30 Oct 2002 20:28:17 +0200 Subject: [Apollo-talk:40] Re: division by zero bug? In-Reply-To: <20021030223838.CB28.GGB03124@nifty.ne.jp> Message-ID: > Hi! "repeater" > This is take_tk > > [Apollo-talk:36] division by zero bug? > "repeater" wrote: > > : -- > : require 'phi' > : form = Phi::Form.new # <= comment out to make this working > : puts(3/2.0) > : Phi.mainloop > : -- > : > : err msg: > : 3: in `to_s': Floating point division by zero (EZeroDivide) > > My apollo did not show such error. > Do you used Ruby 1.7.2? no, the normal 635 version. hmm it works with apollo.exe, but fails when ran with ruby_ap and just clarifying my problem, it is when printing floats, of course: require 'phi' form = Phi::Form.new puts(Math::PI) Phi.mainloop regards re~ From ggb03124 at nifty.ne.jp Thu Oct 31 17:47:38 2002 From: ggb03124 at nifty.ne.jp (Take_tk) Date: Thu, 31 Oct 2002 17:47:38 +0900 Subject: [Apollo-talk:41] Re: division by zero bug? In-Reply-To: References: <20021030223838.CB28.GGB03124@nifty.ne.jp> Message-ID: <20021031173100.9959.GGB03124@nifty.ne.jp> Hi! "repeater" Thank you for your report. > no, the normal 635 version. > hmm it works with apollo.exe, but fails when ran with ruby_ap I conformed the bug, and Mr. moriq announced that he is trying to fix this bug. [ap-dev:0848] -- > require 'phi' > form = Phi::Form.new print "" #++ <== hint for bug fix > puts(Math::PI) > Phi.mainloop -- take_tk = kumagai hidetake