Textlog.textlogSourceThe textlog widgets to display log messages.
This widget inherits from Textview.textview and provides methods to display log messages.
inherit Stk.Textview.textviewFunction for each log level inserts the given message with a tag associated to header characters: Texttag.tag_debug, Texttag.tag_info, Texttag.tag_warning, Texttag.tag_error or Texttag.tag_app.
The theme property of the widget will use this tag to display the message header with the required text properties.
method debug : ?src:Logs.src -> string -> unitmethod info : ?src:Logs.src -> string -> unitmethod warn : ?src:Logs.src -> string -> unitmethod error : ?src:Logs.src -> string -> unitmethod app : ?src:Logs.src -> string -> unitmethod insert_msg : ?src:Logs.src ->
tags:Stk.Texttag.T.t list ->
string ->
unitinsert_msg ?src ~tags str inserts the given message str. Optional argument src indicates the log source. If it is provided, then the message is preceded by the string "[source]" associated to given text tags. source is the log source name.
method print : ?src:Logs.src -> Logs.level -> string -> unit