diff options
Diffstat (limited to 'otherlibs/labltk/examples_camltk/fileinput.ml')
-rw-r--r-- | otherlibs/labltk/examples_camltk/fileinput.ml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/otherlibs/labltk/examples_camltk/fileinput.ml b/otherlibs/labltk/examples_camltk/fileinput.ml index 35e7e8358..c6190bdd4 100644 --- a/otherlibs/labltk/examples_camltk/fileinput.ml +++ b/otherlibs/labltk/examples_camltk/fileinput.ml @@ -23,7 +23,7 @@ let entry0_w = Entry.create top_w [] ;; let button0_w = Button.create top_w [Text "Quit"; Command (fun _ -> exit 0)] ;; Fileevent.add_fileinput fd_in (fun _ -> let n = Unix.read fd_in buffer 0 (String.length buffer) in - let txt = String.sub buffer 0 n in + let txt = String.sub buffer 0 n in Text.insert text0_w (TextIndex (End, [])) txt []) ;; let send _ = let txt = Entry.get entry0_w ^ "\n" in |