package stk

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Class Textlog.textlogSource

The textlog widgets to display log messages.

This widget inherits from Textview.textview and provides methods to display log messages.

val mutable log_cursor : Stk.Textview.B.cursor option

Properties

method max_size : int
method set_max_size : ?delay:float -> ?propagate:bool -> int -> unit

Property max_size.

Log-printing functions

Function 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 -> unit
method info : ?src:Logs.src -> string -> unit
method warn : ?src:Logs.src -> string -> unit
method error : ?src:Logs.src -> string -> unit
method app : ?src:Logs.src -> string -> unit
method insert_msg : ?src:Logs.src -> tags:Stk.Texttag.T.t list -> string -> unit

insert_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 raw : string -> unit

v#raw str prints message str with no tags and no source.

method print : ?src:Logs.src -> Logs.level -> string -> unit
OCaml

Innovation. Community. Security.