diff liboctave/cmd-edit.cc @ 7758:8e14a01ffe9f

input.cc (Fre_read_readline_init_file): new function
author John W. Eaton <jwe@octave.org>
date Mon, 05 May 2008 03:21:52 -0400
parents a1dbe9d80eee
children 78400fde223e
line wrap: on
line diff
--- a/liboctave/cmd-edit.cc	Mon May 05 03:10:16 2008 -0400
+++ b/liboctave/cmd-edit.cc	Mon May 05 03:21:52 2008 -0400
@@ -156,6 +156,8 @@
 
   void do_read_init_file (const std::string& file);
 
+  void do_re_read_init_file (void);
+
   bool do_filename_completion_desired (bool);
 
   bool do_filename_quoting_desired (bool);
@@ -560,6 +562,12 @@
   ::octave_rl_read_init_file (file.c_str ());
 }
 
+void
+gnu_readline::do_re_read_init_file (void)
+{
+  ::octave_rl_re_read_init_file ();
+}
+
 bool
 gnu_readline::do_filename_completion_desired (bool arg)
 {
@@ -1186,6 +1194,13 @@
     }
 }
 
+void
+command_editor::re_read_init_file (void)
+{
+  if (instance_ok ())
+    instance->do_re_read_init_file ();
+}
+
 bool
 command_editor::filename_completion_desired (bool arg)
 {