From: Enrico Tassi Date: Mon, 8 Dec 2008 14:02:53 +0000 (+0000) Subject: alt-l for not working nymore for \fox where x was in an eq class X-Git-Tag: make_still_working~4434 X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;h=a850f7bd35147a327c26330447c3d1748a449d09;p=helm.git alt-l for not working nymore for \fox where x was in an eq class --- diff --git a/helm/software/matita/matitaGui.ml b/helm/software/matita/matitaGui.ml index f0bd8acc0..7db4d5af1 100644 --- a/helm/software/matita/matitaGui.ml +++ b/helm/software/matita/matitaGui.ml @@ -651,7 +651,8 @@ class gui () = connect_menu_item main#ligatureButton self#nextSimilarSymbol; ignore(source_buffer#connect#after#insert_text ~callback:(fun iter str -> - if false && str = " " then self#expand_virtual_if_any iter " ")); + if false && str = " " then + ignore(self#expand_virtual_if_any iter " "))); ignore (findRepl#findEntry#connect#activate find_forward); (* interface lockers *) let lock_world _ = @@ -1107,8 +1108,9 @@ class gui () = ~stop:(iter#copy#backward_chars (MatitaGtkMisc.utf8_string_length inplaceof + len)); source_buffer#insert ~iter:(source_buffer#get_iter_at_mark `INSERT) - (if inplaceof.[0] = '\\' then s else (s ^ tok)) - with Virtuals.Not_a_virtual -> () + (if inplaceof.[0] = '\\' then s else (s ^ tok)); + true + with Virtuals.Not_a_virtual -> false method private nextSimilarSymbol () = let write_similarsymbol s = @@ -1130,21 +1132,20 @@ class gui () = with GText.No_such_mark _ -> true in if new_similarsymbol then + (if not(self#expand_virtual_if_any (source_buffer#get_iter_at_mark `INSERT) "")then let last_symbol = let i = source_buffer#get_iter_at_mark `INSERT in Glib.Utf8.first_char (i#get_slice ~stop:(i#copy#backward_chars 1)) in (match Virtuals.similar_symbols last_symbol with - | [] -> - let i = source_buffer#get_iter_at_mark `INSERT in - self#expand_virtual_if_any i "" + | [] -> () | hd :: next ::tl -> let hd, tl = if hd = last_symbol then next, tl @ [hd] else hd, (next::tl) in write_similarsymbol hd; similarsymbols <- tl @ [ hd ] - | _ -> assert false) (* singleton eq classes are a non sense *) + | _ -> assert false)) (* singleton eq classes are a non sense *) else match similarsymbols with | [] -> ()