IDAPython 8.4
Loading...
Searching...
No Matches
outctx_base_t Class Reference

Proxy of C++ outctx_base_t class.

Inheritance diagram for outctx_base_t:
outctx_t

Public Member Functions

 __init__ (self, *args, **kwargs)
 
"bool" only_main_line (self, *args)
 only_main_line(self) -> bool
 
"bool" multiline (self, *args)
 multiline(self) -> bool
 
"bool" force_code (self, *args)
 force_code(self) -> bool
 
"bool" stack_view (self, *args)
 stack_view(self) -> bool
 
"bool" display_voids (self, *args)
 display_voids(self) -> bool
 
"void" set_gen_xrefs (self, *args)
 set_gen_xrefs(self, on=True)
 
"void" set_gen_cmt (self, *args)
 set_gen_cmt(self, on=True)
 
"void" clr_gen_label (self, *args)
 clr_gen_label(self)
 
"void" set_gen_label (self, *args)
 set_gen_label(self)
 
"void" set_gen_demangled_label (self, *args)
 set_gen_demangled_label(self)
 
"void" set_comment_addr (self, *args)
 set_comment_addr(self, ea)
 
"void" set_dlbind_opnd (self, *args)
 set_dlbind_opnd(self)
 
"bool" print_label_now (self, *args)
 print_label_now(self) -> bool
 
"int" forbid_annotations (self, *args)
 forbid_annotations(self) -> int
 
"void" restore_ctxflags (self, *args)
 restore_ctxflags(self, saved_flags)
 
"size_t" out_printf (self, *args)
 out_printf(self, format) -> size_t Functions to append text to the current output buffer (outbuf) Append a formatted string to the output string.
 
"flags64_t" out_value (self, *args)
 out_value(self, x, outf=0) -> flags64_t Output immediate value.
 
"void" out_symbol (self, *args)
 out_symbol(self, c) Output a character with COLOR_SYMBOL color.
 
"void" out_chars (self, *args)
 out_chars(self, c, n) Append a character multiple times.
 
"void" out_spaces (self, *args)
 out_spaces(self, len) Appends spaces to outbuf until its tag_strlen becomes 'len'.
 
"void" out_line (self, *args)
 out_line(self, str, color=0) Output a string with the specified color.
 
"void" out_keyword (self, *args)
 out_keyword(self, str) Output a string with COLOR_KEYWORD color.
 
"void" out_register (self, *args)
 out_register(self, str) Output a character with COLOR_REG color.
 
"void" out_tagon (self, *args)
 out_tagon(self, tag) Output "turn color on" escape sequence.
 
"void" out_tagoff (self, *args)
 out_tagoff(self, tag) Output "turn color off" escape sequence.
 
"void" out_addr_tag (self, *args)
 out_addr_tag(self, ea) Output "address" escape sequence.
 
"void" out_colored_register_line (self, *args)
 out_colored_register_line(self, str) Output a colored line with register names in it.
 
"void" out_char (self, *args)
 out_char(self, c) Output one character.
 
"void" out_btoa (self, *args)
 out_btoa(self, Word, radix=0) Output a number with the specified base (binary, octal, decimal, hex) The number is output without color codes.
 
"void" out_long (self, *args)
 out_long(self, v, radix) Output a number with appropriate color.
 
"bool" out_name_expr (self, *args)
 out_name_expr(self, x, ea, off=BADADDR) -> bool Output a name expression.
 
"void" close_comment (self, *args)
 close_comment(self)
 
"bool" flush_outbuf (self, *args)
 flush_outbuf(self, indent=-1) -> bool Functions to populate the output line array (lnar) Move the contents of the output buffer to the line array (outbuf->lnar) The kernel augments the outbuf contents with additional text like the line prefix, user-defined comments, xrefs, etc at this call.
 
"bool" flush_buf (self, *args)
 flush_buf(self, buf, indent=-1) -> bool Append contents of 'buf' to the line array.
 
"int" term_outctx (self, *args)
 term_outctx(self, prefix=None) -> int Finalize the output context.
 
"bool" gen_printf (self, *args)
 gen_printf(self, indent, format) -> bool printf-like function to add lines to the line array.
 
"bool" gen_empty_line (self, *args)
 gen_empty_line(self) -> bool Generate empty line.
 
"bool" gen_border_line (self, *args)
 gen_border_line(self, solid=False) -> bool Generate thin border line.
 
"bool" gen_cmt_line (self, *args)
 gen_cmt_line(self, format) -> bool Generate one non-indented comment line, colored with COLOR_AUTOCMT.
 
"bool" gen_collapsed_line (self, *args)
 gen_collapsed_line(self, format) -> bool Generate one non-indented comment line, colored with COLOR_COLLAPSED.
 
"bool" gen_block_cmt (self, *args)
 gen_block_cmt(self, cmt, color) -> bool Generate big non-indented comment lines.
 
"void" setup_outctx (self, *args)
 setup_outctx(self, prefix, makeline_flags) Initialization; normally used only by the kernel.
 
"ssize_t" retrieve_cmt (self, *args)
 retrieve_cmt(self) -> ssize_t
 
"ssize_t" retrieve_name (self, *args)
 retrieve_name(self, arg2, arg3) -> ssize_t
 
"bool" gen_xref_lines (self, *args)
 gen_xref_lines(self) -> bool
 
"void" init_lines_array (self, *args)
 init_lines_array(self, answers, maxsize)
 
"member_t *" get_stkvar (self, *args)
 get_stkvar(self, arg2, arg3, arg4, arg5) -> member_t *
 
"void" gen_empty_line_without_annotations (self, *args)
 gen_empty_line_without_annotations(self)
 
"flags64_t" getF (self, *args)
 getF(self) -> flags64_t
 

Properties

 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
 
 insn_ea = property(_ida_ua.outctx_base_t_insn_ea_get, _ida_ua.outctx_base_t_insn_ea_set, doc=)
 
 outbuf = property(_ida_ua.outctx_base_t_outbuf_get, _ida_ua.outctx_base_t_outbuf_set, doc=)
 
 F32 = property(_ida_ua.outctx_base_t_F32_get, _ida_ua.outctx_base_t_F32_set, doc=)
 
 default_lnnum = property(_ida_ua.outctx_base_t_default_lnnum_get, _ida_ua.outctx_base_t_default_lnnum_set, doc=)
 

Constructor & Destructor Documentation

◆ __init__()

__init__ ( self,
* args,
** kwargs )

Reimplemented in outctx_t.

Member Function Documentation

◆ close_comment()

"void" close_comment ( self,
* args )

◆ clr_gen_label()

"void" clr_gen_label ( self,
* args )

◆ display_voids()

"bool" display_voids ( self,
* args )

◆ flush_buf()

"bool" flush_buf ( self,
* args )

Behaves like flush_outbuf but accepts an arbitrary buffer

Parameters
buf(C++: const char *) char const *
indent(C++: int)

◆ flush_outbuf()

"bool" flush_outbuf ( self,
* args )
Parameters
indent(C++: int)

◆ forbid_annotations()

"int" forbid_annotations ( self,
* args )

◆ force_code()

"bool" force_code ( self,
* args )

◆ gen_block_cmt()

"bool" gen_block_cmt ( self,
* args )
Parameters
cmt(C++: const char *) comment text. may contain
characters to denote new lines. should not contain comment character (;)
color(C++: color_t) color of comment text (one of Color tags)
Returns
: overflow, lnar_maxsize has been reached

◆ gen_border_line()

"bool" gen_border_line ( self,
* args )

This function does nothing if generation of border lines is disabled.

Parameters
solid(C++: bool) generate solid border line (with =), otherwise with -
Returns
: overflow, lnar_maxsize has been reached

◆ gen_cmt_line()

"bool" gen_cmt_line ( self,
* args )
Parameters
format(C++: const char *) printf() style format line. The resulting comment line should not include comment character (;)
Returns
: overflow, lnar_maxsize has been reached

◆ gen_collapsed_line()

"bool" gen_collapsed_line ( self,
* args )
Parameters
format(C++: const char *) printf() style format line. The resulting comment line should not include comment character (;)
Returns
: overflow, lnar_maxsize has been reached

◆ gen_empty_line()

"bool" gen_empty_line ( self,
* args )

This function does nothing if generation of empty lines is disabled.

Returns
: overflow, lnar_maxsize has been reached

◆ gen_empty_line_without_annotations()

"void" gen_empty_line_without_annotations ( self,
* args )

◆ gen_printf()

"bool" gen_printf ( self,
* args )
Parameters
indent(C++: int) indention of the line. if indent == -1, the kernel will indent the line at idainfo::indent. if indent < 0, -indent will be used for indention. The first line printed with indent < 0 is considered as the most important line at the current address. Usually it is the line with the instruction itself. This line will be displayed in the cross-reference lists and other places. If you need to output an additional line before the main line then pass DEFAULT_INDENT instead of -1. The kernel will know that your line is not the most important one.
format(C++: const char *) printf style colored line to generate
Returns
: overflow, lnar_maxsize has been reached

◆ gen_xref_lines()

"bool" gen_xref_lines ( self,
* args )

Reimplemented in outctx_t.

◆ get_stkvar()

"member_t *" get_stkvar ( self,
* args )
Parameters
arg2op_t const &
arg3uval_t
arg4sval_t *
arg5int *

◆ getF()

"flags64_t" getF ( self,
* args )

◆ init_lines_array()

"void" init_lines_array ( self,
* args )
Parameters
answersqstrvec_t *
maxsizeint

◆ multiline()

"bool" multiline ( self,
* args )

◆ only_main_line()

"bool" only_main_line ( self,
* args )

◆ out_addr_tag()

"void" out_addr_tag ( self,
* args )
Parameters
ea(C++: ea_t)

◆ out_btoa()

"void" out_btoa ( self,
* args )

see also out_long()

Parameters
Word(C++: uval_t)
radix(C++: char)

Reimplemented in outctx_t.

◆ out_char()

"void" out_char ( self,
* args )

The character is output without color codes. see also out_symbol()

Parameters
c(C++: char)

◆ out_chars()

"void" out_chars ( self,
* args )
Parameters
c(C++: char)
n(C++: int)

◆ out_colored_register_line()

"void" out_colored_register_line ( self,
* args )

The register names will be substituted by user-defined names (regvar_t) Please note that out_tagoff tries to make substitutions too (when called with COLOR_REG)

Parameters
str(C++: const char *) char const *

◆ out_keyword()

"void" out_keyword ( self,
* args )
Parameters
str(C++: const char *) char const *

◆ out_line()

"void" out_line ( self,
* args )
Parameters
str(C++: const char *) char const *
color(C++: color_t)

◆ out_long()

"void" out_long ( self,
* args )

Low level function. Use out_value() if you can. if 'suspop' is set then this function uses COLOR_VOIDOP instead of COLOR_NUMBER. 'suspop' is initialized:

  • in out_one_operand()
  • in ..\ida\gl.cpp (before calling processor_t::d_out())
Parameters
v(C++: sval_t) value to output
radix(C++: char) base (2,8,10,16)

◆ out_name_expr()

"bool" out_name_expr ( self,
* args )
Parameters
x(C++: const op_t &) instruction operand referencing the name expression
ea(C++: ea_t) address to convert to name expression
off(C++: adiff_t) the value of name expression. this parameter is used only to check that the name expression will have the wanted value. You may pass BADADDR for this parameter but I discourage it because it prohibits checks.
Returns
: true if the name expression has been produced

◆ out_printf()

"size_t" out_printf ( self,
* args )
Parameters
format(C++: const char *) char const *
Returns
: the number of characters appended

◆ out_register()

"void" out_register ( self,
* args )
Parameters
str(C++: const char *) char const *

◆ out_spaces()

"void" out_spaces ( self,
* args )
Parameters
len(C++: ssize_t)

◆ out_symbol()

"void" out_symbol ( self,
* args )
Parameters
c(C++: char)

◆ out_tagoff()

"void" out_tagoff ( self,
* args )
Parameters
tag(C++: color_t)

◆ out_tagon()

"void" out_tagon ( self,
* args )
Parameters
tag(C++: color_t)

◆ out_value()

"flags64_t" out_value ( self,
* args )

Try to use this function to output all constants of instruction operands. This function outputs a number from x.addr or x.value in the form determined by F. It outputs colored text.

Parameters
x(C++: const op_t &) value to output
outf(C++: int) Output value flags
Returns
: flags of the output value, otherwise: -1 if printed a number with COLOR_ERROR 0 if printed a nice number or character or segment or enum

◆ print_label_now()

"bool" print_label_now ( self,
* args )

◆ restore_ctxflags()

"void" restore_ctxflags ( self,
* args )
Parameters
saved_flagsint

◆ retrieve_cmt()

"ssize_t" retrieve_cmt ( self,
* args )

Reimplemented in outctx_t.

◆ retrieve_name()

"ssize_t" retrieve_name ( self,
* args )
Parameters
arg2qstring *
arg3color_t *

Reimplemented in outctx_t.

◆ set_comment_addr()

"void" set_comment_addr ( self,
* args )
Parameters
eaea_t

◆ set_dlbind_opnd()

"void" set_dlbind_opnd ( self,
* args )

◆ set_gen_cmt()

"void" set_gen_cmt ( self,
* args )
Parameters
onbool

◆ set_gen_demangled_label()

"void" set_gen_demangled_label ( self,
* args )

◆ set_gen_label()

"void" set_gen_label ( self,
* args )

◆ set_gen_xrefs()

"void" set_gen_xrefs ( self,
* args )
Parameters
onbool

◆ setup_outctx()

"void" setup_outctx ( self,
* args )
Parameters
prefix(C++: const char *) char const *
makeline_flags(C++: int)

Reimplemented in outctx_t.

◆ stack_view()

"bool" stack_view ( self,
* args )

◆ term_outctx()

"int" term_outctx ( self,
* args )
Parameters
prefix(C++: const char *) char const *
Returns
: the number of generated lines.

Reimplemented in outctx_t.

Property Documentation

◆ default_lnnum

default_lnnum = property(_ida_ua.outctx_base_t_default_lnnum_get, _ida_ua.outctx_base_t_default_lnnum_set, doc=)
static

◆ F32

F32 = property(_ida_ua.outctx_base_t_F32_get, _ida_ua.outctx_base_t_F32_set, doc=)
static

◆ insn_ea

insn_ea = property(_ida_ua.outctx_base_t_insn_ea_get, _ida_ua.outctx_base_t_insn_ea_set, doc=)
static

◆ outbuf

outbuf = property(_ida_ua.outctx_base_t_outbuf_get, _ida_ua.outctx_base_t_outbuf_set, doc=)
static

◆ thisown

thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
static

The documentation for this class was generated from the following file: