Frama_c_gui.Pretty_sourceUtilities to pretty print source with located elements in a Gtk TextBuffer.
type localizable = Frama_c_kernel.Printer_tag.localizablemodule Locs : sig ... endval fold_preconds_at_callsite : Frama_c_kernel.Cil_types.stmt -> unitval are_preconds_unfolded : Frama_c_kernel.Cil_types.stmt -> boolval display_source :
Frama_c_kernel.Cil_types.global list ->
GSourceView.source_buffer ->
host:Gtk_helper.host ->
highlighter:(localizable -> start:int -> stop:int -> unit) ->
selector:(button:int -> localizable -> unit) ->
Locs.state ->
unitThe selector and the highlighter are always host#protected. The selector will not be called when not !Gtk_helper.gui_unlocked. This clears the Locs.state passed as argument, then fills it.
val hilite : Locs.state -> unitval stmt_start : Locs.state -> Frama_c_kernel.Cil_types.stmt -> intOffset at which the current statement starts in the buffer corresponding to state, _without_ ACSL assertions/contracts, etc.
val locate_localizable : Locs.state -> localizable -> (int * int) optionval kf_of_localizable :
localizable ->
Frama_c_kernel.Cil_types.kernel_function optionval ki_of_localizable : localizable -> Frama_c_kernel.Cil_types.kinstrval varinfo_of_localizable :
localizable ->
Frama_c_kernel.Cil_types.varinfo optionval localizable_from_locs :
Locs.state ->
file:Frama_c_kernel.Datatype.Filepath.t ->
line:int ->
localizable listReturns the lists of localizable in file at line visible in the current Locs.state. This function is inefficient as it iterates on all the current Locs.state.