From 209ec7628f7d64cac76f0edae5ca2be4c952ced5 Mon Sep 17 00:00:00 2001 From: ppedrot Date: Wed, 20 Feb 2013 15:49:13 +0000 Subject: CoqIDE: Including autocompletion in word proposals git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@16227 85f007b7-540e-0410-9357-904b9bb8a0f7 --- ide/wg_Completion.ml | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'ide/wg_Completion.ml') diff --git a/ide/wg_Completion.ml b/ide/wg_Completion.ml index c34190c8a..f0d327397 100644 --- a/ide/wg_Completion.ml +++ b/ide/wg_Completion.ml @@ -289,6 +289,17 @@ object (self) let () = model#handle_proposal path in self#hide () + method proposal = + let sel = data#selection#get_selected_rows in + if obj#misc#visible then match sel with + | [] -> None + | path :: _ -> + let row = model#store#get_iter path in + let column = model#column in + let proposal = model#store#get ~row ~column in + Some proposal + else None + method private manage_scrollbar () = (** HACK: we don't have access to the treeview size because of the lack of LablGTK binding for certain functions, so we bypass it by approximating -- cgit v1.2.3