Package ghidra.app.util.pcode

# Class AttributedStringPcodeFormatter

java.lang.Object
ghidra.app.util.pcode.AbstractPcodeFormatter<List<AttributedString>,ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender>
ghidra.app.util.pcode.AttributedStringPcodeFormatter

All Implemented Interfaces:
  `PcodeFormatter<List<AttributedString>>`

public class AttributedStringPcodeFormatter extends AbstractPcodeFormatter<List<AttributedString>,ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender>

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from class ghidra.app.util.pcode.AbstractPcodeFormatter

  `AbstractPcodeFormatter.FormatResult`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AttributedStringPcodeFormatter()`
  Constructor

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender`
  `createAppender(Language language, boolean indent)`
  Create the appender for a formatting invocation
  `protected AbstractPcodeFormatter.FormatResult`
  `formatOpTemplate(ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender appender, OpTpl op)`
  Format a single op template
  `boolean`
  `isFormatRaw()`
  Check if this formatter is configured to display raw p-code
  `void`
  `setFontMetrics(FontMetrics metrics)`
  Set font metrics for AttributedString objects
  `void`
  `setOptions(int maxDisplayLines, boolean displayRawPcode)`
  Set general formatting options

  ### Methods inherited from class ghidra.app.util.pcode.AbstractPcodeFormatter

  `formatAddress, formatCallOtherName, formatConstant, formatInput, formatLabelInput, formatMemoryInput, formatOutput, formatSize, formatTemplates, formatUnique, formatVarnode, formatVarnodeNice, formatVarnodeRaw, isLineLabel`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface ghidra.app.util.pcode.PcodeFormatter

  `formatOps, formatOps`

- ## Constructor Details

  - ### AttributedStringPcodeFormatter

    public AttributedStringPcodeFormatter()
    Constructor

- ## Method Details

  - ### setFontMetrics

    public void setFontMetrics(FontMetrics metrics)
    Set font metrics for AttributedString objects
    Parameters:
      `metrics` - the font metrics

  - ### setOptions

    public void setOptions(int maxDisplayLines, boolean displayRawPcode)
    Set general formatting options
    Parameters:
      `maxDisplayLines` - the maximum number of lines to display
      `displayRawPcode` - show raw pcode

  - ### createAppender

    protected ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender createAppender(Language language, boolean indent)
    Description copied from class: `AbstractPcodeFormatter`
    Create the appender for a formatting invocation
    Specified by:
      `createAppender` in class `AbstractPcodeFormatter<List<AttributedString>,ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender>`
    Parameters:
      `language` - the language of the p-code to format
      `indent` - indicates whether each line should be indented to accommodate line labels
    Returns:
      the new appender

  - ### isFormatRaw

    public boolean isFormatRaw()
    Description copied from class: `AbstractPcodeFormatter`
    Check if this formatter is configured to display raw p-code
    Overrides:
      `isFormatRaw` in class `AbstractPcodeFormatter<List<AttributedString>,ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender>`
    Returns:
      true if displaying raw, false otherwise

  - ### formatOpTemplate

    protected AbstractPcodeFormatter.FormatResult formatOpTemplate(ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender appender, OpTpl op)
    Description copied from class: `AbstractPcodeFormatter`
    Format a single op template
    Overrides:
      `formatOpTemplate` in class `AbstractPcodeFormatter<List<AttributedString>,ghidra.app.util.pcode.AttributedStringPcodeFormatter.ToAttributedStringsAppender>`
    Parameters:
      `appender` - the appender to receive the formatted text
      `op` - the template to format
    Returns:
      instructions to continue or terminate. The loop in `AbstractPcodeFormatter.formatTemplates(Language, List)` is terminated if this method returns `AbstractPcodeFormatter.FormatResult.TERMINATE`.