The standard library Standard_Prettyprinter api defines the interface for the pkg::standard_prettyprinter package.
The Standard_Prettyprinter api is implemented by the standard_prettyprinter package.
The Standard_Prettyprinter api source code is in src/lib/prettyprint/big/src/standard-prettyprinter.api. The above information is manually maintained and may contain errors.
api { Private_State; Left_Margin_Is = BOX_RELATIVE {blanks:Int, tab_to:Int, tabstops_are_every:Int} | CURSOR_RELATIVE {blanks:Int, tab_to:Int, tabstops_are_every:Int}; Standard_Prettyprinter = {box:(Void -> Void) -> Void, box':Int -> Int -> (Void -> Void) -> Void, break':{ifnotwrap:{blanks:Int, tab_to:Int}, ifwrap:{blanks:Int, tab_to:Int}} -> Void, cbox:(Void -> Void) -> Void, cbox':Int -> Int -> (Void -> Void) -> Void, close:Void -> Void, cut:Void -> Void, cut':Int -> Int -> Void, cwrap:(Void -> Void) -> Void, cwrap':Int -> Int -> (Void -> Void) -> Void, default_left_margin_is:Left_Margin_Is, default_target_box_width:Int, default_wrap_policy:String, endlit:String -> Void, flush:Void -> Void, ind:Int -> Void, lit:String -> Void, newline:Void -> Void, pp:Private_State, rulename:String -> Void, tab:Void -> Void, tab':Int -> Int -> Void, tabstops_are_every:Int, txt:String -> Void, txt':Int -> Int -> String -> Void, wrap:(Void -> Void) -> Void, wrap':Int -> Int -> (Void -> Void) -> Void}; package typ : api { package out : api { Prettyprint_Output_Stream; Texttraits; same_texttraits : (Texttraits , Texttraits) -> Bool; push_texttraits : (Prettyprint_Output_Stream , Texttraits) -> Void; pop_texttraits : Prettyprint_Output_Stream -> Void; default_texttraits : Prettyprint_Output_Stream -> Texttraits; put_string : (Prettyprint_Output_Stream , String) -> Void; flush : Prettyprint_Output_Stream -> Void; close : Prettyprint_Output_Stream -> Void;};; Left_Margin_Is = BOX_RELATIVE {blanks:Int, tab_to:Int, tabstops_are_every:Int} | CURSOR_RELATIVE {blanks:Int, tab_to:Int, tabstops_are_every:Int}; Phase1_Token = BLANKS Int | BOX Box | BREAK Break | CONTROL out::Prettyprint_Output_Stream -> Void | ENDLIT String | INDENT Int | LIT String | NEWLINE | POP_TT | PUSH_TT out::Texttraits | TAB {blanks:Int, tab_to:Int, tabstops_are_every:Int}; Break = {ifnotwrap:{blanks:Int, tab_to:Int, tabstops_are_every:Int}, ifwrap:{blanks:Int, tab_to:Int, tabstops_are_every:Int}, wrap:Ref(Bool )}; Wrap_Policy = {code:{box_contents:List(Phase1_Token ), target_width:Int} -> {actual_box_width:Int, is_multiline:Bool}, name:String}; Box ={actual_width:Ref(Int ), contents:Ref(List(Phase1_Token ) ), id:Int, is_multiline:Ref(Bool ), left_margin_is:Left_Margin_Is, reversed_contents:Ref(List(Phase1_Token ) ), rulename:Ref(String ), target_width:Int, wrap_policy:Wrap_Policy}; Prettyprinter_Configuration_Args = DEFAULT_LEFT_MARGIN_IS Left_Margin_Is | DEFAULT_TARGET_BOX_WIDTH Int | DEFAULT_WRAP_POLICY Wrap_Policy | TABSTOPS_ARE_EVERY Int; Prettyprinter = {box:Ref(Box ), box_nesting:Ref(Int ), nested_boxes:Ref(List(Box ) ), next_box_id:Ref(Int ), output_stream:out::Prettyprint_Output_Stream, output_stream_is_closed:Ref(Bool ), texttraits_stack:Ref(List(out::Texttraits ) )}; package b : api { Phase2_Token = BLANKS Int | CONTROL out::Prettyprint_Output_Stream -> Void | ENDLIT String | LIT String | NEWLINE | POP_TT | PUSH_TT out::Texttraits;};; package c : api { Phase3_Token = BLANKS Int | CONTROL out::Prettyprint_Output_Stream -> Void | LIT String | NEWLINE | POP_TT | PUSH_TT out::Texttraits;};; package d : api { Phase4_Token = BLANKS Int | CONTROL out::Prettyprint_Output_Stream -> Void | LIT String | POP_TT | PUSH_TT out::Texttraits;};;};; Prettyprinter = Standard_Prettyprinter; Pp = Prettyprinter; Npp = Null_Or(Prettyprinter ); Prettyprint_Output_Stream; Traitful_Text; Texttraits; open_box : (Prettyprinter , typ::Left_Margin_Is , typ::Wrap_Policy , Int) -> Void; indent : (Prettyprinter , Int) -> Void; break' : ( Prettyprinter , {ifnotwrap:{blanks:Int, tab_to:Int, tabstops_are_every:Int}, ifwrap:{blanks:Int, tab_to:Int, tabstops_are_every:Int}} ) -> Void; horizontal : typ::Wrap_Policy; vertical : typ::Wrap_Policy; normal : typ::Wrap_Policy; ragged_right : typ::Wrap_Policy; make_prettyprinter : Prettyprint_Output_Stream -> List(typ::Prettyprinter_Configuration_Args ) -> Pp; process_mill_options : List(typ::Prettyprinter_Configuration_Args ) -> {default_left_margin_is:typ::Left_Margin_Is, default_target_box_width:Int, default_wrap_policy:typ::Wrap_Policy, tabstops_are_every:Int}; get_prettyprint_output_stream : Pp -> Prettyprint_Output_Stream; flush_prettyprinter : Pp -> Void; close_prettyprinter : Pp -> Void; traitful_text : Pp -> Traitful_Text -> Void; set_rulename_for_current_box : (Pp , String) -> Void; nblanks : Int -> String; shut_box : Pp -> Void; lit : Pp -> String -> Void; endlit : Pp -> String -> Void; break : Pp -> {blanks:Int, indent_on_wrap:Int} -> Void; blank : Pp -> Int -> Void; cut : Pp -> Void; newline : Pp -> Void; nonbreakable_blanks : Pp -> Int -> Void; tab : Pp -> {blanks:Int, tab_to:Int, tabstops_are_every:Int} -> Void; push_texttraits : (Pp , Texttraits) -> Void; pop_texttraits : Pp -> Void; control : Pp -> (Prettyprint_Output_Stream -> Void) -> Void; package box : api { Arg = FORMAT typ::Wrap_Policy | LEFT_MARGIN_IS typ::Left_Margin_Is | WIDTH Int;};; start_box : Standard_Prettyprinter -> List(box::Arg ) -> Void; seqx : (Void -> Void) -> (X -> Void) -> List(X ) -> Void; record : Prettyprinter -> String -> List(((String , (Void -> Void))) ) -> Void; tuple : Prettyprinter -> String -> List((Void -> Void) ) -> Void; tuplex : Prettyprinter -> (X -> Void) -> String -> List(X ) -> Void; listx : Prettyprinter -> (X -> Void) -> String -> List(X ) -> Void; block : Prettyprinter -> List((Void -> Void) ) -> Void; with_standard_prettyprinter : Prettyprint_Output_Stream -> List(typ::Prettyprinter_Configuration_Args ) -> (Prettyprinter -> Void) -> Void; prettyprint_to_string : List(typ::Prettyprinter_Configuration_Args ) -> (Prettyprinter -> Void) -> String; make_standard_prettyprinter_into_file : String -> List(typ::Prettyprinter_Configuration_Args ) -> Standard_Prettyprinter; make_standard_prettyprinter_into_buffer : List(typ::Prettyprinter_Configuration_Args ) -> {get_buffer_contents_and_clear_buffer:Void -> String, pp:Standard_Prettyprinter};};